From ce66c5f1b99fe36b5b91e8b59cc75ce8a4e9cba5 Mon Sep 17 00:00:00 2001 From: Jon Skeet Date: Tue, 28 Apr 2015 15:06:59 +0100 Subject: Updated set of unit tests and unit test protos. This commit includes changes to the C#-specific protos, and rebuilt versions of the "stock" protos. The stock protos have been locally updated to have a specific C# namespace, but this is expected to change soon, so hasn't been committed. Four areas are currently not tested: 1) Serialization - we may restore this at some point, possibly optionally. 2) Services - currently nothing is generated for this; will need to see how it interacts with GRPC 3) Fields beginning with _{digit} - see https://github.com/google/protobuf/issues/308 4) Fields with names which conflict with the declaring type in nasty ways - see https://github.com/google/protobuf/issues/309 --- .../TestProtos/UnitTestExtrasFullProtoFile.cs | 2144 -- .../TestProtos/UnitTestExtrasLiteProtoFile.cs | 4226 --- .../TestProtos/UnitTestImportLiteProtoFile.cs | 308 - .../TestProtos/UnitTestImportProtoFile.cs | 346 - .../UnitTestLiteImportNonLiteProtoFile.cs | 324 - .../TestProtos/UnitTestLiteProtoFile.cs | 8948 ----- .../TestProtos/UnitTestProtoFile.cs | 21602 ------------ .../TestProtos/UnitTestRpcInteropLite.cs | 1395 - .../TestProtos/Unittest.cs | 33513 +++++++++++++++++++ .../TestProtos/UnittestExtrasFull.cs | 2141 ++ .../TestProtos/UnittestExtrasLite.cs | 4209 +++ .../TestProtos/UnittestExtrasXmltest.cs | 2277 ++ .../TestProtos/UnittestImport.cs | 347 + .../TestProtos/UnittestImportLite.cs | 309 + .../TestProtos/UnittestImportPublic.cs | 333 + .../TestProtos/UnittestImportPublicLite.cs | 300 + .../TestProtos/UnittestIssues.cs | 3437 ++ .../TestProtos/UnittestLite.cs | 12460 +++++++ .../TestProtos/UnittestLiteImportsNonlite.cs | 325 + 19 files changed, 59651 insertions(+), 39293 deletions(-) delete mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestExtrasFullProtoFile.cs delete mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestExtrasLiteProtoFile.cs delete mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestImportLiteProtoFile.cs delete mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestImportProtoFile.cs delete mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestLiteImportNonLiteProtoFile.cs delete mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestLiteProtoFile.cs delete mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestProtoFile.cs delete mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestRpcInteropLite.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/Unittest.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasFull.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasLite.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasXmltest.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImport.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportLite.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublic.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublicLite.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestIssues.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestLite.cs create mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestLiteImportsNonlite.cs (limited to 'csharp/src/ProtocolBuffersLite.Test/TestProtos') diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestExtrasFullProtoFile.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestExtrasFullProtoFile.cs deleted file mode 100644 index 42ef030d..00000000 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestExtrasFullProtoFile.cs +++ /dev/null @@ -1,2144 +0,0 @@ -// Generated by ProtoGen, Version=2.4.1.555, Culture=neutral, PublicKeyToken=55f7125234beb589. DO NOT EDIT! -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnitTestExtrasFullProtoFile { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.EmployeeId); - } - #endregion - #region Extensions - public const int EmployeeIdFieldNumber = 126; - public static pb::GeneratedExtensionBase EmployeeId; - #endregion - - #region Static variables - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestInteropPerson__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestInteropEmployeeId__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestInteropEmployeeId__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestMissingFieldsA__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestMissingFieldsA__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestMissingFieldsB__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestMissingFieldsB__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__FieldAccessorTable; - #endregion - #region Descriptor - public static pbd::FileDescriptor Descriptor { - get { return descriptor; } - } - private static pbd::FileDescriptor descriptor; - - static UnitTestExtrasFullProtoFile() { - byte[] descriptorData = global::System.Convert.FromBase64String( - string.Concat( - "CiFleHRlc3QvdW5pdHRlc3RfZXh0cmFzX2Z1bGwucHJvdG8SF3Byb3RvYnVm", - "X3VuaXR0ZXN0X2V4dHJhGiRnb29nbGUvcHJvdG9idWYvY3NoYXJwX29wdGlv", - "bnMucHJvdG8i1gMKEVRlc3RJbnRlcm9wUGVyc29uEgwKBG5hbWUYASACKAkS", - "CgoCaWQYAiACKAUSDQoFZW1haWwYAyABKAkSEQoFY29kZXMYCiADKAVCAhAB", - "EkUKBXBob25lGAQgAygLMjYucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEuVGVz", - "dEludGVyb3BQZXJzb24uUGhvbmVOdW1iZXISRwoJYWRkcmVzc2VzGAUgAygK", - "MjQucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEuVGVzdEludGVyb3BQZXJzb24u", - "QWRkcmVzc2VzGmcKC1Bob25lTnVtYmVyEg4KBm51bWJlchgBIAIoCRJICgR0", - "eXBlGAIgASgOMjQucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEuVGVzdEludGVy", - "b3BQZXJzb24uUGhvbmVUeXBlOgRIT01FGlgKCUFkZHJlc3NlcxIPCgdhZGRy", - "ZXNzGAEgAigJEhAKCGFkZHJlc3MyGAIgASgJEgwKBGNpdHkYAyACKAkSDQoF", - "c3RhdGUYBCACKAkSCwoDemlwGAUgAigHIisKCVBob25lVHlwZRIKCgZNT0JJ", - "TEUQABIICgRIT01FEAESCAoEV09SSxACKgUIZBDIASInChVUZXN0SW50ZXJv", - "cEVtcGxveWVlSWQSDgoGbnVtYmVyGAEgAigJIqUBChJUZXN0TWlzc2luZ0Zp", - "ZWxkc0ESDAoEbmFtZRgBIAIoCRIKCgJpZBgCIAIoBRINCgVlbWFpbBgDIAEo", - "CRI/CgV0ZXN0QRgLIAEoCzIwLnByb3RvYnVmX3VuaXR0ZXN0X2V4dHJhLlRl", - "c3RNaXNzaW5nRmllbGRzQS5TdWJBGiUKBFN1YkESDQoFY291bnQYBSACKAUS", - "DgoGdmFsdWVzGAYgAygJIpgBChJUZXN0TWlzc2luZ0ZpZWxkc0ISDAoEbmFt", - "ZRgBIAIoCRIKCgJpZBgCIAIoBRIPCgd3ZWJzaXRlGAQgASgJEj8KBXRlc3RC", - "GAwgASgLMjAucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEuVGVzdE1pc3NpbmdG", - "aWVsZHNCLlN1YkIaFgoEU3ViQhIOCgZ2YWx1ZXMYByADKAk6bwoLZW1wbG95", - "ZWVfaWQSKi5wcm90b2J1Zl91bml0dGVzdF9leHRyYS5UZXN0SW50ZXJvcFBl", - "cnNvbhh+IAIoCzIuLnByb3RvYnVmX3VuaXR0ZXN0X2V4dHJhLlRlc3RJbnRl", - "cm9wRW1wbG95ZWVJZEJaChNjb20uZ29vZ2xlLnByb3RvYnVmSALCPkAKIUdv", - "b2dsZS5Qcm90b2NvbEJ1ZmZlcnMuVGVzdFByb3RvcxIbVW5pdFRlc3RFeHRy", - "YXNGdWxsUHJvdG9GaWxl")); - pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { - descriptor = root; - internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor = Descriptor.MessageTypes[0]; - internal__static_protobuf_unittest_extra_TestInteropPerson__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor, - new string[] { "Name", "Id", "Email", "Codes", "Phone", "Addresses", }); - internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__Descriptor = internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__Descriptor, - new string[] { "Number", "Type", }); - internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__Descriptor = internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor.NestedTypes[1]; - internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__Descriptor, - new string[] { "Address", "Address2", "City", "State", "Zip", }); - internal__static_protobuf_unittest_extra_TestInteropEmployeeId__Descriptor = Descriptor.MessageTypes[1]; - internal__static_protobuf_unittest_extra_TestInteropEmployeeId__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestInteropEmployeeId__Descriptor, - new string[] { "Number", }); - internal__static_protobuf_unittest_extra_TestMissingFieldsA__Descriptor = Descriptor.MessageTypes[2]; - internal__static_protobuf_unittest_extra_TestMissingFieldsA__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestMissingFieldsA__Descriptor, - new string[] { "Name", "Id", "Email", "TestA", }); - internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__Descriptor = internal__static_protobuf_unittest_extra_TestMissingFieldsA__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__Descriptor, - new string[] { "Count", "Values", }); - internal__static_protobuf_unittest_extra_TestMissingFieldsB__Descriptor = Descriptor.MessageTypes[3]; - internal__static_protobuf_unittest_extra_TestMissingFieldsB__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestMissingFieldsB__Descriptor, - new string[] { "Name", "Id", "Website", "TestB", }); - internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__Descriptor = internal__static_protobuf_unittest_extra_TestMissingFieldsB__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__Descriptor, - new string[] { "Values", }); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.EmployeeId = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.Descriptor.Extensions[0]); - pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); - RegisterAllExtensions(registry); - global::Google.ProtocolBuffers.DescriptorProtos.CSharpOptions.RegisterAllExtensions(registry); - return registry; - }; - pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, - new pbd::FileDescriptor[] { - global::Google.ProtocolBuffers.DescriptorProtos.CSharpOptions.Descriptor, - }, assigner); - } - #endregion - - } - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestInteropPerson : pb::ExtendableMessage { - private TestInteropPerson() { } - private static readonly TestInteropPerson defaultInstance = new TestInteropPerson().MakeReadOnly(); - public static TestInteropPerson DefaultInstance { - get { return defaultInstance; } - } - - public override TestInteropPerson DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestInteropPerson ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestInteropPerson__FieldAccessorTable; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - public enum PhoneType { - MOBILE = 0, - HOME = 1, - WORK = 2, - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class PhoneNumber : pb::GeneratedMessage { - private PhoneNumber() { } - private static readonly PhoneNumber defaultInstance = new PhoneNumber().MakeReadOnly(); - public static PhoneNumber DefaultInstance { - get { return defaultInstance; } - } - - public override PhoneNumber DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override PhoneNumber ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__FieldAccessorTable; } - } - - public const int NumberFieldNumber = 1; - private bool hasNumber; - private string number_ = ""; - public bool HasNumber { - get { return hasNumber; } - } - public string Number { - get { return number_; } - } - - public const int TypeFieldNumber = 2; - private bool hasType; - private global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType type_ = global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType.HOME; - public bool HasType { - get { return hasType; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType Type { - get { return type_; } - } - - public static PhoneNumber ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static PhoneNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static PhoneNumber ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static PhoneNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static PhoneNumber ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static PhoneNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static PhoneNumber ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static PhoneNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static PhoneNumber ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static PhoneNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private PhoneNumber MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(PhoneNumber prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(PhoneNumber cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private PhoneNumber result; - - private PhoneNumber PrepareBuilder() { - if (resultIsReadOnly) { - PhoneNumber original = result; - result = new PhoneNumber(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override PhoneNumber MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber.Descriptor; } - } - - public override PhoneNumber DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber.DefaultInstance; } - } - - public override PhoneNumber BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - - public bool HasNumber { - get { return result.hasNumber; } - } - public string Number { - get { return result.Number; } - set { SetNumber(value); } - } - public Builder SetNumber(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasNumber = true; - result.number_ = value; - return this; - } - public Builder ClearNumber() { - PrepareBuilder(); - result.hasNumber = false; - result.number_ = ""; - return this; - } - - public bool HasType { - get { return result.hasType; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType Type { - get { return result.Type; } - set { SetType(value); } - } - public Builder SetType(global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType value) { - PrepareBuilder(); - result.hasType = true; - result.type_ = value; - return this; - } - public Builder ClearType() { - PrepareBuilder(); - result.hasType = false; - result.type_ = global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType.HOME; - return this; - } - } - static PhoneNumber() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Addresses : pb::GeneratedMessage { - private Addresses() { } - private static readonly Addresses defaultInstance = new Addresses().MakeReadOnly(); - public static Addresses DefaultInstance { - get { return defaultInstance; } - } - - public override Addresses DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override Addresses ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__FieldAccessorTable; } - } - - public const int AddressFieldNumber = 1; - private bool hasAddress; - private string address_ = ""; - public bool HasAddress { - get { return hasAddress; } - } - public string Address { - get { return address_; } - } - - public const int Address2FieldNumber = 2; - private bool hasAddress2; - private string address2_ = ""; - public bool HasAddress2 { - get { return hasAddress2; } - } - public string Address2 { - get { return address2_; } - } - - public const int CityFieldNumber = 3; - private bool hasCity; - private string city_ = ""; - public bool HasCity { - get { return hasCity; } - } - public string City { - get { return city_; } - } - - public const int StateFieldNumber = 4; - private bool hasState; - private string state_ = ""; - public bool HasState { - get { return hasState; } - } - public string State { - get { return state_; } - } - - public const int ZipFieldNumber = 5; - private bool hasZip; - private uint zip_; - public bool HasZip { - get { return hasZip; } - } - [global::System.CLSCompliant(false)] - public uint Zip { - get { return zip_; } - } - - public static Addresses ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Addresses ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Addresses ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Addresses ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Addresses ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Addresses ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static Addresses ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static Addresses ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static Addresses ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Addresses ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private Addresses MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Addresses prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Addresses cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Addresses result; - - private Addresses PrepareBuilder() { - if (resultIsReadOnly) { - Addresses original = result; - result = new Addresses(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Addresses MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses.Descriptor; } - } - - public override Addresses DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses.DefaultInstance; } - } - - public override Addresses BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - - public bool HasAddress { - get { return result.hasAddress; } - } - public string Address { - get { return result.Address; } - set { SetAddress(value); } - } - public Builder SetAddress(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasAddress = true; - result.address_ = value; - return this; - } - public Builder ClearAddress() { - PrepareBuilder(); - result.hasAddress = false; - result.address_ = ""; - return this; - } - - public bool HasAddress2 { - get { return result.hasAddress2; } - } - public string Address2 { - get { return result.Address2; } - set { SetAddress2(value); } - } - public Builder SetAddress2(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasAddress2 = true; - result.address2_ = value; - return this; - } - public Builder ClearAddress2() { - PrepareBuilder(); - result.hasAddress2 = false; - result.address2_ = ""; - return this; - } - - public bool HasCity { - get { return result.hasCity; } - } - public string City { - get { return result.City; } - set { SetCity(value); } - } - public Builder SetCity(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasCity = true; - result.city_ = value; - return this; - } - public Builder ClearCity() { - PrepareBuilder(); - result.hasCity = false; - result.city_ = ""; - return this; - } - - public bool HasState { - get { return result.hasState; } - } - public string State { - get { return result.State; } - set { SetState(value); } - } - public Builder SetState(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasState = true; - result.state_ = value; - return this; - } - public Builder ClearState() { - PrepareBuilder(); - result.hasState = false; - result.state_ = ""; - return this; - } - - public bool HasZip { - get { return result.hasZip; } - } - [global::System.CLSCompliant(false)] - public uint Zip { - get { return result.Zip; } - set { SetZip(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetZip(uint value) { - PrepareBuilder(); - result.hasZip = true; - result.zip_ = value; - return this; - } - public Builder ClearZip() { - PrepareBuilder(); - result.hasZip = false; - result.zip_ = 0; - return this; - } - } - static Addresses() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.Descriptor, null); - } - } - - } - #endregion - - public const int NameFieldNumber = 1; - private bool hasName; - private string name_ = ""; - public bool HasName { - get { return hasName; } - } - public string Name { - get { return name_; } - } - - public const int IdFieldNumber = 2; - private bool hasId; - private int id_; - public bool HasId { - get { return hasId; } - } - public int Id { - get { return id_; } - } - - public const int EmailFieldNumber = 3; - private bool hasEmail; - private string email_ = ""; - public bool HasEmail { - get { return hasEmail; } - } - public string Email { - get { return email_; } - } - - public const int CodesFieldNumber = 10; - private pbc::PopsicleList codes_ = new pbc::PopsicleList(); - public scg::IList CodesList { - get { return pbc::Lists.AsReadOnly(codes_); } - } - public int CodesCount { - get { return codes_.Count; } - } - public int GetCodes(int index) { - return codes_[index]; - } - - public const int PhoneFieldNumber = 4; - private pbc::PopsicleList phone_ = new pbc::PopsicleList(); - public scg::IList PhoneList { - get { return phone_; } - } - public int PhoneCount { - get { return phone_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber GetPhone(int index) { - return phone_[index]; - } - - public const int AddressesFieldNumber = 5; - private pbc::PopsicleList addresses_ = new pbc::PopsicleList(); - public scg::IList AddressesList { - get { return addresses_; } - } - public int AddressesCount { - get { return addresses_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses GetAddresses(int index) { - return addresses_[index]; - } - - public static TestInteropPerson ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestInteropPerson ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestInteropPerson ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestInteropPerson ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestInteropPerson ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestInteropPerson ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestInteropPerson ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestInteropPerson ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestInteropPerson ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestInteropPerson ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestInteropPerson MakeReadOnly() { - codes_.MakeReadOnly(); - phone_.MakeReadOnly(); - addresses_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestInteropPerson prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestInteropPerson cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestInteropPerson result; - - private TestInteropPerson PrepareBuilder() { - if (resultIsReadOnly) { - TestInteropPerson original = result; - result = new TestInteropPerson(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestInteropPerson MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Descriptor; } - } - - public override TestInteropPerson DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.DefaultInstance; } - } - - public override TestInteropPerson BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - - public bool HasName { - get { return result.hasName; } - } - public string Name { - get { return result.Name; } - set { SetName(value); } - } - public Builder SetName(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasName = true; - result.name_ = value; - return this; - } - public Builder ClearName() { - PrepareBuilder(); - result.hasName = false; - result.name_ = ""; - return this; - } - - public bool HasId { - get { return result.hasId; } - } - public int Id { - get { return result.Id; } - set { SetId(value); } - } - public Builder SetId(int value) { - PrepareBuilder(); - result.hasId = true; - result.id_ = value; - return this; - } - public Builder ClearId() { - PrepareBuilder(); - result.hasId = false; - result.id_ = 0; - return this; - } - - public bool HasEmail { - get { return result.hasEmail; } - } - public string Email { - get { return result.Email; } - set { SetEmail(value); } - } - public Builder SetEmail(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasEmail = true; - result.email_ = value; - return this; - } - public Builder ClearEmail() { - PrepareBuilder(); - result.hasEmail = false; - result.email_ = ""; - return this; - } - - public pbc::IPopsicleList CodesList { - get { return PrepareBuilder().codes_; } - } - public int CodesCount { - get { return result.CodesCount; } - } - public int GetCodes(int index) { - return result.GetCodes(index); - } - public Builder SetCodes(int index, int value) { - PrepareBuilder(); - result.codes_[index] = value; - return this; - } - public Builder AddCodes(int value) { - PrepareBuilder(); - result.codes_.Add(value); - return this; - } - public Builder AddRangeCodes(scg::IEnumerable values) { - PrepareBuilder(); - result.codes_.Add(values); - return this; - } - public Builder ClearCodes() { - PrepareBuilder(); - result.codes_.Clear(); - return this; - } - - public pbc::IPopsicleList PhoneList { - get { return PrepareBuilder().phone_; } - } - public int PhoneCount { - get { return result.PhoneCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber GetPhone(int index) { - return result.GetPhone(index); - } - public Builder SetPhone(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.phone_[index] = value; - return this; - } - public Builder SetPhone(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.phone_[index] = builderForValue.Build(); - return this; - } - public Builder AddPhone(global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.phone_.Add(value); - return this; - } - public Builder AddPhone(global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.phone_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangePhone(scg::IEnumerable values) { - PrepareBuilder(); - result.phone_.Add(values); - return this; - } - public Builder ClearPhone() { - PrepareBuilder(); - result.phone_.Clear(); - return this; - } - - public pbc::IPopsicleList AddressesList { - get { return PrepareBuilder().addresses_; } - } - public int AddressesCount { - get { return result.AddressesCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses GetAddresses(int index) { - return result.GetAddresses(index); - } - public Builder SetAddresses(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.addresses_[index] = value; - return this; - } - public Builder SetAddresses(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.addresses_[index] = builderForValue.Build(); - return this; - } - public Builder AddAddresses(global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.addresses_.Add(value); - return this; - } - public Builder AddAddresses(global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.addresses_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeAddresses(scg::IEnumerable values) { - PrepareBuilder(); - result.addresses_.Add(values); - return this; - } - public Builder ClearAddresses() { - PrepareBuilder(); - result.addresses_.Clear(); - return this; - } - } - static TestInteropPerson() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestInteropEmployeeId : pb::GeneratedMessage { - private TestInteropEmployeeId() { } - private static readonly TestInteropEmployeeId defaultInstance = new TestInteropEmployeeId().MakeReadOnly(); - public static TestInteropEmployeeId DefaultInstance { - get { return defaultInstance; } - } - - public override TestInteropEmployeeId DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestInteropEmployeeId ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestInteropEmployeeId__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestInteropEmployeeId__FieldAccessorTable; } - } - - public const int NumberFieldNumber = 1; - private bool hasNumber; - private string number_ = ""; - public bool HasNumber { - get { return hasNumber; } - } - public string Number { - get { return number_; } - } - - public static TestInteropEmployeeId ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestInteropEmployeeId ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestInteropEmployeeId ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestInteropEmployeeId ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestInteropEmployeeId ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestInteropEmployeeId ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestInteropEmployeeId ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestInteropEmployeeId ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestInteropEmployeeId ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestInteropEmployeeId ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestInteropEmployeeId MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestInteropEmployeeId prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestInteropEmployeeId cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestInteropEmployeeId result; - - private TestInteropEmployeeId PrepareBuilder() { - if (resultIsReadOnly) { - TestInteropEmployeeId original = result; - result = new TestInteropEmployeeId(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestInteropEmployeeId MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropEmployeeId.Descriptor; } - } - - public override TestInteropEmployeeId DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropEmployeeId.DefaultInstance; } - } - - public override TestInteropEmployeeId BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - - public bool HasNumber { - get { return result.hasNumber; } - } - public string Number { - get { return result.Number; } - set { SetNumber(value); } - } - public Builder SetNumber(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasNumber = true; - result.number_ = value; - return this; - } - public Builder ClearNumber() { - PrepareBuilder(); - result.hasNumber = false; - result.number_ = ""; - return this; - } - } - static TestInteropEmployeeId() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestMissingFieldsA : pb::GeneratedMessage { - private TestMissingFieldsA() { } - private static readonly TestMissingFieldsA defaultInstance = new TestMissingFieldsA().MakeReadOnly(); - public static TestMissingFieldsA DefaultInstance { - get { return defaultInstance; } - } - - public override TestMissingFieldsA DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestMissingFieldsA ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestMissingFieldsA__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestMissingFieldsA__FieldAccessorTable; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class SubA : pb::GeneratedMessage { - private SubA() { } - private static readonly SubA defaultInstance = new SubA().MakeReadOnly(); - public static SubA DefaultInstance { - get { return defaultInstance; } - } - - public override SubA DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override SubA ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__FieldAccessorTable; } - } - - public const int CountFieldNumber = 5; - private bool hasCount; - private int count_; - public bool HasCount { - get { return hasCount; } - } - public int Count { - get { return count_; } - } - - public const int ValuesFieldNumber = 6; - private pbc::PopsicleList values_ = new pbc::PopsicleList(); - public scg::IList ValuesList { - get { return pbc::Lists.AsReadOnly(values_); } - } - public int ValuesCount { - get { return values_.Count; } - } - public string GetValues(int index) { - return values_[index]; - } - - public static SubA ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SubA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SubA ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SubA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SubA ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SubA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static SubA ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static SubA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static SubA ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SubA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private SubA MakeReadOnly() { - values_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(SubA prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(SubA cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private SubA result; - - private SubA PrepareBuilder() { - if (resultIsReadOnly) { - SubA original = result; - result = new SubA(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override SubA MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.Descriptor; } - } - - public override SubA DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.DefaultInstance; } - } - - public override SubA BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - - public bool HasCount { - get { return result.hasCount; } - } - public int Count { - get { return result.Count; } - set { SetCount(value); } - } - public Builder SetCount(int value) { - PrepareBuilder(); - result.hasCount = true; - result.count_ = value; - return this; - } - public Builder ClearCount() { - PrepareBuilder(); - result.hasCount = false; - result.count_ = 0; - return this; - } - - public pbc::IPopsicleList ValuesList { - get { return PrepareBuilder().values_; } - } - public int ValuesCount { - get { return result.ValuesCount; } - } - public string GetValues(int index) { - return result.GetValues(index); - } - public Builder SetValues(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.values_[index] = value; - return this; - } - public Builder AddValues(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.values_.Add(value); - return this; - } - public Builder AddRangeValues(scg::IEnumerable values) { - PrepareBuilder(); - result.values_.Add(values); - return this; - } - public Builder ClearValues() { - PrepareBuilder(); - result.values_.Clear(); - return this; - } - } - static SubA() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.Descriptor, null); - } - } - - } - #endregion - - public const int NameFieldNumber = 1; - private bool hasName; - private string name_ = ""; - public bool HasName { - get { return hasName; } - } - public string Name { - get { return name_; } - } - - public const int IdFieldNumber = 2; - private bool hasId; - private int id_; - public bool HasId { - get { return hasId; } - } - public int Id { - get { return id_; } - } - - public const int EmailFieldNumber = 3; - private bool hasEmail; - private string email_ = ""; - public bool HasEmail { - get { return hasEmail; } - } - public string Email { - get { return email_; } - } - - public const int TestAFieldNumber = 11; - private bool hasTestA; - private global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA testA_; - public bool HasTestA { - get { return hasTestA; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA TestA { - get { return testA_ ?? global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.DefaultInstance; } - } - - public static TestMissingFieldsA ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMissingFieldsA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMissingFieldsA ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMissingFieldsA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMissingFieldsA ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMissingFieldsA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestMissingFieldsA ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestMissingFieldsA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestMissingFieldsA ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMissingFieldsA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestMissingFieldsA MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestMissingFieldsA prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestMissingFieldsA cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestMissingFieldsA result; - - private TestMissingFieldsA PrepareBuilder() { - if (resultIsReadOnly) { - TestMissingFieldsA original = result; - result = new TestMissingFieldsA(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestMissingFieldsA MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Descriptor; } - } - - public override TestMissingFieldsA DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.DefaultInstance; } - } - - public override TestMissingFieldsA BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - - public bool HasName { - get { return result.hasName; } - } - public string Name { - get { return result.Name; } - set { SetName(value); } - } - public Builder SetName(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasName = true; - result.name_ = value; - return this; - } - public Builder ClearName() { - PrepareBuilder(); - result.hasName = false; - result.name_ = ""; - return this; - } - - public bool HasId { - get { return result.hasId; } - } - public int Id { - get { return result.Id; } - set { SetId(value); } - } - public Builder SetId(int value) { - PrepareBuilder(); - result.hasId = true; - result.id_ = value; - return this; - } - public Builder ClearId() { - PrepareBuilder(); - result.hasId = false; - result.id_ = 0; - return this; - } - - public bool HasEmail { - get { return result.hasEmail; } - } - public string Email { - get { return result.Email; } - set { SetEmail(value); } - } - public Builder SetEmail(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasEmail = true; - result.email_ = value; - return this; - } - public Builder ClearEmail() { - PrepareBuilder(); - result.hasEmail = false; - result.email_ = ""; - return this; - } - - public bool HasTestA { - get { return result.hasTestA; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA TestA { - get { return result.TestA; } - set { SetTestA(value); } - } - public Builder SetTestA(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasTestA = true; - result.testA_ = value; - return this; - } - public Builder SetTestA(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasTestA = true; - result.testA_ = builderForValue.Build(); - return this; - } - public Builder MergeTestA(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasTestA && - result.testA_ != global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.DefaultInstance) { - result.testA_ = global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.CreateBuilder(result.testA_).MergeFrom(value).BuildPartial(); - } else { - result.testA_ = value; - } - result.hasTestA = true; - return this; - } - public Builder ClearTestA() { - PrepareBuilder(); - result.hasTestA = false; - result.testA_ = null; - return this; - } - } - static TestMissingFieldsA() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestMissingFieldsB : pb::GeneratedMessage { - private TestMissingFieldsB() { } - private static readonly TestMissingFieldsB defaultInstance = new TestMissingFieldsB().MakeReadOnly(); - public static TestMissingFieldsB DefaultInstance { - get { return defaultInstance; } - } - - public override TestMissingFieldsB DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestMissingFieldsB ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestMissingFieldsB__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestMissingFieldsB__FieldAccessorTable; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class SubB : pb::GeneratedMessage { - private SubB() { } - private static readonly SubB defaultInstance = new SubB().MakeReadOnly(); - public static SubB DefaultInstance { - get { return defaultInstance; } - } - - public override SubB DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override SubB ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__FieldAccessorTable; } - } - - public const int ValuesFieldNumber = 7; - private pbc::PopsicleList values_ = new pbc::PopsicleList(); - public scg::IList ValuesList { - get { return pbc::Lists.AsReadOnly(values_); } - } - public int ValuesCount { - get { return values_.Count; } - } - public string GetValues(int index) { - return values_[index]; - } - - public static SubB ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SubB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SubB ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SubB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SubB ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SubB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static SubB ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static SubB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static SubB ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SubB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private SubB MakeReadOnly() { - values_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(SubB prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(SubB cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private SubB result; - - private SubB PrepareBuilder() { - if (resultIsReadOnly) { - SubB original = result; - result = new SubB(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override SubB MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.Descriptor; } - } - - public override SubB DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.DefaultInstance; } - } - - public override SubB BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - - public pbc::IPopsicleList ValuesList { - get { return PrepareBuilder().values_; } - } - public int ValuesCount { - get { return result.ValuesCount; } - } - public string GetValues(int index) { - return result.GetValues(index); - } - public Builder SetValues(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.values_[index] = value; - return this; - } - public Builder AddValues(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.values_.Add(value); - return this; - } - public Builder AddRangeValues(scg::IEnumerable values) { - PrepareBuilder(); - result.values_.Add(values); - return this; - } - public Builder ClearValues() { - PrepareBuilder(); - result.values_.Clear(); - return this; - } - } - static SubB() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.Descriptor, null); - } - } - - } - #endregion - - public const int NameFieldNumber = 1; - private bool hasName; - private string name_ = ""; - public bool HasName { - get { return hasName; } - } - public string Name { - get { return name_; } - } - - public const int IdFieldNumber = 2; - private bool hasId; - private int id_; - public bool HasId { - get { return hasId; } - } - public int Id { - get { return id_; } - } - - public const int WebsiteFieldNumber = 4; - private bool hasWebsite; - private string website_ = ""; - public bool HasWebsite { - get { return hasWebsite; } - } - public string Website { - get { return website_; } - } - - public const int TestBFieldNumber = 12; - private bool hasTestB; - private global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB testB_; - public bool HasTestB { - get { return hasTestB; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB TestB { - get { return testB_ ?? global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.DefaultInstance; } - } - - public static TestMissingFieldsB ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMissingFieldsB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMissingFieldsB ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMissingFieldsB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMissingFieldsB ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMissingFieldsB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestMissingFieldsB ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestMissingFieldsB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestMissingFieldsB ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMissingFieldsB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestMissingFieldsB MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestMissingFieldsB prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestMissingFieldsB cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestMissingFieldsB result; - - private TestMissingFieldsB PrepareBuilder() { - if (resultIsReadOnly) { - TestMissingFieldsB original = result; - result = new TestMissingFieldsB(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestMissingFieldsB MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Descriptor; } - } - - public override TestMissingFieldsB DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.DefaultInstance; } - } - - public override TestMissingFieldsB BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - - public bool HasName { - get { return result.hasName; } - } - public string Name { - get { return result.Name; } - set { SetName(value); } - } - public Builder SetName(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasName = true; - result.name_ = value; - return this; - } - public Builder ClearName() { - PrepareBuilder(); - result.hasName = false; - result.name_ = ""; - return this; - } - - public bool HasId { - get { return result.hasId; } - } - public int Id { - get { return result.Id; } - set { SetId(value); } - } - public Builder SetId(int value) { - PrepareBuilder(); - result.hasId = true; - result.id_ = value; - return this; - } - public Builder ClearId() { - PrepareBuilder(); - result.hasId = false; - result.id_ = 0; - return this; - } - - public bool HasWebsite { - get { return result.hasWebsite; } - } - public string Website { - get { return result.Website; } - set { SetWebsite(value); } - } - public Builder SetWebsite(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasWebsite = true; - result.website_ = value; - return this; - } - public Builder ClearWebsite() { - PrepareBuilder(); - result.hasWebsite = false; - result.website_ = ""; - return this; - } - - public bool HasTestB { - get { return result.hasTestB; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB TestB { - get { return result.TestB; } - set { SetTestB(value); } - } - public Builder SetTestB(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasTestB = true; - result.testB_ = value; - return this; - } - public Builder SetTestB(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasTestB = true; - result.testB_ = builderForValue.Build(); - return this; - } - public Builder MergeTestB(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasTestB && - result.testB_ != global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.DefaultInstance) { - result.testB_ = global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.CreateBuilder(result.testB_).MergeFrom(value).BuildPartial(); - } else { - result.testB_ = value; - } - result.hasTestB = true; - return this; - } - public Builder ClearTestB() { - PrepareBuilder(); - result.hasTestB = false; - result.testB_ = null; - return this; - } - } - static TestMissingFieldsB() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasFullProtoFile.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestExtrasLiteProtoFile.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestExtrasLiteProtoFile.cs deleted file mode 100644 index caeb5ba9..00000000 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestExtrasLiteProtoFile.cs +++ /dev/null @@ -1,4226 +0,0 @@ -// Generated by ProtoGen, Version=2.4.1.555, Culture=neutral, PublicKeyToken=55f7125234beb589. DO NOT EDIT! -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnitTestExtrasLiteProtoFile { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.EmployeeIdLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedInt32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedInt64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedUint32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedUint64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSint32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSint64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedFixed32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedFixed64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSfixed32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSfixed64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedFloatExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedDoubleExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedBoolExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedEnumExtensionLite); - } - #endregion - #region Extensions - public const int EmployeeIdLiteFieldNumber = 126; - public static pb::GeneratedExtensionLite EmployeeIdLite; - public const int UnpackedInt32ExtensionLiteFieldNumber = 90; - public static pb::GeneratedRepeatExtensionLite UnpackedInt32ExtensionLite; - public const int UnpackedInt64ExtensionLiteFieldNumber = 91; - public static pb::GeneratedRepeatExtensionLite UnpackedInt64ExtensionLite; - public const int UnpackedUint32ExtensionLiteFieldNumber = 92; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite UnpackedUint32ExtensionLite; - public const int UnpackedUint64ExtensionLiteFieldNumber = 93; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite UnpackedUint64ExtensionLite; - public const int UnpackedSint32ExtensionLiteFieldNumber = 94; - public static pb::GeneratedRepeatExtensionLite UnpackedSint32ExtensionLite; - public const int UnpackedSint64ExtensionLiteFieldNumber = 95; - public static pb::GeneratedRepeatExtensionLite UnpackedSint64ExtensionLite; - public const int UnpackedFixed32ExtensionLiteFieldNumber = 96; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite UnpackedFixed32ExtensionLite; - public const int UnpackedFixed64ExtensionLiteFieldNumber = 97; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite UnpackedFixed64ExtensionLite; - public const int UnpackedSfixed32ExtensionLiteFieldNumber = 98; - public static pb::GeneratedRepeatExtensionLite UnpackedSfixed32ExtensionLite; - public const int UnpackedSfixed64ExtensionLiteFieldNumber = 99; - public static pb::GeneratedRepeatExtensionLite UnpackedSfixed64ExtensionLite; - public const int UnpackedFloatExtensionLiteFieldNumber = 100; - public static pb::GeneratedRepeatExtensionLite UnpackedFloatExtensionLite; - public const int UnpackedDoubleExtensionLiteFieldNumber = 101; - public static pb::GeneratedRepeatExtensionLite UnpackedDoubleExtensionLite; - public const int UnpackedBoolExtensionLiteFieldNumber = 102; - public static pb::GeneratedRepeatExtensionLite UnpackedBoolExtensionLite; - public const int UnpackedEnumExtensionLiteFieldNumber = 103; - public static pb::GeneratedRepeatExtensionLite UnpackedEnumExtensionLite; - #endregion - - #region Static variables - #endregion - #region Extensions - internal static readonly object Descriptor; - static UnitTestExtrasLiteProtoFile() { - Descriptor = null; - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.EmployeeIdLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest_extra.employee_id_lite", - global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.TestInteropEmployeeIdLite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.EmployeeIdLiteFieldNumber, - pbd::FieldType.Message); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedInt32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_int32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedInt32ExtensionLiteFieldNumber, - pbd::FieldType.Int32, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedInt64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_int64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedInt64ExtensionLiteFieldNumber, - pbd::FieldType.Int64, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedUint32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_uint32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedUint32ExtensionLiteFieldNumber, - pbd::FieldType.UInt32, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedUint64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_uint64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedUint64ExtensionLiteFieldNumber, - pbd::FieldType.UInt64, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSint32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_sint32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSint32ExtensionLiteFieldNumber, - pbd::FieldType.SInt32, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSint64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_sint64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSint64ExtensionLiteFieldNumber, - pbd::FieldType.SInt64, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedFixed32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_fixed32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedFixed32ExtensionLiteFieldNumber, - pbd::FieldType.Fixed32, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedFixed64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_fixed64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedFixed64ExtensionLiteFieldNumber, - pbd::FieldType.Fixed64, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSfixed32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_sfixed32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSfixed32ExtensionLiteFieldNumber, - pbd::FieldType.SFixed32, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSfixed64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_sfixed64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedSfixed64ExtensionLiteFieldNumber, - pbd::FieldType.SFixed64, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedFloatExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_float_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedFloatExtensionLiteFieldNumber, - pbd::FieldType.Float, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedDoubleExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_double_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedDoubleExtensionLiteFieldNumber, - pbd::FieldType.Double, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedBoolExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_bool_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedBoolExtensionLiteFieldNumber, - pbd::FieldType.Bool, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedEnumExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest_extra.unpacked_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.UnpackedEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum, - false); - } - #endregion - - } - #region Enums - public enum ExtraEnum { - DEFAULT = 10, - EXLITE_FOO = 7, - EXLITE_BAR = 8, - EXLITE_BAZ = 9, - } - - public enum UnpackedTypesForeignEnumLite { - FOREIGN_LITE_FOO = 4, - FOREIGN_LITE_BAR = 5, - FOREIGN_LITE_BAZ = 6, - } - - #endregion - - #region Messages - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestRequiredLite : pb::GeneratedMessageLite { - private TestRequiredLite() { } - private static readonly TestRequiredLite defaultInstance = new TestRequiredLite().MakeReadOnly(); - private static readonly string[] _testRequiredLiteFieldNames = new string[] { "d", "en" }; - private static readonly uint[] _testRequiredLiteFieldTags = new uint[] { 8, 16 }; - public static TestRequiredLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestRequiredLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestRequiredLite ThisMessage { - get { return this; } - } - - public const int DFieldNumber = 1; - private bool hasD; - private int d_; - public bool HasD { - get { return hasD; } - } - public int D { - get { return d_; } - } - - public const int EnFieldNumber = 2; - private bool hasEn; - private global::Google.ProtocolBuffers.TestProtos.ExtraEnum en_ = global::Google.ProtocolBuffers.TestProtos.ExtraEnum.DEFAULT; - public bool HasEn { - get { return hasEn; } - } - public global::Google.ProtocolBuffers.TestProtos.ExtraEnum En { - get { return en_; } - } - - public override bool IsInitialized { - get { - if (!hasD) return false; - if (!hasEn) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testRequiredLiteFieldNames; - if (hasD) { - output.WriteInt32(1, field_names[0], D); - } - if (hasEn) { - output.WriteEnum(2, field_names[1], (int) En, En); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasD) { - size += pb::CodedOutputStream.ComputeInt32Size(1, D); - } - if (hasEn) { - size += pb::CodedOutputStream.ComputeEnumSize(2, (int) En); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasD) hash ^= d_.GetHashCode(); - if (hasEn) hash ^= en_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestRequiredLite other = obj as TestRequiredLite; - if (other == null) return false; - if (hasD != other.hasD || (hasD && !d_.Equals(other.d_))) return false; - if (hasEn != other.hasEn || (hasEn && !en_.Equals(other.en_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("d", hasD, d_, writer); - PrintField("en", hasEn, en_, writer); - } - #endregion - - public static TestRequiredLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequiredLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequiredLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequiredLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequiredLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequiredLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestRequiredLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestRequiredLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestRequiredLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequiredLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestRequiredLite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestRequiredLite prototype) { - return new Builder(prototype); - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestRequiredLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestRequiredLite result; - - private TestRequiredLite PrepareBuilder() { - if (resultIsReadOnly) { - TestRequiredLite original = result; - result = new TestRequiredLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestRequiredLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestRequiredLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredLite.DefaultInstance; } - } - - public override TestRequiredLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestRequiredLite) { - return MergeFrom((TestRequiredLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestRequiredLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredLite.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasD) { - D = other.D; - } - if (other.HasEn) { - En = other.En; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testRequiredLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testRequiredLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasD = input.ReadInt32(ref result.d_); - break; - } - case 16: { - object unknown; - if(input.ReadEnum(ref result.en_, out unknown)) { - result.hasEn = true; - } else if(unknown is int) { - } - break; - } - } - } - - return this; - } - - - public bool HasD { - get { return result.hasD; } - } - public int D { - get { return result.D; } - set { SetD(value); } - } - public Builder SetD(int value) { - PrepareBuilder(); - result.hasD = true; - result.d_ = value; - return this; - } - public Builder ClearD() { - PrepareBuilder(); - result.hasD = false; - result.d_ = 0; - return this; - } - - public bool HasEn { - get { return result.hasEn; } - } - public global::Google.ProtocolBuffers.TestProtos.ExtraEnum En { - get { return result.En; } - set { SetEn(value); } - } - public Builder SetEn(global::Google.ProtocolBuffers.TestProtos.ExtraEnum value) { - PrepareBuilder(); - result.hasEn = true; - result.en_ = value; - return this; - } - public Builder ClearEn() { - PrepareBuilder(); - result.hasEn = false; - result.en_ = global::Google.ProtocolBuffers.TestProtos.ExtraEnum.DEFAULT; - return this; - } - } - static TestRequiredLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.Descriptor, null); - } - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestInteropPersonLite : pb::ExtendableMessageLite { - private TestInteropPersonLite() { } - private static readonly TestInteropPersonLite defaultInstance = new TestInteropPersonLite().MakeReadOnly(); - private static readonly string[] _testInteropPersonLiteFieldNames = new string[] { "addresses", "codes", "email", "id", "name", "phone" }; - private static readonly uint[] _testInteropPersonLiteFieldTags = new uint[] { 43, 82, 26, 16, 10, 34 }; - public static TestInteropPersonLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestInteropPersonLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestInteropPersonLite ThisMessage { - get { return this; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - public enum PhoneType { - MOBILE = 0, - HOME = 1, - WORK = 2, - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class PhoneNumber : pb::GeneratedMessageLite { - private PhoneNumber() { } - private static readonly PhoneNumber defaultInstance = new PhoneNumber().MakeReadOnly(); - private static readonly string[] _phoneNumberFieldNames = new string[] { "number", "type" }; - private static readonly uint[] _phoneNumberFieldTags = new uint[] { 10, 16 }; - public static PhoneNumber DefaultInstance { - get { return defaultInstance; } - } - - public override PhoneNumber DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override PhoneNumber ThisMessage { - get { return this; } - } - - public const int NumberFieldNumber = 1; - private bool hasNumber; - private string number_ = ""; - public bool HasNumber { - get { return hasNumber; } - } - public string Number { - get { return number_; } - } - - public const int TypeFieldNumber = 2; - private bool hasType; - private global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType type_ = global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType.HOME; - public bool HasType { - get { return hasType; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType Type { - get { return type_; } - } - - public override bool IsInitialized { - get { - if (!hasNumber) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _phoneNumberFieldNames; - if (hasNumber) { - output.WriteString(1, field_names[0], Number); - } - if (hasType) { - output.WriteEnum(2, field_names[1], (int) Type, Type); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasNumber) { - size += pb::CodedOutputStream.ComputeStringSize(1, Number); - } - if (hasType) { - size += pb::CodedOutputStream.ComputeEnumSize(2, (int) Type); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasNumber) hash ^= number_.GetHashCode(); - if (hasType) hash ^= type_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - PhoneNumber other = obj as PhoneNumber; - if (other == null) return false; - if (hasNumber != other.hasNumber || (hasNumber && !number_.Equals(other.number_))) return false; - if (hasType != other.hasType || (hasType && !type_.Equals(other.type_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("number", hasNumber, number_, writer); - PrintField("type", hasType, type_, writer); - } - #endregion - - public static PhoneNumber ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static PhoneNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static PhoneNumber ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static PhoneNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static PhoneNumber ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static PhoneNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static PhoneNumber ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static PhoneNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static PhoneNumber ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static PhoneNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private PhoneNumber MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(PhoneNumber prototype) { - return new Builder(prototype); - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(PhoneNumber cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private PhoneNumber result; - - private PhoneNumber PrepareBuilder() { - if (resultIsReadOnly) { - PhoneNumber original = result; - result = new PhoneNumber(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override PhoneNumber MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override PhoneNumber DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber.DefaultInstance; } - } - - public override PhoneNumber BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is PhoneNumber) { - return MergeFrom((PhoneNumber) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(PhoneNumber other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasNumber) { - Number = other.Number; - } - if (other.HasType) { - Type = other.Type; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_phoneNumberFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _phoneNumberFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasNumber = input.ReadString(ref result.number_); - break; - } - case 16: { - object unknown; - if(input.ReadEnum(ref result.type_, out unknown)) { - result.hasType = true; - } else if(unknown is int) { - } - break; - } - } - } - - return this; - } - - - public bool HasNumber { - get { return result.hasNumber; } - } - public string Number { - get { return result.Number; } - set { SetNumber(value); } - } - public Builder SetNumber(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasNumber = true; - result.number_ = value; - return this; - } - public Builder ClearNumber() { - PrepareBuilder(); - result.hasNumber = false; - result.number_ = ""; - return this; - } - - public bool HasType { - get { return result.hasType; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType Type { - get { return result.Type; } - set { SetType(value); } - } - public Builder SetType(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType value) { - PrepareBuilder(); - result.hasType = true; - result.type_ = value; - return this; - } - public Builder ClearType() { - PrepareBuilder(); - result.hasType = false; - result.type_ = global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType.HOME; - return this; - } - } - static PhoneNumber() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.Descriptor, null); - } - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Addresses : pb::GeneratedMessageLite { - private Addresses() { } - private static readonly Addresses defaultInstance = new Addresses().MakeReadOnly(); - private static readonly string[] _addressesFieldNames = new string[] { "address", "address2", "city", "state", "zip" }; - private static readonly uint[] _addressesFieldTags = new uint[] { 10, 18, 26, 34, 45 }; - public static Addresses DefaultInstance { - get { return defaultInstance; } - } - - public override Addresses DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override Addresses ThisMessage { - get { return this; } - } - - public const int AddressFieldNumber = 1; - private bool hasAddress; - private string address_ = ""; - public bool HasAddress { - get { return hasAddress; } - } - public string Address { - get { return address_; } - } - - public const int Address2FieldNumber = 2; - private bool hasAddress2; - private string address2_ = ""; - public bool HasAddress2 { - get { return hasAddress2; } - } - public string Address2 { - get { return address2_; } - } - - public const int CityFieldNumber = 3; - private bool hasCity; - private string city_ = ""; - public bool HasCity { - get { return hasCity; } - } - public string City { - get { return city_; } - } - - public const int StateFieldNumber = 4; - private bool hasState; - private string state_ = ""; - public bool HasState { - get { return hasState; } - } - public string State { - get { return state_; } - } - - public const int ZipFieldNumber = 5; - private bool hasZip; - private uint zip_; - public bool HasZip { - get { return hasZip; } - } - [global::System.CLSCompliant(false)] - public uint Zip { - get { return zip_; } - } - - public override bool IsInitialized { - get { - if (!hasAddress) return false; - if (!hasCity) return false; - if (!hasState) return false; - if (!hasZip) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _addressesFieldNames; - if (hasAddress) { - output.WriteString(1, field_names[0], Address); - } - if (hasAddress2) { - output.WriteString(2, field_names[1], Address2); - } - if (hasCity) { - output.WriteString(3, field_names[2], City); - } - if (hasState) { - output.WriteString(4, field_names[3], State); - } - if (hasZip) { - output.WriteFixed32(5, field_names[4], Zip); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasAddress) { - size += pb::CodedOutputStream.ComputeStringSize(1, Address); - } - if (hasAddress2) { - size += pb::CodedOutputStream.ComputeStringSize(2, Address2); - } - if (hasCity) { - size += pb::CodedOutputStream.ComputeStringSize(3, City); - } - if (hasState) { - size += pb::CodedOutputStream.ComputeStringSize(4, State); - } - if (hasZip) { - size += pb::CodedOutputStream.ComputeFixed32Size(5, Zip); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasAddress) hash ^= address_.GetHashCode(); - if (hasAddress2) hash ^= address2_.GetHashCode(); - if (hasCity) hash ^= city_.GetHashCode(); - if (hasState) hash ^= state_.GetHashCode(); - if (hasZip) hash ^= zip_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - Addresses other = obj as Addresses; - if (other == null) return false; - if (hasAddress != other.hasAddress || (hasAddress && !address_.Equals(other.address_))) return false; - if (hasAddress2 != other.hasAddress2 || (hasAddress2 && !address2_.Equals(other.address2_))) return false; - if (hasCity != other.hasCity || (hasCity && !city_.Equals(other.city_))) return false; - if (hasState != other.hasState || (hasState && !state_.Equals(other.state_))) return false; - if (hasZip != other.hasZip || (hasZip && !zip_.Equals(other.zip_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("address", hasAddress, address_, writer); - PrintField("address2", hasAddress2, address2_, writer); - PrintField("city", hasCity, city_, writer); - PrintField("state", hasState, state_, writer); - PrintField("zip", hasZip, zip_, writer); - } - #endregion - - public static Addresses ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Addresses ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Addresses ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Addresses ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Addresses ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Addresses ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static Addresses ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static Addresses ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static Addresses ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Addresses ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private Addresses MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Addresses prototype) { - return new Builder(prototype); - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Addresses cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Addresses result; - - private Addresses PrepareBuilder() { - if (resultIsReadOnly) { - Addresses original = result; - result = new Addresses(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Addresses MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override Addresses DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses.DefaultInstance; } - } - - public override Addresses BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is Addresses) { - return MergeFrom((Addresses) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(Addresses other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasAddress) { - Address = other.Address; - } - if (other.HasAddress2) { - Address2 = other.Address2; - } - if (other.HasCity) { - City = other.City; - } - if (other.HasState) { - State = other.State; - } - if (other.HasZip) { - Zip = other.Zip; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_addressesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _addressesFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasAddress = input.ReadString(ref result.address_); - break; - } - case 18: { - result.hasAddress2 = input.ReadString(ref result.address2_); - break; - } - case 26: { - result.hasCity = input.ReadString(ref result.city_); - break; - } - case 34: { - result.hasState = input.ReadString(ref result.state_); - break; - } - case 45: { - result.hasZip = input.ReadFixed32(ref result.zip_); - break; - } - } - } - - return this; - } - - - public bool HasAddress { - get { return result.hasAddress; } - } - public string Address { - get { return result.Address; } - set { SetAddress(value); } - } - public Builder SetAddress(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasAddress = true; - result.address_ = value; - return this; - } - public Builder ClearAddress() { - PrepareBuilder(); - result.hasAddress = false; - result.address_ = ""; - return this; - } - - public bool HasAddress2 { - get { return result.hasAddress2; } - } - public string Address2 { - get { return result.Address2; } - set { SetAddress2(value); } - } - public Builder SetAddress2(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasAddress2 = true; - result.address2_ = value; - return this; - } - public Builder ClearAddress2() { - PrepareBuilder(); - result.hasAddress2 = false; - result.address2_ = ""; - return this; - } - - public bool HasCity { - get { return result.hasCity; } - } - public string City { - get { return result.City; } - set { SetCity(value); } - } - public Builder SetCity(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasCity = true; - result.city_ = value; - return this; - } - public Builder ClearCity() { - PrepareBuilder(); - result.hasCity = false; - result.city_ = ""; - return this; - } - - public bool HasState { - get { return result.hasState; } - } - public string State { - get { return result.State; } - set { SetState(value); } - } - public Builder SetState(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasState = true; - result.state_ = value; - return this; - } - public Builder ClearState() { - PrepareBuilder(); - result.hasState = false; - result.state_ = ""; - return this; - } - - public bool HasZip { - get { return result.hasZip; } - } - [global::System.CLSCompliant(false)] - public uint Zip { - get { return result.Zip; } - set { SetZip(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetZip(uint value) { - PrepareBuilder(); - result.hasZip = true; - result.zip_ = value; - return this; - } - public Builder ClearZip() { - PrepareBuilder(); - result.hasZip = false; - result.zip_ = 0; - return this; - } - } - static Addresses() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.Descriptor, null); - } - } - - } - #endregion - - public const int NameFieldNumber = 1; - private bool hasName; - private string name_ = ""; - public bool HasName { - get { return hasName; } - } - public string Name { - get { return name_; } - } - - public const int IdFieldNumber = 2; - private bool hasId; - private int id_; - public bool HasId { - get { return hasId; } - } - public int Id { - get { return id_; } - } - - public const int EmailFieldNumber = 3; - private bool hasEmail; - private string email_ = ""; - public bool HasEmail { - get { return hasEmail; } - } - public string Email { - get { return email_; } - } - - public const int CodesFieldNumber = 10; - private int codesMemoizedSerializedSize; - private pbc::PopsicleList codes_ = new pbc::PopsicleList(); - public scg::IList CodesList { - get { return pbc::Lists.AsReadOnly(codes_); } - } - public int CodesCount { - get { return codes_.Count; } - } - public int GetCodes(int index) { - return codes_[index]; - } - - public const int PhoneFieldNumber = 4; - private pbc::PopsicleList phone_ = new pbc::PopsicleList(); - public scg::IList PhoneList { - get { return phone_; } - } - public int PhoneCount { - get { return phone_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber GetPhone(int index) { - return phone_[index]; - } - - public const int AddressesFieldNumber = 5; - private pbc::PopsicleList addresses_ = new pbc::PopsicleList(); - public scg::IList AddressesList { - get { return addresses_; } - } - public int AddressesCount { - get { return addresses_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses GetAddresses(int index) { - return addresses_[index]; - } - - public override bool IsInitialized { - get { - if (!hasName) return false; - if (!hasId) return false; - foreach (global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber element in PhoneList) { - if (!element.IsInitialized) return false; - } - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testInteropPersonLiteFieldNames; - pb::ExtendableMessageLite.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - if (hasName) { - output.WriteString(1, field_names[4], Name); - } - if (hasId) { - output.WriteInt32(2, field_names[3], Id); - } - if (hasEmail) { - output.WriteString(3, field_names[2], Email); - } - if (phone_.Count > 0) { - output.WriteMessageArray(4, field_names[5], phone_); - } - if (addresses_.Count > 0) { - output.WriteGroupArray(5, field_names[0], addresses_); - } - if (codes_.Count > 0) { - output.WritePackedInt32Array(10, field_names[1], codesMemoizedSerializedSize, codes_); - } - extensionWriter.WriteUntil(200, output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasName) { - size += pb::CodedOutputStream.ComputeStringSize(1, Name); - } - if (hasId) { - size += pb::CodedOutputStream.ComputeInt32Size(2, Id); - } - if (hasEmail) { - size += pb::CodedOutputStream.ComputeStringSize(3, Email); - } - { - int dataSize = 0; - foreach (int element in CodesList) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - if (codes_.Count != 0) { - size += 1 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - codesMemoizedSerializedSize = dataSize; - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber element in PhoneList) { - size += pb::CodedOutputStream.ComputeMessageSize(4, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses element in AddressesList) { - size += pb::CodedOutputStream.ComputeGroupSize(5, element); - } - size += ExtensionsSerializedSize; - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasName) hash ^= name_.GetHashCode(); - if (hasId) hash ^= id_.GetHashCode(); - if (hasEmail) hash ^= email_.GetHashCode(); - foreach(int i in codes_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber i in phone_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses i in addresses_) - hash ^= i.GetHashCode(); - hash ^= base.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestInteropPersonLite other = obj as TestInteropPersonLite; - if (other == null) return false; - if (hasName != other.hasName || (hasName && !name_.Equals(other.name_))) return false; - if (hasId != other.hasId || (hasId && !id_.Equals(other.id_))) return false; - if (hasEmail != other.hasEmail || (hasEmail && !email_.Equals(other.email_))) return false; - if(codes_.Count != other.codes_.Count) return false; - for(int ix=0; ix < codes_.Count; ix++) - if(!codes_[ix].Equals(other.codes_[ix])) return false; - if(phone_.Count != other.phone_.Count) return false; - for(int ix=0; ix < phone_.Count; ix++) - if(!phone_[ix].Equals(other.phone_[ix])) return false; - if(addresses_.Count != other.addresses_.Count) return false; - for(int ix=0; ix < addresses_.Count; ix++) - if(!addresses_[ix].Equals(other.addresses_[ix])) return false; - if (!base.Equals(other)) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("name", hasName, name_, writer); - PrintField("id", hasId, id_, writer); - PrintField("email", hasEmail, email_, writer); - PrintField("phone", phone_, writer); - PrintField("Addresses", addresses_, writer); - PrintField("codes", codes_, writer); - base.PrintTo(writer); - } - #endregion - - public static TestInteropPersonLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestInteropPersonLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestInteropPersonLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestInteropPersonLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestInteropPersonLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestInteropPersonLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestInteropPersonLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestInteropPersonLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestInteropPersonLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestInteropPersonLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestInteropPersonLite MakeReadOnly() { - codes_.MakeReadOnly(); - phone_.MakeReadOnly(); - addresses_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestInteropPersonLite prototype) { - return new Builder(prototype); - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestInteropPersonLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestInteropPersonLite result; - - private TestInteropPersonLite PrepareBuilder() { - if (resultIsReadOnly) { - TestInteropPersonLite original = result; - result = new TestInteropPersonLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestInteropPersonLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestInteropPersonLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.DefaultInstance; } - } - - public override TestInteropPersonLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestInteropPersonLite) { - return MergeFrom((TestInteropPersonLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestInteropPersonLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasName) { - Name = other.Name; - } - if (other.HasId) { - Id = other.Id; - } - if (other.HasEmail) { - Email = other.Email; - } - if (other.codes_.Count != 0) { - result.codes_.Add(other.codes_); - } - if (other.phone_.Count != 0) { - result.phone_.Add(other.phone_); - } - if (other.addresses_.Count != 0) { - result.addresses_.Add(other.addresses_); - } - this.MergeExtensionFields(other); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testInteropPersonLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testInteropPersonLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasName = input.ReadString(ref result.name_); - break; - } - case 16: { - result.hasId = input.ReadInt32(ref result.id_); - break; - } - case 26: { - result.hasEmail = input.ReadString(ref result.email_); - break; - } - case 34: { - input.ReadMessageArray(tag, field_name, result.phone_, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber.DefaultInstance, extensionRegistry); - break; - } - case 43: { - input.ReadGroupArray(tag, field_name, result.addresses_, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses.DefaultInstance, extensionRegistry); - break; - } - case 82: - case 80: { - input.ReadInt32Array(tag, field_name, result.codes_); - break; - } - } - } - - return this; - } - - - public bool HasName { - get { return result.hasName; } - } - public string Name { - get { return result.Name; } - set { SetName(value); } - } - public Builder SetName(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasName = true; - result.name_ = value; - return this; - } - public Builder ClearName() { - PrepareBuilder(); - result.hasName = false; - result.name_ = ""; - return this; - } - - public bool HasId { - get { return result.hasId; } - } - public int Id { - get { return result.Id; } - set { SetId(value); } - } - public Builder SetId(int value) { - PrepareBuilder(); - result.hasId = true; - result.id_ = value; - return this; - } - public Builder ClearId() { - PrepareBuilder(); - result.hasId = false; - result.id_ = 0; - return this; - } - - public bool HasEmail { - get { return result.hasEmail; } - } - public string Email { - get { return result.Email; } - set { SetEmail(value); } - } - public Builder SetEmail(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasEmail = true; - result.email_ = value; - return this; - } - public Builder ClearEmail() { - PrepareBuilder(); - result.hasEmail = false; - result.email_ = ""; - return this; - } - - public pbc::IPopsicleList CodesList { - get { return PrepareBuilder().codes_; } - } - public int CodesCount { - get { return result.CodesCount; } - } - public int GetCodes(int index) { - return result.GetCodes(index); - } - public Builder SetCodes(int index, int value) { - PrepareBuilder(); - result.codes_[index] = value; - return this; - } - public Builder AddCodes(int value) { - PrepareBuilder(); - result.codes_.Add(value); - return this; - } - public Builder AddRangeCodes(scg::IEnumerable values) { - PrepareBuilder(); - result.codes_.Add(values); - return this; - } - public Builder ClearCodes() { - PrepareBuilder(); - result.codes_.Clear(); - return this; - } - - public pbc::IPopsicleList PhoneList { - get { return PrepareBuilder().phone_; } - } - public int PhoneCount { - get { return result.PhoneCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber GetPhone(int index) { - return result.GetPhone(index); - } - public Builder SetPhone(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.phone_[index] = value; - return this; - } - public Builder SetPhone(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.phone_[index] = builderForValue.Build(); - return this; - } - public Builder AddPhone(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.phone_.Add(value); - return this; - } - public Builder AddPhone(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.phone_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangePhone(scg::IEnumerable values) { - PrepareBuilder(); - result.phone_.Add(values); - return this; - } - public Builder ClearPhone() { - PrepareBuilder(); - result.phone_.Clear(); - return this; - } - - public pbc::IPopsicleList AddressesList { - get { return PrepareBuilder().addresses_; } - } - public int AddressesCount { - get { return result.AddressesCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses GetAddresses(int index) { - return result.GetAddresses(index); - } - public Builder SetAddresses(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.addresses_[index] = value; - return this; - } - public Builder SetAddresses(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.addresses_[index] = builderForValue.Build(); - return this; - } - public Builder AddAddresses(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.addresses_.Add(value); - return this; - } - public Builder AddAddresses(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.addresses_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeAddresses(scg::IEnumerable values) { - PrepareBuilder(); - result.addresses_.Add(values); - return this; - } - public Builder ClearAddresses() { - PrepareBuilder(); - result.addresses_.Clear(); - return this; - } - } - static TestInteropPersonLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.Descriptor, null); - } - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestInteropEmployeeIdLite : pb::GeneratedMessageLite { - private TestInteropEmployeeIdLite() { } - private static readonly TestInteropEmployeeIdLite defaultInstance = new TestInteropEmployeeIdLite().MakeReadOnly(); - private static readonly string[] _testInteropEmployeeIdLiteFieldNames = new string[] { "number" }; - private static readonly uint[] _testInteropEmployeeIdLiteFieldTags = new uint[] { 10 }; - public static TestInteropEmployeeIdLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestInteropEmployeeIdLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestInteropEmployeeIdLite ThisMessage { - get { return this; } - } - - public const int NumberFieldNumber = 1; - private bool hasNumber; - private string number_ = ""; - public bool HasNumber { - get { return hasNumber; } - } - public string Number { - get { return number_; } - } - - public override bool IsInitialized { - get { - if (!hasNumber) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testInteropEmployeeIdLiteFieldNames; - if (hasNumber) { - output.WriteString(1, field_names[0], Number); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasNumber) { - size += pb::CodedOutputStream.ComputeStringSize(1, Number); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasNumber) hash ^= number_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestInteropEmployeeIdLite other = obj as TestInteropEmployeeIdLite; - if (other == null) return false; - if (hasNumber != other.hasNumber || (hasNumber && !number_.Equals(other.number_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("number", hasNumber, number_, writer); - } - #endregion - - public static TestInteropEmployeeIdLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestInteropEmployeeIdLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestInteropEmployeeIdLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestInteropEmployeeIdLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestInteropEmployeeIdLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestInteropEmployeeIdLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestInteropEmployeeIdLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestInteropEmployeeIdLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestInteropEmployeeIdLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestInteropEmployeeIdLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestInteropEmployeeIdLite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestInteropEmployeeIdLite prototype) { - return new Builder(prototype); - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestInteropEmployeeIdLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestInteropEmployeeIdLite result; - - private TestInteropEmployeeIdLite PrepareBuilder() { - if (resultIsReadOnly) { - TestInteropEmployeeIdLite original = result; - result = new TestInteropEmployeeIdLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestInteropEmployeeIdLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestInteropEmployeeIdLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestInteropEmployeeIdLite.DefaultInstance; } - } - - public override TestInteropEmployeeIdLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestInteropEmployeeIdLite) { - return MergeFrom((TestInteropEmployeeIdLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestInteropEmployeeIdLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestInteropEmployeeIdLite.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasNumber) { - Number = other.Number; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testInteropEmployeeIdLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testInteropEmployeeIdLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasNumber = input.ReadString(ref result.number_); - break; - } - } - } - - return this; - } - - - public bool HasNumber { - get { return result.hasNumber; } - } - public string Number { - get { return result.Number; } - set { SetNumber(value); } - } - public Builder SetNumber(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasNumber = true; - result.number_ = value; - return this; - } - public Builder ClearNumber() { - PrepareBuilder(); - result.hasNumber = false; - result.number_ = ""; - return this; - } - } - static TestInteropEmployeeIdLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.Descriptor, null); - } - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestUnpackedExtensionsLite : pb::ExtendableMessageLite { - private TestUnpackedExtensionsLite() { } - private static readonly TestUnpackedExtensionsLite defaultInstance = new TestUnpackedExtensionsLite().MakeReadOnly(); - private static readonly string[] _testUnpackedExtensionsLiteFieldNames = new string[] { }; - private static readonly uint[] _testUnpackedExtensionsLiteFieldTags = new uint[] { }; - public static TestUnpackedExtensionsLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestUnpackedExtensionsLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestUnpackedExtensionsLite ThisMessage { - get { return this; } - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testUnpackedExtensionsLiteFieldNames; - pb::ExtendableMessageLite.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(536870912, output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += ExtensionsSerializedSize; - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - hash ^= base.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestUnpackedExtensionsLite other = obj as TestUnpackedExtensionsLite; - if (other == null) return false; - if (!base.Equals(other)) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - base.PrintTo(writer); - } - #endregion - - public static TestUnpackedExtensionsLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestUnpackedExtensionsLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedExtensionsLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestUnpackedExtensionsLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedExtensionsLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestUnpackedExtensionsLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestUnpackedExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestUnpackedExtensionsLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestUnpackedExtensionsLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestUnpackedExtensionsLite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestUnpackedExtensionsLite prototype) { - return new Builder(prototype); - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestUnpackedExtensionsLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestUnpackedExtensionsLite result; - - private TestUnpackedExtensionsLite PrepareBuilder() { - if (resultIsReadOnly) { - TestUnpackedExtensionsLite original = result; - result = new TestUnpackedExtensionsLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestUnpackedExtensionsLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestUnpackedExtensionsLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance; } - } - - public override TestUnpackedExtensionsLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestUnpackedExtensionsLite) { - return MergeFrom((TestUnpackedExtensionsLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestUnpackedExtensionsLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testUnpackedExtensionsLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testUnpackedExtensionsLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - } - } - - return this; - } - - } - static TestUnpackedExtensionsLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.Descriptor, null); - } - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestUnpackedTypesLite : pb::GeneratedMessageLite { - private TestUnpackedTypesLite() { } - private static readonly TestUnpackedTypesLite defaultInstance = new TestUnpackedTypesLite().MakeReadOnly(); - private static readonly string[] _testUnpackedTypesLiteFieldNames = new string[] { "unpacked_bool", "unpacked_double", "unpacked_enum", "unpacked_fixed32", "unpacked_fixed64", "unpacked_float", "unpacked_int32", "unpacked_int64", "unpacked_sfixed32", "unpacked_sfixed64", "unpacked_sint32", "unpacked_sint64", "unpacked_uint32", "unpacked_uint64" }; - private static readonly uint[] _testUnpackedTypesLiteFieldTags = new uint[] { 816, 809, 824, 773, 777, 805, 720, 728, 789, 793, 752, 760, 736, 744 }; - public static TestUnpackedTypesLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestUnpackedTypesLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestUnpackedTypesLite ThisMessage { - get { return this; } - } - - public const int UnpackedInt32FieldNumber = 90; - private pbc::PopsicleList unpackedInt32_ = new pbc::PopsicleList(); - public scg::IList UnpackedInt32List { - get { return pbc::Lists.AsReadOnly(unpackedInt32_); } - } - public int UnpackedInt32Count { - get { return unpackedInt32_.Count; } - } - public int GetUnpackedInt32(int index) { - return unpackedInt32_[index]; - } - - public const int UnpackedInt64FieldNumber = 91; - private pbc::PopsicleList unpackedInt64_ = new pbc::PopsicleList(); - public scg::IList UnpackedInt64List { - get { return pbc::Lists.AsReadOnly(unpackedInt64_); } - } - public int UnpackedInt64Count { - get { return unpackedInt64_.Count; } - } - public long GetUnpackedInt64(int index) { - return unpackedInt64_[index]; - } - - public const int UnpackedUint32FieldNumber = 92; - private pbc::PopsicleList unpackedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedUint32List { - get { return pbc::Lists.AsReadOnly(unpackedUint32_); } - } - public int UnpackedUint32Count { - get { return unpackedUint32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedUint32(int index) { - return unpackedUint32_[index]; - } - - public const int UnpackedUint64FieldNumber = 93; - private pbc::PopsicleList unpackedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedUint64List { - get { return pbc::Lists.AsReadOnly(unpackedUint64_); } - } - public int UnpackedUint64Count { - get { return unpackedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedUint64(int index) { - return unpackedUint64_[index]; - } - - public const int UnpackedSint32FieldNumber = 94; - private pbc::PopsicleList unpackedSint32_ = new pbc::PopsicleList(); - public scg::IList UnpackedSint32List { - get { return pbc::Lists.AsReadOnly(unpackedSint32_); } - } - public int UnpackedSint32Count { - get { return unpackedSint32_.Count; } - } - public int GetUnpackedSint32(int index) { - return unpackedSint32_[index]; - } - - public const int UnpackedSint64FieldNumber = 95; - private pbc::PopsicleList unpackedSint64_ = new pbc::PopsicleList(); - public scg::IList UnpackedSint64List { - get { return pbc::Lists.AsReadOnly(unpackedSint64_); } - } - public int UnpackedSint64Count { - get { return unpackedSint64_.Count; } - } - public long GetUnpackedSint64(int index) { - return unpackedSint64_[index]; - } - - public const int UnpackedFixed32FieldNumber = 96; - private pbc::PopsicleList unpackedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedFixed32List { - get { return pbc::Lists.AsReadOnly(unpackedFixed32_); } - } - public int UnpackedFixed32Count { - get { return unpackedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedFixed32(int index) { - return unpackedFixed32_[index]; - } - - public const int UnpackedFixed64FieldNumber = 97; - private pbc::PopsicleList unpackedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedFixed64List { - get { return pbc::Lists.AsReadOnly(unpackedFixed64_); } - } - public int UnpackedFixed64Count { - get { return unpackedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedFixed64(int index) { - return unpackedFixed64_[index]; - } - - public const int UnpackedSfixed32FieldNumber = 98; - private pbc::PopsicleList unpackedSfixed32_ = new pbc::PopsicleList(); - public scg::IList UnpackedSfixed32List { - get { return pbc::Lists.AsReadOnly(unpackedSfixed32_); } - } - public int UnpackedSfixed32Count { - get { return unpackedSfixed32_.Count; } - } - public int GetUnpackedSfixed32(int index) { - return unpackedSfixed32_[index]; - } - - public const int UnpackedSfixed64FieldNumber = 99; - private pbc::PopsicleList unpackedSfixed64_ = new pbc::PopsicleList(); - public scg::IList UnpackedSfixed64List { - get { return pbc::Lists.AsReadOnly(unpackedSfixed64_); } - } - public int UnpackedSfixed64Count { - get { return unpackedSfixed64_.Count; } - } - public long GetUnpackedSfixed64(int index) { - return unpackedSfixed64_[index]; - } - - public const int UnpackedFloatFieldNumber = 100; - private pbc::PopsicleList unpackedFloat_ = new pbc::PopsicleList(); - public scg::IList UnpackedFloatList { - get { return pbc::Lists.AsReadOnly(unpackedFloat_); } - } - public int UnpackedFloatCount { - get { return unpackedFloat_.Count; } - } - public float GetUnpackedFloat(int index) { - return unpackedFloat_[index]; - } - - public const int UnpackedDoubleFieldNumber = 101; - private pbc::PopsicleList unpackedDouble_ = new pbc::PopsicleList(); - public scg::IList UnpackedDoubleList { - get { return pbc::Lists.AsReadOnly(unpackedDouble_); } - } - public int UnpackedDoubleCount { - get { return unpackedDouble_.Count; } - } - public double GetUnpackedDouble(int index) { - return unpackedDouble_[index]; - } - - public const int UnpackedBoolFieldNumber = 102; - private pbc::PopsicleList unpackedBool_ = new pbc::PopsicleList(); - public scg::IList UnpackedBoolList { - get { return pbc::Lists.AsReadOnly(unpackedBool_); } - } - public int UnpackedBoolCount { - get { return unpackedBool_.Count; } - } - public bool GetUnpackedBool(int index) { - return unpackedBool_[index]; - } - - public const int UnpackedEnumFieldNumber = 103; - private pbc::PopsicleList unpackedEnum_ = new pbc::PopsicleList(); - public scg::IList UnpackedEnumList { - get { return pbc::Lists.AsReadOnly(unpackedEnum_); } - } - public int UnpackedEnumCount { - get { return unpackedEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite GetUnpackedEnum(int index) { - return unpackedEnum_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testUnpackedTypesLiteFieldNames; - if (unpackedInt32_.Count > 0) { - output.WriteInt32Array(90, field_names[6], unpackedInt32_); - } - if (unpackedInt64_.Count > 0) { - output.WriteInt64Array(91, field_names[7], unpackedInt64_); - } - if (unpackedUint32_.Count > 0) { - output.WriteUInt32Array(92, field_names[12], unpackedUint32_); - } - if (unpackedUint64_.Count > 0) { - output.WriteUInt64Array(93, field_names[13], unpackedUint64_); - } - if (unpackedSint32_.Count > 0) { - output.WriteSInt32Array(94, field_names[10], unpackedSint32_); - } - if (unpackedSint64_.Count > 0) { - output.WriteSInt64Array(95, field_names[11], unpackedSint64_); - } - if (unpackedFixed32_.Count > 0) { - output.WriteFixed32Array(96, field_names[3], unpackedFixed32_); - } - if (unpackedFixed64_.Count > 0) { - output.WriteFixed64Array(97, field_names[4], unpackedFixed64_); - } - if (unpackedSfixed32_.Count > 0) { - output.WriteSFixed32Array(98, field_names[8], unpackedSfixed32_); - } - if (unpackedSfixed64_.Count > 0) { - output.WriteSFixed64Array(99, field_names[9], unpackedSfixed64_); - } - if (unpackedFloat_.Count > 0) { - output.WriteFloatArray(100, field_names[5], unpackedFloat_); - } - if (unpackedDouble_.Count > 0) { - output.WriteDoubleArray(101, field_names[1], unpackedDouble_); - } - if (unpackedBool_.Count > 0) { - output.WriteBoolArray(102, field_names[0], unpackedBool_); - } - if (unpackedEnum_.Count > 0) { - output.WriteEnumArray(103, field_names[2], unpackedEnum_); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (int element in UnpackedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedInt32_.Count; - } - { - int dataSize = 0; - foreach (long element in UnpackedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedInt64_.Count; - } - { - int dataSize = 0; - foreach (uint element in UnpackedUint32List) { - dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedUint32_.Count; - } - { - int dataSize = 0; - foreach (ulong element in UnpackedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedUint64_.Count; - } - { - int dataSize = 0; - foreach (int element in UnpackedSint32List) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedSint32_.Count; - } - { - int dataSize = 0; - foreach (long element in UnpackedSint64List) { - dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedSint64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * unpackedFixed32_.Count; - size += dataSize; - size += 2 * unpackedFixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * unpackedFixed64_.Count; - size += dataSize; - size += 2 * unpackedFixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * unpackedSfixed32_.Count; - size += dataSize; - size += 2 * unpackedSfixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * unpackedSfixed64_.Count; - size += dataSize; - size += 2 * unpackedSfixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * unpackedFloat_.Count; - size += dataSize; - size += 2 * unpackedFloat_.Count; - } - { - int dataSize = 0; - dataSize = 8 * unpackedDouble_.Count; - size += dataSize; - size += 2 * unpackedDouble_.Count; - } - { - int dataSize = 0; - dataSize = 1 * unpackedBool_.Count; - size += dataSize; - size += 2 * unpackedBool_.Count; - } - { - int dataSize = 0; - if (unpackedEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite element in unpackedEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * unpackedEnum_.Count; - } - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - foreach(int i in unpackedInt32_) - hash ^= i.GetHashCode(); - foreach(long i in unpackedInt64_) - hash ^= i.GetHashCode(); - foreach(uint i in unpackedUint32_) - hash ^= i.GetHashCode(); - foreach(ulong i in unpackedUint64_) - hash ^= i.GetHashCode(); - foreach(int i in unpackedSint32_) - hash ^= i.GetHashCode(); - foreach(long i in unpackedSint64_) - hash ^= i.GetHashCode(); - foreach(uint i in unpackedFixed32_) - hash ^= i.GetHashCode(); - foreach(ulong i in unpackedFixed64_) - hash ^= i.GetHashCode(); - foreach(int i in unpackedSfixed32_) - hash ^= i.GetHashCode(); - foreach(long i in unpackedSfixed64_) - hash ^= i.GetHashCode(); - foreach(float i in unpackedFloat_) - hash ^= i.GetHashCode(); - foreach(double i in unpackedDouble_) - hash ^= i.GetHashCode(); - foreach(bool i in unpackedBool_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite i in unpackedEnum_) - hash ^= i.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestUnpackedTypesLite other = obj as TestUnpackedTypesLite; - if (other == null) return false; - if(unpackedInt32_.Count != other.unpackedInt32_.Count) return false; - for(int ix=0; ix < unpackedInt32_.Count; ix++) - if(!unpackedInt32_[ix].Equals(other.unpackedInt32_[ix])) return false; - if(unpackedInt64_.Count != other.unpackedInt64_.Count) return false; - for(int ix=0; ix < unpackedInt64_.Count; ix++) - if(!unpackedInt64_[ix].Equals(other.unpackedInt64_[ix])) return false; - if(unpackedUint32_.Count != other.unpackedUint32_.Count) return false; - for(int ix=0; ix < unpackedUint32_.Count; ix++) - if(!unpackedUint32_[ix].Equals(other.unpackedUint32_[ix])) return false; - if(unpackedUint64_.Count != other.unpackedUint64_.Count) return false; - for(int ix=0; ix < unpackedUint64_.Count; ix++) - if(!unpackedUint64_[ix].Equals(other.unpackedUint64_[ix])) return false; - if(unpackedSint32_.Count != other.unpackedSint32_.Count) return false; - for(int ix=0; ix < unpackedSint32_.Count; ix++) - if(!unpackedSint32_[ix].Equals(other.unpackedSint32_[ix])) return false; - if(unpackedSint64_.Count != other.unpackedSint64_.Count) return false; - for(int ix=0; ix < unpackedSint64_.Count; ix++) - if(!unpackedSint64_[ix].Equals(other.unpackedSint64_[ix])) return false; - if(unpackedFixed32_.Count != other.unpackedFixed32_.Count) return false; - for(int ix=0; ix < unpackedFixed32_.Count; ix++) - if(!unpackedFixed32_[ix].Equals(other.unpackedFixed32_[ix])) return false; - if(unpackedFixed64_.Count != other.unpackedFixed64_.Count) return false; - for(int ix=0; ix < unpackedFixed64_.Count; ix++) - if(!unpackedFixed64_[ix].Equals(other.unpackedFixed64_[ix])) return false; - if(unpackedSfixed32_.Count != other.unpackedSfixed32_.Count) return false; - for(int ix=0; ix < unpackedSfixed32_.Count; ix++) - if(!unpackedSfixed32_[ix].Equals(other.unpackedSfixed32_[ix])) return false; - if(unpackedSfixed64_.Count != other.unpackedSfixed64_.Count) return false; - for(int ix=0; ix < unpackedSfixed64_.Count; ix++) - if(!unpackedSfixed64_[ix].Equals(other.unpackedSfixed64_[ix])) return false; - if(unpackedFloat_.Count != other.unpackedFloat_.Count) return false; - for(int ix=0; ix < unpackedFloat_.Count; ix++) - if(!unpackedFloat_[ix].Equals(other.unpackedFloat_[ix])) return false; - if(unpackedDouble_.Count != other.unpackedDouble_.Count) return false; - for(int ix=0; ix < unpackedDouble_.Count; ix++) - if(!unpackedDouble_[ix].Equals(other.unpackedDouble_[ix])) return false; - if(unpackedBool_.Count != other.unpackedBool_.Count) return false; - for(int ix=0; ix < unpackedBool_.Count; ix++) - if(!unpackedBool_[ix].Equals(other.unpackedBool_[ix])) return false; - if(unpackedEnum_.Count != other.unpackedEnum_.Count) return false; - for(int ix=0; ix < unpackedEnum_.Count; ix++) - if(!unpackedEnum_[ix].Equals(other.unpackedEnum_[ix])) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("unpacked_int32", unpackedInt32_, writer); - PrintField("unpacked_int64", unpackedInt64_, writer); - PrintField("unpacked_uint32", unpackedUint32_, writer); - PrintField("unpacked_uint64", unpackedUint64_, writer); - PrintField("unpacked_sint32", unpackedSint32_, writer); - PrintField("unpacked_sint64", unpackedSint64_, writer); - PrintField("unpacked_fixed32", unpackedFixed32_, writer); - PrintField("unpacked_fixed64", unpackedFixed64_, writer); - PrintField("unpacked_sfixed32", unpackedSfixed32_, writer); - PrintField("unpacked_sfixed64", unpackedSfixed64_, writer); - PrintField("unpacked_float", unpackedFloat_, writer); - PrintField("unpacked_double", unpackedDouble_, writer); - PrintField("unpacked_bool", unpackedBool_, writer); - PrintField("unpacked_enum", unpackedEnum_, writer); - } - #endregion - - public static TestUnpackedTypesLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestUnpackedTypesLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedTypesLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestUnpackedTypesLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedTypesLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestUnpackedTypesLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedTypesLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestUnpackedTypesLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestUnpackedTypesLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestUnpackedTypesLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestUnpackedTypesLite MakeReadOnly() { - unpackedInt32_.MakeReadOnly(); - unpackedInt64_.MakeReadOnly(); - unpackedUint32_.MakeReadOnly(); - unpackedUint64_.MakeReadOnly(); - unpackedSint32_.MakeReadOnly(); - unpackedSint64_.MakeReadOnly(); - unpackedFixed32_.MakeReadOnly(); - unpackedFixed64_.MakeReadOnly(); - unpackedSfixed32_.MakeReadOnly(); - unpackedSfixed64_.MakeReadOnly(); - unpackedFloat_.MakeReadOnly(); - unpackedDouble_.MakeReadOnly(); - unpackedBool_.MakeReadOnly(); - unpackedEnum_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestUnpackedTypesLite prototype) { - return new Builder(prototype); - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestUnpackedTypesLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestUnpackedTypesLite result; - - private TestUnpackedTypesLite PrepareBuilder() { - if (resultIsReadOnly) { - TestUnpackedTypesLite original = result; - result = new TestUnpackedTypesLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestUnpackedTypesLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestUnpackedTypesLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypesLite.DefaultInstance; } - } - - public override TestUnpackedTypesLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestUnpackedTypesLite) { - return MergeFrom((TestUnpackedTypesLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestUnpackedTypesLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypesLite.DefaultInstance) return this; - PrepareBuilder(); - if (other.unpackedInt32_.Count != 0) { - result.unpackedInt32_.Add(other.unpackedInt32_); - } - if (other.unpackedInt64_.Count != 0) { - result.unpackedInt64_.Add(other.unpackedInt64_); - } - if (other.unpackedUint32_.Count != 0) { - result.unpackedUint32_.Add(other.unpackedUint32_); - } - if (other.unpackedUint64_.Count != 0) { - result.unpackedUint64_.Add(other.unpackedUint64_); - } - if (other.unpackedSint32_.Count != 0) { - result.unpackedSint32_.Add(other.unpackedSint32_); - } - if (other.unpackedSint64_.Count != 0) { - result.unpackedSint64_.Add(other.unpackedSint64_); - } - if (other.unpackedFixed32_.Count != 0) { - result.unpackedFixed32_.Add(other.unpackedFixed32_); - } - if (other.unpackedFixed64_.Count != 0) { - result.unpackedFixed64_.Add(other.unpackedFixed64_); - } - if (other.unpackedSfixed32_.Count != 0) { - result.unpackedSfixed32_.Add(other.unpackedSfixed32_); - } - if (other.unpackedSfixed64_.Count != 0) { - result.unpackedSfixed64_.Add(other.unpackedSfixed64_); - } - if (other.unpackedFloat_.Count != 0) { - result.unpackedFloat_.Add(other.unpackedFloat_); - } - if (other.unpackedDouble_.Count != 0) { - result.unpackedDouble_.Add(other.unpackedDouble_); - } - if (other.unpackedBool_.Count != 0) { - result.unpackedBool_.Add(other.unpackedBool_); - } - if (other.unpackedEnum_.Count != 0) { - result.unpackedEnum_.Add(other.unpackedEnum_); - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testUnpackedTypesLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testUnpackedTypesLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 722: - case 720: { - input.ReadInt32Array(tag, field_name, result.unpackedInt32_); - break; - } - case 730: - case 728: { - input.ReadInt64Array(tag, field_name, result.unpackedInt64_); - break; - } - case 738: - case 736: { - input.ReadUInt32Array(tag, field_name, result.unpackedUint32_); - break; - } - case 746: - case 744: { - input.ReadUInt64Array(tag, field_name, result.unpackedUint64_); - break; - } - case 754: - case 752: { - input.ReadSInt32Array(tag, field_name, result.unpackedSint32_); - break; - } - case 762: - case 760: { - input.ReadSInt64Array(tag, field_name, result.unpackedSint64_); - break; - } - case 770: - case 773: { - input.ReadFixed32Array(tag, field_name, result.unpackedFixed32_); - break; - } - case 778: - case 777: { - input.ReadFixed64Array(tag, field_name, result.unpackedFixed64_); - break; - } - case 786: - case 789: { - input.ReadSFixed32Array(tag, field_name, result.unpackedSfixed32_); - break; - } - case 794: - case 793: { - input.ReadSFixed64Array(tag, field_name, result.unpackedSfixed64_); - break; - } - case 802: - case 805: { - input.ReadFloatArray(tag, field_name, result.unpackedFloat_); - break; - } - case 810: - case 809: { - input.ReadDoubleArray(tag, field_name, result.unpackedDouble_); - break; - } - case 818: - case 816: { - input.ReadBoolArray(tag, field_name, result.unpackedBool_); - break; - } - case 826: - case 824: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.unpackedEnum_, out unknownItems); - break; - } - } - } - - return this; - } - - - public pbc::IPopsicleList UnpackedInt32List { - get { return PrepareBuilder().unpackedInt32_; } - } - public int UnpackedInt32Count { - get { return result.UnpackedInt32Count; } - } - public int GetUnpackedInt32(int index) { - return result.GetUnpackedInt32(index); - } - public Builder SetUnpackedInt32(int index, int value) { - PrepareBuilder(); - result.unpackedInt32_[index] = value; - return this; - } - public Builder AddUnpackedInt32(int value) { - PrepareBuilder(); - result.unpackedInt32_.Add(value); - return this; - } - public Builder AddRangeUnpackedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedInt32_.Add(values); - return this; - } - public Builder ClearUnpackedInt32() { - PrepareBuilder(); - result.unpackedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedInt64List { - get { return PrepareBuilder().unpackedInt64_; } - } - public int UnpackedInt64Count { - get { return result.UnpackedInt64Count; } - } - public long GetUnpackedInt64(int index) { - return result.GetUnpackedInt64(index); - } - public Builder SetUnpackedInt64(int index, long value) { - PrepareBuilder(); - result.unpackedInt64_[index] = value; - return this; - } - public Builder AddUnpackedInt64(long value) { - PrepareBuilder(); - result.unpackedInt64_.Add(value); - return this; - } - public Builder AddRangeUnpackedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedInt64_.Add(values); - return this; - } - public Builder ClearUnpackedInt64() { - PrepareBuilder(); - result.unpackedInt64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedUint32List { - get { return PrepareBuilder().unpackedUint32_; } - } - public int UnpackedUint32Count { - get { return result.UnpackedUint32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedUint32(int index) { - return result.GetUnpackedUint32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedUint32(int index, uint value) { - PrepareBuilder(); - result.unpackedUint32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedUint32(uint value) { - PrepareBuilder(); - result.unpackedUint32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedUint32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedUint32_.Add(values); - return this; - } - public Builder ClearUnpackedUint32() { - PrepareBuilder(); - result.unpackedUint32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedUint64List { - get { return PrepareBuilder().unpackedUint64_; } - } - public int UnpackedUint64Count { - get { return result.UnpackedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedUint64(int index) { - return result.GetUnpackedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedUint64(int index, ulong value) { - PrepareBuilder(); - result.unpackedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedUint64(ulong value) { - PrepareBuilder(); - result.unpackedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedUint64_.Add(values); - return this; - } - public Builder ClearUnpackedUint64() { - PrepareBuilder(); - result.unpackedUint64_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSint32List { - get { return PrepareBuilder().unpackedSint32_; } - } - public int UnpackedSint32Count { - get { return result.UnpackedSint32Count; } - } - public int GetUnpackedSint32(int index) { - return result.GetUnpackedSint32(index); - } - public Builder SetUnpackedSint32(int index, int value) { - PrepareBuilder(); - result.unpackedSint32_[index] = value; - return this; - } - public Builder AddUnpackedSint32(int value) { - PrepareBuilder(); - result.unpackedSint32_.Add(value); - return this; - } - public Builder AddRangeUnpackedSint32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSint32_.Add(values); - return this; - } - public Builder ClearUnpackedSint32() { - PrepareBuilder(); - result.unpackedSint32_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSint64List { - get { return PrepareBuilder().unpackedSint64_; } - } - public int UnpackedSint64Count { - get { return result.UnpackedSint64Count; } - } - public long GetUnpackedSint64(int index) { - return result.GetUnpackedSint64(index); - } - public Builder SetUnpackedSint64(int index, long value) { - PrepareBuilder(); - result.unpackedSint64_[index] = value; - return this; - } - public Builder AddUnpackedSint64(long value) { - PrepareBuilder(); - result.unpackedSint64_.Add(value); - return this; - } - public Builder AddRangeUnpackedSint64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSint64_.Add(values); - return this; - } - public Builder ClearUnpackedSint64() { - PrepareBuilder(); - result.unpackedSint64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedFixed32List { - get { return PrepareBuilder().unpackedFixed32_; } - } - public int UnpackedFixed32Count { - get { return result.UnpackedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedFixed32(int index) { - return result.GetUnpackedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedFixed32(int index, uint value) { - PrepareBuilder(); - result.unpackedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedFixed32(uint value) { - PrepareBuilder(); - result.unpackedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedFixed32_.Add(values); - return this; - } - public Builder ClearUnpackedFixed32() { - PrepareBuilder(); - result.unpackedFixed32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedFixed64List { - get { return PrepareBuilder().unpackedFixed64_; } - } - public int UnpackedFixed64Count { - get { return result.UnpackedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedFixed64(int index) { - return result.GetUnpackedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedFixed64(int index, ulong value) { - PrepareBuilder(); - result.unpackedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedFixed64(ulong value) { - PrepareBuilder(); - result.unpackedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedFixed64_.Add(values); - return this; - } - public Builder ClearUnpackedFixed64() { - PrepareBuilder(); - result.unpackedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSfixed32List { - get { return PrepareBuilder().unpackedSfixed32_; } - } - public int UnpackedSfixed32Count { - get { return result.UnpackedSfixed32Count; } - } - public int GetUnpackedSfixed32(int index) { - return result.GetUnpackedSfixed32(index); - } - public Builder SetUnpackedSfixed32(int index, int value) { - PrepareBuilder(); - result.unpackedSfixed32_[index] = value; - return this; - } - public Builder AddUnpackedSfixed32(int value) { - PrepareBuilder(); - result.unpackedSfixed32_.Add(value); - return this; - } - public Builder AddRangeUnpackedSfixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSfixed32_.Add(values); - return this; - } - public Builder ClearUnpackedSfixed32() { - PrepareBuilder(); - result.unpackedSfixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSfixed64List { - get { return PrepareBuilder().unpackedSfixed64_; } - } - public int UnpackedSfixed64Count { - get { return result.UnpackedSfixed64Count; } - } - public long GetUnpackedSfixed64(int index) { - return result.GetUnpackedSfixed64(index); - } - public Builder SetUnpackedSfixed64(int index, long value) { - PrepareBuilder(); - result.unpackedSfixed64_[index] = value; - return this; - } - public Builder AddUnpackedSfixed64(long value) { - PrepareBuilder(); - result.unpackedSfixed64_.Add(value); - return this; - } - public Builder AddRangeUnpackedSfixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSfixed64_.Add(values); - return this; - } - public Builder ClearUnpackedSfixed64() { - PrepareBuilder(); - result.unpackedSfixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedFloatList { - get { return PrepareBuilder().unpackedFloat_; } - } - public int UnpackedFloatCount { - get { return result.UnpackedFloatCount; } - } - public float GetUnpackedFloat(int index) { - return result.GetUnpackedFloat(index); - } - public Builder SetUnpackedFloat(int index, float value) { - PrepareBuilder(); - result.unpackedFloat_[index] = value; - return this; - } - public Builder AddUnpackedFloat(float value) { - PrepareBuilder(); - result.unpackedFloat_.Add(value); - return this; - } - public Builder AddRangeUnpackedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedFloat_.Add(values); - return this; - } - public Builder ClearUnpackedFloat() { - PrepareBuilder(); - result.unpackedFloat_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedDoubleList { - get { return PrepareBuilder().unpackedDouble_; } - } - public int UnpackedDoubleCount { - get { return result.UnpackedDoubleCount; } - } - public double GetUnpackedDouble(int index) { - return result.GetUnpackedDouble(index); - } - public Builder SetUnpackedDouble(int index, double value) { - PrepareBuilder(); - result.unpackedDouble_[index] = value; - return this; - } - public Builder AddUnpackedDouble(double value) { - PrepareBuilder(); - result.unpackedDouble_.Add(value); - return this; - } - public Builder AddRangeUnpackedDouble(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedDouble_.Add(values); - return this; - } - public Builder ClearUnpackedDouble() { - PrepareBuilder(); - result.unpackedDouble_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedBoolList { - get { return PrepareBuilder().unpackedBool_; } - } - public int UnpackedBoolCount { - get { return result.UnpackedBoolCount; } - } - public bool GetUnpackedBool(int index) { - return result.GetUnpackedBool(index); - } - public Builder SetUnpackedBool(int index, bool value) { - PrepareBuilder(); - result.unpackedBool_[index] = value; - return this; - } - public Builder AddUnpackedBool(bool value) { - PrepareBuilder(); - result.unpackedBool_.Add(value); - return this; - } - public Builder AddRangeUnpackedBool(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedBool_.Add(values); - return this; - } - public Builder ClearUnpackedBool() { - PrepareBuilder(); - result.unpackedBool_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedEnumList { - get { return PrepareBuilder().unpackedEnum_; } - } - public int UnpackedEnumCount { - get { return result.UnpackedEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite GetUnpackedEnum(int index) { - return result.GetUnpackedEnum(index); - } - public Builder SetUnpackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite value) { - PrepareBuilder(); - result.unpackedEnum_[index] = value; - return this; - } - public Builder AddUnpackedEnum(global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite value) { - PrepareBuilder(); - result.unpackedEnum_.Add(value); - return this; - } - public Builder AddRangeUnpackedEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedEnum_.Add(values); - return this; - } - public Builder ClearUnpackedEnum() { - PrepareBuilder(); - result.unpackedEnum_.Clear(); - return this; - } - } - static TestUnpackedTypesLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.Descriptor, null); - } - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class BucketOfBytes : pb::GeneratedMessageLite { - private BucketOfBytes() { } - private static readonly BucketOfBytes defaultInstance = new BucketOfBytes().MakeReadOnly(); - private static readonly string[] _bucketOfBytesFieldNames = new string[] { "value" }; - private static readonly uint[] _bucketOfBytesFieldTags = new uint[] { 10 }; - public static BucketOfBytes DefaultInstance { - get { return defaultInstance; } - } - - public override BucketOfBytes DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override BucketOfBytes ThisMessage { - get { return this; } - } - - public const int ValueFieldNumber = 1; - private bool hasValue; - private pb::ByteString value_ = pb::ByteString.Empty; - public bool HasValue { - get { return hasValue; } - } - public pb::ByteString Value { - get { return value_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _bucketOfBytesFieldNames; - if (hasValue) { - output.WriteBytes(1, field_names[0], Value); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasValue) { - size += pb::CodedOutputStream.ComputeBytesSize(1, Value); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasValue) hash ^= value_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - BucketOfBytes other = obj as BucketOfBytes; - if (other == null) return false; - if (hasValue != other.hasValue || (hasValue && !value_.Equals(other.value_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("value", hasValue, value_, writer); - } - #endregion - - public static BucketOfBytes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BucketOfBytes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BucketOfBytes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BucketOfBytes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BucketOfBytes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BucketOfBytes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static BucketOfBytes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static BucketOfBytes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static BucketOfBytes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BucketOfBytes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private BucketOfBytes MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(BucketOfBytes prototype) { - return new Builder(prototype); - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(BucketOfBytes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private BucketOfBytes result; - - private BucketOfBytes PrepareBuilder() { - if (resultIsReadOnly) { - BucketOfBytes original = result; - result = new BucketOfBytes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override BucketOfBytes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override BucketOfBytes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.BucketOfBytes.DefaultInstance; } - } - - public override BucketOfBytes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is BucketOfBytes) { - return MergeFrom((BucketOfBytes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(BucketOfBytes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.BucketOfBytes.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasValue) { - Value = other.Value; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_bucketOfBytesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _bucketOfBytesFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasValue = input.ReadBytes(ref result.value_); - break; - } - } - } - - return this; - } - - - public bool HasValue { - get { return result.hasValue; } - } - public pb::ByteString Value { - get { return result.Value; } - set { SetValue(value); } - } - public Builder SetValue(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasValue = true; - result.value_ = value; - return this; - } - public Builder ClearValue() { - PrepareBuilder(); - result.hasValue = false; - result.value_ = pb::ByteString.Empty; - return this; - } - } - static BucketOfBytes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.Descriptor, null); - } - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class BucketOfBytesEx : pb::GeneratedMessageLite { - private BucketOfBytesEx() { } - private static readonly BucketOfBytesEx defaultInstance = new BucketOfBytesEx().MakeReadOnly(); - private static readonly string[] _bucketOfBytesExFieldNames = new string[] { "value", "value2" }; - private static readonly uint[] _bucketOfBytesExFieldTags = new uint[] { 10, 2042 }; - public static BucketOfBytesEx DefaultInstance { - get { return defaultInstance; } - } - - public override BucketOfBytesEx DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override BucketOfBytesEx ThisMessage { - get { return this; } - } - - public const int ValueFieldNumber = 1; - private bool hasValue; - private pb::ByteString value_ = pb::ByteString.Empty; - public bool HasValue { - get { return hasValue; } - } - public pb::ByteString Value { - get { return value_; } - } - - public const int Value2FieldNumber = 255; - private bool hasValue2; - private pb::ByteString value2_ = pb::ByteString.Empty; - public bool HasValue2 { - get { return hasValue2; } - } - public pb::ByteString Value2 { - get { return value2_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _bucketOfBytesExFieldNames; - if (hasValue) { - output.WriteBytes(1, field_names[0], Value); - } - if (hasValue2) { - output.WriteBytes(255, field_names[1], Value2); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasValue) { - size += pb::CodedOutputStream.ComputeBytesSize(1, Value); - } - if (hasValue2) { - size += pb::CodedOutputStream.ComputeBytesSize(255, Value2); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasValue) hash ^= value_.GetHashCode(); - if (hasValue2) hash ^= value2_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - BucketOfBytesEx other = obj as BucketOfBytesEx; - if (other == null) return false; - if (hasValue != other.hasValue || (hasValue && !value_.Equals(other.value_))) return false; - if (hasValue2 != other.hasValue2 || (hasValue2 && !value2_.Equals(other.value2_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("value", hasValue, value_, writer); - PrintField("value2", hasValue2, value2_, writer); - } - #endregion - - public static BucketOfBytesEx ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BucketOfBytesEx ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BucketOfBytesEx ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BucketOfBytesEx ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BucketOfBytesEx ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BucketOfBytesEx ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static BucketOfBytesEx ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static BucketOfBytesEx ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static BucketOfBytesEx ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BucketOfBytesEx ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private BucketOfBytesEx MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(BucketOfBytesEx prototype) { - return new Builder(prototype); - } - - [global::System.SerializableAttribute()] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(BucketOfBytesEx cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private BucketOfBytesEx result; - - private BucketOfBytesEx PrepareBuilder() { - if (resultIsReadOnly) { - BucketOfBytesEx original = result; - result = new BucketOfBytesEx(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override BucketOfBytesEx MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override BucketOfBytesEx DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.BucketOfBytesEx.DefaultInstance; } - } - - public override BucketOfBytesEx BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is BucketOfBytesEx) { - return MergeFrom((BucketOfBytesEx) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(BucketOfBytesEx other) { - if (other == global::Google.ProtocolBuffers.TestProtos.BucketOfBytesEx.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasValue) { - Value = other.Value; - } - if (other.HasValue2) { - Value2 = other.Value2; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_bucketOfBytesExFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _bucketOfBytesExFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasValue = input.ReadBytes(ref result.value_); - break; - } - case 2042: { - result.hasValue2 = input.ReadBytes(ref result.value2_); - break; - } - } - } - - return this; - } - - - public bool HasValue { - get { return result.hasValue; } - } - public pb::ByteString Value { - get { return result.Value; } - set { SetValue(value); } - } - public Builder SetValue(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasValue = true; - result.value_ = value; - return this; - } - public Builder ClearValue() { - PrepareBuilder(); - result.hasValue = false; - result.value_ = pb::ByteString.Empty; - return this; - } - - public bool HasValue2 { - get { return result.hasValue2; } - } - public pb::ByteString Value2 { - get { return result.Value2; } - set { SetValue2(value); } - } - public Builder SetValue2(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasValue2 = true; - result.value2_ = value; - return this; - } - public Builder ClearValue2() { - PrepareBuilder(); - result.hasValue2 = false; - result.value2_ = pb::ByteString.Empty; - return this; - } - } - static BucketOfBytesEx() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestExtrasLiteProtoFile.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestImportLiteProtoFile.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestImportLiteProtoFile.cs deleted file mode 100644 index fe1f408f..00000000 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestImportLiteProtoFile.cs +++ /dev/null @@ -1,308 +0,0 @@ -// Generated by ProtoGen, Version=2.4.1.555, Culture=neutral, PublicKeyToken=55f7125234beb589. DO NOT EDIT! -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnitTestImportLiteProtoFile { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - } - #endregion - #region Static variables - #endregion - #region Extensions - internal static readonly object Descriptor; - static UnitTestImportLiteProtoFile() { - Descriptor = null; - } - #endregion - - } - #region Enums - public enum ImportEnumLite { - IMPORT_LITE_FOO = 7, - IMPORT_LITE_BAR = 8, - IMPORT_LITE_BAZ = 9, - } - - #endregion - - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class ImportMessageLite : pb::GeneratedMessageLite { - private ImportMessageLite() { } - private static readonly ImportMessageLite defaultInstance = new ImportMessageLite().MakeReadOnly(); - private static readonly string[] _importMessageLiteFieldNames = new string[] { "d" }; - private static readonly uint[] _importMessageLiteFieldTags = new uint[] { 8 }; - public static ImportMessageLite DefaultInstance { - get { return defaultInstance; } - } - - public override ImportMessageLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override ImportMessageLite ThisMessage { - get { return this; } - } - - public const int DFieldNumber = 1; - private bool hasD; - private int d_; - public bool HasD { - get { return hasD; } - } - public int D { - get { return d_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _importMessageLiteFieldNames; - if (hasD) { - output.WriteInt32(1, field_names[0], D); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasD) { - size += pb::CodedOutputStream.ComputeInt32Size(1, D); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasD) hash ^= d_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - ImportMessageLite other = obj as ImportMessageLite; - if (other == null) return false; - if (hasD != other.hasD || (hasD && !d_.Equals(other.d_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("d", hasD, d_, writer); - } - #endregion - - public static ImportMessageLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ImportMessageLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ImportMessageLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ImportMessageLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ImportMessageLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ImportMessageLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static ImportMessageLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static ImportMessageLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static ImportMessageLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ImportMessageLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private ImportMessageLite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(ImportMessageLite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(ImportMessageLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private ImportMessageLite result; - - private ImportMessageLite PrepareBuilder() { - if (resultIsReadOnly) { - ImportMessageLite original = result; - result = new ImportMessageLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override ImportMessageLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override ImportMessageLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance; } - } - - public override ImportMessageLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is ImportMessageLite) { - return MergeFrom((ImportMessageLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(ImportMessageLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasD) { - D = other.D; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_importMessageLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _importMessageLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasD = input.ReadInt32(ref result.d_); - break; - } - } - } - - return this; - } - - - public bool HasD { - get { return result.hasD; } - } - public int D { - get { return result.D; } - set { SetD(value); } - } - public Builder SetD(int value) { - PrepareBuilder(); - result.hasD = true; - result.d_ = value; - return this; - } - public Builder ClearD() { - PrepareBuilder(); - result.hasD = false; - result.d_ = 0; - return this; - } - } - static ImportMessageLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestImportLiteProtoFile.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestImportProtoFile.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestImportProtoFile.cs deleted file mode 100644 index 4cae2b8b..00000000 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestImportProtoFile.cs +++ /dev/null @@ -1,346 +0,0 @@ -// Generated by ProtoGen, Version=2.4.1.555, Culture=neutral, PublicKeyToken=55f7125234beb589. DO NOT EDIT! -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnitTestImportProtoFile { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - } - #endregion - #region Static variables - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_import_ImportMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_import_ImportMessage__FieldAccessorTable; - #endregion - #region Descriptor - public static pbd::FileDescriptor Descriptor { - get { return descriptor; } - } - private static pbd::FileDescriptor descriptor; - - static UnitTestImportProtoFile() { - byte[] descriptorData = global::System.Convert.FromBase64String( - string.Concat( - "CiVnb29nbGUvcHJvdG9idWYvdW5pdHRlc3RfaW1wb3J0LnByb3RvEhhwcm90", - "b2J1Zl91bml0dGVzdF9pbXBvcnQaJGdvb2dsZS9wcm90b2J1Zi9jc2hhcnBf", - "b3B0aW9ucy5wcm90byIaCg1JbXBvcnRNZXNzYWdlEgkKAWQYASABKAUqPAoK", - "SW1wb3J0RW51bRIOCgpJTVBPUlRfRk9PEAcSDgoKSU1QT1JUX0JBUhAIEg4K", - "CklNUE9SVF9CQVoQCUJbChhjb20uZ29vZ2xlLnByb3RvYnVmLnRlc3RIAcI+", - "PAohR29vZ2xlLlByb3RvY29sQnVmZmVycy5UZXN0UHJvdG9zEhdVbml0VGVz", - "dEltcG9ydFByb3RvRmlsZQ==")); - pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { - descriptor = root; - internal__static_protobuf_unittest_import_ImportMessage__Descriptor = Descriptor.MessageTypes[0]; - internal__static_protobuf_unittest_import_ImportMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_import_ImportMessage__Descriptor, - new string[] { "D", }); - pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); - RegisterAllExtensions(registry); - global::Google.ProtocolBuffers.DescriptorProtos.CSharpOptions.RegisterAllExtensions(registry); - return registry; - }; - pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, - new pbd::FileDescriptor[] { - global::Google.ProtocolBuffers.DescriptorProtos.CSharpOptions.Descriptor, - }, assigner); - } - #endregion - - } - #region Enums - public enum ImportEnum { - IMPORT_FOO = 7, - IMPORT_BAR = 8, - IMPORT_BAZ = 9, - } - - #endregion - - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class ImportMessage : pb::GeneratedMessage { - private ImportMessage() { } - private static readonly ImportMessage defaultInstance = new ImportMessage().MakeReadOnly(); - private static readonly string[] _importMessageFieldNames = new string[] { "d" }; - private static readonly uint[] _importMessageFieldTags = new uint[] { 8 }; - public static ImportMessage DefaultInstance { - get { return defaultInstance; } - } - - public override ImportMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override ImportMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestImportProtoFile.internal__static_protobuf_unittest_import_ImportMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestImportProtoFile.internal__static_protobuf_unittest_import_ImportMessage__FieldAccessorTable; } - } - - public const int DFieldNumber = 1; - private bool hasD; - private int d_; - public bool HasD { - get { return hasD; } - } - public int D { - get { return d_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _importMessageFieldNames; - if (hasD) { - output.WriteInt32(1, field_names[0], D); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasD) { - size += pb::CodedOutputStream.ComputeInt32Size(1, D); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static ImportMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ImportMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ImportMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ImportMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ImportMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ImportMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static ImportMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static ImportMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static ImportMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ImportMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private ImportMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(ImportMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(ImportMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private ImportMessage result; - - private ImportMessage PrepareBuilder() { - if (resultIsReadOnly) { - ImportMessage original = result; - result = new ImportMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override ImportMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.ImportMessage.Descriptor; } - } - - public override ImportMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance; } - } - - public override ImportMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is ImportMessage) { - return MergeFrom((ImportMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(ImportMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasD) { - D = other.D; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_importMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _importMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasD = input.ReadInt32(ref result.d_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasD { - get { return result.hasD; } - } - public int D { - get { return result.D; } - set { SetD(value); } - } - public Builder SetD(int value) { - PrepareBuilder(); - result.hasD = true; - result.d_ = value; - return this; - } - public Builder ClearD() { - PrepareBuilder(); - result.hasD = false; - result.d_ = 0; - return this; - } - } - static ImportMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestImportProtoFile.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestLiteImportNonLiteProtoFile.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestLiteImportNonLiteProtoFile.cs deleted file mode 100644 index 1ed29692..00000000 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestLiteImportNonLiteProtoFile.cs +++ /dev/null @@ -1,324 +0,0 @@ -// Generated by ProtoGen, Version=2.4.1.555, Culture=neutral, PublicKeyToken=55f7125234beb589. DO NOT EDIT! -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnitTestLiteImportNonLiteProtoFile { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - } - #endregion - #region Static variables - #endregion - #region Extensions - internal static readonly object Descriptor; - static UnitTestLiteImportNonLiteProtoFile() { - Descriptor = null; - } - #endregion - - } - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestLiteImportsNonlite : pb::GeneratedMessageLite { - private TestLiteImportsNonlite() { } - private static readonly TestLiteImportsNonlite defaultInstance = new TestLiteImportsNonlite().MakeReadOnly(); - private static readonly string[] _testLiteImportsNonliteFieldNames = new string[] { "message" }; - private static readonly uint[] _testLiteImportsNonliteFieldTags = new uint[] { 10 }; - public static TestLiteImportsNonlite DefaultInstance { - get { return defaultInstance; } - } - - public override TestLiteImportsNonlite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestLiteImportsNonlite ThisMessage { - get { return this; } - } - - public const int MessageFieldNumber = 1; - private bool hasMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes message_; - public bool HasMessage { - get { return hasMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Message { - get { return message_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testLiteImportsNonliteFieldNames; - if (hasMessage) { - output.WriteMessage(1, field_names[0], Message); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(1, Message); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasMessage) hash ^= message_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestLiteImportsNonlite other = obj as TestLiteImportsNonlite; - if (other == null) return false; - if (hasMessage != other.hasMessage || (hasMessage && !message_.Equals(other.message_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("message", hasMessage, message_, writer); - } - #endregion - - public static TestLiteImportsNonlite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestLiteImportsNonlite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestLiteImportsNonlite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestLiteImportsNonlite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestLiteImportsNonlite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestLiteImportsNonlite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestLiteImportsNonlite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestLiteImportsNonlite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestLiteImportsNonlite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestLiteImportsNonlite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestLiteImportsNonlite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestLiteImportsNonlite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestLiteImportsNonlite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestLiteImportsNonlite result; - - private TestLiteImportsNonlite PrepareBuilder() { - if (resultIsReadOnly) { - TestLiteImportsNonlite original = result; - result = new TestLiteImportsNonlite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestLiteImportsNonlite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestLiteImportsNonlite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestLiteImportsNonlite.DefaultInstance; } - } - - public override TestLiteImportsNonlite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestLiteImportsNonlite) { - return MergeFrom((TestLiteImportsNonlite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestLiteImportsNonlite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestLiteImportsNonlite.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasMessage) { - MergeMessage(other.Message); - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testLiteImportsNonliteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testLiteImportsNonliteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasMessage) { - subBuilder.MergeFrom(Message); - } - input.ReadMessage(subBuilder, extensionRegistry); - Message = subBuilder.BuildPartial(); - break; - } - } - } - - return this; - } - - - public bool HasMessage { - get { return result.hasMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Message { - get { return result.Message; } - set { SetMessage(value); } - } - public Builder SetMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasMessage = true; - result.message_ = value; - return this; - } - public Builder SetMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasMessage = true; - result.message_ = builderForValue.Build(); - return this; - } - public Builder MergeMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasMessage && - result.message_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.message_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.message_).MergeFrom(value).BuildPartial(); - } else { - result.message_ = value; - } - result.hasMessage = true; - return this; - } - public Builder ClearMessage() { - PrepareBuilder(); - result.hasMessage = false; - result.message_ = null; - return this; - } - } - static TestLiteImportsNonlite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteImportNonLiteProtoFile.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestLiteProtoFile.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestLiteProtoFile.cs deleted file mode 100644 index 5ddc7279..00000000 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestLiteProtoFile.cs +++ /dev/null @@ -1,8948 +0,0 @@ -// Generated by ProtoGen, Version=2.4.1.555, Culture=neutral, PublicKeyToken=55f7125234beb589. DO NOT EDIT! -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnitTestLiteProtoFile { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalInt32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalInt64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalUint32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalUint64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSint32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSint64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalFixed32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalFixed64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSfixed32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSfixed64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalFloatExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalDoubleExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalBoolExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalStringExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalBytesExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalGroupExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalNestedMessageExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalForeignMessageExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalImportMessageExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalNestedEnumExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalForeignEnumExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalImportEnumExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalStringPieceExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalCordExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedInt32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedInt64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedUint32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedUint64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSint32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSint64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedFixed32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedFixed64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSfixed32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSfixed64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedFloatExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedDoubleExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedBoolExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedStringExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedBytesExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedGroupExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedNestedMessageExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedForeignMessageExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedImportMessageExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedNestedEnumExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedForeignEnumExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedImportEnumExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedStringPieceExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedCordExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultInt32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultInt64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultUint32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultUint64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSint32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSint64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultFixed32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultFixed64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSfixed32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSfixed64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultFloatExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultDoubleExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultBoolExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultStringExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultBytesExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultNestedEnumExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultForeignEnumExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultImportEnumExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultStringPieceExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultCordExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedInt32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedInt64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedUint32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedUint64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSint32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSint64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedFixed32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedFixed64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSfixed32ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSfixed64ExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedFloatExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedDoubleExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedBoolExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedEnumExtensionLite); - registry.Add(global::Google.ProtocolBuffers.TestProtos.TestNestedExtensionLite.NestedExtension); - } - #endregion - #region Extensions - public const int OptionalInt32ExtensionLiteFieldNumber = 1; - public static pb::GeneratedExtensionLite OptionalInt32ExtensionLite; - public const int OptionalInt64ExtensionLiteFieldNumber = 2; - public static pb::GeneratedExtensionLite OptionalInt64ExtensionLite; - public const int OptionalUint32ExtensionLiteFieldNumber = 3; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionLite OptionalUint32ExtensionLite; - public const int OptionalUint64ExtensionLiteFieldNumber = 4; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionLite OptionalUint64ExtensionLite; - public const int OptionalSint32ExtensionLiteFieldNumber = 5; - public static pb::GeneratedExtensionLite OptionalSint32ExtensionLite; - public const int OptionalSint64ExtensionLiteFieldNumber = 6; - public static pb::GeneratedExtensionLite OptionalSint64ExtensionLite; - public const int OptionalFixed32ExtensionLiteFieldNumber = 7; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionLite OptionalFixed32ExtensionLite; - public const int OptionalFixed64ExtensionLiteFieldNumber = 8; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionLite OptionalFixed64ExtensionLite; - public const int OptionalSfixed32ExtensionLiteFieldNumber = 9; - public static pb::GeneratedExtensionLite OptionalSfixed32ExtensionLite; - public const int OptionalSfixed64ExtensionLiteFieldNumber = 10; - public static pb::GeneratedExtensionLite OptionalSfixed64ExtensionLite; - public const int OptionalFloatExtensionLiteFieldNumber = 11; - public static pb::GeneratedExtensionLite OptionalFloatExtensionLite; - public const int OptionalDoubleExtensionLiteFieldNumber = 12; - public static pb::GeneratedExtensionLite OptionalDoubleExtensionLite; - public const int OptionalBoolExtensionLiteFieldNumber = 13; - public static pb::GeneratedExtensionLite OptionalBoolExtensionLite; - public const int OptionalStringExtensionLiteFieldNumber = 14; - public static pb::GeneratedExtensionLite OptionalStringExtensionLite; - public const int OptionalBytesExtensionLiteFieldNumber = 15; - public static pb::GeneratedExtensionLite OptionalBytesExtensionLite; - public const int OptionalGroupExtensionLiteFieldNumber = 16; - public static pb::GeneratedExtensionLite OptionalGroupExtensionLite; - public const int OptionalNestedMessageExtensionLiteFieldNumber = 18; - public static pb::GeneratedExtensionLite OptionalNestedMessageExtensionLite; - public const int OptionalForeignMessageExtensionLiteFieldNumber = 19; - public static pb::GeneratedExtensionLite OptionalForeignMessageExtensionLite; - public const int OptionalImportMessageExtensionLiteFieldNumber = 20; - public static pb::GeneratedExtensionLite OptionalImportMessageExtensionLite; - public const int OptionalNestedEnumExtensionLiteFieldNumber = 21; - public static pb::GeneratedExtensionLite OptionalNestedEnumExtensionLite; - public const int OptionalForeignEnumExtensionLiteFieldNumber = 22; - public static pb::GeneratedExtensionLite OptionalForeignEnumExtensionLite; - public const int OptionalImportEnumExtensionLiteFieldNumber = 23; - public static pb::GeneratedExtensionLite OptionalImportEnumExtensionLite; - public const int OptionalStringPieceExtensionLiteFieldNumber = 24; - public static pb::GeneratedExtensionLite OptionalStringPieceExtensionLite; - public const int OptionalCordExtensionLiteFieldNumber = 25; - public static pb::GeneratedExtensionLite OptionalCordExtensionLite; - public const int RepeatedInt32ExtensionLiteFieldNumber = 31; - public static pb::GeneratedRepeatExtensionLite RepeatedInt32ExtensionLite; - public const int RepeatedInt64ExtensionLiteFieldNumber = 32; - public static pb::GeneratedRepeatExtensionLite RepeatedInt64ExtensionLite; - public const int RepeatedUint32ExtensionLiteFieldNumber = 33; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite RepeatedUint32ExtensionLite; - public const int RepeatedUint64ExtensionLiteFieldNumber = 34; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite RepeatedUint64ExtensionLite; - public const int RepeatedSint32ExtensionLiteFieldNumber = 35; - public static pb::GeneratedRepeatExtensionLite RepeatedSint32ExtensionLite; - public const int RepeatedSint64ExtensionLiteFieldNumber = 36; - public static pb::GeneratedRepeatExtensionLite RepeatedSint64ExtensionLite; - public const int RepeatedFixed32ExtensionLiteFieldNumber = 37; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite RepeatedFixed32ExtensionLite; - public const int RepeatedFixed64ExtensionLiteFieldNumber = 38; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite RepeatedFixed64ExtensionLite; - public const int RepeatedSfixed32ExtensionLiteFieldNumber = 39; - public static pb::GeneratedRepeatExtensionLite RepeatedSfixed32ExtensionLite; - public const int RepeatedSfixed64ExtensionLiteFieldNumber = 40; - public static pb::GeneratedRepeatExtensionLite RepeatedSfixed64ExtensionLite; - public const int RepeatedFloatExtensionLiteFieldNumber = 41; - public static pb::GeneratedRepeatExtensionLite RepeatedFloatExtensionLite; - public const int RepeatedDoubleExtensionLiteFieldNumber = 42; - public static pb::GeneratedRepeatExtensionLite RepeatedDoubleExtensionLite; - public const int RepeatedBoolExtensionLiteFieldNumber = 43; - public static pb::GeneratedRepeatExtensionLite RepeatedBoolExtensionLite; - public const int RepeatedStringExtensionLiteFieldNumber = 44; - public static pb::GeneratedRepeatExtensionLite RepeatedStringExtensionLite; - public const int RepeatedBytesExtensionLiteFieldNumber = 45; - public static pb::GeneratedRepeatExtensionLite RepeatedBytesExtensionLite; - public const int RepeatedGroupExtensionLiteFieldNumber = 46; - public static pb::GeneratedRepeatExtensionLite RepeatedGroupExtensionLite; - public const int RepeatedNestedMessageExtensionLiteFieldNumber = 48; - public static pb::GeneratedRepeatExtensionLite RepeatedNestedMessageExtensionLite; - public const int RepeatedForeignMessageExtensionLiteFieldNumber = 49; - public static pb::GeneratedRepeatExtensionLite RepeatedForeignMessageExtensionLite; - public const int RepeatedImportMessageExtensionLiteFieldNumber = 50; - public static pb::GeneratedRepeatExtensionLite RepeatedImportMessageExtensionLite; - public const int RepeatedNestedEnumExtensionLiteFieldNumber = 51; - public static pb::GeneratedRepeatExtensionLite RepeatedNestedEnumExtensionLite; - public const int RepeatedForeignEnumExtensionLiteFieldNumber = 52; - public static pb::GeneratedRepeatExtensionLite RepeatedForeignEnumExtensionLite; - public const int RepeatedImportEnumExtensionLiteFieldNumber = 53; - public static pb::GeneratedRepeatExtensionLite RepeatedImportEnumExtensionLite; - public const int RepeatedStringPieceExtensionLiteFieldNumber = 54; - public static pb::GeneratedRepeatExtensionLite RepeatedStringPieceExtensionLite; - public const int RepeatedCordExtensionLiteFieldNumber = 55; - public static pb::GeneratedRepeatExtensionLite RepeatedCordExtensionLite; - public const int DefaultInt32ExtensionLiteFieldNumber = 61; - public static pb::GeneratedExtensionLite DefaultInt32ExtensionLite; - public const int DefaultInt64ExtensionLiteFieldNumber = 62; - public static pb::GeneratedExtensionLite DefaultInt64ExtensionLite; - public const int DefaultUint32ExtensionLiteFieldNumber = 63; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionLite DefaultUint32ExtensionLite; - public const int DefaultUint64ExtensionLiteFieldNumber = 64; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionLite DefaultUint64ExtensionLite; - public const int DefaultSint32ExtensionLiteFieldNumber = 65; - public static pb::GeneratedExtensionLite DefaultSint32ExtensionLite; - public const int DefaultSint64ExtensionLiteFieldNumber = 66; - public static pb::GeneratedExtensionLite DefaultSint64ExtensionLite; - public const int DefaultFixed32ExtensionLiteFieldNumber = 67; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionLite DefaultFixed32ExtensionLite; - public const int DefaultFixed64ExtensionLiteFieldNumber = 68; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionLite DefaultFixed64ExtensionLite; - public const int DefaultSfixed32ExtensionLiteFieldNumber = 69; - public static pb::GeneratedExtensionLite DefaultSfixed32ExtensionLite; - public const int DefaultSfixed64ExtensionLiteFieldNumber = 70; - public static pb::GeneratedExtensionLite DefaultSfixed64ExtensionLite; - public const int DefaultFloatExtensionLiteFieldNumber = 71; - public static pb::GeneratedExtensionLite DefaultFloatExtensionLite; - public const int DefaultDoubleExtensionLiteFieldNumber = 72; - public static pb::GeneratedExtensionLite DefaultDoubleExtensionLite; - public const int DefaultBoolExtensionLiteFieldNumber = 73; - public static pb::GeneratedExtensionLite DefaultBoolExtensionLite; - public const int DefaultStringExtensionLiteFieldNumber = 74; - public static pb::GeneratedExtensionLite DefaultStringExtensionLite; - public const int DefaultBytesExtensionLiteFieldNumber = 75; - public static pb::GeneratedExtensionLite DefaultBytesExtensionLite; - public const int DefaultNestedEnumExtensionLiteFieldNumber = 81; - public static pb::GeneratedExtensionLite DefaultNestedEnumExtensionLite; - public const int DefaultForeignEnumExtensionLiteFieldNumber = 82; - public static pb::GeneratedExtensionLite DefaultForeignEnumExtensionLite; - public const int DefaultImportEnumExtensionLiteFieldNumber = 83; - public static pb::GeneratedExtensionLite DefaultImportEnumExtensionLite; - public const int DefaultStringPieceExtensionLiteFieldNumber = 84; - public static pb::GeneratedExtensionLite DefaultStringPieceExtensionLite; - public const int DefaultCordExtensionLiteFieldNumber = 85; - public static pb::GeneratedExtensionLite DefaultCordExtensionLite; - public const int PackedInt32ExtensionLiteFieldNumber = 90; - public static pb::GeneratedRepeatExtensionLite PackedInt32ExtensionLite; - public const int PackedInt64ExtensionLiteFieldNumber = 91; - public static pb::GeneratedRepeatExtensionLite PackedInt64ExtensionLite; - public const int PackedUint32ExtensionLiteFieldNumber = 92; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite PackedUint32ExtensionLite; - public const int PackedUint64ExtensionLiteFieldNumber = 93; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite PackedUint64ExtensionLite; - public const int PackedSint32ExtensionLiteFieldNumber = 94; - public static pb::GeneratedRepeatExtensionLite PackedSint32ExtensionLite; - public const int PackedSint64ExtensionLiteFieldNumber = 95; - public static pb::GeneratedRepeatExtensionLite PackedSint64ExtensionLite; - public const int PackedFixed32ExtensionLiteFieldNumber = 96; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite PackedFixed32ExtensionLite; - public const int PackedFixed64ExtensionLiteFieldNumber = 97; - [global::System.CLSCompliant(false)] - public static pb::GeneratedRepeatExtensionLite PackedFixed64ExtensionLite; - public const int PackedSfixed32ExtensionLiteFieldNumber = 98; - public static pb::GeneratedRepeatExtensionLite PackedSfixed32ExtensionLite; - public const int PackedSfixed64ExtensionLiteFieldNumber = 99; - public static pb::GeneratedRepeatExtensionLite PackedSfixed64ExtensionLite; - public const int PackedFloatExtensionLiteFieldNumber = 100; - public static pb::GeneratedRepeatExtensionLite PackedFloatExtensionLite; - public const int PackedDoubleExtensionLiteFieldNumber = 101; - public static pb::GeneratedRepeatExtensionLite PackedDoubleExtensionLite; - public const int PackedBoolExtensionLiteFieldNumber = 102; - public static pb::GeneratedRepeatExtensionLite PackedBoolExtensionLite; - public const int PackedEnumExtensionLiteFieldNumber = 103; - public static pb::GeneratedRepeatExtensionLite PackedEnumExtensionLite; - #endregion - - #region Static variables - #endregion - #region Extensions - internal static readonly object Descriptor; - static UnitTestLiteProtoFile() { - Descriptor = null; - global::Google.ProtocolBuffers.TestProtos.TestNestedExtensionLite.NestedExtension = - new pb::GeneratedExtensionLite( - "protobuf_unittest.TestNestedExtensionLite.nested_extension", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(int), - null, - null, - global::Google.ProtocolBuffers.TestProtos.TestNestedExtensionLite.NestedExtensionFieldNumber, - pbd::FieldType.Int32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalInt32ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_int32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(int), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalInt32ExtensionLiteFieldNumber, - pbd::FieldType.Int32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalInt64ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_int64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(long), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalInt64ExtensionLiteFieldNumber, - pbd::FieldType.Int64); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalUint32ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_uint32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(uint), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalUint32ExtensionLiteFieldNumber, - pbd::FieldType.UInt32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalUint64ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_uint64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(ulong), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalUint64ExtensionLiteFieldNumber, - pbd::FieldType.UInt64); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSint32ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_sint32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(int), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSint32ExtensionLiteFieldNumber, - pbd::FieldType.SInt32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSint64ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_sint64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(long), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSint64ExtensionLiteFieldNumber, - pbd::FieldType.SInt64); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalFixed32ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_fixed32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(uint), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalFixed32ExtensionLiteFieldNumber, - pbd::FieldType.Fixed32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalFixed64ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_fixed64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(ulong), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalFixed64ExtensionLiteFieldNumber, - pbd::FieldType.Fixed64); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSfixed32ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_sfixed32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(int), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSfixed32ExtensionLiteFieldNumber, - pbd::FieldType.SFixed32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSfixed64ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_sfixed64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(long), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalSfixed64ExtensionLiteFieldNumber, - pbd::FieldType.SFixed64); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalFloatExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_float_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(float), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalFloatExtensionLiteFieldNumber, - pbd::FieldType.Float); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalDoubleExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_double_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(double), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalDoubleExtensionLiteFieldNumber, - pbd::FieldType.Double); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalBoolExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_bool_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(bool), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalBoolExtensionLiteFieldNumber, - pbd::FieldType.Bool); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalStringExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_string_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalStringExtensionLiteFieldNumber, - pbd::FieldType.String); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalBytesExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_bytes_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalBytesExtensionLiteFieldNumber, - pbd::FieldType.Bytes); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalGroupExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optionalgroup_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension_lite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalGroupExtensionLiteFieldNumber, - pbd::FieldType.Group); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalNestedMessageExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_nested_message_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalNestedMessageExtensionLiteFieldNumber, - pbd::FieldType.Message); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalForeignMessageExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_foreign_message_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalForeignMessageExtensionLiteFieldNumber, - pbd::FieldType.Message); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalImportMessageExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_import_message_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalImportMessageExtensionLiteFieldNumber, - pbd::FieldType.Message); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalNestedEnumExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_nested_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum), - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalNestedEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalForeignEnumExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_foreign_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite), - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalForeignEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalImportEnumExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_import_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - default(global::Google.ProtocolBuffers.TestProtos.ImportEnumLite), - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalImportEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalStringPieceExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_string_piece_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalStringPieceExtensionLiteFieldNumber, - pbd::FieldType.String); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalCordExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.optional_cord_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.OptionalCordExtensionLiteFieldNumber, - pbd::FieldType.String); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedInt32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_int32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedInt32ExtensionLiteFieldNumber, - pbd::FieldType.Int32, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedInt64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_int64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedInt64ExtensionLiteFieldNumber, - pbd::FieldType.Int64, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedUint32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_uint32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedUint32ExtensionLiteFieldNumber, - pbd::FieldType.UInt32, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedUint64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_uint64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedUint64ExtensionLiteFieldNumber, - pbd::FieldType.UInt64, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSint32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_sint32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSint32ExtensionLiteFieldNumber, - pbd::FieldType.SInt32, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSint64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_sint64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSint64ExtensionLiteFieldNumber, - pbd::FieldType.SInt64, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedFixed32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_fixed32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedFixed32ExtensionLiteFieldNumber, - pbd::FieldType.Fixed32, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedFixed64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_fixed64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedFixed64ExtensionLiteFieldNumber, - pbd::FieldType.Fixed64, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSfixed32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_sfixed32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSfixed32ExtensionLiteFieldNumber, - pbd::FieldType.SFixed32, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSfixed64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_sfixed64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedSfixed64ExtensionLiteFieldNumber, - pbd::FieldType.SFixed64, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedFloatExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_float_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedFloatExtensionLiteFieldNumber, - pbd::FieldType.Float, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedDoubleExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_double_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedDoubleExtensionLiteFieldNumber, - pbd::FieldType.Double, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedBoolExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_bool_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedBoolExtensionLiteFieldNumber, - pbd::FieldType.Bool, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedStringExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_string_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedStringExtensionLiteFieldNumber, - pbd::FieldType.String, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedBytesExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_bytes_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedBytesExtensionLiteFieldNumber, - pbd::FieldType.Bytes, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedGroupExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeatedgroup_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension_lite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedGroupExtensionLiteFieldNumber, - pbd::FieldType.Group, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedNestedMessageExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_nested_message_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedNestedMessageExtensionLiteFieldNumber, - pbd::FieldType.Message, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedForeignMessageExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_foreign_message_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedForeignMessageExtensionLiteFieldNumber, - pbd::FieldType.Message, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedImportMessageExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_import_message_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedImportMessageExtensionLiteFieldNumber, - pbd::FieldType.Message, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedNestedEnumExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_nested_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedNestedEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedForeignEnumExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_foreign_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedForeignEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedImportEnumExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_import_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedImportEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedStringPieceExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_string_piece_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedStringPieceExtensionLiteFieldNumber, - pbd::FieldType.String, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedCordExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.repeated_cord_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.RepeatedCordExtensionLiteFieldNumber, - pbd::FieldType.String, - false); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultInt32ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_int32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - 41, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultInt32ExtensionLiteFieldNumber, - pbd::FieldType.Int32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultInt64ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_int64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - 42L, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultInt64ExtensionLiteFieldNumber, - pbd::FieldType.Int64); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultUint32ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_uint32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - 43, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultUint32ExtensionLiteFieldNumber, - pbd::FieldType.UInt32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultUint64ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_uint64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - 44UL, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultUint64ExtensionLiteFieldNumber, - pbd::FieldType.UInt64); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSint32ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_sint32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - -45, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSint32ExtensionLiteFieldNumber, - pbd::FieldType.SInt32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSint64ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_sint64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - 46, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSint64ExtensionLiteFieldNumber, - pbd::FieldType.SInt64); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultFixed32ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_fixed32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - 47, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultFixed32ExtensionLiteFieldNumber, - pbd::FieldType.Fixed32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultFixed64ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_fixed64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - 48, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultFixed64ExtensionLiteFieldNumber, - pbd::FieldType.Fixed64); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSfixed32ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_sfixed32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - 49, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSfixed32ExtensionLiteFieldNumber, - pbd::FieldType.SFixed32); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSfixed64ExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_sfixed64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - -50, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultSfixed64ExtensionLiteFieldNumber, - pbd::FieldType.SFixed64); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultFloatExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_float_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - 51.5F, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultFloatExtensionLiteFieldNumber, - pbd::FieldType.Float); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultDoubleExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_double_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - 52000D, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultDoubleExtensionLiteFieldNumber, - pbd::FieldType.Double); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultBoolExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_bool_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - true, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultBoolExtensionLiteFieldNumber, - pbd::FieldType.Bool); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultStringExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_string_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - "hello", - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultStringExtensionLiteFieldNumber, - pbd::FieldType.String); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultBytesExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_bytes_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - pb::ByteString.FromBase64("d29ybGQ="), - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultBytesExtensionLiteFieldNumber, - pbd::FieldType.Bytes); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultNestedEnumExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_nested_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum.BAR, - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultNestedEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultForeignEnumExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_foreign_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite.FOREIGN_LITE_BAR, - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultForeignEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultImportEnumExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_import_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - global::Google.ProtocolBuffers.TestProtos.ImportEnumLite.IMPORT_LITE_BAR, - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultImportEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultStringPieceExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_string_piece_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - "abc", - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultStringPieceExtensionLiteFieldNumber, - pbd::FieldType.String); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultCordExtensionLite = - new pb::GeneratedExtensionLite( - "protobuf_unittest.default_cord_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, - "123", - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.DefaultCordExtensionLiteFieldNumber, - pbd::FieldType.String); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedInt32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_int32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedInt32ExtensionLiteFieldNumber, - pbd::FieldType.Int32, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedInt64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_int64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedInt64ExtensionLiteFieldNumber, - pbd::FieldType.Int64, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedUint32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_uint32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedUint32ExtensionLiteFieldNumber, - pbd::FieldType.UInt32, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedUint64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_uint64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedUint64ExtensionLiteFieldNumber, - pbd::FieldType.UInt64, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSint32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_sint32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSint32ExtensionLiteFieldNumber, - pbd::FieldType.SInt32, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSint64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_sint64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSint64ExtensionLiteFieldNumber, - pbd::FieldType.SInt64, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedFixed32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_fixed32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedFixed32ExtensionLiteFieldNumber, - pbd::FieldType.Fixed32, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedFixed64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_fixed64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedFixed64ExtensionLiteFieldNumber, - pbd::FieldType.Fixed64, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSfixed32ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_sfixed32_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSfixed32ExtensionLiteFieldNumber, - pbd::FieldType.SFixed32, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSfixed64ExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_sfixed64_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedSfixed64ExtensionLiteFieldNumber, - pbd::FieldType.SFixed64, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedFloatExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_float_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedFloatExtensionLiteFieldNumber, - pbd::FieldType.Float, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedDoubleExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_double_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedDoubleExtensionLiteFieldNumber, - pbd::FieldType.Double, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedBoolExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_bool_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - null, - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedBoolExtensionLiteFieldNumber, - pbd::FieldType.Bool, - true); - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedEnumExtensionLite = - new pb::GeneratedRepeatExtensionLite( - "protobuf_unittest.packed_enum_extension_lite", - global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, - null, - new EnumLiteMap(), - global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.PackedEnumExtensionLiteFieldNumber, - pbd::FieldType.Enum, - true); - } - #endregion - - } - #region Enums - public enum ForeignEnumLite { - FOREIGN_LITE_FOO = 4, - FOREIGN_LITE_BAR = 5, - FOREIGN_LITE_BAZ = 6, - } - - #endregion - - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestAllTypesLite : pb::GeneratedMessageLite { - private TestAllTypesLite() { } - private static readonly TestAllTypesLite defaultInstance = new TestAllTypesLite().MakeReadOnly(); - private static readonly string[] _testAllTypesLiteFieldNames = new string[] { "default_bool", "default_bytes", "default_cord", "default_double", "default_fixed32", "default_fixed64", "default_float", "default_foreign_enum", "default_import_enum", "default_int32", "default_int64", "default_nested_enum", "default_sfixed32", "default_sfixed64", "default_sint32", "default_sint64", "default_string", "default_string_piece", "default_uint32", "default_uint64", "optional_bool", "optional_bytes", "optional_cord", "optional_double", "optional_fixed32", "optional_fixed64", "optional_float", "optional_foreign_enum", "optional_foreign_message", "optional_import_enum", "optional_import_message", "optional_int32", "optional_int64", "optional_nested_enum", "optional_nested_message", "optional_sfixed32", "optional_sfixed64", "optional_sint32", "optional_sint64", "optional_string", "optional_string_piece", "optional_uint32", "optional_uint64", "optionalgroup", "repeated_bool", "repeated_bytes", "repeated_cord", "repeated_double", "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_foreign_enum", "repeated_foreign_message", "repeated_import_enum", "repeated_import_message", "repeated_int32", "repeated_int64", "repeated_nested_enum", "repeated_nested_message", "repeated_sfixed32", "repeated_sfixed64", "repeated_sint32", "repeated_sint64", "repeated_string", "repeated_string_piece", "repeated_uint32", "repeated_uint64", "repeatedgroup" }; - private static readonly uint[] _testAllTypesLiteFieldTags = new uint[] { 584, 602, 682, 577, 541, 545, 573, 656, 664, 488, 496, 648, 557, 561, 520, 528, 594, 674, 504, 512, 104, 122, 202, 97, 61, 65, 93, 176, 154, 184, 162, 8, 16, 168, 146, 77, 81, 40, 48, 114, 194, 24, 32, 131, 344, 362, 442, 337, 301, 305, 333, 416, 394, 424, 402, 248, 256, 408, 386, 317, 321, 280, 288, 354, 434, 264, 272, 371 }; - public static TestAllTypesLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestAllTypesLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestAllTypesLite ThisMessage { - get { return this; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - public enum NestedEnum { - FOO = 1, - BAR = 2, - BAZ = 3, - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NestedMessage : pb::GeneratedMessageLite { - private NestedMessage() { } - private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); - private static readonly string[] _nestedMessageFieldNames = new string[] { "bb" }; - private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8 }; - public static NestedMessage DefaultInstance { - get { return defaultInstance; } - } - - public override NestedMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override NestedMessage ThisMessage { - get { return this; } - } - - public const int BbFieldNumber = 1; - private bool hasBb; - private int bb_; - public bool HasBb { - get { return hasBb; } - } - public int Bb { - get { return bb_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _nestedMessageFieldNames; - if (hasBb) { - output.WriteInt32(1, field_names[0], Bb); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasBb) { - size += pb::CodedOutputStream.ComputeInt32Size(1, Bb); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasBb) hash ^= bb_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - NestedMessage other = obj as NestedMessage; - if (other == null) return false; - if (hasBb != other.hasBb || (hasBb && !bb_.Equals(other.bb_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("bb", hasBb, bb_, writer); - } - #endregion - - public static NestedMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NestedMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NestedMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NestedMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NestedMessage result; - - private NestedMessage PrepareBuilder() { - if (resultIsReadOnly) { - NestedMessage original = result; - result = new NestedMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NestedMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override NestedMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance; } - } - - public override NestedMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is NestedMessage) { - return MergeFrom((NestedMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(NestedMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasBb) { - Bb = other.Bb; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _nestedMessageFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasBb = input.ReadInt32(ref result.bb_); - break; - } - } - } - - return this; - } - - - public bool HasBb { - get { return result.hasBb; } - } - public int Bb { - get { return result.Bb; } - set { SetBb(value); } - } - public Builder SetBb(int value) { - PrepareBuilder(); - result.hasBb = true; - result.bb_ = value; - return this; - } - public Builder ClearBb() { - PrepareBuilder(); - result.hasBb = false; - result.bb_ = 0; - return this; - } - } - static NestedMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OptionalGroup : pb::GeneratedMessageLite { - private OptionalGroup() { } - private static readonly OptionalGroup defaultInstance = new OptionalGroup().MakeReadOnly(); - private static readonly string[] _optionalGroupFieldNames = new string[] { "a" }; - private static readonly uint[] _optionalGroupFieldTags = new uint[] { 136 }; - public static OptionalGroup DefaultInstance { - get { return defaultInstance; } - } - - public override OptionalGroup DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override OptionalGroup ThisMessage { - get { return this; } - } - - public const int AFieldNumber = 17; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _optionalGroupFieldNames; - if (hasA) { - output.WriteInt32(17, field_names[0], A); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(17, A); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasA) hash ^= a_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - OptionalGroup other = obj as OptionalGroup; - if (other == null) return false; - if (hasA != other.hasA || (hasA && !a_.Equals(other.a_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("a", hasA, a_, writer); - } - #endregion - - public static OptionalGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static OptionalGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private OptionalGroup MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OptionalGroup prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OptionalGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OptionalGroup result; - - private OptionalGroup PrepareBuilder() { - if (resultIsReadOnly) { - OptionalGroup original = result; - result = new OptionalGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OptionalGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override OptionalGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.DefaultInstance; } - } - - public override OptionalGroup BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is OptionalGroup) { - return MergeFrom((OptionalGroup) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(OptionalGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _optionalGroupFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 136: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static OptionalGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class RepeatedGroup : pb::GeneratedMessageLite { - private RepeatedGroup() { } - private static readonly RepeatedGroup defaultInstance = new RepeatedGroup().MakeReadOnly(); - private static readonly string[] _repeatedGroupFieldNames = new string[] { "a" }; - private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 376 }; - public static RepeatedGroup DefaultInstance { - get { return defaultInstance; } - } - - public override RepeatedGroup DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override RepeatedGroup ThisMessage { - get { return this; } - } - - public const int AFieldNumber = 47; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _repeatedGroupFieldNames; - if (hasA) { - output.WriteInt32(47, field_names[0], A); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(47, A); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasA) hash ^= a_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - RepeatedGroup other = obj as RepeatedGroup; - if (other == null) return false; - if (hasA != other.hasA || (hasA && !a_.Equals(other.a_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("a", hasA, a_, writer); - } - #endregion - - public static RepeatedGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private RepeatedGroup MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(RepeatedGroup prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(RepeatedGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private RepeatedGroup result; - - private RepeatedGroup PrepareBuilder() { - if (resultIsReadOnly) { - RepeatedGroup original = result; - result = new RepeatedGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override RepeatedGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override RepeatedGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup.DefaultInstance; } - } - - public override RepeatedGroup BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is RepeatedGroup) { - return MergeFrom((RepeatedGroup) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(RepeatedGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _repeatedGroupFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 376: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static RepeatedGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - } - #endregion - - public const int OptionalInt32FieldNumber = 1; - private bool hasOptionalInt32; - private int optionalInt32_; - public bool HasOptionalInt32 { - get { return hasOptionalInt32; } - } - public int OptionalInt32 { - get { return optionalInt32_; } - } - - public const int OptionalInt64FieldNumber = 2; - private bool hasOptionalInt64; - private long optionalInt64_; - public bool HasOptionalInt64 { - get { return hasOptionalInt64; } - } - public long OptionalInt64 { - get { return optionalInt64_; } - } - - public const int OptionalUint32FieldNumber = 3; - private bool hasOptionalUint32; - private uint optionalUint32_; - public bool HasOptionalUint32 { - get { return hasOptionalUint32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalUint32 { - get { return optionalUint32_; } - } - - public const int OptionalUint64FieldNumber = 4; - private bool hasOptionalUint64; - private ulong optionalUint64_; - public bool HasOptionalUint64 { - get { return hasOptionalUint64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalUint64 { - get { return optionalUint64_; } - } - - public const int OptionalSint32FieldNumber = 5; - private bool hasOptionalSint32; - private int optionalSint32_; - public bool HasOptionalSint32 { - get { return hasOptionalSint32; } - } - public int OptionalSint32 { - get { return optionalSint32_; } - } - - public const int OptionalSint64FieldNumber = 6; - private bool hasOptionalSint64; - private long optionalSint64_; - public bool HasOptionalSint64 { - get { return hasOptionalSint64; } - } - public long OptionalSint64 { - get { return optionalSint64_; } - } - - public const int OptionalFixed32FieldNumber = 7; - private bool hasOptionalFixed32; - private uint optionalFixed32_; - public bool HasOptionalFixed32 { - get { return hasOptionalFixed32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalFixed32 { - get { return optionalFixed32_; } - } - - public const int OptionalFixed64FieldNumber = 8; - private bool hasOptionalFixed64; - private ulong optionalFixed64_; - public bool HasOptionalFixed64 { - get { return hasOptionalFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalFixed64 { - get { return optionalFixed64_; } - } - - public const int OptionalSfixed32FieldNumber = 9; - private bool hasOptionalSfixed32; - private int optionalSfixed32_; - public bool HasOptionalSfixed32 { - get { return hasOptionalSfixed32; } - } - public int OptionalSfixed32 { - get { return optionalSfixed32_; } - } - - public const int OptionalSfixed64FieldNumber = 10; - private bool hasOptionalSfixed64; - private long optionalSfixed64_; - public bool HasOptionalSfixed64 { - get { return hasOptionalSfixed64; } - } - public long OptionalSfixed64 { - get { return optionalSfixed64_; } - } - - public const int OptionalFloatFieldNumber = 11; - private bool hasOptionalFloat; - private float optionalFloat_; - public bool HasOptionalFloat { - get { return hasOptionalFloat; } - } - public float OptionalFloat { - get { return optionalFloat_; } - } - - public const int OptionalDoubleFieldNumber = 12; - private bool hasOptionalDouble; - private double optionalDouble_; - public bool HasOptionalDouble { - get { return hasOptionalDouble; } - } - public double OptionalDouble { - get { return optionalDouble_; } - } - - public const int OptionalBoolFieldNumber = 13; - private bool hasOptionalBool; - private bool optionalBool_; - public bool HasOptionalBool { - get { return hasOptionalBool; } - } - public bool OptionalBool { - get { return optionalBool_; } - } - - public const int OptionalStringFieldNumber = 14; - private bool hasOptionalString; - private string optionalString_ = ""; - public bool HasOptionalString { - get { return hasOptionalString; } - } - public string OptionalString { - get { return optionalString_; } - } - - public const int OptionalBytesFieldNumber = 15; - private bool hasOptionalBytes; - private pb::ByteString optionalBytes_ = pb::ByteString.Empty; - public bool HasOptionalBytes { - get { return hasOptionalBytes; } - } - public pb::ByteString OptionalBytes { - get { return optionalBytes_; } - } - - public const int OptionalGroupFieldNumber = 16; - private bool hasOptionalGroup; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup optionalGroup_; - public bool HasOptionalGroup { - get { return hasOptionalGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup OptionalGroup { - get { return optionalGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.DefaultInstance; } - } - - public const int OptionalNestedMessageFieldNumber = 18; - private bool hasOptionalNestedMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage optionalNestedMessage_; - public bool HasOptionalNestedMessage { - get { return hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage OptionalNestedMessage { - get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance; } - } - - public const int OptionalForeignMessageFieldNumber = 19; - private bool hasOptionalForeignMessage; - private global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite optionalForeignMessage_; - public bool HasOptionalForeignMessage { - get { return hasOptionalForeignMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite OptionalForeignMessage { - get { return optionalForeignMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance; } - } - - public const int OptionalImportMessageFieldNumber = 20; - private bool hasOptionalImportMessage; - private global::Google.ProtocolBuffers.TestProtos.ImportMessageLite optionalImportMessage_; - public bool HasOptionalImportMessage { - get { return hasOptionalImportMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessageLite OptionalImportMessage { - get { return optionalImportMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance; } - } - - public const int OptionalNestedEnumFieldNumber = 21; - private bool hasOptionalNestedEnum; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum.FOO; - public bool HasOptionalNestedEnum { - get { return hasOptionalNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum OptionalNestedEnum { - get { return optionalNestedEnum_; } - } - - public const int OptionalForeignEnumFieldNumber = 22; - private bool hasOptionalForeignEnum; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite.FOREIGN_LITE_FOO; - public bool HasOptionalForeignEnum { - get { return hasOptionalForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite OptionalForeignEnum { - get { return optionalForeignEnum_; } - } - - public const int OptionalImportEnumFieldNumber = 23; - private bool hasOptionalImportEnum; - private global::Google.ProtocolBuffers.TestProtos.ImportEnumLite optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnumLite.IMPORT_LITE_FOO; - public bool HasOptionalImportEnum { - get { return hasOptionalImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite OptionalImportEnum { - get { return optionalImportEnum_; } - } - - public const int OptionalStringPieceFieldNumber = 24; - private bool hasOptionalStringPiece; - private string optionalStringPiece_ = ""; - public bool HasOptionalStringPiece { - get { return hasOptionalStringPiece; } - } - public string OptionalStringPiece { - get { return optionalStringPiece_; } - } - - public const int OptionalCordFieldNumber = 25; - private bool hasOptionalCord; - private string optionalCord_ = ""; - public bool HasOptionalCord { - get { return hasOptionalCord; } - } - public string OptionalCord { - get { return optionalCord_; } - } - - public const int RepeatedInt32FieldNumber = 31; - private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt32List { - get { return pbc::Lists.AsReadOnly(repeatedInt32_); } - } - public int RepeatedInt32Count { - get { return repeatedInt32_.Count; } - } - public int GetRepeatedInt32(int index) { - return repeatedInt32_[index]; - } - - public const int RepeatedInt64FieldNumber = 32; - private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt64List { - get { return pbc::Lists.AsReadOnly(repeatedInt64_); } - } - public int RepeatedInt64Count { - get { return repeatedInt64_.Count; } - } - public long GetRepeatedInt64(int index) { - return repeatedInt64_[index]; - } - - public const int RepeatedUint32FieldNumber = 33; - private pbc::PopsicleList repeatedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedUint32List { - get { return pbc::Lists.AsReadOnly(repeatedUint32_); } - } - public int RepeatedUint32Count { - get { return repeatedUint32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedUint32(int index) { - return repeatedUint32_[index]; - } - - public const int RepeatedUint64FieldNumber = 34; - private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedUint64List { - get { return pbc::Lists.AsReadOnly(repeatedUint64_); } - } - public int RepeatedUint64Count { - get { return repeatedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return repeatedUint64_[index]; - } - - public const int RepeatedSint32FieldNumber = 35; - private pbc::PopsicleList repeatedSint32_ = new pbc::PopsicleList(); - public scg::IList RepeatedSint32List { - get { return pbc::Lists.AsReadOnly(repeatedSint32_); } - } - public int RepeatedSint32Count { - get { return repeatedSint32_.Count; } - } - public int GetRepeatedSint32(int index) { - return repeatedSint32_[index]; - } - - public const int RepeatedSint64FieldNumber = 36; - private pbc::PopsicleList repeatedSint64_ = new pbc::PopsicleList(); - public scg::IList RepeatedSint64List { - get { return pbc::Lists.AsReadOnly(repeatedSint64_); } - } - public int RepeatedSint64Count { - get { return repeatedSint64_.Count; } - } - public long GetRepeatedSint64(int index) { - return repeatedSint64_[index]; - } - - public const int RepeatedFixed32FieldNumber = 37; - private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed32List { - get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } - } - public int RepeatedFixed32Count { - get { return repeatedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return repeatedFixed32_[index]; - } - - public const int RepeatedFixed64FieldNumber = 38; - private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed64List { - get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } - } - public int RepeatedFixed64Count { - get { return repeatedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return repeatedFixed64_[index]; - } - - public const int RepeatedSfixed32FieldNumber = 39; - private pbc::PopsicleList repeatedSfixed32_ = new pbc::PopsicleList(); - public scg::IList RepeatedSfixed32List { - get { return pbc::Lists.AsReadOnly(repeatedSfixed32_); } - } - public int RepeatedSfixed32Count { - get { return repeatedSfixed32_.Count; } - } - public int GetRepeatedSfixed32(int index) { - return repeatedSfixed32_[index]; - } - - public const int RepeatedSfixed64FieldNumber = 40; - private pbc::PopsicleList repeatedSfixed64_ = new pbc::PopsicleList(); - public scg::IList RepeatedSfixed64List { - get { return pbc::Lists.AsReadOnly(repeatedSfixed64_); } - } - public int RepeatedSfixed64Count { - get { return repeatedSfixed64_.Count; } - } - public long GetRepeatedSfixed64(int index) { - return repeatedSfixed64_[index]; - } - - public const int RepeatedFloatFieldNumber = 41; - private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); - public scg::IList RepeatedFloatList { - get { return pbc::Lists.AsReadOnly(repeatedFloat_); } - } - public int RepeatedFloatCount { - get { return repeatedFloat_.Count; } - } - public float GetRepeatedFloat(int index) { - return repeatedFloat_[index]; - } - - public const int RepeatedDoubleFieldNumber = 42; - private pbc::PopsicleList repeatedDouble_ = new pbc::PopsicleList(); - public scg::IList RepeatedDoubleList { - get { return pbc::Lists.AsReadOnly(repeatedDouble_); } - } - public int RepeatedDoubleCount { - get { return repeatedDouble_.Count; } - } - public double GetRepeatedDouble(int index) { - return repeatedDouble_[index]; - } - - public const int RepeatedBoolFieldNumber = 43; - private pbc::PopsicleList repeatedBool_ = new pbc::PopsicleList(); - public scg::IList RepeatedBoolList { - get { return pbc::Lists.AsReadOnly(repeatedBool_); } - } - public int RepeatedBoolCount { - get { return repeatedBool_.Count; } - } - public bool GetRepeatedBool(int index) { - return repeatedBool_[index]; - } - - public const int RepeatedStringFieldNumber = 44; - private pbc::PopsicleList repeatedString_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringList { - get { return pbc::Lists.AsReadOnly(repeatedString_); } - } - public int RepeatedStringCount { - get { return repeatedString_.Count; } - } - public string GetRepeatedString(int index) { - return repeatedString_[index]; - } - - public const int RepeatedBytesFieldNumber = 45; - private pbc::PopsicleList repeatedBytes_ = new pbc::PopsicleList(); - public scg::IList RepeatedBytesList { - get { return pbc::Lists.AsReadOnly(repeatedBytes_); } - } - public int RepeatedBytesCount { - get { return repeatedBytes_.Count; } - } - public pb::ByteString GetRepeatedBytes(int index) { - return repeatedBytes_[index]; - } - - public const int RepeatedGroupFieldNumber = 46; - private pbc::PopsicleList repeatedGroup_ = new pbc::PopsicleList(); - public scg::IList RepeatedGroupList { - get { return repeatedGroup_; } - } - public int RepeatedGroupCount { - get { return repeatedGroup_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup GetRepeatedGroup(int index) { - return repeatedGroup_[index]; - } - - public const int RepeatedNestedMessageFieldNumber = 48; - private pbc::PopsicleList repeatedNestedMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedNestedMessageList { - get { return repeatedNestedMessage_; } - } - public int RepeatedNestedMessageCount { - get { return repeatedNestedMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage GetRepeatedNestedMessage(int index) { - return repeatedNestedMessage_[index]; - } - - public const int RepeatedForeignMessageFieldNumber = 49; - private pbc::PopsicleList repeatedForeignMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedForeignMessageList { - get { return repeatedForeignMessage_; } - } - public int RepeatedForeignMessageCount { - get { return repeatedForeignMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite GetRepeatedForeignMessage(int index) { - return repeatedForeignMessage_[index]; - } - - public const int RepeatedImportMessageFieldNumber = 50; - private pbc::PopsicleList repeatedImportMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedImportMessageList { - get { return repeatedImportMessage_; } - } - public int RepeatedImportMessageCount { - get { return repeatedImportMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessageLite GetRepeatedImportMessage(int index) { - return repeatedImportMessage_[index]; - } - - public const int RepeatedNestedEnumFieldNumber = 51; - private pbc::PopsicleList repeatedNestedEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedNestedEnumList { - get { return pbc::Lists.AsReadOnly(repeatedNestedEnum_); } - } - public int RepeatedNestedEnumCount { - get { return repeatedNestedEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum GetRepeatedNestedEnum(int index) { - return repeatedNestedEnum_[index]; - } - - public const int RepeatedForeignEnumFieldNumber = 52; - private pbc::PopsicleList repeatedForeignEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedForeignEnumList { - get { return pbc::Lists.AsReadOnly(repeatedForeignEnum_); } - } - public int RepeatedForeignEnumCount { - get { return repeatedForeignEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite GetRepeatedForeignEnum(int index) { - return repeatedForeignEnum_[index]; - } - - public const int RepeatedImportEnumFieldNumber = 53; - private pbc::PopsicleList repeatedImportEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedImportEnumList { - get { return pbc::Lists.AsReadOnly(repeatedImportEnum_); } - } - public int RepeatedImportEnumCount { - get { return repeatedImportEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite GetRepeatedImportEnum(int index) { - return repeatedImportEnum_[index]; - } - - public const int RepeatedStringPieceFieldNumber = 54; - private pbc::PopsicleList repeatedStringPiece_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringPieceList { - get { return pbc::Lists.AsReadOnly(repeatedStringPiece_); } - } - public int RepeatedStringPieceCount { - get { return repeatedStringPiece_.Count; } - } - public string GetRepeatedStringPiece(int index) { - return repeatedStringPiece_[index]; - } - - public const int RepeatedCordFieldNumber = 55; - private pbc::PopsicleList repeatedCord_ = new pbc::PopsicleList(); - public scg::IList RepeatedCordList { - get { return pbc::Lists.AsReadOnly(repeatedCord_); } - } - public int RepeatedCordCount { - get { return repeatedCord_.Count; } - } - public string GetRepeatedCord(int index) { - return repeatedCord_[index]; - } - - public const int DefaultInt32FieldNumber = 61; - private bool hasDefaultInt32; - private int defaultInt32_ = 41; - public bool HasDefaultInt32 { - get { return hasDefaultInt32; } - } - public int DefaultInt32 { - get { return defaultInt32_; } - } - - public const int DefaultInt64FieldNumber = 62; - private bool hasDefaultInt64; - private long defaultInt64_ = 42L; - public bool HasDefaultInt64 { - get { return hasDefaultInt64; } - } - public long DefaultInt64 { - get { return defaultInt64_; } - } - - public const int DefaultUint32FieldNumber = 63; - private bool hasDefaultUint32; - private uint defaultUint32_ = 43; - public bool HasDefaultUint32 { - get { return hasDefaultUint32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultUint32 { - get { return defaultUint32_; } - } - - public const int DefaultUint64FieldNumber = 64; - private bool hasDefaultUint64; - private ulong defaultUint64_ = 44UL; - public bool HasDefaultUint64 { - get { return hasDefaultUint64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultUint64 { - get { return defaultUint64_; } - } - - public const int DefaultSint32FieldNumber = 65; - private bool hasDefaultSint32; - private int defaultSint32_ = -45; - public bool HasDefaultSint32 { - get { return hasDefaultSint32; } - } - public int DefaultSint32 { - get { return defaultSint32_; } - } - - public const int DefaultSint64FieldNumber = 66; - private bool hasDefaultSint64; - private long defaultSint64_ = 46; - public bool HasDefaultSint64 { - get { return hasDefaultSint64; } - } - public long DefaultSint64 { - get { return defaultSint64_; } - } - - public const int DefaultFixed32FieldNumber = 67; - private bool hasDefaultFixed32; - private uint defaultFixed32_ = 47; - public bool HasDefaultFixed32 { - get { return hasDefaultFixed32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultFixed32 { - get { return defaultFixed32_; } - } - - public const int DefaultFixed64FieldNumber = 68; - private bool hasDefaultFixed64; - private ulong defaultFixed64_ = 48; - public bool HasDefaultFixed64 { - get { return hasDefaultFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultFixed64 { - get { return defaultFixed64_; } - } - - public const int DefaultSfixed32FieldNumber = 69; - private bool hasDefaultSfixed32; - private int defaultSfixed32_ = 49; - public bool HasDefaultSfixed32 { - get { return hasDefaultSfixed32; } - } - public int DefaultSfixed32 { - get { return defaultSfixed32_; } - } - - public const int DefaultSfixed64FieldNumber = 70; - private bool hasDefaultSfixed64; - private long defaultSfixed64_ = -50; - public bool HasDefaultSfixed64 { - get { return hasDefaultSfixed64; } - } - public long DefaultSfixed64 { - get { return defaultSfixed64_; } - } - - public const int DefaultFloatFieldNumber = 71; - private bool hasDefaultFloat; - private float defaultFloat_ = 51.5F; - public bool HasDefaultFloat { - get { return hasDefaultFloat; } - } - public float DefaultFloat { - get { return defaultFloat_; } - } - - public const int DefaultDoubleFieldNumber = 72; - private bool hasDefaultDouble; - private double defaultDouble_ = 52000D; - public bool HasDefaultDouble { - get { return hasDefaultDouble; } - } - public double DefaultDouble { - get { return defaultDouble_; } - } - - public const int DefaultBoolFieldNumber = 73; - private bool hasDefaultBool; - private bool defaultBool_ = true; - public bool HasDefaultBool { - get { return hasDefaultBool; } - } - public bool DefaultBool { - get { return defaultBool_; } - } - - public const int DefaultStringFieldNumber = 74; - private bool hasDefaultString; - private string defaultString_ = "hello"; - public bool HasDefaultString { - get { return hasDefaultString; } - } - public string DefaultString { - get { return defaultString_; } - } - - public const int DefaultBytesFieldNumber = 75; - private bool hasDefaultBytes; - private pb::ByteString defaultBytes_ = pb::ByteString.FromBase64("d29ybGQ="); - public bool HasDefaultBytes { - get { return hasDefaultBytes; } - } - public pb::ByteString DefaultBytes { - get { return defaultBytes_; } - } - - public const int DefaultNestedEnumFieldNumber = 81; - private bool hasDefaultNestedEnum; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum.BAR; - public bool HasDefaultNestedEnum { - get { return hasDefaultNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum DefaultNestedEnum { - get { return defaultNestedEnum_; } - } - - public const int DefaultForeignEnumFieldNumber = 82; - private bool hasDefaultForeignEnum; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite.FOREIGN_LITE_BAR; - public bool HasDefaultForeignEnum { - get { return hasDefaultForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite DefaultForeignEnum { - get { return defaultForeignEnum_; } - } - - public const int DefaultImportEnumFieldNumber = 83; - private bool hasDefaultImportEnum; - private global::Google.ProtocolBuffers.TestProtos.ImportEnumLite defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnumLite.IMPORT_LITE_BAR; - public bool HasDefaultImportEnum { - get { return hasDefaultImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite DefaultImportEnum { - get { return defaultImportEnum_; } - } - - public const int DefaultStringPieceFieldNumber = 84; - private bool hasDefaultStringPiece; - private string defaultStringPiece_ = "abc"; - public bool HasDefaultStringPiece { - get { return hasDefaultStringPiece; } - } - public string DefaultStringPiece { - get { return defaultStringPiece_; } - } - - public const int DefaultCordFieldNumber = 85; - private bool hasDefaultCord; - private string defaultCord_ = "123"; - public bool HasDefaultCord { - get { return hasDefaultCord; } - } - public string DefaultCord { - get { return defaultCord_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testAllTypesLiteFieldNames; - if (hasOptionalInt32) { - output.WriteInt32(1, field_names[31], OptionalInt32); - } - if (hasOptionalInt64) { - output.WriteInt64(2, field_names[32], OptionalInt64); - } - if (hasOptionalUint32) { - output.WriteUInt32(3, field_names[41], OptionalUint32); - } - if (hasOptionalUint64) { - output.WriteUInt64(4, field_names[42], OptionalUint64); - } - if (hasOptionalSint32) { - output.WriteSInt32(5, field_names[37], OptionalSint32); - } - if (hasOptionalSint64) { - output.WriteSInt64(6, field_names[38], OptionalSint64); - } - if (hasOptionalFixed32) { - output.WriteFixed32(7, field_names[24], OptionalFixed32); - } - if (hasOptionalFixed64) { - output.WriteFixed64(8, field_names[25], OptionalFixed64); - } - if (hasOptionalSfixed32) { - output.WriteSFixed32(9, field_names[35], OptionalSfixed32); - } - if (hasOptionalSfixed64) { - output.WriteSFixed64(10, field_names[36], OptionalSfixed64); - } - if (hasOptionalFloat) { - output.WriteFloat(11, field_names[26], OptionalFloat); - } - if (hasOptionalDouble) { - output.WriteDouble(12, field_names[23], OptionalDouble); - } - if (hasOptionalBool) { - output.WriteBool(13, field_names[20], OptionalBool); - } - if (hasOptionalString) { - output.WriteString(14, field_names[39], OptionalString); - } - if (hasOptionalBytes) { - output.WriteBytes(15, field_names[21], OptionalBytes); - } - if (hasOptionalGroup) { - output.WriteGroup(16, field_names[43], OptionalGroup); - } - if (hasOptionalNestedMessage) { - output.WriteMessage(18, field_names[34], OptionalNestedMessage); - } - if (hasOptionalForeignMessage) { - output.WriteMessage(19, field_names[28], OptionalForeignMessage); - } - if (hasOptionalImportMessage) { - output.WriteMessage(20, field_names[30], OptionalImportMessage); - } - if (hasOptionalNestedEnum) { - output.WriteEnum(21, field_names[33], (int) OptionalNestedEnum, OptionalNestedEnum); - } - if (hasOptionalForeignEnum) { - output.WriteEnum(22, field_names[27], (int) OptionalForeignEnum, OptionalForeignEnum); - } - if (hasOptionalImportEnum) { - output.WriteEnum(23, field_names[29], (int) OptionalImportEnum, OptionalImportEnum); - } - if (hasOptionalStringPiece) { - output.WriteString(24, field_names[40], OptionalStringPiece); - } - if (hasOptionalCord) { - output.WriteString(25, field_names[22], OptionalCord); - } - if (repeatedInt32_.Count > 0) { - output.WriteInt32Array(31, field_names[55], repeatedInt32_); - } - if (repeatedInt64_.Count > 0) { - output.WriteInt64Array(32, field_names[56], repeatedInt64_); - } - if (repeatedUint32_.Count > 0) { - output.WriteUInt32Array(33, field_names[65], repeatedUint32_); - } - if (repeatedUint64_.Count > 0) { - output.WriteUInt64Array(34, field_names[66], repeatedUint64_); - } - if (repeatedSint32_.Count > 0) { - output.WriteSInt32Array(35, field_names[61], repeatedSint32_); - } - if (repeatedSint64_.Count > 0) { - output.WriteSInt64Array(36, field_names[62], repeatedSint64_); - } - if (repeatedFixed32_.Count > 0) { - output.WriteFixed32Array(37, field_names[48], repeatedFixed32_); - } - if (repeatedFixed64_.Count > 0) { - output.WriteFixed64Array(38, field_names[49], repeatedFixed64_); - } - if (repeatedSfixed32_.Count > 0) { - output.WriteSFixed32Array(39, field_names[59], repeatedSfixed32_); - } - if (repeatedSfixed64_.Count > 0) { - output.WriteSFixed64Array(40, field_names[60], repeatedSfixed64_); - } - if (repeatedFloat_.Count > 0) { - output.WriteFloatArray(41, field_names[50], repeatedFloat_); - } - if (repeatedDouble_.Count > 0) { - output.WriteDoubleArray(42, field_names[47], repeatedDouble_); - } - if (repeatedBool_.Count > 0) { - output.WriteBoolArray(43, field_names[44], repeatedBool_); - } - if (repeatedString_.Count > 0) { - output.WriteStringArray(44, field_names[63], repeatedString_); - } - if (repeatedBytes_.Count > 0) { - output.WriteBytesArray(45, field_names[45], repeatedBytes_); - } - if (repeatedGroup_.Count > 0) { - output.WriteGroupArray(46, field_names[67], repeatedGroup_); - } - if (repeatedNestedMessage_.Count > 0) { - output.WriteMessageArray(48, field_names[58], repeatedNestedMessage_); - } - if (repeatedForeignMessage_.Count > 0) { - output.WriteMessageArray(49, field_names[52], repeatedForeignMessage_); - } - if (repeatedImportMessage_.Count > 0) { - output.WriteMessageArray(50, field_names[54], repeatedImportMessage_); - } - if (repeatedNestedEnum_.Count > 0) { - output.WriteEnumArray(51, field_names[57], repeatedNestedEnum_); - } - if (repeatedForeignEnum_.Count > 0) { - output.WriteEnumArray(52, field_names[51], repeatedForeignEnum_); - } - if (repeatedImportEnum_.Count > 0) { - output.WriteEnumArray(53, field_names[53], repeatedImportEnum_); - } - if (repeatedStringPiece_.Count > 0) { - output.WriteStringArray(54, field_names[64], repeatedStringPiece_); - } - if (repeatedCord_.Count > 0) { - output.WriteStringArray(55, field_names[46], repeatedCord_); - } - if (hasDefaultInt32) { - output.WriteInt32(61, field_names[9], DefaultInt32); - } - if (hasDefaultInt64) { - output.WriteInt64(62, field_names[10], DefaultInt64); - } - if (hasDefaultUint32) { - output.WriteUInt32(63, field_names[18], DefaultUint32); - } - if (hasDefaultUint64) { - output.WriteUInt64(64, field_names[19], DefaultUint64); - } - if (hasDefaultSint32) { - output.WriteSInt32(65, field_names[14], DefaultSint32); - } - if (hasDefaultSint64) { - output.WriteSInt64(66, field_names[15], DefaultSint64); - } - if (hasDefaultFixed32) { - output.WriteFixed32(67, field_names[4], DefaultFixed32); - } - if (hasDefaultFixed64) { - output.WriteFixed64(68, field_names[5], DefaultFixed64); - } - if (hasDefaultSfixed32) { - output.WriteSFixed32(69, field_names[12], DefaultSfixed32); - } - if (hasDefaultSfixed64) { - output.WriteSFixed64(70, field_names[13], DefaultSfixed64); - } - if (hasDefaultFloat) { - output.WriteFloat(71, field_names[6], DefaultFloat); - } - if (hasDefaultDouble) { - output.WriteDouble(72, field_names[3], DefaultDouble); - } - if (hasDefaultBool) { - output.WriteBool(73, field_names[0], DefaultBool); - } - if (hasDefaultString) { - output.WriteString(74, field_names[16], DefaultString); - } - if (hasDefaultBytes) { - output.WriteBytes(75, field_names[1], DefaultBytes); - } - if (hasDefaultNestedEnum) { - output.WriteEnum(81, field_names[11], (int) DefaultNestedEnum, DefaultNestedEnum); - } - if (hasDefaultForeignEnum) { - output.WriteEnum(82, field_names[7], (int) DefaultForeignEnum, DefaultForeignEnum); - } - if (hasDefaultImportEnum) { - output.WriteEnum(83, field_names[8], (int) DefaultImportEnum, DefaultImportEnum); - } - if (hasDefaultStringPiece) { - output.WriteString(84, field_names[17], DefaultStringPiece); - } - if (hasDefaultCord) { - output.WriteString(85, field_names[2], DefaultCord); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasOptionalInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(1, OptionalInt32); - } - if (hasOptionalInt64) { - size += pb::CodedOutputStream.ComputeInt64Size(2, OptionalInt64); - } - if (hasOptionalUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(3, OptionalUint32); - } - if (hasOptionalUint64) { - size += pb::CodedOutputStream.ComputeUInt64Size(4, OptionalUint64); - } - if (hasOptionalSint32) { - size += pb::CodedOutputStream.ComputeSInt32Size(5, OptionalSint32); - } - if (hasOptionalSint64) { - size += pb::CodedOutputStream.ComputeSInt64Size(6, OptionalSint64); - } - if (hasOptionalFixed32) { - size += pb::CodedOutputStream.ComputeFixed32Size(7, OptionalFixed32); - } - if (hasOptionalFixed64) { - size += pb::CodedOutputStream.ComputeFixed64Size(8, OptionalFixed64); - } - if (hasOptionalSfixed32) { - size += pb::CodedOutputStream.ComputeSFixed32Size(9, OptionalSfixed32); - } - if (hasOptionalSfixed64) { - size += pb::CodedOutputStream.ComputeSFixed64Size(10, OptionalSfixed64); - } - if (hasOptionalFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(11, OptionalFloat); - } - if (hasOptionalDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(12, OptionalDouble); - } - if (hasOptionalBool) { - size += pb::CodedOutputStream.ComputeBoolSize(13, OptionalBool); - } - if (hasOptionalString) { - size += pb::CodedOutputStream.ComputeStringSize(14, OptionalString); - } - if (hasOptionalBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(15, OptionalBytes); - } - if (hasOptionalGroup) { - size += pb::CodedOutputStream.ComputeGroupSize(16, OptionalGroup); - } - if (hasOptionalNestedMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(18, OptionalNestedMessage); - } - if (hasOptionalForeignMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(19, OptionalForeignMessage); - } - if (hasOptionalImportMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(20, OptionalImportMessage); - } - if (hasOptionalNestedEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(21, (int) OptionalNestedEnum); - } - if (hasOptionalForeignEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(22, (int) OptionalForeignEnum); - } - if (hasOptionalImportEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(23, (int) OptionalImportEnum); - } - if (hasOptionalStringPiece) { - size += pb::CodedOutputStream.ComputeStringSize(24, OptionalStringPiece); - } - if (hasOptionalCord) { - size += pb::CodedOutputStream.ComputeStringSize(25, OptionalCord); - } - { - int dataSize = 0; - foreach (int element in RepeatedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedInt32_.Count; - } - { - int dataSize = 0; - foreach (long element in RepeatedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedInt64_.Count; - } - { - int dataSize = 0; - foreach (uint element in RepeatedUint32List) { - dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedUint32_.Count; - } - { - int dataSize = 0; - foreach (ulong element in RepeatedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedUint64_.Count; - } - { - int dataSize = 0; - foreach (int element in RepeatedSint32List) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedSint32_.Count; - } - { - int dataSize = 0; - foreach (long element in RepeatedSint64List) { - dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedSint64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedFixed32_.Count; - size += dataSize; - size += 2 * repeatedFixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedFixed64_.Count; - size += dataSize; - size += 2 * repeatedFixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedSfixed32_.Count; - size += dataSize; - size += 2 * repeatedSfixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedSfixed64_.Count; - size += dataSize; - size += 2 * repeatedSfixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedFloat_.Count; - size += dataSize; - size += 2 * repeatedFloat_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedDouble_.Count; - size += dataSize; - size += 2 * repeatedDouble_.Count; - } - { - int dataSize = 0; - dataSize = 1 * repeatedBool_.Count; - size += dataSize; - size += 2 * repeatedBool_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedStringList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedString_.Count; - } - { - int dataSize = 0; - foreach (pb::ByteString element in RepeatedBytesList) { - dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedBytes_.Count; - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup element in RepeatedGroupList) { - size += pb::CodedOutputStream.ComputeGroupSize(46, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage element in RepeatedNestedMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(48, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite element in RepeatedForeignMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(49, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.ImportMessageLite element in RepeatedImportMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(50, element); - } - { - int dataSize = 0; - if (repeatedNestedEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum element in repeatedNestedEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedNestedEnum_.Count; - } - } - { - int dataSize = 0; - if (repeatedForeignEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite element in repeatedForeignEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedForeignEnum_.Count; - } - } - { - int dataSize = 0; - if (repeatedImportEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ImportEnumLite element in repeatedImportEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedImportEnum_.Count; - } - } - { - int dataSize = 0; - foreach (string element in RepeatedStringPieceList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedStringPiece_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedCordList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedCord_.Count; - } - if (hasDefaultInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(61, DefaultInt32); - } - if (hasDefaultInt64) { - size += pb::CodedOutputStream.ComputeInt64Size(62, DefaultInt64); - } - if (hasDefaultUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(63, DefaultUint32); - } - if (hasDefaultUint64) { - size += pb::CodedOutputStream.ComputeUInt64Size(64, DefaultUint64); - } - if (hasDefaultSint32) { - size += pb::CodedOutputStream.ComputeSInt32Size(65, DefaultSint32); - } - if (hasDefaultSint64) { - size += pb::CodedOutputStream.ComputeSInt64Size(66, DefaultSint64); - } - if (hasDefaultFixed32) { - size += pb::CodedOutputStream.ComputeFixed32Size(67, DefaultFixed32); - } - if (hasDefaultFixed64) { - size += pb::CodedOutputStream.ComputeFixed64Size(68, DefaultFixed64); - } - if (hasDefaultSfixed32) { - size += pb::CodedOutputStream.ComputeSFixed32Size(69, DefaultSfixed32); - } - if (hasDefaultSfixed64) { - size += pb::CodedOutputStream.ComputeSFixed64Size(70, DefaultSfixed64); - } - if (hasDefaultFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(71, DefaultFloat); - } - if (hasDefaultDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(72, DefaultDouble); - } - if (hasDefaultBool) { - size += pb::CodedOutputStream.ComputeBoolSize(73, DefaultBool); - } - if (hasDefaultString) { - size += pb::CodedOutputStream.ComputeStringSize(74, DefaultString); - } - if (hasDefaultBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(75, DefaultBytes); - } - if (hasDefaultNestedEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(81, (int) DefaultNestedEnum); - } - if (hasDefaultForeignEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(82, (int) DefaultForeignEnum); - } - if (hasDefaultImportEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(83, (int) DefaultImportEnum); - } - if (hasDefaultStringPiece) { - size += pb::CodedOutputStream.ComputeStringSize(84, DefaultStringPiece); - } - if (hasDefaultCord) { - size += pb::CodedOutputStream.ComputeStringSize(85, DefaultCord); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasOptionalInt32) hash ^= optionalInt32_.GetHashCode(); - if (hasOptionalInt64) hash ^= optionalInt64_.GetHashCode(); - if (hasOptionalUint32) hash ^= optionalUint32_.GetHashCode(); - if (hasOptionalUint64) hash ^= optionalUint64_.GetHashCode(); - if (hasOptionalSint32) hash ^= optionalSint32_.GetHashCode(); - if (hasOptionalSint64) hash ^= optionalSint64_.GetHashCode(); - if (hasOptionalFixed32) hash ^= optionalFixed32_.GetHashCode(); - if (hasOptionalFixed64) hash ^= optionalFixed64_.GetHashCode(); - if (hasOptionalSfixed32) hash ^= optionalSfixed32_.GetHashCode(); - if (hasOptionalSfixed64) hash ^= optionalSfixed64_.GetHashCode(); - if (hasOptionalFloat) hash ^= optionalFloat_.GetHashCode(); - if (hasOptionalDouble) hash ^= optionalDouble_.GetHashCode(); - if (hasOptionalBool) hash ^= optionalBool_.GetHashCode(); - if (hasOptionalString) hash ^= optionalString_.GetHashCode(); - if (hasOptionalBytes) hash ^= optionalBytes_.GetHashCode(); - if (hasOptionalGroup) hash ^= optionalGroup_.GetHashCode(); - if (hasOptionalNestedMessage) hash ^= optionalNestedMessage_.GetHashCode(); - if (hasOptionalForeignMessage) hash ^= optionalForeignMessage_.GetHashCode(); - if (hasOptionalImportMessage) hash ^= optionalImportMessage_.GetHashCode(); - if (hasOptionalNestedEnum) hash ^= optionalNestedEnum_.GetHashCode(); - if (hasOptionalForeignEnum) hash ^= optionalForeignEnum_.GetHashCode(); - if (hasOptionalImportEnum) hash ^= optionalImportEnum_.GetHashCode(); - if (hasOptionalStringPiece) hash ^= optionalStringPiece_.GetHashCode(); - if (hasOptionalCord) hash ^= optionalCord_.GetHashCode(); - foreach(int i in repeatedInt32_) - hash ^= i.GetHashCode(); - foreach(long i in repeatedInt64_) - hash ^= i.GetHashCode(); - foreach(uint i in repeatedUint32_) - hash ^= i.GetHashCode(); - foreach(ulong i in repeatedUint64_) - hash ^= i.GetHashCode(); - foreach(int i in repeatedSint32_) - hash ^= i.GetHashCode(); - foreach(long i in repeatedSint64_) - hash ^= i.GetHashCode(); - foreach(uint i in repeatedFixed32_) - hash ^= i.GetHashCode(); - foreach(ulong i in repeatedFixed64_) - hash ^= i.GetHashCode(); - foreach(int i in repeatedSfixed32_) - hash ^= i.GetHashCode(); - foreach(long i in repeatedSfixed64_) - hash ^= i.GetHashCode(); - foreach(float i in repeatedFloat_) - hash ^= i.GetHashCode(); - foreach(double i in repeatedDouble_) - hash ^= i.GetHashCode(); - foreach(bool i in repeatedBool_) - hash ^= i.GetHashCode(); - foreach(string i in repeatedString_) - hash ^= i.GetHashCode(); - foreach(pb::ByteString i in repeatedBytes_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup i in repeatedGroup_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage i in repeatedNestedMessage_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite i in repeatedForeignMessage_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite i in repeatedImportMessage_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum i in repeatedNestedEnum_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite i in repeatedForeignEnum_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.ImportEnumLite i in repeatedImportEnum_) - hash ^= i.GetHashCode(); - foreach(string i in repeatedStringPiece_) - hash ^= i.GetHashCode(); - foreach(string i in repeatedCord_) - hash ^= i.GetHashCode(); - if (hasDefaultInt32) hash ^= defaultInt32_.GetHashCode(); - if (hasDefaultInt64) hash ^= defaultInt64_.GetHashCode(); - if (hasDefaultUint32) hash ^= defaultUint32_.GetHashCode(); - if (hasDefaultUint64) hash ^= defaultUint64_.GetHashCode(); - if (hasDefaultSint32) hash ^= defaultSint32_.GetHashCode(); - if (hasDefaultSint64) hash ^= defaultSint64_.GetHashCode(); - if (hasDefaultFixed32) hash ^= defaultFixed32_.GetHashCode(); - if (hasDefaultFixed64) hash ^= defaultFixed64_.GetHashCode(); - if (hasDefaultSfixed32) hash ^= defaultSfixed32_.GetHashCode(); - if (hasDefaultSfixed64) hash ^= defaultSfixed64_.GetHashCode(); - if (hasDefaultFloat) hash ^= defaultFloat_.GetHashCode(); - if (hasDefaultDouble) hash ^= defaultDouble_.GetHashCode(); - if (hasDefaultBool) hash ^= defaultBool_.GetHashCode(); - if (hasDefaultString) hash ^= defaultString_.GetHashCode(); - if (hasDefaultBytes) hash ^= defaultBytes_.GetHashCode(); - if (hasDefaultNestedEnum) hash ^= defaultNestedEnum_.GetHashCode(); - if (hasDefaultForeignEnum) hash ^= defaultForeignEnum_.GetHashCode(); - if (hasDefaultImportEnum) hash ^= defaultImportEnum_.GetHashCode(); - if (hasDefaultStringPiece) hash ^= defaultStringPiece_.GetHashCode(); - if (hasDefaultCord) hash ^= defaultCord_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestAllTypesLite other = obj as TestAllTypesLite; - if (other == null) return false; - if (hasOptionalInt32 != other.hasOptionalInt32 || (hasOptionalInt32 && !optionalInt32_.Equals(other.optionalInt32_))) return false; - if (hasOptionalInt64 != other.hasOptionalInt64 || (hasOptionalInt64 && !optionalInt64_.Equals(other.optionalInt64_))) return false; - if (hasOptionalUint32 != other.hasOptionalUint32 || (hasOptionalUint32 && !optionalUint32_.Equals(other.optionalUint32_))) return false; - if (hasOptionalUint64 != other.hasOptionalUint64 || (hasOptionalUint64 && !optionalUint64_.Equals(other.optionalUint64_))) return false; - if (hasOptionalSint32 != other.hasOptionalSint32 || (hasOptionalSint32 && !optionalSint32_.Equals(other.optionalSint32_))) return false; - if (hasOptionalSint64 != other.hasOptionalSint64 || (hasOptionalSint64 && !optionalSint64_.Equals(other.optionalSint64_))) return false; - if (hasOptionalFixed32 != other.hasOptionalFixed32 || (hasOptionalFixed32 && !optionalFixed32_.Equals(other.optionalFixed32_))) return false; - if (hasOptionalFixed64 != other.hasOptionalFixed64 || (hasOptionalFixed64 && !optionalFixed64_.Equals(other.optionalFixed64_))) return false; - if (hasOptionalSfixed32 != other.hasOptionalSfixed32 || (hasOptionalSfixed32 && !optionalSfixed32_.Equals(other.optionalSfixed32_))) return false; - if (hasOptionalSfixed64 != other.hasOptionalSfixed64 || (hasOptionalSfixed64 && !optionalSfixed64_.Equals(other.optionalSfixed64_))) return false; - if (hasOptionalFloat != other.hasOptionalFloat || (hasOptionalFloat && !optionalFloat_.Equals(other.optionalFloat_))) return false; - if (hasOptionalDouble != other.hasOptionalDouble || (hasOptionalDouble && !optionalDouble_.Equals(other.optionalDouble_))) return false; - if (hasOptionalBool != other.hasOptionalBool || (hasOptionalBool && !optionalBool_.Equals(other.optionalBool_))) return false; - if (hasOptionalString != other.hasOptionalString || (hasOptionalString && !optionalString_.Equals(other.optionalString_))) return false; - if (hasOptionalBytes != other.hasOptionalBytes || (hasOptionalBytes && !optionalBytes_.Equals(other.optionalBytes_))) return false; - if (hasOptionalGroup != other.hasOptionalGroup || (hasOptionalGroup && !optionalGroup_.Equals(other.optionalGroup_))) return false; - if (hasOptionalNestedMessage != other.hasOptionalNestedMessage || (hasOptionalNestedMessage && !optionalNestedMessage_.Equals(other.optionalNestedMessage_))) return false; - if (hasOptionalForeignMessage != other.hasOptionalForeignMessage || (hasOptionalForeignMessage && !optionalForeignMessage_.Equals(other.optionalForeignMessage_))) return false; - if (hasOptionalImportMessage != other.hasOptionalImportMessage || (hasOptionalImportMessage && !optionalImportMessage_.Equals(other.optionalImportMessage_))) return false; - if (hasOptionalNestedEnum != other.hasOptionalNestedEnum || (hasOptionalNestedEnum && !optionalNestedEnum_.Equals(other.optionalNestedEnum_))) return false; - if (hasOptionalForeignEnum != other.hasOptionalForeignEnum || (hasOptionalForeignEnum && !optionalForeignEnum_.Equals(other.optionalForeignEnum_))) return false; - if (hasOptionalImportEnum != other.hasOptionalImportEnum || (hasOptionalImportEnum && !optionalImportEnum_.Equals(other.optionalImportEnum_))) return false; - if (hasOptionalStringPiece != other.hasOptionalStringPiece || (hasOptionalStringPiece && !optionalStringPiece_.Equals(other.optionalStringPiece_))) return false; - if (hasOptionalCord != other.hasOptionalCord || (hasOptionalCord && !optionalCord_.Equals(other.optionalCord_))) return false; - if(repeatedInt32_.Count != other.repeatedInt32_.Count) return false; - for(int ix=0; ix < repeatedInt32_.Count; ix++) - if(!repeatedInt32_[ix].Equals(other.repeatedInt32_[ix])) return false; - if(repeatedInt64_.Count != other.repeatedInt64_.Count) return false; - for(int ix=0; ix < repeatedInt64_.Count; ix++) - if(!repeatedInt64_[ix].Equals(other.repeatedInt64_[ix])) return false; - if(repeatedUint32_.Count != other.repeatedUint32_.Count) return false; - for(int ix=0; ix < repeatedUint32_.Count; ix++) - if(!repeatedUint32_[ix].Equals(other.repeatedUint32_[ix])) return false; - if(repeatedUint64_.Count != other.repeatedUint64_.Count) return false; - for(int ix=0; ix < repeatedUint64_.Count; ix++) - if(!repeatedUint64_[ix].Equals(other.repeatedUint64_[ix])) return false; - if(repeatedSint32_.Count != other.repeatedSint32_.Count) return false; - for(int ix=0; ix < repeatedSint32_.Count; ix++) - if(!repeatedSint32_[ix].Equals(other.repeatedSint32_[ix])) return false; - if(repeatedSint64_.Count != other.repeatedSint64_.Count) return false; - for(int ix=0; ix < repeatedSint64_.Count; ix++) - if(!repeatedSint64_[ix].Equals(other.repeatedSint64_[ix])) return false; - if(repeatedFixed32_.Count != other.repeatedFixed32_.Count) return false; - for(int ix=0; ix < repeatedFixed32_.Count; ix++) - if(!repeatedFixed32_[ix].Equals(other.repeatedFixed32_[ix])) return false; - if(repeatedFixed64_.Count != other.repeatedFixed64_.Count) return false; - for(int ix=0; ix < repeatedFixed64_.Count; ix++) - if(!repeatedFixed64_[ix].Equals(other.repeatedFixed64_[ix])) return false; - if(repeatedSfixed32_.Count != other.repeatedSfixed32_.Count) return false; - for(int ix=0; ix < repeatedSfixed32_.Count; ix++) - if(!repeatedSfixed32_[ix].Equals(other.repeatedSfixed32_[ix])) return false; - if(repeatedSfixed64_.Count != other.repeatedSfixed64_.Count) return false; - for(int ix=0; ix < repeatedSfixed64_.Count; ix++) - if(!repeatedSfixed64_[ix].Equals(other.repeatedSfixed64_[ix])) return false; - if(repeatedFloat_.Count != other.repeatedFloat_.Count) return false; - for(int ix=0; ix < repeatedFloat_.Count; ix++) - if(!repeatedFloat_[ix].Equals(other.repeatedFloat_[ix])) return false; - if(repeatedDouble_.Count != other.repeatedDouble_.Count) return false; - for(int ix=0; ix < repeatedDouble_.Count; ix++) - if(!repeatedDouble_[ix].Equals(other.repeatedDouble_[ix])) return false; - if(repeatedBool_.Count != other.repeatedBool_.Count) return false; - for(int ix=0; ix < repeatedBool_.Count; ix++) - if(!repeatedBool_[ix].Equals(other.repeatedBool_[ix])) return false; - if(repeatedString_.Count != other.repeatedString_.Count) return false; - for(int ix=0; ix < repeatedString_.Count; ix++) - if(!repeatedString_[ix].Equals(other.repeatedString_[ix])) return false; - if(repeatedBytes_.Count != other.repeatedBytes_.Count) return false; - for(int ix=0; ix < repeatedBytes_.Count; ix++) - if(!repeatedBytes_[ix].Equals(other.repeatedBytes_[ix])) return false; - if(repeatedGroup_.Count != other.repeatedGroup_.Count) return false; - for(int ix=0; ix < repeatedGroup_.Count; ix++) - if(!repeatedGroup_[ix].Equals(other.repeatedGroup_[ix])) return false; - if(repeatedNestedMessage_.Count != other.repeatedNestedMessage_.Count) return false; - for(int ix=0; ix < repeatedNestedMessage_.Count; ix++) - if(!repeatedNestedMessage_[ix].Equals(other.repeatedNestedMessage_[ix])) return false; - if(repeatedForeignMessage_.Count != other.repeatedForeignMessage_.Count) return false; - for(int ix=0; ix < repeatedForeignMessage_.Count; ix++) - if(!repeatedForeignMessage_[ix].Equals(other.repeatedForeignMessage_[ix])) return false; - if(repeatedImportMessage_.Count != other.repeatedImportMessage_.Count) return false; - for(int ix=0; ix < repeatedImportMessage_.Count; ix++) - if(!repeatedImportMessage_[ix].Equals(other.repeatedImportMessage_[ix])) return false; - if(repeatedNestedEnum_.Count != other.repeatedNestedEnum_.Count) return false; - for(int ix=0; ix < repeatedNestedEnum_.Count; ix++) - if(!repeatedNestedEnum_[ix].Equals(other.repeatedNestedEnum_[ix])) return false; - if(repeatedForeignEnum_.Count != other.repeatedForeignEnum_.Count) return false; - for(int ix=0; ix < repeatedForeignEnum_.Count; ix++) - if(!repeatedForeignEnum_[ix].Equals(other.repeatedForeignEnum_[ix])) return false; - if(repeatedImportEnum_.Count != other.repeatedImportEnum_.Count) return false; - for(int ix=0; ix < repeatedImportEnum_.Count; ix++) - if(!repeatedImportEnum_[ix].Equals(other.repeatedImportEnum_[ix])) return false; - if(repeatedStringPiece_.Count != other.repeatedStringPiece_.Count) return false; - for(int ix=0; ix < repeatedStringPiece_.Count; ix++) - if(!repeatedStringPiece_[ix].Equals(other.repeatedStringPiece_[ix])) return false; - if(repeatedCord_.Count != other.repeatedCord_.Count) return false; - for(int ix=0; ix < repeatedCord_.Count; ix++) - if(!repeatedCord_[ix].Equals(other.repeatedCord_[ix])) return false; - if (hasDefaultInt32 != other.hasDefaultInt32 || (hasDefaultInt32 && !defaultInt32_.Equals(other.defaultInt32_))) return false; - if (hasDefaultInt64 != other.hasDefaultInt64 || (hasDefaultInt64 && !defaultInt64_.Equals(other.defaultInt64_))) return false; - if (hasDefaultUint32 != other.hasDefaultUint32 || (hasDefaultUint32 && !defaultUint32_.Equals(other.defaultUint32_))) return false; - if (hasDefaultUint64 != other.hasDefaultUint64 || (hasDefaultUint64 && !defaultUint64_.Equals(other.defaultUint64_))) return false; - if (hasDefaultSint32 != other.hasDefaultSint32 || (hasDefaultSint32 && !defaultSint32_.Equals(other.defaultSint32_))) return false; - if (hasDefaultSint64 != other.hasDefaultSint64 || (hasDefaultSint64 && !defaultSint64_.Equals(other.defaultSint64_))) return false; - if (hasDefaultFixed32 != other.hasDefaultFixed32 || (hasDefaultFixed32 && !defaultFixed32_.Equals(other.defaultFixed32_))) return false; - if (hasDefaultFixed64 != other.hasDefaultFixed64 || (hasDefaultFixed64 && !defaultFixed64_.Equals(other.defaultFixed64_))) return false; - if (hasDefaultSfixed32 != other.hasDefaultSfixed32 || (hasDefaultSfixed32 && !defaultSfixed32_.Equals(other.defaultSfixed32_))) return false; - if (hasDefaultSfixed64 != other.hasDefaultSfixed64 || (hasDefaultSfixed64 && !defaultSfixed64_.Equals(other.defaultSfixed64_))) return false; - if (hasDefaultFloat != other.hasDefaultFloat || (hasDefaultFloat && !defaultFloat_.Equals(other.defaultFloat_))) return false; - if (hasDefaultDouble != other.hasDefaultDouble || (hasDefaultDouble && !defaultDouble_.Equals(other.defaultDouble_))) return false; - if (hasDefaultBool != other.hasDefaultBool || (hasDefaultBool && !defaultBool_.Equals(other.defaultBool_))) return false; - if (hasDefaultString != other.hasDefaultString || (hasDefaultString && !defaultString_.Equals(other.defaultString_))) return false; - if (hasDefaultBytes != other.hasDefaultBytes || (hasDefaultBytes && !defaultBytes_.Equals(other.defaultBytes_))) return false; - if (hasDefaultNestedEnum != other.hasDefaultNestedEnum || (hasDefaultNestedEnum && !defaultNestedEnum_.Equals(other.defaultNestedEnum_))) return false; - if (hasDefaultForeignEnum != other.hasDefaultForeignEnum || (hasDefaultForeignEnum && !defaultForeignEnum_.Equals(other.defaultForeignEnum_))) return false; - if (hasDefaultImportEnum != other.hasDefaultImportEnum || (hasDefaultImportEnum && !defaultImportEnum_.Equals(other.defaultImportEnum_))) return false; - if (hasDefaultStringPiece != other.hasDefaultStringPiece || (hasDefaultStringPiece && !defaultStringPiece_.Equals(other.defaultStringPiece_))) return false; - if (hasDefaultCord != other.hasDefaultCord || (hasDefaultCord && !defaultCord_.Equals(other.defaultCord_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("optional_int32", hasOptionalInt32, optionalInt32_, writer); - PrintField("optional_int64", hasOptionalInt64, optionalInt64_, writer); - PrintField("optional_uint32", hasOptionalUint32, optionalUint32_, writer); - PrintField("optional_uint64", hasOptionalUint64, optionalUint64_, writer); - PrintField("optional_sint32", hasOptionalSint32, optionalSint32_, writer); - PrintField("optional_sint64", hasOptionalSint64, optionalSint64_, writer); - PrintField("optional_fixed32", hasOptionalFixed32, optionalFixed32_, writer); - PrintField("optional_fixed64", hasOptionalFixed64, optionalFixed64_, writer); - PrintField("optional_sfixed32", hasOptionalSfixed32, optionalSfixed32_, writer); - PrintField("optional_sfixed64", hasOptionalSfixed64, optionalSfixed64_, writer); - PrintField("optional_float", hasOptionalFloat, optionalFloat_, writer); - PrintField("optional_double", hasOptionalDouble, optionalDouble_, writer); - PrintField("optional_bool", hasOptionalBool, optionalBool_, writer); - PrintField("optional_string", hasOptionalString, optionalString_, writer); - PrintField("optional_bytes", hasOptionalBytes, optionalBytes_, writer); - PrintField("OptionalGroup", hasOptionalGroup, optionalGroup_, writer); - PrintField("optional_nested_message", hasOptionalNestedMessage, optionalNestedMessage_, writer); - PrintField("optional_foreign_message", hasOptionalForeignMessage, optionalForeignMessage_, writer); - PrintField("optional_import_message", hasOptionalImportMessage, optionalImportMessage_, writer); - PrintField("optional_nested_enum", hasOptionalNestedEnum, optionalNestedEnum_, writer); - PrintField("optional_foreign_enum", hasOptionalForeignEnum, optionalForeignEnum_, writer); - PrintField("optional_import_enum", hasOptionalImportEnum, optionalImportEnum_, writer); - PrintField("optional_string_piece", hasOptionalStringPiece, optionalStringPiece_, writer); - PrintField("optional_cord", hasOptionalCord, optionalCord_, writer); - PrintField("repeated_int32", repeatedInt32_, writer); - PrintField("repeated_int64", repeatedInt64_, writer); - PrintField("repeated_uint32", repeatedUint32_, writer); - PrintField("repeated_uint64", repeatedUint64_, writer); - PrintField("repeated_sint32", repeatedSint32_, writer); - PrintField("repeated_sint64", repeatedSint64_, writer); - PrintField("repeated_fixed32", repeatedFixed32_, writer); - PrintField("repeated_fixed64", repeatedFixed64_, writer); - PrintField("repeated_sfixed32", repeatedSfixed32_, writer); - PrintField("repeated_sfixed64", repeatedSfixed64_, writer); - PrintField("repeated_float", repeatedFloat_, writer); - PrintField("repeated_double", repeatedDouble_, writer); - PrintField("repeated_bool", repeatedBool_, writer); - PrintField("repeated_string", repeatedString_, writer); - PrintField("repeated_bytes", repeatedBytes_, writer); - PrintField("RepeatedGroup", repeatedGroup_, writer); - PrintField("repeated_nested_message", repeatedNestedMessage_, writer); - PrintField("repeated_foreign_message", repeatedForeignMessage_, writer); - PrintField("repeated_import_message", repeatedImportMessage_, writer); - PrintField("repeated_nested_enum", repeatedNestedEnum_, writer); - PrintField("repeated_foreign_enum", repeatedForeignEnum_, writer); - PrintField("repeated_import_enum", repeatedImportEnum_, writer); - PrintField("repeated_string_piece", repeatedStringPiece_, writer); - PrintField("repeated_cord", repeatedCord_, writer); - PrintField("default_int32", hasDefaultInt32, defaultInt32_, writer); - PrintField("default_int64", hasDefaultInt64, defaultInt64_, writer); - PrintField("default_uint32", hasDefaultUint32, defaultUint32_, writer); - PrintField("default_uint64", hasDefaultUint64, defaultUint64_, writer); - PrintField("default_sint32", hasDefaultSint32, defaultSint32_, writer); - PrintField("default_sint64", hasDefaultSint64, defaultSint64_, writer); - PrintField("default_fixed32", hasDefaultFixed32, defaultFixed32_, writer); - PrintField("default_fixed64", hasDefaultFixed64, defaultFixed64_, writer); - PrintField("default_sfixed32", hasDefaultSfixed32, defaultSfixed32_, writer); - PrintField("default_sfixed64", hasDefaultSfixed64, defaultSfixed64_, writer); - PrintField("default_float", hasDefaultFloat, defaultFloat_, writer); - PrintField("default_double", hasDefaultDouble, defaultDouble_, writer); - PrintField("default_bool", hasDefaultBool, defaultBool_, writer); - PrintField("default_string", hasDefaultString, defaultString_, writer); - PrintField("default_bytes", hasDefaultBytes, defaultBytes_, writer); - PrintField("default_nested_enum", hasDefaultNestedEnum, defaultNestedEnum_, writer); - PrintField("default_foreign_enum", hasDefaultForeignEnum, defaultForeignEnum_, writer); - PrintField("default_import_enum", hasDefaultImportEnum, defaultImportEnum_, writer); - PrintField("default_string_piece", hasDefaultStringPiece, defaultStringPiece_, writer); - PrintField("default_cord", hasDefaultCord, defaultCord_, writer); - } - #endregion - - public static TestAllTypesLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllTypesLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllTypesLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllTypesLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllTypesLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllTypesLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestAllTypesLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestAllTypesLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestAllTypesLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllTypesLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestAllTypesLite MakeReadOnly() { - repeatedInt32_.MakeReadOnly(); - repeatedInt64_.MakeReadOnly(); - repeatedUint32_.MakeReadOnly(); - repeatedUint64_.MakeReadOnly(); - repeatedSint32_.MakeReadOnly(); - repeatedSint64_.MakeReadOnly(); - repeatedFixed32_.MakeReadOnly(); - repeatedFixed64_.MakeReadOnly(); - repeatedSfixed32_.MakeReadOnly(); - repeatedSfixed64_.MakeReadOnly(); - repeatedFloat_.MakeReadOnly(); - repeatedDouble_.MakeReadOnly(); - repeatedBool_.MakeReadOnly(); - repeatedString_.MakeReadOnly(); - repeatedBytes_.MakeReadOnly(); - repeatedGroup_.MakeReadOnly(); - repeatedNestedMessage_.MakeReadOnly(); - repeatedForeignMessage_.MakeReadOnly(); - repeatedImportMessage_.MakeReadOnly(); - repeatedNestedEnum_.MakeReadOnly(); - repeatedForeignEnum_.MakeReadOnly(); - repeatedImportEnum_.MakeReadOnly(); - repeatedStringPiece_.MakeReadOnly(); - repeatedCord_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestAllTypesLite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestAllTypesLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestAllTypesLite result; - - private TestAllTypesLite PrepareBuilder() { - if (resultIsReadOnly) { - TestAllTypesLite original = result; - result = new TestAllTypesLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestAllTypesLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestAllTypesLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance; } - } - - public override TestAllTypesLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestAllTypesLite) { - return MergeFrom((TestAllTypesLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestAllTypesLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasOptionalInt32) { - OptionalInt32 = other.OptionalInt32; - } - if (other.HasOptionalInt64) { - OptionalInt64 = other.OptionalInt64; - } - if (other.HasOptionalUint32) { - OptionalUint32 = other.OptionalUint32; - } - if (other.HasOptionalUint64) { - OptionalUint64 = other.OptionalUint64; - } - if (other.HasOptionalSint32) { - OptionalSint32 = other.OptionalSint32; - } - if (other.HasOptionalSint64) { - OptionalSint64 = other.OptionalSint64; - } - if (other.HasOptionalFixed32) { - OptionalFixed32 = other.OptionalFixed32; - } - if (other.HasOptionalFixed64) { - OptionalFixed64 = other.OptionalFixed64; - } - if (other.HasOptionalSfixed32) { - OptionalSfixed32 = other.OptionalSfixed32; - } - if (other.HasOptionalSfixed64) { - OptionalSfixed64 = other.OptionalSfixed64; - } - if (other.HasOptionalFloat) { - OptionalFloat = other.OptionalFloat; - } - if (other.HasOptionalDouble) { - OptionalDouble = other.OptionalDouble; - } - if (other.HasOptionalBool) { - OptionalBool = other.OptionalBool; - } - if (other.HasOptionalString) { - OptionalString = other.OptionalString; - } - if (other.HasOptionalBytes) { - OptionalBytes = other.OptionalBytes; - } - if (other.HasOptionalGroup) { - MergeOptionalGroup(other.OptionalGroup); - } - if (other.HasOptionalNestedMessage) { - MergeOptionalNestedMessage(other.OptionalNestedMessage); - } - if (other.HasOptionalForeignMessage) { - MergeOptionalForeignMessage(other.OptionalForeignMessage); - } - if (other.HasOptionalImportMessage) { - MergeOptionalImportMessage(other.OptionalImportMessage); - } - if (other.HasOptionalNestedEnum) { - OptionalNestedEnum = other.OptionalNestedEnum; - } - if (other.HasOptionalForeignEnum) { - OptionalForeignEnum = other.OptionalForeignEnum; - } - if (other.HasOptionalImportEnum) { - OptionalImportEnum = other.OptionalImportEnum; - } - if (other.HasOptionalStringPiece) { - OptionalStringPiece = other.OptionalStringPiece; - } - if (other.HasOptionalCord) { - OptionalCord = other.OptionalCord; - } - if (other.repeatedInt32_.Count != 0) { - result.repeatedInt32_.Add(other.repeatedInt32_); - } - if (other.repeatedInt64_.Count != 0) { - result.repeatedInt64_.Add(other.repeatedInt64_); - } - if (other.repeatedUint32_.Count != 0) { - result.repeatedUint32_.Add(other.repeatedUint32_); - } - if (other.repeatedUint64_.Count != 0) { - result.repeatedUint64_.Add(other.repeatedUint64_); - } - if (other.repeatedSint32_.Count != 0) { - result.repeatedSint32_.Add(other.repeatedSint32_); - } - if (other.repeatedSint64_.Count != 0) { - result.repeatedSint64_.Add(other.repeatedSint64_); - } - if (other.repeatedFixed32_.Count != 0) { - result.repeatedFixed32_.Add(other.repeatedFixed32_); - } - if (other.repeatedFixed64_.Count != 0) { - result.repeatedFixed64_.Add(other.repeatedFixed64_); - } - if (other.repeatedSfixed32_.Count != 0) { - result.repeatedSfixed32_.Add(other.repeatedSfixed32_); - } - if (other.repeatedSfixed64_.Count != 0) { - result.repeatedSfixed64_.Add(other.repeatedSfixed64_); - } - if (other.repeatedFloat_.Count != 0) { - result.repeatedFloat_.Add(other.repeatedFloat_); - } - if (other.repeatedDouble_.Count != 0) { - result.repeatedDouble_.Add(other.repeatedDouble_); - } - if (other.repeatedBool_.Count != 0) { - result.repeatedBool_.Add(other.repeatedBool_); - } - if (other.repeatedString_.Count != 0) { - result.repeatedString_.Add(other.repeatedString_); - } - if (other.repeatedBytes_.Count != 0) { - result.repeatedBytes_.Add(other.repeatedBytes_); - } - if (other.repeatedGroup_.Count != 0) { - result.repeatedGroup_.Add(other.repeatedGroup_); - } - if (other.repeatedNestedMessage_.Count != 0) { - result.repeatedNestedMessage_.Add(other.repeatedNestedMessage_); - } - if (other.repeatedForeignMessage_.Count != 0) { - result.repeatedForeignMessage_.Add(other.repeatedForeignMessage_); - } - if (other.repeatedImportMessage_.Count != 0) { - result.repeatedImportMessage_.Add(other.repeatedImportMessage_); - } - if (other.repeatedNestedEnum_.Count != 0) { - result.repeatedNestedEnum_.Add(other.repeatedNestedEnum_); - } - if (other.repeatedForeignEnum_.Count != 0) { - result.repeatedForeignEnum_.Add(other.repeatedForeignEnum_); - } - if (other.repeatedImportEnum_.Count != 0) { - result.repeatedImportEnum_.Add(other.repeatedImportEnum_); - } - if (other.repeatedStringPiece_.Count != 0) { - result.repeatedStringPiece_.Add(other.repeatedStringPiece_); - } - if (other.repeatedCord_.Count != 0) { - result.repeatedCord_.Add(other.repeatedCord_); - } - if (other.HasDefaultInt32) { - DefaultInt32 = other.DefaultInt32; - } - if (other.HasDefaultInt64) { - DefaultInt64 = other.DefaultInt64; - } - if (other.HasDefaultUint32) { - DefaultUint32 = other.DefaultUint32; - } - if (other.HasDefaultUint64) { - DefaultUint64 = other.DefaultUint64; - } - if (other.HasDefaultSint32) { - DefaultSint32 = other.DefaultSint32; - } - if (other.HasDefaultSint64) { - DefaultSint64 = other.DefaultSint64; - } - if (other.HasDefaultFixed32) { - DefaultFixed32 = other.DefaultFixed32; - } - if (other.HasDefaultFixed64) { - DefaultFixed64 = other.DefaultFixed64; - } - if (other.HasDefaultSfixed32) { - DefaultSfixed32 = other.DefaultSfixed32; - } - if (other.HasDefaultSfixed64) { - DefaultSfixed64 = other.DefaultSfixed64; - } - if (other.HasDefaultFloat) { - DefaultFloat = other.DefaultFloat; - } - if (other.HasDefaultDouble) { - DefaultDouble = other.DefaultDouble; - } - if (other.HasDefaultBool) { - DefaultBool = other.DefaultBool; - } - if (other.HasDefaultString) { - DefaultString = other.DefaultString; - } - if (other.HasDefaultBytes) { - DefaultBytes = other.DefaultBytes; - } - if (other.HasDefaultNestedEnum) { - DefaultNestedEnum = other.DefaultNestedEnum; - } - if (other.HasDefaultForeignEnum) { - DefaultForeignEnum = other.DefaultForeignEnum; - } - if (other.HasDefaultImportEnum) { - DefaultImportEnum = other.DefaultImportEnum; - } - if (other.HasDefaultStringPiece) { - DefaultStringPiece = other.DefaultStringPiece; - } - if (other.HasDefaultCord) { - DefaultCord = other.DefaultCord; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testAllTypesLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testAllTypesLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); - break; - } - case 16: { - result.hasOptionalInt64 = input.ReadInt64(ref result.optionalInt64_); - break; - } - case 24: { - result.hasOptionalUint32 = input.ReadUInt32(ref result.optionalUint32_); - break; - } - case 32: { - result.hasOptionalUint64 = input.ReadUInt64(ref result.optionalUint64_); - break; - } - case 40: { - result.hasOptionalSint32 = input.ReadSInt32(ref result.optionalSint32_); - break; - } - case 48: { - result.hasOptionalSint64 = input.ReadSInt64(ref result.optionalSint64_); - break; - } - case 61: { - result.hasOptionalFixed32 = input.ReadFixed32(ref result.optionalFixed32_); - break; - } - case 65: { - result.hasOptionalFixed64 = input.ReadFixed64(ref result.optionalFixed64_); - break; - } - case 77: { - result.hasOptionalSfixed32 = input.ReadSFixed32(ref result.optionalSfixed32_); - break; - } - case 81: { - result.hasOptionalSfixed64 = input.ReadSFixed64(ref result.optionalSfixed64_); - break; - } - case 93: { - result.hasOptionalFloat = input.ReadFloat(ref result.optionalFloat_); - break; - } - case 97: { - result.hasOptionalDouble = input.ReadDouble(ref result.optionalDouble_); - break; - } - case 104: { - result.hasOptionalBool = input.ReadBool(ref result.optionalBool_); - break; - } - case 114: { - result.hasOptionalString = input.ReadString(ref result.optionalString_); - break; - } - case 122: { - result.hasOptionalBytes = input.ReadBytes(ref result.optionalBytes_); - break; - } - case 131: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.CreateBuilder(); - if (result.hasOptionalGroup) { - subBuilder.MergeFrom(OptionalGroup); - } - input.ReadGroup(16, subBuilder, extensionRegistry); - OptionalGroup = subBuilder.BuildPartial(); - break; - } - case 146: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.CreateBuilder(); - if (result.hasOptionalNestedMessage) { - subBuilder.MergeFrom(OptionalNestedMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalNestedMessage = subBuilder.BuildPartial(); - break; - } - case 154: { - global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.CreateBuilder(); - if (result.hasOptionalForeignMessage) { - subBuilder.MergeFrom(OptionalForeignMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalForeignMessage = subBuilder.BuildPartial(); - break; - } - case 162: { - global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.CreateBuilder(); - if (result.hasOptionalImportMessage) { - subBuilder.MergeFrom(OptionalImportMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalImportMessage = subBuilder.BuildPartial(); - break; - } - case 168: { - object unknown; - if(input.ReadEnum(ref result.optionalNestedEnum_, out unknown)) { - result.hasOptionalNestedEnum = true; - } else if(unknown is int) { - } - break; - } - case 176: { - object unknown; - if(input.ReadEnum(ref result.optionalForeignEnum_, out unknown)) { - result.hasOptionalForeignEnum = true; - } else if(unknown is int) { - } - break; - } - case 184: { - object unknown; - if(input.ReadEnum(ref result.optionalImportEnum_, out unknown)) { - result.hasOptionalImportEnum = true; - } else if(unknown is int) { - } - break; - } - case 194: { - result.hasOptionalStringPiece = input.ReadString(ref result.optionalStringPiece_); - break; - } - case 202: { - result.hasOptionalCord = input.ReadString(ref result.optionalCord_); - break; - } - case 250: - case 248: { - input.ReadInt32Array(tag, field_name, result.repeatedInt32_); - break; - } - case 258: - case 256: { - input.ReadInt64Array(tag, field_name, result.repeatedInt64_); - break; - } - case 266: - case 264: { - input.ReadUInt32Array(tag, field_name, result.repeatedUint32_); - break; - } - case 274: - case 272: { - input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); - break; - } - case 282: - case 280: { - input.ReadSInt32Array(tag, field_name, result.repeatedSint32_); - break; - } - case 290: - case 288: { - input.ReadSInt64Array(tag, field_name, result.repeatedSint64_); - break; - } - case 298: - case 301: { - input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); - break; - } - case 306: - case 305: { - input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); - break; - } - case 314: - case 317: { - input.ReadSFixed32Array(tag, field_name, result.repeatedSfixed32_); - break; - } - case 322: - case 321: { - input.ReadSFixed64Array(tag, field_name, result.repeatedSfixed64_); - break; - } - case 330: - case 333: { - input.ReadFloatArray(tag, field_name, result.repeatedFloat_); - break; - } - case 338: - case 337: { - input.ReadDoubleArray(tag, field_name, result.repeatedDouble_); - break; - } - case 346: - case 344: { - input.ReadBoolArray(tag, field_name, result.repeatedBool_); - break; - } - case 354: { - input.ReadStringArray(tag, field_name, result.repeatedString_); - break; - } - case 362: { - input.ReadBytesArray(tag, field_name, result.repeatedBytes_); - break; - } - case 371: { - input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup.DefaultInstance, extensionRegistry); - break; - } - case 386: { - input.ReadMessageArray(tag, field_name, result.repeatedNestedMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance, extensionRegistry); - break; - } - case 394: { - input.ReadMessageArray(tag, field_name, result.repeatedForeignMessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance, extensionRegistry); - break; - } - case 402: { - input.ReadMessageArray(tag, field_name, result.repeatedImportMessage_, global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance, extensionRegistry); - break; - } - case 410: - case 408: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedNestedEnum_, out unknownItems); - break; - } - case 418: - case 416: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedForeignEnum_, out unknownItems); - break; - } - case 426: - case 424: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedImportEnum_, out unknownItems); - break; - } - case 434: { - input.ReadStringArray(tag, field_name, result.repeatedStringPiece_); - break; - } - case 442: { - input.ReadStringArray(tag, field_name, result.repeatedCord_); - break; - } - case 488: { - result.hasDefaultInt32 = input.ReadInt32(ref result.defaultInt32_); - break; - } - case 496: { - result.hasDefaultInt64 = input.ReadInt64(ref result.defaultInt64_); - break; - } - case 504: { - result.hasDefaultUint32 = input.ReadUInt32(ref result.defaultUint32_); - break; - } - case 512: { - result.hasDefaultUint64 = input.ReadUInt64(ref result.defaultUint64_); - break; - } - case 520: { - result.hasDefaultSint32 = input.ReadSInt32(ref result.defaultSint32_); - break; - } - case 528: { - result.hasDefaultSint64 = input.ReadSInt64(ref result.defaultSint64_); - break; - } - case 541: { - result.hasDefaultFixed32 = input.ReadFixed32(ref result.defaultFixed32_); - break; - } - case 545: { - result.hasDefaultFixed64 = input.ReadFixed64(ref result.defaultFixed64_); - break; - } - case 557: { - result.hasDefaultSfixed32 = input.ReadSFixed32(ref result.defaultSfixed32_); - break; - } - case 561: { - result.hasDefaultSfixed64 = input.ReadSFixed64(ref result.defaultSfixed64_); - break; - } - case 573: { - result.hasDefaultFloat = input.ReadFloat(ref result.defaultFloat_); - break; - } - case 577: { - result.hasDefaultDouble = input.ReadDouble(ref result.defaultDouble_); - break; - } - case 584: { - result.hasDefaultBool = input.ReadBool(ref result.defaultBool_); - break; - } - case 594: { - result.hasDefaultString = input.ReadString(ref result.defaultString_); - break; - } - case 602: { - result.hasDefaultBytes = input.ReadBytes(ref result.defaultBytes_); - break; - } - case 648: { - object unknown; - if(input.ReadEnum(ref result.defaultNestedEnum_, out unknown)) { - result.hasDefaultNestedEnum = true; - } else if(unknown is int) { - } - break; - } - case 656: { - object unknown; - if(input.ReadEnum(ref result.defaultForeignEnum_, out unknown)) { - result.hasDefaultForeignEnum = true; - } else if(unknown is int) { - } - break; - } - case 664: { - object unknown; - if(input.ReadEnum(ref result.defaultImportEnum_, out unknown)) { - result.hasDefaultImportEnum = true; - } else if(unknown is int) { - } - break; - } - case 674: { - result.hasDefaultStringPiece = input.ReadString(ref result.defaultStringPiece_); - break; - } - case 682: { - result.hasDefaultCord = input.ReadString(ref result.defaultCord_); - break; - } - } - } - - return this; - } - - - public bool HasOptionalInt32 { - get { return result.hasOptionalInt32; } - } - public int OptionalInt32 { - get { return result.OptionalInt32; } - set { SetOptionalInt32(value); } - } - public Builder SetOptionalInt32(int value) { - PrepareBuilder(); - result.hasOptionalInt32 = true; - result.optionalInt32_ = value; - return this; - } - public Builder ClearOptionalInt32() { - PrepareBuilder(); - result.hasOptionalInt32 = false; - result.optionalInt32_ = 0; - return this; - } - - public bool HasOptionalInt64 { - get { return result.hasOptionalInt64; } - } - public long OptionalInt64 { - get { return result.OptionalInt64; } - set { SetOptionalInt64(value); } - } - public Builder SetOptionalInt64(long value) { - PrepareBuilder(); - result.hasOptionalInt64 = true; - result.optionalInt64_ = value; - return this; - } - public Builder ClearOptionalInt64() { - PrepareBuilder(); - result.hasOptionalInt64 = false; - result.optionalInt64_ = 0L; - return this; - } - - public bool HasOptionalUint32 { - get { return result.hasOptionalUint32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalUint32 { - get { return result.OptionalUint32; } - set { SetOptionalUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalUint32(uint value) { - PrepareBuilder(); - result.hasOptionalUint32 = true; - result.optionalUint32_ = value; - return this; - } - public Builder ClearOptionalUint32() { - PrepareBuilder(); - result.hasOptionalUint32 = false; - result.optionalUint32_ = 0; - return this; - } - - public bool HasOptionalUint64 { - get { return result.hasOptionalUint64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalUint64 { - get { return result.OptionalUint64; } - set { SetOptionalUint64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalUint64(ulong value) { - PrepareBuilder(); - result.hasOptionalUint64 = true; - result.optionalUint64_ = value; - return this; - } - public Builder ClearOptionalUint64() { - PrepareBuilder(); - result.hasOptionalUint64 = false; - result.optionalUint64_ = 0UL; - return this; - } - - public bool HasOptionalSint32 { - get { return result.hasOptionalSint32; } - } - public int OptionalSint32 { - get { return result.OptionalSint32; } - set { SetOptionalSint32(value); } - } - public Builder SetOptionalSint32(int value) { - PrepareBuilder(); - result.hasOptionalSint32 = true; - result.optionalSint32_ = value; - return this; - } - public Builder ClearOptionalSint32() { - PrepareBuilder(); - result.hasOptionalSint32 = false; - result.optionalSint32_ = 0; - return this; - } - - public bool HasOptionalSint64 { - get { return result.hasOptionalSint64; } - } - public long OptionalSint64 { - get { return result.OptionalSint64; } - set { SetOptionalSint64(value); } - } - public Builder SetOptionalSint64(long value) { - PrepareBuilder(); - result.hasOptionalSint64 = true; - result.optionalSint64_ = value; - return this; - } - public Builder ClearOptionalSint64() { - PrepareBuilder(); - result.hasOptionalSint64 = false; - result.optionalSint64_ = 0; - return this; - } - - public bool HasOptionalFixed32 { - get { return result.hasOptionalFixed32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalFixed32 { - get { return result.OptionalFixed32; } - set { SetOptionalFixed32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalFixed32(uint value) { - PrepareBuilder(); - result.hasOptionalFixed32 = true; - result.optionalFixed32_ = value; - return this; - } - public Builder ClearOptionalFixed32() { - PrepareBuilder(); - result.hasOptionalFixed32 = false; - result.optionalFixed32_ = 0; - return this; - } - - public bool HasOptionalFixed64 { - get { return result.hasOptionalFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalFixed64 { - get { return result.OptionalFixed64; } - set { SetOptionalFixed64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalFixed64(ulong value) { - PrepareBuilder(); - result.hasOptionalFixed64 = true; - result.optionalFixed64_ = value; - return this; - } - public Builder ClearOptionalFixed64() { - PrepareBuilder(); - result.hasOptionalFixed64 = false; - result.optionalFixed64_ = 0; - return this; - } - - public bool HasOptionalSfixed32 { - get { return result.hasOptionalSfixed32; } - } - public int OptionalSfixed32 { - get { return result.OptionalSfixed32; } - set { SetOptionalSfixed32(value); } - } - public Builder SetOptionalSfixed32(int value) { - PrepareBuilder(); - result.hasOptionalSfixed32 = true; - result.optionalSfixed32_ = value; - return this; - } - public Builder ClearOptionalSfixed32() { - PrepareBuilder(); - result.hasOptionalSfixed32 = false; - result.optionalSfixed32_ = 0; - return this; - } - - public bool HasOptionalSfixed64 { - get { return result.hasOptionalSfixed64; } - } - public long OptionalSfixed64 { - get { return result.OptionalSfixed64; } - set { SetOptionalSfixed64(value); } - } - public Builder SetOptionalSfixed64(long value) { - PrepareBuilder(); - result.hasOptionalSfixed64 = true; - result.optionalSfixed64_ = value; - return this; - } - public Builder ClearOptionalSfixed64() { - PrepareBuilder(); - result.hasOptionalSfixed64 = false; - result.optionalSfixed64_ = 0; - return this; - } - - public bool HasOptionalFloat { - get { return result.hasOptionalFloat; } - } - public float OptionalFloat { - get { return result.OptionalFloat; } - set { SetOptionalFloat(value); } - } - public Builder SetOptionalFloat(float value) { - PrepareBuilder(); - result.hasOptionalFloat = true; - result.optionalFloat_ = value; - return this; - } - public Builder ClearOptionalFloat() { - PrepareBuilder(); - result.hasOptionalFloat = false; - result.optionalFloat_ = 0F; - return this; - } - - public bool HasOptionalDouble { - get { return result.hasOptionalDouble; } - } - public double OptionalDouble { - get { return result.OptionalDouble; } - set { SetOptionalDouble(value); } - } - public Builder SetOptionalDouble(double value) { - PrepareBuilder(); - result.hasOptionalDouble = true; - result.optionalDouble_ = value; - return this; - } - public Builder ClearOptionalDouble() { - PrepareBuilder(); - result.hasOptionalDouble = false; - result.optionalDouble_ = 0D; - return this; - } - - public bool HasOptionalBool { - get { return result.hasOptionalBool; } - } - public bool OptionalBool { - get { return result.OptionalBool; } - set { SetOptionalBool(value); } - } - public Builder SetOptionalBool(bool value) { - PrepareBuilder(); - result.hasOptionalBool = true; - result.optionalBool_ = value; - return this; - } - public Builder ClearOptionalBool() { - PrepareBuilder(); - result.hasOptionalBool = false; - result.optionalBool_ = false; - return this; - } - - public bool HasOptionalString { - get { return result.hasOptionalString; } - } - public string OptionalString { - get { return result.OptionalString; } - set { SetOptionalString(value); } - } - public Builder SetOptionalString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalString = true; - result.optionalString_ = value; - return this; - } - public Builder ClearOptionalString() { - PrepareBuilder(); - result.hasOptionalString = false; - result.optionalString_ = ""; - return this; - } - - public bool HasOptionalBytes { - get { return result.hasOptionalBytes; } - } - public pb::ByteString OptionalBytes { - get { return result.OptionalBytes; } - set { SetOptionalBytes(value); } - } - public Builder SetOptionalBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalBytes = true; - result.optionalBytes_ = value; - return this; - } - public Builder ClearOptionalBytes() { - PrepareBuilder(); - result.hasOptionalBytes = false; - result.optionalBytes_ = pb::ByteString.Empty; - return this; - } - - public bool HasOptionalGroup { - get { return result.hasOptionalGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup OptionalGroup { - get { return result.OptionalGroup; } - set { SetOptionalGroup(value); } - } - public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalGroup = true; - result.optionalGroup_ = value; - return this; - } - public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalGroup = true; - result.optionalGroup_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalGroup && - result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.DefaultInstance) { - result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial(); - } else { - result.optionalGroup_ = value; - } - result.hasOptionalGroup = true; - return this; - } - public Builder ClearOptionalGroup() { - PrepareBuilder(); - result.hasOptionalGroup = false; - result.optionalGroup_ = null; - return this; - } - - public bool HasOptionalNestedMessage { - get { return result.hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage OptionalNestedMessage { - get { return result.OptionalNestedMessage; } - set { SetOptionalNestedMessage(value); } - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = value; - return this; - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalNestedMessage && - result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance) { - result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalNestedMessage_ = value; - } - result.hasOptionalNestedMessage = true; - return this; - } - public Builder ClearOptionalNestedMessage() { - PrepareBuilder(); - result.hasOptionalNestedMessage = false; - result.optionalNestedMessage_ = null; - return this; - } - - public bool HasOptionalForeignMessage { - get { return result.hasOptionalForeignMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite OptionalForeignMessage { - get { return result.OptionalForeignMessage; } - set { SetOptionalForeignMessage(value); } - } - public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalForeignMessage = true; - result.optionalForeignMessage_ = value; - return this; - } - public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalForeignMessage = true; - result.optionalForeignMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalForeignMessage && - result.optionalForeignMessage_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance) { - result.optionalForeignMessage_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.CreateBuilder(result.optionalForeignMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalForeignMessage_ = value; - } - result.hasOptionalForeignMessage = true; - return this; - } - public Builder ClearOptionalForeignMessage() { - PrepareBuilder(); - result.hasOptionalForeignMessage = false; - result.optionalForeignMessage_ = null; - return this; - } - - public bool HasOptionalImportMessage { - get { return result.hasOptionalImportMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessageLite OptionalImportMessage { - get { return result.OptionalImportMessage; } - set { SetOptionalImportMessage(value); } - } - public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalImportMessage = true; - result.optionalImportMessage_ = value; - return this; - } - public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalImportMessage = true; - result.optionalImportMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalImportMessage && - result.optionalImportMessage_ != global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance) { - result.optionalImportMessage_ = global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.CreateBuilder(result.optionalImportMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalImportMessage_ = value; - } - result.hasOptionalImportMessage = true; - return this; - } - public Builder ClearOptionalImportMessage() { - PrepareBuilder(); - result.hasOptionalImportMessage = false; - result.optionalImportMessage_ = null; - return this; - } - - public bool HasOptionalNestedEnum { - get { return result.hasOptionalNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum OptionalNestedEnum { - get { return result.OptionalNestedEnum; } - set { SetOptionalNestedEnum(value); } - } - public Builder SetOptionalNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum value) { - PrepareBuilder(); - result.hasOptionalNestedEnum = true; - result.optionalNestedEnum_ = value; - return this; - } - public Builder ClearOptionalNestedEnum() { - PrepareBuilder(); - result.hasOptionalNestedEnum = false; - result.optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum.FOO; - return this; - } - - public bool HasOptionalForeignEnum { - get { return result.hasOptionalForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite OptionalForeignEnum { - get { return result.OptionalForeignEnum; } - set { SetOptionalForeignEnum(value); } - } - public Builder SetOptionalForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { - PrepareBuilder(); - result.hasOptionalForeignEnum = true; - result.optionalForeignEnum_ = value; - return this; - } - public Builder ClearOptionalForeignEnum() { - PrepareBuilder(); - result.hasOptionalForeignEnum = false; - result.optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite.FOREIGN_LITE_FOO; - return this; - } - - public bool HasOptionalImportEnum { - get { return result.hasOptionalImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite OptionalImportEnum { - get { return result.OptionalImportEnum; } - set { SetOptionalImportEnum(value); } - } - public Builder SetOptionalImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnumLite value) { - PrepareBuilder(); - result.hasOptionalImportEnum = true; - result.optionalImportEnum_ = value; - return this; - } - public Builder ClearOptionalImportEnum() { - PrepareBuilder(); - result.hasOptionalImportEnum = false; - result.optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnumLite.IMPORT_LITE_FOO; - return this; - } - - public bool HasOptionalStringPiece { - get { return result.hasOptionalStringPiece; } - } - public string OptionalStringPiece { - get { return result.OptionalStringPiece; } - set { SetOptionalStringPiece(value); } - } - public Builder SetOptionalStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalStringPiece = true; - result.optionalStringPiece_ = value; - return this; - } - public Builder ClearOptionalStringPiece() { - PrepareBuilder(); - result.hasOptionalStringPiece = false; - result.optionalStringPiece_ = ""; - return this; - } - - public bool HasOptionalCord { - get { return result.hasOptionalCord; } - } - public string OptionalCord { - get { return result.OptionalCord; } - set { SetOptionalCord(value); } - } - public Builder SetOptionalCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalCord = true; - result.optionalCord_ = value; - return this; - } - public Builder ClearOptionalCord() { - PrepareBuilder(); - result.hasOptionalCord = false; - result.optionalCord_ = ""; - return this; - } - - public pbc::IPopsicleList RepeatedInt32List { - get { return PrepareBuilder().repeatedInt32_; } - } - public int RepeatedInt32Count { - get { return result.RepeatedInt32Count; } - } - public int GetRepeatedInt32(int index) { - return result.GetRepeatedInt32(index); - } - public Builder SetRepeatedInt32(int index, int value) { - PrepareBuilder(); - result.repeatedInt32_[index] = value; - return this; - } - public Builder AddRepeatedInt32(int value) { - PrepareBuilder(); - result.repeatedInt32_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt32_.Add(values); - return this; - } - public Builder ClearRepeatedInt32() { - PrepareBuilder(); - result.repeatedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedInt64List { - get { return PrepareBuilder().repeatedInt64_; } - } - public int RepeatedInt64Count { - get { return result.RepeatedInt64Count; } - } - public long GetRepeatedInt64(int index) { - return result.GetRepeatedInt64(index); - } - public Builder SetRepeatedInt64(int index, long value) { - PrepareBuilder(); - result.repeatedInt64_[index] = value; - return this; - } - public Builder AddRepeatedInt64(long value) { - PrepareBuilder(); - result.repeatedInt64_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt64_.Add(values); - return this; - } - public Builder ClearRepeatedInt64() { - PrepareBuilder(); - result.repeatedInt64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedUint32List { - get { return PrepareBuilder().repeatedUint32_; } - } - public int RepeatedUint32Count { - get { return result.RepeatedUint32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedUint32(int index) { - return result.GetRepeatedUint32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedUint32(int index, uint value) { - PrepareBuilder(); - result.repeatedUint32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedUint32(uint value) { - PrepareBuilder(); - result.repeatedUint32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedUint32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedUint32_.Add(values); - return this; - } - public Builder ClearRepeatedUint32() { - PrepareBuilder(); - result.repeatedUint32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedUint64List { - get { return PrepareBuilder().repeatedUint64_; } - } - public int RepeatedUint64Count { - get { return result.RepeatedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return result.GetRepeatedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedUint64(int index, ulong value) { - PrepareBuilder(); - result.repeatedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedUint64(ulong value) { - PrepareBuilder(); - result.repeatedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedUint64_.Add(values); - return this; - } - public Builder ClearRepeatedUint64() { - PrepareBuilder(); - result.repeatedUint64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSint32List { - get { return PrepareBuilder().repeatedSint32_; } - } - public int RepeatedSint32Count { - get { return result.RepeatedSint32Count; } - } - public int GetRepeatedSint32(int index) { - return result.GetRepeatedSint32(index); - } - public Builder SetRepeatedSint32(int index, int value) { - PrepareBuilder(); - result.repeatedSint32_[index] = value; - return this; - } - public Builder AddRepeatedSint32(int value) { - PrepareBuilder(); - result.repeatedSint32_.Add(value); - return this; - } - public Builder AddRangeRepeatedSint32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSint32_.Add(values); - return this; - } - public Builder ClearRepeatedSint32() { - PrepareBuilder(); - result.repeatedSint32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSint64List { - get { return PrepareBuilder().repeatedSint64_; } - } - public int RepeatedSint64Count { - get { return result.RepeatedSint64Count; } - } - public long GetRepeatedSint64(int index) { - return result.GetRepeatedSint64(index); - } - public Builder SetRepeatedSint64(int index, long value) { - PrepareBuilder(); - result.repeatedSint64_[index] = value; - return this; - } - public Builder AddRepeatedSint64(long value) { - PrepareBuilder(); - result.repeatedSint64_.Add(value); - return this; - } - public Builder AddRangeRepeatedSint64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSint64_.Add(values); - return this; - } - public Builder ClearRepeatedSint64() { - PrepareBuilder(); - result.repeatedSint64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed32List { - get { return PrepareBuilder().repeatedFixed32_; } - } - public int RepeatedFixed32Count { - get { return result.RepeatedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return result.GetRepeatedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed32(int index, uint value) { - PrepareBuilder(); - result.repeatedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed32(uint value) { - PrepareBuilder(); - result.repeatedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed32_.Add(values); - return this; - } - public Builder ClearRepeatedFixed32() { - PrepareBuilder(); - result.repeatedFixed32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed64List { - get { return PrepareBuilder().repeatedFixed64_; } - } - public int RepeatedFixed64Count { - get { return result.RepeatedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return result.GetRepeatedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed64(int index, ulong value) { - PrepareBuilder(); - result.repeatedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed64(ulong value) { - PrepareBuilder(); - result.repeatedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed64_.Add(values); - return this; - } - public Builder ClearRepeatedFixed64() { - PrepareBuilder(); - result.repeatedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSfixed32List { - get { return PrepareBuilder().repeatedSfixed32_; } - } - public int RepeatedSfixed32Count { - get { return result.RepeatedSfixed32Count; } - } - public int GetRepeatedSfixed32(int index) { - return result.GetRepeatedSfixed32(index); - } - public Builder SetRepeatedSfixed32(int index, int value) { - PrepareBuilder(); - result.repeatedSfixed32_[index] = value; - return this; - } - public Builder AddRepeatedSfixed32(int value) { - PrepareBuilder(); - result.repeatedSfixed32_.Add(value); - return this; - } - public Builder AddRangeRepeatedSfixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSfixed32_.Add(values); - return this; - } - public Builder ClearRepeatedSfixed32() { - PrepareBuilder(); - result.repeatedSfixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSfixed64List { - get { return PrepareBuilder().repeatedSfixed64_; } - } - public int RepeatedSfixed64Count { - get { return result.RepeatedSfixed64Count; } - } - public long GetRepeatedSfixed64(int index) { - return result.GetRepeatedSfixed64(index); - } - public Builder SetRepeatedSfixed64(int index, long value) { - PrepareBuilder(); - result.repeatedSfixed64_[index] = value; - return this; - } - public Builder AddRepeatedSfixed64(long value) { - PrepareBuilder(); - result.repeatedSfixed64_.Add(value); - return this; - } - public Builder AddRangeRepeatedSfixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSfixed64_.Add(values); - return this; - } - public Builder ClearRepeatedSfixed64() { - PrepareBuilder(); - result.repeatedSfixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedFloatList { - get { return PrepareBuilder().repeatedFloat_; } - } - public int RepeatedFloatCount { - get { return result.RepeatedFloatCount; } - } - public float GetRepeatedFloat(int index) { - return result.GetRepeatedFloat(index); - } - public Builder SetRepeatedFloat(int index, float value) { - PrepareBuilder(); - result.repeatedFloat_[index] = value; - return this; - } - public Builder AddRepeatedFloat(float value) { - PrepareBuilder(); - result.repeatedFloat_.Add(value); - return this; - } - public Builder AddRangeRepeatedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFloat_.Add(values); - return this; - } - public Builder ClearRepeatedFloat() { - PrepareBuilder(); - result.repeatedFloat_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedDoubleList { - get { return PrepareBuilder().repeatedDouble_; } - } - public int RepeatedDoubleCount { - get { return result.RepeatedDoubleCount; } - } - public double GetRepeatedDouble(int index) { - return result.GetRepeatedDouble(index); - } - public Builder SetRepeatedDouble(int index, double value) { - PrepareBuilder(); - result.repeatedDouble_[index] = value; - return this; - } - public Builder AddRepeatedDouble(double value) { - PrepareBuilder(); - result.repeatedDouble_.Add(value); - return this; - } - public Builder AddRangeRepeatedDouble(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedDouble_.Add(values); - return this; - } - public Builder ClearRepeatedDouble() { - PrepareBuilder(); - result.repeatedDouble_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedBoolList { - get { return PrepareBuilder().repeatedBool_; } - } - public int RepeatedBoolCount { - get { return result.RepeatedBoolCount; } - } - public bool GetRepeatedBool(int index) { - return result.GetRepeatedBool(index); - } - public Builder SetRepeatedBool(int index, bool value) { - PrepareBuilder(); - result.repeatedBool_[index] = value; - return this; - } - public Builder AddRepeatedBool(bool value) { - PrepareBuilder(); - result.repeatedBool_.Add(value); - return this; - } - public Builder AddRangeRepeatedBool(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedBool_.Add(values); - return this; - } - public Builder ClearRepeatedBool() { - PrepareBuilder(); - result.repeatedBool_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringList { - get { return PrepareBuilder().repeatedString_; } - } - public int RepeatedStringCount { - get { return result.RepeatedStringCount; } - } - public string GetRepeatedString(int index) { - return result.GetRepeatedString(index); - } - public Builder SetRepeatedString(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedString_[index] = value; - return this; - } - public Builder AddRepeatedString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedString_.Add(value); - return this; - } - public Builder AddRangeRepeatedString(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedString_.Add(values); - return this; - } - public Builder ClearRepeatedString() { - PrepareBuilder(); - result.repeatedString_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedBytesList { - get { return PrepareBuilder().repeatedBytes_; } - } - public int RepeatedBytesCount { - get { return result.RepeatedBytesCount; } - } - public pb::ByteString GetRepeatedBytes(int index) { - return result.GetRepeatedBytes(index); - } - public Builder SetRepeatedBytes(int index, pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedBytes_[index] = value; - return this; - } - public Builder AddRepeatedBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedBytes_.Add(value); - return this; - } - public Builder AddRangeRepeatedBytes(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedBytes_.Add(values); - return this; - } - public Builder ClearRepeatedBytes() { - PrepareBuilder(); - result.repeatedBytes_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedGroupList { - get { return PrepareBuilder().repeatedGroup_; } - } - public int RepeatedGroupCount { - get { return result.RepeatedGroupCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup GetRepeatedGroup(int index) { - return result.GetRepeatedGroup(index); - } - public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedGroup_[index] = value; - return this; - } - public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedGroup_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedGroup_.Add(value); - return this; - } - public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedGroup_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedGroup(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedGroup_.Add(values); - return this; - } - public Builder ClearRepeatedGroup() { - PrepareBuilder(); - result.repeatedGroup_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedNestedMessageList { - get { return PrepareBuilder().repeatedNestedMessage_; } - } - public int RepeatedNestedMessageCount { - get { return result.RepeatedNestedMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage GetRepeatedNestedMessage(int index) { - return result.GetRepeatedNestedMessage(index); - } - public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedNestedMessage_[index] = value; - return this; - } - public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedNestedMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedNestedMessage_.Add(value); - return this; - } - public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedNestedMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedNestedMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedNestedMessage_.Add(values); - return this; - } - public Builder ClearRepeatedNestedMessage() { - PrepareBuilder(); - result.repeatedNestedMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedForeignMessageList { - get { return PrepareBuilder().repeatedForeignMessage_; } - } - public int RepeatedForeignMessageCount { - get { return result.RepeatedForeignMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite GetRepeatedForeignMessage(int index) { - return result.GetRepeatedForeignMessage(index); - } - public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedForeignMessage_[index] = value; - return this; - } - public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedForeignMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedForeignMessage_.Add(value); - return this; - } - public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedForeignMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedForeignMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedForeignMessage_.Add(values); - return this; - } - public Builder ClearRepeatedForeignMessage() { - PrepareBuilder(); - result.repeatedForeignMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedImportMessageList { - get { return PrepareBuilder().repeatedImportMessage_; } - } - public int RepeatedImportMessageCount { - get { return result.RepeatedImportMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessageLite GetRepeatedImportMessage(int index) { - return result.GetRepeatedImportMessage(index); - } - public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessageLite value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedImportMessage_[index] = value; - return this; - } - public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedImportMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedImportMessage_.Add(value); - return this; - } - public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedImportMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedImportMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedImportMessage_.Add(values); - return this; - } - public Builder ClearRepeatedImportMessage() { - PrepareBuilder(); - result.repeatedImportMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedNestedEnumList { - get { return PrepareBuilder().repeatedNestedEnum_; } - } - public int RepeatedNestedEnumCount { - get { return result.RepeatedNestedEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum GetRepeatedNestedEnum(int index) { - return result.GetRepeatedNestedEnum(index); - } - public Builder SetRepeatedNestedEnum(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum value) { - PrepareBuilder(); - result.repeatedNestedEnum_[index] = value; - return this; - } - public Builder AddRepeatedNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum value) { - PrepareBuilder(); - result.repeatedNestedEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedNestedEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedNestedEnum_.Add(values); - return this; - } - public Builder ClearRepeatedNestedEnum() { - PrepareBuilder(); - result.repeatedNestedEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedForeignEnumList { - get { return PrepareBuilder().repeatedForeignEnum_; } - } - public int RepeatedForeignEnumCount { - get { return result.RepeatedForeignEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite GetRepeatedForeignEnum(int index) { - return result.GetRepeatedForeignEnum(index); - } - public Builder SetRepeatedForeignEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { - PrepareBuilder(); - result.repeatedForeignEnum_[index] = value; - return this; - } - public Builder AddRepeatedForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { - PrepareBuilder(); - result.repeatedForeignEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedForeignEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedForeignEnum_.Add(values); - return this; - } - public Builder ClearRepeatedForeignEnum() { - PrepareBuilder(); - result.repeatedForeignEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedImportEnumList { - get { return PrepareBuilder().repeatedImportEnum_; } - } - public int RepeatedImportEnumCount { - get { return result.RepeatedImportEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite GetRepeatedImportEnum(int index) { - return result.GetRepeatedImportEnum(index); - } - public Builder SetRepeatedImportEnum(int index, global::Google.ProtocolBuffers.TestProtos.ImportEnumLite value) { - PrepareBuilder(); - result.repeatedImportEnum_[index] = value; - return this; - } - public Builder AddRepeatedImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnumLite value) { - PrepareBuilder(); - result.repeatedImportEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedImportEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedImportEnum_.Add(values); - return this; - } - public Builder ClearRepeatedImportEnum() { - PrepareBuilder(); - result.repeatedImportEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringPieceList { - get { return PrepareBuilder().repeatedStringPiece_; } - } - public int RepeatedStringPieceCount { - get { return result.RepeatedStringPieceCount; } - } - public string GetRepeatedStringPiece(int index) { - return result.GetRepeatedStringPiece(index); - } - public Builder SetRepeatedStringPiece(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPiece_[index] = value; - return this; - } - public Builder AddRepeatedStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPiece_.Add(value); - return this; - } - public Builder AddRangeRepeatedStringPiece(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedStringPiece_.Add(values); - return this; - } - public Builder ClearRepeatedStringPiece() { - PrepareBuilder(); - result.repeatedStringPiece_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedCordList { - get { return PrepareBuilder().repeatedCord_; } - } - public int RepeatedCordCount { - get { return result.RepeatedCordCount; } - } - public string GetRepeatedCord(int index) { - return result.GetRepeatedCord(index); - } - public Builder SetRepeatedCord(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCord_[index] = value; - return this; - } - public Builder AddRepeatedCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCord_.Add(value); - return this; - } - public Builder AddRangeRepeatedCord(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedCord_.Add(values); - return this; - } - public Builder ClearRepeatedCord() { - PrepareBuilder(); - result.repeatedCord_.Clear(); - return this; - } - - public bool HasDefaultInt32 { - get { return result.hasDefaultInt32; } - } - public int DefaultInt32 { - get { return result.DefaultInt32; } - set { SetDefaultInt32(value); } - } - public Builder SetDefaultInt32(int value) { - PrepareBuilder(); - result.hasDefaultInt32 = true; - result.defaultInt32_ = value; - return this; - } - public Builder ClearDefaultInt32() { - PrepareBuilder(); - result.hasDefaultInt32 = false; - result.defaultInt32_ = 41; - return this; - } - - public bool HasDefaultInt64 { - get { return result.hasDefaultInt64; } - } - public long DefaultInt64 { - get { return result.DefaultInt64; } - set { SetDefaultInt64(value); } - } - public Builder SetDefaultInt64(long value) { - PrepareBuilder(); - result.hasDefaultInt64 = true; - result.defaultInt64_ = value; - return this; - } - public Builder ClearDefaultInt64() { - PrepareBuilder(); - result.hasDefaultInt64 = false; - result.defaultInt64_ = 42L; - return this; - } - - public bool HasDefaultUint32 { - get { return result.hasDefaultUint32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultUint32 { - get { return result.DefaultUint32; } - set { SetDefaultUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultUint32(uint value) { - PrepareBuilder(); - result.hasDefaultUint32 = true; - result.defaultUint32_ = value; - return this; - } - public Builder ClearDefaultUint32() { - PrepareBuilder(); - result.hasDefaultUint32 = false; - result.defaultUint32_ = 43; - return this; - } - - public bool HasDefaultUint64 { - get { return result.hasDefaultUint64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultUint64 { - get { return result.DefaultUint64; } - set { SetDefaultUint64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultUint64(ulong value) { - PrepareBuilder(); - result.hasDefaultUint64 = true; - result.defaultUint64_ = value; - return this; - } - public Builder ClearDefaultUint64() { - PrepareBuilder(); - result.hasDefaultUint64 = false; - result.defaultUint64_ = 44UL; - return this; - } - - public bool HasDefaultSint32 { - get { return result.hasDefaultSint32; } - } - public int DefaultSint32 { - get { return result.DefaultSint32; } - set { SetDefaultSint32(value); } - } - public Builder SetDefaultSint32(int value) { - PrepareBuilder(); - result.hasDefaultSint32 = true; - result.defaultSint32_ = value; - return this; - } - public Builder ClearDefaultSint32() { - PrepareBuilder(); - result.hasDefaultSint32 = false; - result.defaultSint32_ = -45; - return this; - } - - public bool HasDefaultSint64 { - get { return result.hasDefaultSint64; } - } - public long DefaultSint64 { - get { return result.DefaultSint64; } - set { SetDefaultSint64(value); } - } - public Builder SetDefaultSint64(long value) { - PrepareBuilder(); - result.hasDefaultSint64 = true; - result.defaultSint64_ = value; - return this; - } - public Builder ClearDefaultSint64() { - PrepareBuilder(); - result.hasDefaultSint64 = false; - result.defaultSint64_ = 46; - return this; - } - - public bool HasDefaultFixed32 { - get { return result.hasDefaultFixed32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultFixed32 { - get { return result.DefaultFixed32; } - set { SetDefaultFixed32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultFixed32(uint value) { - PrepareBuilder(); - result.hasDefaultFixed32 = true; - result.defaultFixed32_ = value; - return this; - } - public Builder ClearDefaultFixed32() { - PrepareBuilder(); - result.hasDefaultFixed32 = false; - result.defaultFixed32_ = 47; - return this; - } - - public bool HasDefaultFixed64 { - get { return result.hasDefaultFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultFixed64 { - get { return result.DefaultFixed64; } - set { SetDefaultFixed64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultFixed64(ulong value) { - PrepareBuilder(); - result.hasDefaultFixed64 = true; - result.defaultFixed64_ = value; - return this; - } - public Builder ClearDefaultFixed64() { - PrepareBuilder(); - result.hasDefaultFixed64 = false; - result.defaultFixed64_ = 48; - return this; - } - - public bool HasDefaultSfixed32 { - get { return result.hasDefaultSfixed32; } - } - public int DefaultSfixed32 { - get { return result.DefaultSfixed32; } - set { SetDefaultSfixed32(value); } - } - public Builder SetDefaultSfixed32(int value) { - PrepareBuilder(); - result.hasDefaultSfixed32 = true; - result.defaultSfixed32_ = value; - return this; - } - public Builder ClearDefaultSfixed32() { - PrepareBuilder(); - result.hasDefaultSfixed32 = false; - result.defaultSfixed32_ = 49; - return this; - } - - public bool HasDefaultSfixed64 { - get { return result.hasDefaultSfixed64; } - } - public long DefaultSfixed64 { - get { return result.DefaultSfixed64; } - set { SetDefaultSfixed64(value); } - } - public Builder SetDefaultSfixed64(long value) { - PrepareBuilder(); - result.hasDefaultSfixed64 = true; - result.defaultSfixed64_ = value; - return this; - } - public Builder ClearDefaultSfixed64() { - PrepareBuilder(); - result.hasDefaultSfixed64 = false; - result.defaultSfixed64_ = -50; - return this; - } - - public bool HasDefaultFloat { - get { return result.hasDefaultFloat; } - } - public float DefaultFloat { - get { return result.DefaultFloat; } - set { SetDefaultFloat(value); } - } - public Builder SetDefaultFloat(float value) { - PrepareBuilder(); - result.hasDefaultFloat = true; - result.defaultFloat_ = value; - return this; - } - public Builder ClearDefaultFloat() { - PrepareBuilder(); - result.hasDefaultFloat = false; - result.defaultFloat_ = 51.5F; - return this; - } - - public bool HasDefaultDouble { - get { return result.hasDefaultDouble; } - } - public double DefaultDouble { - get { return result.DefaultDouble; } - set { SetDefaultDouble(value); } - } - public Builder SetDefaultDouble(double value) { - PrepareBuilder(); - result.hasDefaultDouble = true; - result.defaultDouble_ = value; - return this; - } - public Builder ClearDefaultDouble() { - PrepareBuilder(); - result.hasDefaultDouble = false; - result.defaultDouble_ = 52000D; - return this; - } - - public bool HasDefaultBool { - get { return result.hasDefaultBool; } - } - public bool DefaultBool { - get { return result.DefaultBool; } - set { SetDefaultBool(value); } - } - public Builder SetDefaultBool(bool value) { - PrepareBuilder(); - result.hasDefaultBool = true; - result.defaultBool_ = value; - return this; - } - public Builder ClearDefaultBool() { - PrepareBuilder(); - result.hasDefaultBool = false; - result.defaultBool_ = true; - return this; - } - - public bool HasDefaultString { - get { return result.hasDefaultString; } - } - public string DefaultString { - get { return result.DefaultString; } - set { SetDefaultString(value); } - } - public Builder SetDefaultString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultString = true; - result.defaultString_ = value; - return this; - } - public Builder ClearDefaultString() { - PrepareBuilder(); - result.hasDefaultString = false; - result.defaultString_ = "hello"; - return this; - } - - public bool HasDefaultBytes { - get { return result.hasDefaultBytes; } - } - public pb::ByteString DefaultBytes { - get { return result.DefaultBytes; } - set { SetDefaultBytes(value); } - } - public Builder SetDefaultBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultBytes = true; - result.defaultBytes_ = value; - return this; - } - public Builder ClearDefaultBytes() { - PrepareBuilder(); - result.hasDefaultBytes = false; - result.defaultBytes_ = pb::ByteString.FromBase64("d29ybGQ="); - return this; - } - - public bool HasDefaultNestedEnum { - get { return result.hasDefaultNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum DefaultNestedEnum { - get { return result.DefaultNestedEnum; } - set { SetDefaultNestedEnum(value); } - } - public Builder SetDefaultNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum value) { - PrepareBuilder(); - result.hasDefaultNestedEnum = true; - result.defaultNestedEnum_ = value; - return this; - } - public Builder ClearDefaultNestedEnum() { - PrepareBuilder(); - result.hasDefaultNestedEnum = false; - result.defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum.BAR; - return this; - } - - public bool HasDefaultForeignEnum { - get { return result.hasDefaultForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite DefaultForeignEnum { - get { return result.DefaultForeignEnum; } - set { SetDefaultForeignEnum(value); } - } - public Builder SetDefaultForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { - PrepareBuilder(); - result.hasDefaultForeignEnum = true; - result.defaultForeignEnum_ = value; - return this; - } - public Builder ClearDefaultForeignEnum() { - PrepareBuilder(); - result.hasDefaultForeignEnum = false; - result.defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite.FOREIGN_LITE_BAR; - return this; - } - - public bool HasDefaultImportEnum { - get { return result.hasDefaultImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite DefaultImportEnum { - get { return result.DefaultImportEnum; } - set { SetDefaultImportEnum(value); } - } - public Builder SetDefaultImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnumLite value) { - PrepareBuilder(); - result.hasDefaultImportEnum = true; - result.defaultImportEnum_ = value; - return this; - } - public Builder ClearDefaultImportEnum() { - PrepareBuilder(); - result.hasDefaultImportEnum = false; - result.defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnumLite.IMPORT_LITE_BAR; - return this; - } - - public bool HasDefaultStringPiece { - get { return result.hasDefaultStringPiece; } - } - public string DefaultStringPiece { - get { return result.DefaultStringPiece; } - set { SetDefaultStringPiece(value); } - } - public Builder SetDefaultStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultStringPiece = true; - result.defaultStringPiece_ = value; - return this; - } - public Builder ClearDefaultStringPiece() { - PrepareBuilder(); - result.hasDefaultStringPiece = false; - result.defaultStringPiece_ = "abc"; - return this; - } - - public bool HasDefaultCord { - get { return result.hasDefaultCord; } - } - public string DefaultCord { - get { return result.DefaultCord; } - set { SetDefaultCord(value); } - } - public Builder SetDefaultCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultCord = true; - result.defaultCord_ = value; - return this; - } - public Builder ClearDefaultCord() { - PrepareBuilder(); - result.hasDefaultCord = false; - result.defaultCord_ = "123"; - return this; - } - } - static TestAllTypesLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class ForeignMessageLite : pb::GeneratedMessageLite { - private ForeignMessageLite() { } - private static readonly ForeignMessageLite defaultInstance = new ForeignMessageLite().MakeReadOnly(); - private static readonly string[] _foreignMessageLiteFieldNames = new string[] { "c" }; - private static readonly uint[] _foreignMessageLiteFieldTags = new uint[] { 8 }; - public static ForeignMessageLite DefaultInstance { - get { return defaultInstance; } - } - - public override ForeignMessageLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override ForeignMessageLite ThisMessage { - get { return this; } - } - - public const int CFieldNumber = 1; - private bool hasC; - private int c_; - public bool HasC { - get { return hasC; } - } - public int C { - get { return c_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _foreignMessageLiteFieldNames; - if (hasC) { - output.WriteInt32(1, field_names[0], C); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasC) { - size += pb::CodedOutputStream.ComputeInt32Size(1, C); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasC) hash ^= c_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - ForeignMessageLite other = obj as ForeignMessageLite; - if (other == null) return false; - if (hasC != other.hasC || (hasC && !c_.Equals(other.c_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("c", hasC, c_, writer); - } - #endregion - - public static ForeignMessageLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ForeignMessageLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ForeignMessageLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ForeignMessageLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ForeignMessageLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ForeignMessageLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static ForeignMessageLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static ForeignMessageLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static ForeignMessageLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ForeignMessageLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private ForeignMessageLite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(ForeignMessageLite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(ForeignMessageLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private ForeignMessageLite result; - - private ForeignMessageLite PrepareBuilder() { - if (resultIsReadOnly) { - ForeignMessageLite original = result; - result = new ForeignMessageLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override ForeignMessageLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override ForeignMessageLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance; } - } - - public override ForeignMessageLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is ForeignMessageLite) { - return MergeFrom((ForeignMessageLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(ForeignMessageLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasC) { - C = other.C; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_foreignMessageLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _foreignMessageLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasC = input.ReadInt32(ref result.c_); - break; - } - } - } - - return this; - } - - - public bool HasC { - get { return result.hasC; } - } - public int C { - get { return result.C; } - set { SetC(value); } - } - public Builder SetC(int value) { - PrepareBuilder(); - result.hasC = true; - result.c_ = value; - return this; - } - public Builder ClearC() { - PrepareBuilder(); - result.hasC = false; - result.c_ = 0; - return this; - } - } - static ForeignMessageLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestPackedTypesLite : pb::GeneratedMessageLite { - private TestPackedTypesLite() { } - private static readonly TestPackedTypesLite defaultInstance = new TestPackedTypesLite().MakeReadOnly(); - private static readonly string[] _testPackedTypesLiteFieldNames = new string[] { "packed_bool", "packed_double", "packed_enum", "packed_fixed32", "packed_fixed64", "packed_float", "packed_int32", "packed_int64", "packed_sfixed32", "packed_sfixed64", "packed_sint32", "packed_sint64", "packed_uint32", "packed_uint64" }; - private static readonly uint[] _testPackedTypesLiteFieldTags = new uint[] { 818, 810, 826, 770, 778, 802, 722, 730, 786, 794, 754, 762, 738, 746 }; - public static TestPackedTypesLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestPackedTypesLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestPackedTypesLite ThisMessage { - get { return this; } - } - - public const int PackedInt32FieldNumber = 90; - private int packedInt32MemoizedSerializedSize; - private pbc::PopsicleList packedInt32_ = new pbc::PopsicleList(); - public scg::IList PackedInt32List { - get { return pbc::Lists.AsReadOnly(packedInt32_); } - } - public int PackedInt32Count { - get { return packedInt32_.Count; } - } - public int GetPackedInt32(int index) { - return packedInt32_[index]; - } - - public const int PackedInt64FieldNumber = 91; - private int packedInt64MemoizedSerializedSize; - private pbc::PopsicleList packedInt64_ = new pbc::PopsicleList(); - public scg::IList PackedInt64List { - get { return pbc::Lists.AsReadOnly(packedInt64_); } - } - public int PackedInt64Count { - get { return packedInt64_.Count; } - } - public long GetPackedInt64(int index) { - return packedInt64_[index]; - } - - public const int PackedUint32FieldNumber = 92; - private int packedUint32MemoizedSerializedSize; - private pbc::PopsicleList packedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedUint32List { - get { return pbc::Lists.AsReadOnly(packedUint32_); } - } - public int PackedUint32Count { - get { return packedUint32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedUint32(int index) { - return packedUint32_[index]; - } - - public const int PackedUint64FieldNumber = 93; - private int packedUint64MemoizedSerializedSize; - private pbc::PopsicleList packedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedUint64List { - get { return pbc::Lists.AsReadOnly(packedUint64_); } - } - public int PackedUint64Count { - get { return packedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedUint64(int index) { - return packedUint64_[index]; - } - - public const int PackedSint32FieldNumber = 94; - private int packedSint32MemoizedSerializedSize; - private pbc::PopsicleList packedSint32_ = new pbc::PopsicleList(); - public scg::IList PackedSint32List { - get { return pbc::Lists.AsReadOnly(packedSint32_); } - } - public int PackedSint32Count { - get { return packedSint32_.Count; } - } - public int GetPackedSint32(int index) { - return packedSint32_[index]; - } - - public const int PackedSint64FieldNumber = 95; - private int packedSint64MemoizedSerializedSize; - private pbc::PopsicleList packedSint64_ = new pbc::PopsicleList(); - public scg::IList PackedSint64List { - get { return pbc::Lists.AsReadOnly(packedSint64_); } - } - public int PackedSint64Count { - get { return packedSint64_.Count; } - } - public long GetPackedSint64(int index) { - return packedSint64_[index]; - } - - public const int PackedFixed32FieldNumber = 96; - private int packedFixed32MemoizedSerializedSize; - private pbc::PopsicleList packedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedFixed32List { - get { return pbc::Lists.AsReadOnly(packedFixed32_); } - } - public int PackedFixed32Count { - get { return packedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedFixed32(int index) { - return packedFixed32_[index]; - } - - public const int PackedFixed64FieldNumber = 97; - private int packedFixed64MemoizedSerializedSize; - private pbc::PopsicleList packedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedFixed64List { - get { return pbc::Lists.AsReadOnly(packedFixed64_); } - } - public int PackedFixed64Count { - get { return packedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedFixed64(int index) { - return packedFixed64_[index]; - } - - public const int PackedSfixed32FieldNumber = 98; - private int packedSfixed32MemoizedSerializedSize; - private pbc::PopsicleList packedSfixed32_ = new pbc::PopsicleList(); - public scg::IList PackedSfixed32List { - get { return pbc::Lists.AsReadOnly(packedSfixed32_); } - } - public int PackedSfixed32Count { - get { return packedSfixed32_.Count; } - } - public int GetPackedSfixed32(int index) { - return packedSfixed32_[index]; - } - - public const int PackedSfixed64FieldNumber = 99; - private int packedSfixed64MemoizedSerializedSize; - private pbc::PopsicleList packedSfixed64_ = new pbc::PopsicleList(); - public scg::IList PackedSfixed64List { - get { return pbc::Lists.AsReadOnly(packedSfixed64_); } - } - public int PackedSfixed64Count { - get { return packedSfixed64_.Count; } - } - public long GetPackedSfixed64(int index) { - return packedSfixed64_[index]; - } - - public const int PackedFloatFieldNumber = 100; - private int packedFloatMemoizedSerializedSize; - private pbc::PopsicleList packedFloat_ = new pbc::PopsicleList(); - public scg::IList PackedFloatList { - get { return pbc::Lists.AsReadOnly(packedFloat_); } - } - public int PackedFloatCount { - get { return packedFloat_.Count; } - } - public float GetPackedFloat(int index) { - return packedFloat_[index]; - } - - public const int PackedDoubleFieldNumber = 101; - private int packedDoubleMemoizedSerializedSize; - private pbc::PopsicleList packedDouble_ = new pbc::PopsicleList(); - public scg::IList PackedDoubleList { - get { return pbc::Lists.AsReadOnly(packedDouble_); } - } - public int PackedDoubleCount { - get { return packedDouble_.Count; } - } - public double GetPackedDouble(int index) { - return packedDouble_[index]; - } - - public const int PackedBoolFieldNumber = 102; - private int packedBoolMemoizedSerializedSize; - private pbc::PopsicleList packedBool_ = new pbc::PopsicleList(); - public scg::IList PackedBoolList { - get { return pbc::Lists.AsReadOnly(packedBool_); } - } - public int PackedBoolCount { - get { return packedBool_.Count; } - } - public bool GetPackedBool(int index) { - return packedBool_[index]; - } - - public const int PackedEnumFieldNumber = 103; - private int packedEnumMemoizedSerializedSize; - private pbc::PopsicleList packedEnum_ = new pbc::PopsicleList(); - public scg::IList PackedEnumList { - get { return pbc::Lists.AsReadOnly(packedEnum_); } - } - public int PackedEnumCount { - get { return packedEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite GetPackedEnum(int index) { - return packedEnum_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testPackedTypesLiteFieldNames; - if (packedInt32_.Count > 0) { - output.WritePackedInt32Array(90, field_names[6], packedInt32MemoizedSerializedSize, packedInt32_); - } - if (packedInt64_.Count > 0) { - output.WritePackedInt64Array(91, field_names[7], packedInt64MemoizedSerializedSize, packedInt64_); - } - if (packedUint32_.Count > 0) { - output.WritePackedUInt32Array(92, field_names[12], packedUint32MemoizedSerializedSize, packedUint32_); - } - if (packedUint64_.Count > 0) { - output.WritePackedUInt64Array(93, field_names[13], packedUint64MemoizedSerializedSize, packedUint64_); - } - if (packedSint32_.Count > 0) { - output.WritePackedSInt32Array(94, field_names[10], packedSint32MemoizedSerializedSize, packedSint32_); - } - if (packedSint64_.Count > 0) { - output.WritePackedSInt64Array(95, field_names[11], packedSint64MemoizedSerializedSize, packedSint64_); - } - if (packedFixed32_.Count > 0) { - output.WritePackedFixed32Array(96, field_names[3], packedFixed32MemoizedSerializedSize, packedFixed32_); - } - if (packedFixed64_.Count > 0) { - output.WritePackedFixed64Array(97, field_names[4], packedFixed64MemoizedSerializedSize, packedFixed64_); - } - if (packedSfixed32_.Count > 0) { - output.WritePackedSFixed32Array(98, field_names[8], packedSfixed32MemoizedSerializedSize, packedSfixed32_); - } - if (packedSfixed64_.Count > 0) { - output.WritePackedSFixed64Array(99, field_names[9], packedSfixed64MemoizedSerializedSize, packedSfixed64_); - } - if (packedFloat_.Count > 0) { - output.WritePackedFloatArray(100, field_names[5], packedFloatMemoizedSerializedSize, packedFloat_); - } - if (packedDouble_.Count > 0) { - output.WritePackedDoubleArray(101, field_names[1], packedDoubleMemoizedSerializedSize, packedDouble_); - } - if (packedBool_.Count > 0) { - output.WritePackedBoolArray(102, field_names[0], packedBoolMemoizedSerializedSize, packedBool_); - } - if (packedEnum_.Count > 0) { - output.WritePackedEnumArray(103, field_names[2], packedEnumMemoizedSerializedSize, packedEnum_); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (int element in PackedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - if (packedInt32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedInt32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (long element in PackedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - if (packedInt64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedInt64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (uint element in PackedUint32List) { - dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); - } - size += dataSize; - if (packedUint32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedUint32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (ulong element in PackedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - if (packedUint64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedUint64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (int element in PackedSint32List) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - if (packedSint32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSint32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (long element in PackedSint64List) { - dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); - } - size += dataSize; - if (packedSint64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSint64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 4 * packedFixed32_.Count; - size += dataSize; - if (packedFixed32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedFixed32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 8 * packedFixed64_.Count; - size += dataSize; - if (packedFixed64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedFixed64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 4 * packedSfixed32_.Count; - size += dataSize; - if (packedSfixed32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSfixed32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 8 * packedSfixed64_.Count; - size += dataSize; - if (packedSfixed64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSfixed64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 4 * packedFloat_.Count; - size += dataSize; - if (packedFloat_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedFloatMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 8 * packedDouble_.Count; - size += dataSize; - if (packedDouble_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedDoubleMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 1 * packedBool_.Count; - size += dataSize; - if (packedBool_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedBoolMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - if (packedEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite element in packedEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2; - size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); - } - packedEnumMemoizedSerializedSize = dataSize; - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - foreach(int i in packedInt32_) - hash ^= i.GetHashCode(); - foreach(long i in packedInt64_) - hash ^= i.GetHashCode(); - foreach(uint i in packedUint32_) - hash ^= i.GetHashCode(); - foreach(ulong i in packedUint64_) - hash ^= i.GetHashCode(); - foreach(int i in packedSint32_) - hash ^= i.GetHashCode(); - foreach(long i in packedSint64_) - hash ^= i.GetHashCode(); - foreach(uint i in packedFixed32_) - hash ^= i.GetHashCode(); - foreach(ulong i in packedFixed64_) - hash ^= i.GetHashCode(); - foreach(int i in packedSfixed32_) - hash ^= i.GetHashCode(); - foreach(long i in packedSfixed64_) - hash ^= i.GetHashCode(); - foreach(float i in packedFloat_) - hash ^= i.GetHashCode(); - foreach(double i in packedDouble_) - hash ^= i.GetHashCode(); - foreach(bool i in packedBool_) - hash ^= i.GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite i in packedEnum_) - hash ^= i.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestPackedTypesLite other = obj as TestPackedTypesLite; - if (other == null) return false; - if(packedInt32_.Count != other.packedInt32_.Count) return false; - for(int ix=0; ix < packedInt32_.Count; ix++) - if(!packedInt32_[ix].Equals(other.packedInt32_[ix])) return false; - if(packedInt64_.Count != other.packedInt64_.Count) return false; - for(int ix=0; ix < packedInt64_.Count; ix++) - if(!packedInt64_[ix].Equals(other.packedInt64_[ix])) return false; - if(packedUint32_.Count != other.packedUint32_.Count) return false; - for(int ix=0; ix < packedUint32_.Count; ix++) - if(!packedUint32_[ix].Equals(other.packedUint32_[ix])) return false; - if(packedUint64_.Count != other.packedUint64_.Count) return false; - for(int ix=0; ix < packedUint64_.Count; ix++) - if(!packedUint64_[ix].Equals(other.packedUint64_[ix])) return false; - if(packedSint32_.Count != other.packedSint32_.Count) return false; - for(int ix=0; ix < packedSint32_.Count; ix++) - if(!packedSint32_[ix].Equals(other.packedSint32_[ix])) return false; - if(packedSint64_.Count != other.packedSint64_.Count) return false; - for(int ix=0; ix < packedSint64_.Count; ix++) - if(!packedSint64_[ix].Equals(other.packedSint64_[ix])) return false; - if(packedFixed32_.Count != other.packedFixed32_.Count) return false; - for(int ix=0; ix < packedFixed32_.Count; ix++) - if(!packedFixed32_[ix].Equals(other.packedFixed32_[ix])) return false; - if(packedFixed64_.Count != other.packedFixed64_.Count) return false; - for(int ix=0; ix < packedFixed64_.Count; ix++) - if(!packedFixed64_[ix].Equals(other.packedFixed64_[ix])) return false; - if(packedSfixed32_.Count != other.packedSfixed32_.Count) return false; - for(int ix=0; ix < packedSfixed32_.Count; ix++) - if(!packedSfixed32_[ix].Equals(other.packedSfixed32_[ix])) return false; - if(packedSfixed64_.Count != other.packedSfixed64_.Count) return false; - for(int ix=0; ix < packedSfixed64_.Count; ix++) - if(!packedSfixed64_[ix].Equals(other.packedSfixed64_[ix])) return false; - if(packedFloat_.Count != other.packedFloat_.Count) return false; - for(int ix=0; ix < packedFloat_.Count; ix++) - if(!packedFloat_[ix].Equals(other.packedFloat_[ix])) return false; - if(packedDouble_.Count != other.packedDouble_.Count) return false; - for(int ix=0; ix < packedDouble_.Count; ix++) - if(!packedDouble_[ix].Equals(other.packedDouble_[ix])) return false; - if(packedBool_.Count != other.packedBool_.Count) return false; - for(int ix=0; ix < packedBool_.Count; ix++) - if(!packedBool_[ix].Equals(other.packedBool_[ix])) return false; - if(packedEnum_.Count != other.packedEnum_.Count) return false; - for(int ix=0; ix < packedEnum_.Count; ix++) - if(!packedEnum_[ix].Equals(other.packedEnum_[ix])) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("packed_int32", packedInt32_, writer); - PrintField("packed_int64", packedInt64_, writer); - PrintField("packed_uint32", packedUint32_, writer); - PrintField("packed_uint64", packedUint64_, writer); - PrintField("packed_sint32", packedSint32_, writer); - PrintField("packed_sint64", packedSint64_, writer); - PrintField("packed_fixed32", packedFixed32_, writer); - PrintField("packed_fixed64", packedFixed64_, writer); - PrintField("packed_sfixed32", packedSfixed32_, writer); - PrintField("packed_sfixed64", packedSfixed64_, writer); - PrintField("packed_float", packedFloat_, writer); - PrintField("packed_double", packedDouble_, writer); - PrintField("packed_bool", packedBool_, writer); - PrintField("packed_enum", packedEnum_, writer); - } - #endregion - - public static TestPackedTypesLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedTypesLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedTypesLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedTypesLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedTypesLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedTypesLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestPackedTypesLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestPackedTypesLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestPackedTypesLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedTypesLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestPackedTypesLite MakeReadOnly() { - packedInt32_.MakeReadOnly(); - packedInt64_.MakeReadOnly(); - packedUint32_.MakeReadOnly(); - packedUint64_.MakeReadOnly(); - packedSint32_.MakeReadOnly(); - packedSint64_.MakeReadOnly(); - packedFixed32_.MakeReadOnly(); - packedFixed64_.MakeReadOnly(); - packedSfixed32_.MakeReadOnly(); - packedSfixed64_.MakeReadOnly(); - packedFloat_.MakeReadOnly(); - packedDouble_.MakeReadOnly(); - packedBool_.MakeReadOnly(); - packedEnum_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestPackedTypesLite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestPackedTypesLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestPackedTypesLite result; - - private TestPackedTypesLite PrepareBuilder() { - if (resultIsReadOnly) { - TestPackedTypesLite original = result; - result = new TestPackedTypesLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestPackedTypesLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestPackedTypesLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypesLite.DefaultInstance; } - } - - public override TestPackedTypesLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestPackedTypesLite) { - return MergeFrom((TestPackedTypesLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestPackedTypesLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedTypesLite.DefaultInstance) return this; - PrepareBuilder(); - if (other.packedInt32_.Count != 0) { - result.packedInt32_.Add(other.packedInt32_); - } - if (other.packedInt64_.Count != 0) { - result.packedInt64_.Add(other.packedInt64_); - } - if (other.packedUint32_.Count != 0) { - result.packedUint32_.Add(other.packedUint32_); - } - if (other.packedUint64_.Count != 0) { - result.packedUint64_.Add(other.packedUint64_); - } - if (other.packedSint32_.Count != 0) { - result.packedSint32_.Add(other.packedSint32_); - } - if (other.packedSint64_.Count != 0) { - result.packedSint64_.Add(other.packedSint64_); - } - if (other.packedFixed32_.Count != 0) { - result.packedFixed32_.Add(other.packedFixed32_); - } - if (other.packedFixed64_.Count != 0) { - result.packedFixed64_.Add(other.packedFixed64_); - } - if (other.packedSfixed32_.Count != 0) { - result.packedSfixed32_.Add(other.packedSfixed32_); - } - if (other.packedSfixed64_.Count != 0) { - result.packedSfixed64_.Add(other.packedSfixed64_); - } - if (other.packedFloat_.Count != 0) { - result.packedFloat_.Add(other.packedFloat_); - } - if (other.packedDouble_.Count != 0) { - result.packedDouble_.Add(other.packedDouble_); - } - if (other.packedBool_.Count != 0) { - result.packedBool_.Add(other.packedBool_); - } - if (other.packedEnum_.Count != 0) { - result.packedEnum_.Add(other.packedEnum_); - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testPackedTypesLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testPackedTypesLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 722: - case 720: { - input.ReadInt32Array(tag, field_name, result.packedInt32_); - break; - } - case 730: - case 728: { - input.ReadInt64Array(tag, field_name, result.packedInt64_); - break; - } - case 738: - case 736: { - input.ReadUInt32Array(tag, field_name, result.packedUint32_); - break; - } - case 746: - case 744: { - input.ReadUInt64Array(tag, field_name, result.packedUint64_); - break; - } - case 754: - case 752: { - input.ReadSInt32Array(tag, field_name, result.packedSint32_); - break; - } - case 762: - case 760: { - input.ReadSInt64Array(tag, field_name, result.packedSint64_); - break; - } - case 770: - case 773: { - input.ReadFixed32Array(tag, field_name, result.packedFixed32_); - break; - } - case 778: - case 777: { - input.ReadFixed64Array(tag, field_name, result.packedFixed64_); - break; - } - case 786: - case 789: { - input.ReadSFixed32Array(tag, field_name, result.packedSfixed32_); - break; - } - case 794: - case 793: { - input.ReadSFixed64Array(tag, field_name, result.packedSfixed64_); - break; - } - case 802: - case 805: { - input.ReadFloatArray(tag, field_name, result.packedFloat_); - break; - } - case 810: - case 809: { - input.ReadDoubleArray(tag, field_name, result.packedDouble_); - break; - } - case 818: - case 816: { - input.ReadBoolArray(tag, field_name, result.packedBool_); - break; - } - case 826: - case 824: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.packedEnum_, out unknownItems); - break; - } - } - } - - return this; - } - - - public pbc::IPopsicleList PackedInt32List { - get { return PrepareBuilder().packedInt32_; } - } - public int PackedInt32Count { - get { return result.PackedInt32Count; } - } - public int GetPackedInt32(int index) { - return result.GetPackedInt32(index); - } - public Builder SetPackedInt32(int index, int value) { - PrepareBuilder(); - result.packedInt32_[index] = value; - return this; - } - public Builder AddPackedInt32(int value) { - PrepareBuilder(); - result.packedInt32_.Add(value); - return this; - } - public Builder AddRangePackedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedInt32_.Add(values); - return this; - } - public Builder ClearPackedInt32() { - PrepareBuilder(); - result.packedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedInt64List { - get { return PrepareBuilder().packedInt64_; } - } - public int PackedInt64Count { - get { return result.PackedInt64Count; } - } - public long GetPackedInt64(int index) { - return result.GetPackedInt64(index); - } - public Builder SetPackedInt64(int index, long value) { - PrepareBuilder(); - result.packedInt64_[index] = value; - return this; - } - public Builder AddPackedInt64(long value) { - PrepareBuilder(); - result.packedInt64_.Add(value); - return this; - } - public Builder AddRangePackedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedInt64_.Add(values); - return this; - } - public Builder ClearPackedInt64() { - PrepareBuilder(); - result.packedInt64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedUint32List { - get { return PrepareBuilder().packedUint32_; } - } - public int PackedUint32Count { - get { return result.PackedUint32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedUint32(int index) { - return result.GetPackedUint32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedUint32(int index, uint value) { - PrepareBuilder(); - result.packedUint32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedUint32(uint value) { - PrepareBuilder(); - result.packedUint32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedUint32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedUint32_.Add(values); - return this; - } - public Builder ClearPackedUint32() { - PrepareBuilder(); - result.packedUint32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedUint64List { - get { return PrepareBuilder().packedUint64_; } - } - public int PackedUint64Count { - get { return result.PackedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedUint64(int index) { - return result.GetPackedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedUint64(int index, ulong value) { - PrepareBuilder(); - result.packedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedUint64(ulong value) { - PrepareBuilder(); - result.packedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedUint64_.Add(values); - return this; - } - public Builder ClearPackedUint64() { - PrepareBuilder(); - result.packedUint64_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSint32List { - get { return PrepareBuilder().packedSint32_; } - } - public int PackedSint32Count { - get { return result.PackedSint32Count; } - } - public int GetPackedSint32(int index) { - return result.GetPackedSint32(index); - } - public Builder SetPackedSint32(int index, int value) { - PrepareBuilder(); - result.packedSint32_[index] = value; - return this; - } - public Builder AddPackedSint32(int value) { - PrepareBuilder(); - result.packedSint32_.Add(value); - return this; - } - public Builder AddRangePackedSint32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSint32_.Add(values); - return this; - } - public Builder ClearPackedSint32() { - PrepareBuilder(); - result.packedSint32_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSint64List { - get { return PrepareBuilder().packedSint64_; } - } - public int PackedSint64Count { - get { return result.PackedSint64Count; } - } - public long GetPackedSint64(int index) { - return result.GetPackedSint64(index); - } - public Builder SetPackedSint64(int index, long value) { - PrepareBuilder(); - result.packedSint64_[index] = value; - return this; - } - public Builder AddPackedSint64(long value) { - PrepareBuilder(); - result.packedSint64_.Add(value); - return this; - } - public Builder AddRangePackedSint64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSint64_.Add(values); - return this; - } - public Builder ClearPackedSint64() { - PrepareBuilder(); - result.packedSint64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedFixed32List { - get { return PrepareBuilder().packedFixed32_; } - } - public int PackedFixed32Count { - get { return result.PackedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedFixed32(int index) { - return result.GetPackedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedFixed32(int index, uint value) { - PrepareBuilder(); - result.packedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedFixed32(uint value) { - PrepareBuilder(); - result.packedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedFixed32_.Add(values); - return this; - } - public Builder ClearPackedFixed32() { - PrepareBuilder(); - result.packedFixed32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedFixed64List { - get { return PrepareBuilder().packedFixed64_; } - } - public int PackedFixed64Count { - get { return result.PackedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedFixed64(int index) { - return result.GetPackedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedFixed64(int index, ulong value) { - PrepareBuilder(); - result.packedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedFixed64(ulong value) { - PrepareBuilder(); - result.packedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedFixed64_.Add(values); - return this; - } - public Builder ClearPackedFixed64() { - PrepareBuilder(); - result.packedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSfixed32List { - get { return PrepareBuilder().packedSfixed32_; } - } - public int PackedSfixed32Count { - get { return result.PackedSfixed32Count; } - } - public int GetPackedSfixed32(int index) { - return result.GetPackedSfixed32(index); - } - public Builder SetPackedSfixed32(int index, int value) { - PrepareBuilder(); - result.packedSfixed32_[index] = value; - return this; - } - public Builder AddPackedSfixed32(int value) { - PrepareBuilder(); - result.packedSfixed32_.Add(value); - return this; - } - public Builder AddRangePackedSfixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSfixed32_.Add(values); - return this; - } - public Builder ClearPackedSfixed32() { - PrepareBuilder(); - result.packedSfixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSfixed64List { - get { return PrepareBuilder().packedSfixed64_; } - } - public int PackedSfixed64Count { - get { return result.PackedSfixed64Count; } - } - public long GetPackedSfixed64(int index) { - return result.GetPackedSfixed64(index); - } - public Builder SetPackedSfixed64(int index, long value) { - PrepareBuilder(); - result.packedSfixed64_[index] = value; - return this; - } - public Builder AddPackedSfixed64(long value) { - PrepareBuilder(); - result.packedSfixed64_.Add(value); - return this; - } - public Builder AddRangePackedSfixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSfixed64_.Add(values); - return this; - } - public Builder ClearPackedSfixed64() { - PrepareBuilder(); - result.packedSfixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedFloatList { - get { return PrepareBuilder().packedFloat_; } - } - public int PackedFloatCount { - get { return result.PackedFloatCount; } - } - public float GetPackedFloat(int index) { - return result.GetPackedFloat(index); - } - public Builder SetPackedFloat(int index, float value) { - PrepareBuilder(); - result.packedFloat_[index] = value; - return this; - } - public Builder AddPackedFloat(float value) { - PrepareBuilder(); - result.packedFloat_.Add(value); - return this; - } - public Builder AddRangePackedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.packedFloat_.Add(values); - return this; - } - public Builder ClearPackedFloat() { - PrepareBuilder(); - result.packedFloat_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedDoubleList { - get { return PrepareBuilder().packedDouble_; } - } - public int PackedDoubleCount { - get { return result.PackedDoubleCount; } - } - public double GetPackedDouble(int index) { - return result.GetPackedDouble(index); - } - public Builder SetPackedDouble(int index, double value) { - PrepareBuilder(); - result.packedDouble_[index] = value; - return this; - } - public Builder AddPackedDouble(double value) { - PrepareBuilder(); - result.packedDouble_.Add(value); - return this; - } - public Builder AddRangePackedDouble(scg::IEnumerable values) { - PrepareBuilder(); - result.packedDouble_.Add(values); - return this; - } - public Builder ClearPackedDouble() { - PrepareBuilder(); - result.packedDouble_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedBoolList { - get { return PrepareBuilder().packedBool_; } - } - public int PackedBoolCount { - get { return result.PackedBoolCount; } - } - public bool GetPackedBool(int index) { - return result.GetPackedBool(index); - } - public Builder SetPackedBool(int index, bool value) { - PrepareBuilder(); - result.packedBool_[index] = value; - return this; - } - public Builder AddPackedBool(bool value) { - PrepareBuilder(); - result.packedBool_.Add(value); - return this; - } - public Builder AddRangePackedBool(scg::IEnumerable values) { - PrepareBuilder(); - result.packedBool_.Add(values); - return this; - } - public Builder ClearPackedBool() { - PrepareBuilder(); - result.packedBool_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedEnumList { - get { return PrepareBuilder().packedEnum_; } - } - public int PackedEnumCount { - get { return result.PackedEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite GetPackedEnum(int index) { - return result.GetPackedEnum(index); - } - public Builder SetPackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { - PrepareBuilder(); - result.packedEnum_[index] = value; - return this; - } - public Builder AddPackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { - PrepareBuilder(); - result.packedEnum_.Add(value); - return this; - } - public Builder AddRangePackedEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.packedEnum_.Add(values); - return this; - } - public Builder ClearPackedEnum() { - PrepareBuilder(); - result.packedEnum_.Clear(); - return this; - } - } - static TestPackedTypesLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestAllExtensionsLite : pb::ExtendableMessageLite { - private TestAllExtensionsLite() { } - private static readonly TestAllExtensionsLite defaultInstance = new TestAllExtensionsLite().MakeReadOnly(); - private static readonly string[] _testAllExtensionsLiteFieldNames = new string[] { }; - private static readonly uint[] _testAllExtensionsLiteFieldTags = new uint[] { }; - public static TestAllExtensionsLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestAllExtensionsLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestAllExtensionsLite ThisMessage { - get { return this; } - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testAllExtensionsLiteFieldNames; - pb::ExtendableMessageLite.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(536870912, output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += ExtensionsSerializedSize; - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - hash ^= base.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestAllExtensionsLite other = obj as TestAllExtensionsLite; - if (other == null) return false; - if (!base.Equals(other)) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - base.PrintTo(writer); - } - #endregion - - public static TestAllExtensionsLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllExtensionsLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllExtensionsLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllExtensionsLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllExtensionsLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllExtensionsLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestAllExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestAllExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestAllExtensionsLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllExtensionsLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestAllExtensionsLite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestAllExtensionsLite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestAllExtensionsLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestAllExtensionsLite result; - - private TestAllExtensionsLite PrepareBuilder() { - if (resultIsReadOnly) { - TestAllExtensionsLite original = result; - result = new TestAllExtensionsLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestAllExtensionsLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestAllExtensionsLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance; } - } - - public override TestAllExtensionsLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestAllExtensionsLite) { - return MergeFrom((TestAllExtensionsLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestAllExtensionsLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testAllExtensionsLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testAllExtensionsLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - } - } - - return this; - } - - } - static TestAllExtensionsLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OptionalGroup_extension_lite : pb::GeneratedMessageLite { - private OptionalGroup_extension_lite() { } - private static readonly OptionalGroup_extension_lite defaultInstance = new OptionalGroup_extension_lite().MakeReadOnly(); - private static readonly string[] _optionalGroupExtensionLiteFieldNames = new string[] { "a" }; - private static readonly uint[] _optionalGroupExtensionLiteFieldTags = new uint[] { 136 }; - public static OptionalGroup_extension_lite DefaultInstance { - get { return defaultInstance; } - } - - public override OptionalGroup_extension_lite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override OptionalGroup_extension_lite ThisMessage { - get { return this; } - } - - public const int AFieldNumber = 17; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _optionalGroupExtensionLiteFieldNames; - if (hasA) { - output.WriteInt32(17, field_names[0], A); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(17, A); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasA) hash ^= a_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - OptionalGroup_extension_lite other = obj as OptionalGroup_extension_lite; - if (other == null) return false; - if (hasA != other.hasA || (hasA && !a_.Equals(other.a_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("a", hasA, a_, writer); - } - #endregion - - public static OptionalGroup_extension_lite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup_extension_lite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup_extension_lite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup_extension_lite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup_extension_lite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup_extension_lite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup_extension_lite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static OptionalGroup_extension_lite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static OptionalGroup_extension_lite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup_extension_lite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private OptionalGroup_extension_lite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OptionalGroup_extension_lite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OptionalGroup_extension_lite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OptionalGroup_extension_lite result; - - private OptionalGroup_extension_lite PrepareBuilder() { - if (resultIsReadOnly) { - OptionalGroup_extension_lite original = result; - result = new OptionalGroup_extension_lite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OptionalGroup_extension_lite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override OptionalGroup_extension_lite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension_lite.DefaultInstance; } - } - - public override OptionalGroup_extension_lite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is OptionalGroup_extension_lite) { - return MergeFrom((OptionalGroup_extension_lite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(OptionalGroup_extension_lite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension_lite.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_optionalGroupExtensionLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _optionalGroupExtensionLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 136: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static OptionalGroup_extension_lite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class RepeatedGroup_extension_lite : pb::GeneratedMessageLite { - private RepeatedGroup_extension_lite() { } - private static readonly RepeatedGroup_extension_lite defaultInstance = new RepeatedGroup_extension_lite().MakeReadOnly(); - private static readonly string[] _repeatedGroupExtensionLiteFieldNames = new string[] { "a" }; - private static readonly uint[] _repeatedGroupExtensionLiteFieldTags = new uint[] { 376 }; - public static RepeatedGroup_extension_lite DefaultInstance { - get { return defaultInstance; } - } - - public override RepeatedGroup_extension_lite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override RepeatedGroup_extension_lite ThisMessage { - get { return this; } - } - - public const int AFieldNumber = 47; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _repeatedGroupExtensionLiteFieldNames; - if (hasA) { - output.WriteInt32(47, field_names[0], A); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(47, A); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasA) hash ^= a_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - RepeatedGroup_extension_lite other = obj as RepeatedGroup_extension_lite; - if (other == null) return false; - if (hasA != other.hasA || (hasA && !a_.Equals(other.a_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("a", hasA, a_, writer); - } - #endregion - - public static RepeatedGroup_extension_lite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup_extension_lite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup_extension_lite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup_extension_lite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup_extension_lite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup_extension_lite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup_extension_lite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static RepeatedGroup_extension_lite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static RepeatedGroup_extension_lite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup_extension_lite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private RepeatedGroup_extension_lite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(RepeatedGroup_extension_lite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(RepeatedGroup_extension_lite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private RepeatedGroup_extension_lite result; - - private RepeatedGroup_extension_lite PrepareBuilder() { - if (resultIsReadOnly) { - RepeatedGroup_extension_lite original = result; - result = new RepeatedGroup_extension_lite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override RepeatedGroup_extension_lite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override RepeatedGroup_extension_lite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension_lite.DefaultInstance; } - } - - public override RepeatedGroup_extension_lite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is RepeatedGroup_extension_lite) { - return MergeFrom((RepeatedGroup_extension_lite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(RepeatedGroup_extension_lite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension_lite.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupExtensionLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _repeatedGroupExtensionLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 376: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static RepeatedGroup_extension_lite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestPackedExtensionsLite : pb::ExtendableMessageLite { - private TestPackedExtensionsLite() { } - private static readonly TestPackedExtensionsLite defaultInstance = new TestPackedExtensionsLite().MakeReadOnly(); - private static readonly string[] _testPackedExtensionsLiteFieldNames = new string[] { }; - private static readonly uint[] _testPackedExtensionsLiteFieldTags = new uint[] { }; - public static TestPackedExtensionsLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestPackedExtensionsLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestPackedExtensionsLite ThisMessage { - get { return this; } - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testPackedExtensionsLiteFieldNames; - pb::ExtendableMessageLite.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(536870912, output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += ExtensionsSerializedSize; - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - hash ^= base.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestPackedExtensionsLite other = obj as TestPackedExtensionsLite; - if (other == null) return false; - if (!base.Equals(other)) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - base.PrintTo(writer); - } - #endregion - - public static TestPackedExtensionsLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedExtensionsLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedExtensionsLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedExtensionsLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedExtensionsLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedExtensionsLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestPackedExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestPackedExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestPackedExtensionsLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedExtensionsLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestPackedExtensionsLite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestPackedExtensionsLite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestPackedExtensionsLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestPackedExtensionsLite result; - - private TestPackedExtensionsLite PrepareBuilder() { - if (resultIsReadOnly) { - TestPackedExtensionsLite original = result; - result = new TestPackedExtensionsLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestPackedExtensionsLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestPackedExtensionsLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance; } - } - - public override TestPackedExtensionsLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestPackedExtensionsLite) { - return MergeFrom((TestPackedExtensionsLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestPackedExtensionsLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testPackedExtensionsLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testPackedExtensionsLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - } - } - - return this; - } - - } - static TestPackedExtensionsLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestNestedExtensionLite : pb::GeneratedMessageLite { - private TestNestedExtensionLite() { } - private static readonly TestNestedExtensionLite defaultInstance = new TestNestedExtensionLite().MakeReadOnly(); - private static readonly string[] _testNestedExtensionLiteFieldNames = new string[] { }; - private static readonly uint[] _testNestedExtensionLiteFieldTags = new uint[] { }; - public static TestNestedExtensionLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestNestedExtensionLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestNestedExtensionLite ThisMessage { - get { return this; } - } - - public const int NestedExtensionFieldNumber = 12345; - public static pb::GeneratedExtensionLite NestedExtension; - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testNestedExtensionLiteFieldNames; - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestNestedExtensionLite other = obj as TestNestedExtensionLite; - if (other == null) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - } - #endregion - - public static TestNestedExtensionLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestNestedExtensionLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestNestedExtensionLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestNestedExtensionLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestNestedExtensionLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestNestedExtensionLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestNestedExtensionLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestNestedExtensionLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestNestedExtensionLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestNestedExtensionLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestNestedExtensionLite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestNestedExtensionLite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestNestedExtensionLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestNestedExtensionLite result; - - private TestNestedExtensionLite PrepareBuilder() { - if (resultIsReadOnly) { - TestNestedExtensionLite original = result; - result = new TestNestedExtensionLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestNestedExtensionLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestNestedExtensionLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtensionLite.DefaultInstance; } - } - - public override TestNestedExtensionLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestNestedExtensionLite) { - return MergeFrom((TestNestedExtensionLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestNestedExtensionLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedExtensionLite.DefaultInstance) return this; - PrepareBuilder(); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testNestedExtensionLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testNestedExtensionLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - } - } - - return this; - } - - } - static TestNestedExtensionLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestDeprecatedLite : pb::GeneratedMessageLite { - private TestDeprecatedLite() { } - private static readonly TestDeprecatedLite defaultInstance = new TestDeprecatedLite().MakeReadOnly(); - private static readonly string[] _testDeprecatedLiteFieldNames = new string[] { "deprecated_field" }; - private static readonly uint[] _testDeprecatedLiteFieldTags = new uint[] { 8 }; - public static TestDeprecatedLite DefaultInstance { - get { return defaultInstance; } - } - - public override TestDeprecatedLite DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestDeprecatedLite ThisMessage { - get { return this; } - } - - public const int DeprecatedFieldFieldNumber = 1; - private bool hasDeprecatedField; - private int deprecatedField_; - [global::System.ObsoleteAttribute()] - public bool HasDeprecatedField { - get { return hasDeprecatedField; } - } - [global::System.ObsoleteAttribute()] - public int DeprecatedField { - get { return deprecatedField_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testDeprecatedLiteFieldNames; - if (hasDeprecatedField) { - output.WriteInt32(1, field_names[0], DeprecatedField); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasDeprecatedField) { - size += pb::CodedOutputStream.ComputeInt32Size(1, DeprecatedField); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasDeprecatedField) hash ^= deprecatedField_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - TestDeprecatedLite other = obj as TestDeprecatedLite; - if (other == null) return false; - if (hasDeprecatedField != other.hasDeprecatedField || (hasDeprecatedField && !deprecatedField_.Equals(other.deprecatedField_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("deprecated_field", hasDeprecatedField, deprecatedField_, writer); - } - #endregion - - public static TestDeprecatedLite ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDeprecatedLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDeprecatedLite ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDeprecatedLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDeprecatedLite ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDeprecatedLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestDeprecatedLite ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestDeprecatedLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestDeprecatedLite ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDeprecatedLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestDeprecatedLite MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestDeprecatedLite prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestDeprecatedLite cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestDeprecatedLite result; - - private TestDeprecatedLite PrepareBuilder() { - if (resultIsReadOnly) { - TestDeprecatedLite original = result; - result = new TestDeprecatedLite(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestDeprecatedLite MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override TestDeprecatedLite DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedLite.DefaultInstance; } - } - - public override TestDeprecatedLite BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is TestDeprecatedLite) { - return MergeFrom((TestDeprecatedLite) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestDeprecatedLite other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDeprecatedLite.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasDeprecatedField) { - DeprecatedField = other.DeprecatedField; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testDeprecatedLiteFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testDeprecatedLiteFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasDeprecatedField = input.ReadInt32(ref result.deprecatedField_); - break; - } - } - } - - return this; - } - - - [global::System.ObsoleteAttribute()] - public bool HasDeprecatedField { - get { return result.hasDeprecatedField; } - } - [global::System.ObsoleteAttribute()] - public int DeprecatedField { - get { return result.DeprecatedField; } - set { SetDeprecatedField(value); } - } - [global::System.ObsoleteAttribute()] - public Builder SetDeprecatedField(int value) { - PrepareBuilder(); - result.hasDeprecatedField = true; - result.deprecatedField_ = value; - return this; - } - [global::System.ObsoleteAttribute()] - public Builder ClearDeprecatedField() { - PrepareBuilder(); - result.hasDeprecatedField = false; - result.deprecatedField_ = 0; - return this; - } - } - static TestDeprecatedLite() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestLiteProtoFile.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestProtoFile.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestProtoFile.cs deleted file mode 100644 index dd31c675..00000000 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestProtoFile.cs +++ /dev/null @@ -1,21602 +0,0 @@ -// Generated by ProtoGen, Version=2.4.1.555, Culture=neutral, PublicKeyToken=55f7125234beb589. DO NOT EDIT! -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnitTestProtoFile { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalInt32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalInt64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalUint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalUint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSfixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSfixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFloatExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalDoubleExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalBoolExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalStringExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalBytesExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalGroupExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalNestedMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalForeignMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalImportMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalNestedEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalForeignEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalImportEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalStringPieceExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalCordExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedInt32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedInt64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedUint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedUint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSfixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSfixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFloatExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedDoubleExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedBoolExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedStringExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedBytesExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedGroupExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedNestedMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedForeignMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedImportMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedNestedEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedForeignEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedImportEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedStringPieceExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedCordExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultInt32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultInt64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultUint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultUint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSfixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSfixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFloatExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultDoubleExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultBoolExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultStringExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultBytesExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultNestedEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultForeignEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultImportEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultStringPieceExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultCordExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.MyExtensionString); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.MyExtensionInt); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedInt32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedInt64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedUint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedUint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSfixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSfixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFloatExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedDoubleExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedBoolExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Test); - registry.Add(global::Google.ProtocolBuffers.TestProtos.TestRequired.Single); - registry.Add(global::Google.ProtocolBuffers.TestProtos.TestRequired.Multi); - } - #endregion - #region Extensions - public const int OptionalInt32ExtensionFieldNumber = 1; - public static pb::GeneratedExtensionBase OptionalInt32Extension; - public const int OptionalInt64ExtensionFieldNumber = 2; - public static pb::GeneratedExtensionBase OptionalInt64Extension; - public const int OptionalUint32ExtensionFieldNumber = 3; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase OptionalUint32Extension; - public const int OptionalUint64ExtensionFieldNumber = 4; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase OptionalUint64Extension; - public const int OptionalSint32ExtensionFieldNumber = 5; - public static pb::GeneratedExtensionBase OptionalSint32Extension; - public const int OptionalSint64ExtensionFieldNumber = 6; - public static pb::GeneratedExtensionBase OptionalSint64Extension; - public const int OptionalFixed32ExtensionFieldNumber = 7; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase OptionalFixed32Extension; - public const int OptionalFixed64ExtensionFieldNumber = 8; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase OptionalFixed64Extension; - public const int OptionalSfixed32ExtensionFieldNumber = 9; - public static pb::GeneratedExtensionBase OptionalSfixed32Extension; - public const int OptionalSfixed64ExtensionFieldNumber = 10; - public static pb::GeneratedExtensionBase OptionalSfixed64Extension; - public const int OptionalFloatExtensionFieldNumber = 11; - public static pb::GeneratedExtensionBase OptionalFloatExtension; - public const int OptionalDoubleExtensionFieldNumber = 12; - public static pb::GeneratedExtensionBase OptionalDoubleExtension; - public const int OptionalBoolExtensionFieldNumber = 13; - public static pb::GeneratedExtensionBase OptionalBoolExtension; - public const int OptionalStringExtensionFieldNumber = 14; - public static pb::GeneratedExtensionBase OptionalStringExtension; - public const int OptionalBytesExtensionFieldNumber = 15; - public static pb::GeneratedExtensionBase OptionalBytesExtension; - public const int OptionalGroupExtensionFieldNumber = 16; - public static pb::GeneratedExtensionBase OptionalGroupExtension; - public const int OptionalNestedMessageExtensionFieldNumber = 18; - public static pb::GeneratedExtensionBase OptionalNestedMessageExtension; - public const int OptionalForeignMessageExtensionFieldNumber = 19; - public static pb::GeneratedExtensionBase OptionalForeignMessageExtension; - public const int OptionalImportMessageExtensionFieldNumber = 20; - public static pb::GeneratedExtensionBase OptionalImportMessageExtension; - public const int OptionalNestedEnumExtensionFieldNumber = 21; - public static pb::GeneratedExtensionBase OptionalNestedEnumExtension; - public const int OptionalForeignEnumExtensionFieldNumber = 22; - public static pb::GeneratedExtensionBase OptionalForeignEnumExtension; - public const int OptionalImportEnumExtensionFieldNumber = 23; - public static pb::GeneratedExtensionBase OptionalImportEnumExtension; - public const int OptionalStringPieceExtensionFieldNumber = 24; - public static pb::GeneratedExtensionBase OptionalStringPieceExtension; - public const int OptionalCordExtensionFieldNumber = 25; - public static pb::GeneratedExtensionBase OptionalCordExtension; - public const int RepeatedInt32ExtensionFieldNumber = 31; - public static pb::GeneratedExtensionBase> RepeatedInt32Extension; - public const int RepeatedInt64ExtensionFieldNumber = 32; - public static pb::GeneratedExtensionBase> RepeatedInt64Extension; - public const int RepeatedUint32ExtensionFieldNumber = 33; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> RepeatedUint32Extension; - public const int RepeatedUint64ExtensionFieldNumber = 34; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> RepeatedUint64Extension; - public const int RepeatedSint32ExtensionFieldNumber = 35; - public static pb::GeneratedExtensionBase> RepeatedSint32Extension; - public const int RepeatedSint64ExtensionFieldNumber = 36; - public static pb::GeneratedExtensionBase> RepeatedSint64Extension; - public const int RepeatedFixed32ExtensionFieldNumber = 37; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> RepeatedFixed32Extension; - public const int RepeatedFixed64ExtensionFieldNumber = 38; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> RepeatedFixed64Extension; - public const int RepeatedSfixed32ExtensionFieldNumber = 39; - public static pb::GeneratedExtensionBase> RepeatedSfixed32Extension; - public const int RepeatedSfixed64ExtensionFieldNumber = 40; - public static pb::GeneratedExtensionBase> RepeatedSfixed64Extension; - public const int RepeatedFloatExtensionFieldNumber = 41; - public static pb::GeneratedExtensionBase> RepeatedFloatExtension; - public const int RepeatedDoubleExtensionFieldNumber = 42; - public static pb::GeneratedExtensionBase> RepeatedDoubleExtension; - public const int RepeatedBoolExtensionFieldNumber = 43; - public static pb::GeneratedExtensionBase> RepeatedBoolExtension; - public const int RepeatedStringExtensionFieldNumber = 44; - public static pb::GeneratedExtensionBase> RepeatedStringExtension; - public const int RepeatedBytesExtensionFieldNumber = 45; - public static pb::GeneratedExtensionBase> RepeatedBytesExtension; - public const int RepeatedGroupExtensionFieldNumber = 46; - public static pb::GeneratedExtensionBase> RepeatedGroupExtension; - public const int RepeatedNestedMessageExtensionFieldNumber = 48; - public static pb::GeneratedExtensionBase> RepeatedNestedMessageExtension; - public const int RepeatedForeignMessageExtensionFieldNumber = 49; - public static pb::GeneratedExtensionBase> RepeatedForeignMessageExtension; - public const int RepeatedImportMessageExtensionFieldNumber = 50; - public static pb::GeneratedExtensionBase> RepeatedImportMessageExtension; - public const int RepeatedNestedEnumExtensionFieldNumber = 51; - public static pb::GeneratedExtensionBase> RepeatedNestedEnumExtension; - public const int RepeatedForeignEnumExtensionFieldNumber = 52; - public static pb::GeneratedExtensionBase> RepeatedForeignEnumExtension; - public const int RepeatedImportEnumExtensionFieldNumber = 53; - public static pb::GeneratedExtensionBase> RepeatedImportEnumExtension; - public const int RepeatedStringPieceExtensionFieldNumber = 54; - public static pb::GeneratedExtensionBase> RepeatedStringPieceExtension; - public const int RepeatedCordExtensionFieldNumber = 55; - public static pb::GeneratedExtensionBase> RepeatedCordExtension; - public const int DefaultInt32ExtensionFieldNumber = 61; - public static pb::GeneratedExtensionBase DefaultInt32Extension; - public const int DefaultInt64ExtensionFieldNumber = 62; - public static pb::GeneratedExtensionBase DefaultInt64Extension; - public const int DefaultUint32ExtensionFieldNumber = 63; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase DefaultUint32Extension; - public const int DefaultUint64ExtensionFieldNumber = 64; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase DefaultUint64Extension; - public const int DefaultSint32ExtensionFieldNumber = 65; - public static pb::GeneratedExtensionBase DefaultSint32Extension; - public const int DefaultSint64ExtensionFieldNumber = 66; - public static pb::GeneratedExtensionBase DefaultSint64Extension; - public const int DefaultFixed32ExtensionFieldNumber = 67; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase DefaultFixed32Extension; - public const int DefaultFixed64ExtensionFieldNumber = 68; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase DefaultFixed64Extension; - public const int DefaultSfixed32ExtensionFieldNumber = 69; - public static pb::GeneratedExtensionBase DefaultSfixed32Extension; - public const int DefaultSfixed64ExtensionFieldNumber = 70; - public static pb::GeneratedExtensionBase DefaultSfixed64Extension; - public const int DefaultFloatExtensionFieldNumber = 71; - public static pb::GeneratedExtensionBase DefaultFloatExtension; - public const int DefaultDoubleExtensionFieldNumber = 72; - public static pb::GeneratedExtensionBase DefaultDoubleExtension; - public const int DefaultBoolExtensionFieldNumber = 73; - public static pb::GeneratedExtensionBase DefaultBoolExtension; - public const int DefaultStringExtensionFieldNumber = 74; - public static pb::GeneratedExtensionBase DefaultStringExtension; - public const int DefaultBytesExtensionFieldNumber = 75; - public static pb::GeneratedExtensionBase DefaultBytesExtension; - public const int DefaultNestedEnumExtensionFieldNumber = 81; - public static pb::GeneratedExtensionBase DefaultNestedEnumExtension; - public const int DefaultForeignEnumExtensionFieldNumber = 82; - public static pb::GeneratedExtensionBase DefaultForeignEnumExtension; - public const int DefaultImportEnumExtensionFieldNumber = 83; - public static pb::GeneratedExtensionBase DefaultImportEnumExtension; - public const int DefaultStringPieceExtensionFieldNumber = 84; - public static pb::GeneratedExtensionBase DefaultStringPieceExtension; - public const int DefaultCordExtensionFieldNumber = 85; - public static pb::GeneratedExtensionBase DefaultCordExtension; - public const int MyExtensionStringFieldNumber = 50; - public static pb::GeneratedExtensionBase MyExtensionString; - public const int MyExtensionIntFieldNumber = 5; - public static pb::GeneratedExtensionBase MyExtensionInt; - public const int PackedInt32ExtensionFieldNumber = 90; - public static pb::GeneratedExtensionBase> PackedInt32Extension; - public const int PackedInt64ExtensionFieldNumber = 91; - public static pb::GeneratedExtensionBase> PackedInt64Extension; - public const int PackedUint32ExtensionFieldNumber = 92; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> PackedUint32Extension; - public const int PackedUint64ExtensionFieldNumber = 93; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> PackedUint64Extension; - public const int PackedSint32ExtensionFieldNumber = 94; - public static pb::GeneratedExtensionBase> PackedSint32Extension; - public const int PackedSint64ExtensionFieldNumber = 95; - public static pb::GeneratedExtensionBase> PackedSint64Extension; - public const int PackedFixed32ExtensionFieldNumber = 96; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> PackedFixed32Extension; - public const int PackedFixed64ExtensionFieldNumber = 97; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> PackedFixed64Extension; - public const int PackedSfixed32ExtensionFieldNumber = 98; - public static pb::GeneratedExtensionBase> PackedSfixed32Extension; - public const int PackedSfixed64ExtensionFieldNumber = 99; - public static pb::GeneratedExtensionBase> PackedSfixed64Extension; - public const int PackedFloatExtensionFieldNumber = 100; - public static pb::GeneratedExtensionBase> PackedFloatExtension; - public const int PackedDoubleExtensionFieldNumber = 101; - public static pb::GeneratedExtensionBase> PackedDoubleExtension; - public const int PackedBoolExtensionFieldNumber = 102; - public static pb::GeneratedExtensionBase> PackedBoolExtension; - public const int PackedEnumExtensionFieldNumber = 103; - public static pb::GeneratedExtensionBase> PackedEnumExtension; - #endregion - - #region Static variables - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_ForeignMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllExtensions__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedExtension__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequired__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequired__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredForeign__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestForeignNested__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEmptyMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestFieldOrderings__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_SparseEnumMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OneString__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OneString__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OneBytes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OneBytes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestPackedTypes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestPackedExtensions__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooRequest__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooRequest__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooResponse__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooResponse__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BarRequest__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BarRequest__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BarResponse__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BarResponse__FieldAccessorTable; - #endregion - #region Descriptor - public static pbd::FileDescriptor Descriptor { - get { return descriptor; } - } - private static pbd::FileDescriptor descriptor; - - static UnitTestProtoFile() { - byte[] descriptorData = global::System.Convert.FromBase64String( - string.Concat( - "Ch5nb29nbGUvcHJvdG9idWYvdW5pdHRlc3QucHJvdG8SEXByb3RvYnVmX3Vu", - "aXR0ZXN0GiRnb29nbGUvcHJvdG9idWYvY3NoYXJwX29wdGlvbnMucHJvdG8a", - "JWdvb2dsZS9wcm90b2J1Zi91bml0dGVzdF9pbXBvcnQucHJvdG8iuxUKDFRl", - "c3RBbGxUeXBlcxIWCg5vcHRpb25hbF9pbnQzMhgBIAEoBRIWCg5vcHRpb25h", - "bF9pbnQ2NBgCIAEoAxIXCg9vcHRpb25hbF91aW50MzIYAyABKA0SFwoPb3B0", - "aW9uYWxfdWludDY0GAQgASgEEhcKD29wdGlvbmFsX3NpbnQzMhgFIAEoERIX", - "Cg9vcHRpb25hbF9zaW50NjQYBiABKBISGAoQb3B0aW9uYWxfZml4ZWQzMhgH", - "IAEoBxIYChBvcHRpb25hbF9maXhlZDY0GAggASgGEhkKEW9wdGlvbmFsX3Nm", - "aXhlZDMyGAkgASgPEhkKEW9wdGlvbmFsX3NmaXhlZDY0GAogASgQEhYKDm9w", - "dGlvbmFsX2Zsb2F0GAsgASgCEhcKD29wdGlvbmFsX2RvdWJsZRgMIAEoARIV", - "Cg1vcHRpb25hbF9ib29sGA0gASgIEhcKD29wdGlvbmFsX3N0cmluZxgOIAEo", - "CRIWCg5vcHRpb25hbF9ieXRlcxgPIAEoDBJECg1vcHRpb25hbGdyb3VwGBAg", - "ASgKMi0ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzLk9wdGlvbmFs", - "R3JvdXASTgoXb3B0aW9uYWxfbmVzdGVkX21lc3NhZ2UYEiABKAsyLS5wcm90", - "b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkTWVzc2FnZRJDChhv", - "cHRpb25hbF9mb3JlaWduX21lc3NhZ2UYEyABKAsyIS5wcm90b2J1Zl91bml0", - "dGVzdC5Gb3JlaWduTWVzc2FnZRJIChdvcHRpb25hbF9pbXBvcnRfbWVzc2Fn", - "ZRgUIAEoCzInLnByb3RvYnVmX3VuaXR0ZXN0X2ltcG9ydC5JbXBvcnRNZXNz", - "YWdlEkgKFG9wdGlvbmFsX25lc3RlZF9lbnVtGBUgASgOMioucHJvdG9idWZf", - "dW5pdHRlc3QuVGVzdEFsbFR5cGVzLk5lc3RlZEVudW0SPQoVb3B0aW9uYWxf", - "Zm9yZWlnbl9lbnVtGBYgASgOMh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWln", - "bkVudW0SQgoUb3B0aW9uYWxfaW1wb3J0X2VudW0YFyABKA4yJC5wcm90b2J1", - "Zl91bml0dGVzdF9pbXBvcnQuSW1wb3J0RW51bRIhChVvcHRpb25hbF9zdHJp", - "bmdfcGllY2UYGCABKAlCAggCEhkKDW9wdGlvbmFsX2NvcmQYGSABKAlCAggB", - "EhYKDnJlcGVhdGVkX2ludDMyGB8gAygFEhYKDnJlcGVhdGVkX2ludDY0GCAg", - "AygDEhcKD3JlcGVhdGVkX3VpbnQzMhghIAMoDRIXCg9yZXBlYXRlZF91aW50", - "NjQYIiADKAQSFwoPcmVwZWF0ZWRfc2ludDMyGCMgAygREhcKD3JlcGVhdGVk", - "X3NpbnQ2NBgkIAMoEhIYChByZXBlYXRlZF9maXhlZDMyGCUgAygHEhgKEHJl", - "cGVhdGVkX2ZpeGVkNjQYJiADKAYSGQoRcmVwZWF0ZWRfc2ZpeGVkMzIYJyAD", - "KA8SGQoRcmVwZWF0ZWRfc2ZpeGVkNjQYKCADKBASFgoOcmVwZWF0ZWRfZmxv", - "YXQYKSADKAISFwoPcmVwZWF0ZWRfZG91YmxlGCogAygBEhUKDXJlcGVhdGVk", - "X2Jvb2wYKyADKAgSFwoPcmVwZWF0ZWRfc3RyaW5nGCwgAygJEhYKDnJlcGVh", - "dGVkX2J5dGVzGC0gAygMEkQKDXJlcGVhdGVkZ3JvdXAYLiADKAoyLS5wcm90", - "b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuUmVwZWF0ZWRHcm91cBJOChdy", - "ZXBlYXRlZF9uZXN0ZWRfbWVzc2FnZRgwIAMoCzItLnByb3RvYnVmX3VuaXR0", - "ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdlEkMKGHJlcGVhdGVkX2Zv", - "cmVpZ25fbWVzc2FnZRgxIAMoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVp", - "Z25NZXNzYWdlEkgKF3JlcGVhdGVkX2ltcG9ydF9tZXNzYWdlGDIgAygLMicu", - "cHJvdG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydE1lc3NhZ2USSAoUcmVw", - "ZWF0ZWRfbmVzdGVkX2VudW0YMyADKA4yKi5wcm90b2J1Zl91bml0dGVzdC5U", - "ZXN0QWxsVHlwZXMuTmVzdGVkRW51bRI9ChVyZXBlYXRlZF9mb3JlaWduX2Vu", - "dW0YNCADKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bRJCChRy", - "ZXBlYXRlZF9pbXBvcnRfZW51bRg1IAMoDjIkLnByb3RvYnVmX3VuaXR0ZXN0", - "X2ltcG9ydC5JbXBvcnRFbnVtEiEKFXJlcGVhdGVkX3N0cmluZ19waWVjZRg2", - "IAMoCUICCAISGQoNcmVwZWF0ZWRfY29yZBg3IAMoCUICCAESGQoNZGVmYXVs", - "dF9pbnQzMhg9IAEoBToCNDESGQoNZGVmYXVsdF9pbnQ2NBg+IAEoAzoCNDIS", - "GgoOZGVmYXVsdF91aW50MzIYPyABKA06AjQzEhoKDmRlZmF1bHRfdWludDY0", - "GEAgASgEOgI0NBIbCg5kZWZhdWx0X3NpbnQzMhhBIAEoEToDLTQ1EhoKDmRl", - "ZmF1bHRfc2ludDY0GEIgASgSOgI0NhIbCg9kZWZhdWx0X2ZpeGVkMzIYQyAB", - "KAc6AjQ3EhsKD2RlZmF1bHRfZml4ZWQ2NBhEIAEoBjoCNDgSHAoQZGVmYXVs", - "dF9zZml4ZWQzMhhFIAEoDzoCNDkSHQoQZGVmYXVsdF9zZml4ZWQ2NBhGIAEo", - "EDoDLTUwEhsKDWRlZmF1bHRfZmxvYXQYRyABKAI6BDUxLjUSHQoOZGVmYXVs", - "dF9kb3VibGUYSCABKAE6BTUyMDAwEhoKDGRlZmF1bHRfYm9vbBhJIAEoCDoE", - "dHJ1ZRIdCg5kZWZhdWx0X3N0cmluZxhKIAEoCToFaGVsbG8SHAoNZGVmYXVs", - "dF9ieXRlcxhLIAEoDDoFd29ybGQSTAoTZGVmYXVsdF9uZXN0ZWRfZW51bRhR", - "IAEoDjIqLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRF", - "bnVtOgNCQVISSQoUZGVmYXVsdF9mb3JlaWduX2VudW0YUiABKA4yHi5wcm90", - "b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bToLRk9SRUlHTl9CQVISTQoTZGVm", - "YXVsdF9pbXBvcnRfZW51bRhTIAEoDjIkLnByb3RvYnVmX3VuaXR0ZXN0X2lt", - "cG9ydC5JbXBvcnRFbnVtOgpJTVBPUlRfQkFSEiUKFGRlZmF1bHRfc3RyaW5n", - "X3BpZWNlGFQgASgJOgNhYmNCAggCEh0KDGRlZmF1bHRfY29yZBhVIAEoCToD", - "MTIzQgIIARobCg1OZXN0ZWRNZXNzYWdlEgoKAmJiGAEgASgFGhoKDU9wdGlv", - "bmFsR3JvdXASCQoBYRgRIAEoBRoaCg1SZXBlYXRlZEdyb3VwEgkKAWEYLyAB", - "KAUiJwoKTmVzdGVkRW51bRIHCgNGT08QARIHCgNCQVIQAhIHCgNCQVoQAyI0", - "ChRUZXN0RGVwcmVjYXRlZEZpZWxkcxIcChBkZXByZWNhdGVkX2ludDMyGAEg", - "ASgFQgIYASIbCg5Gb3JlaWduTWVzc2FnZRIJCgFjGAEgASgFIh0KEVRlc3RB", - "bGxFeHRlbnNpb25zKggIARCAgICAAiIkChdPcHRpb25hbEdyb3VwX2V4dGVu", - "c2lvbhIJCgFhGBEgASgFIiQKF1JlcGVhdGVkR3JvdXBfZXh0ZW5zaW9uEgkK", - "AWEYLyABKAUiUAoTVGVzdE5lc3RlZEV4dGVuc2lvbjI5CgR0ZXN0EiQucHJv", - "dG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY6gcgASgJOgR0ZXN0", - "ItUFCgxUZXN0UmVxdWlyZWQSCQoBYRgBIAIoBRIOCgZkdW1teTIYAiABKAUS", - "CQoBYhgDIAIoBRIOCgZkdW1teTQYBCABKAUSDgoGZHVtbXk1GAUgASgFEg4K", - "BmR1bW15NhgGIAEoBRIOCgZkdW1teTcYByABKAUSDgoGZHVtbXk4GAggASgF", - "Eg4KBmR1bW15ORgJIAEoBRIPCgdkdW1teTEwGAogASgFEg8KB2R1bW15MTEY", - "CyABKAUSDwoHZHVtbXkxMhgMIAEoBRIPCgdkdW1teTEzGA0gASgFEg8KB2R1", - "bW15MTQYDiABKAUSDwoHZHVtbXkxNRgPIAEoBRIPCgdkdW1teTE2GBAgASgF", - "Eg8KB2R1bW15MTcYESABKAUSDwoHZHVtbXkxOBgSIAEoBRIPCgdkdW1teTE5", - "GBMgASgFEg8KB2R1bW15MjAYFCABKAUSDwoHZHVtbXkyMRgVIAEoBRIPCgdk", - "dW1teTIyGBYgASgFEg8KB2R1bW15MjMYFyABKAUSDwoHZHVtbXkyNBgYIAEo", - "BRIPCgdkdW1teTI1GBkgASgFEg8KB2R1bW15MjYYGiABKAUSDwoHZHVtbXky", - "NxgbIAEoBRIPCgdkdW1teTI4GBwgASgFEg8KB2R1bW15MjkYHSABKAUSDwoH", - "ZHVtbXkzMBgeIAEoBRIPCgdkdW1teTMxGB8gASgFEg8KB2R1bW15MzIYICAB", - "KAUSCQoBYxghIAIoBTJWCgZzaW5nbGUSJC5wcm90b2J1Zl91bml0dGVzdC5U", - "ZXN0QWxsRXh0ZW5zaW9ucxjoByABKAsyHy5wcm90b2J1Zl91bml0dGVzdC5U", - "ZXN0UmVxdWlyZWQyVQoFbXVsdGkSJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", - "QWxsRXh0ZW5zaW9ucxjpByADKAsyHy5wcm90b2J1Zl91bml0dGVzdC5UZXN0", - "UmVxdWlyZWQimgEKE1Rlc3RSZXF1aXJlZEZvcmVpZ24SOQoQb3B0aW9uYWxf", - "bWVzc2FnZRgBIAEoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RSZXF1aXJl", - "ZBI5ChByZXBlYXRlZF9tZXNzYWdlGAIgAygLMh8ucHJvdG9idWZfdW5pdHRl", - "c3QuVGVzdFJlcXVpcmVkEg0KBWR1bW15GAMgASgFIloKEVRlc3RGb3JlaWdu", - "TmVzdGVkEkUKDmZvcmVpZ25fbmVzdGVkGAEgASgLMi0ucHJvdG9idWZfdW5p", - "dHRlc3QuVGVzdEFsbFR5cGVzLk5lc3RlZE1lc3NhZ2UiEgoQVGVzdEVtcHR5", - "TWVzc2FnZSIqCh5UZXN0RW1wdHlNZXNzYWdlV2l0aEV4dGVuc2lvbnMqCAgB", - "EICAgIACIjcKG1Rlc3RNdWx0aXBsZUV4dGVuc2lvblJhbmdlcyoECCoQKyoG", - "CK8gEJQhKgoIgIAEEICAgIACIjQKGFRlc3RSZWFsbHlMYXJnZVRhZ051bWJl", - "chIJCgFhGAEgASgFEg0KAmJiGP///38gASgFIlUKFFRlc3RSZWN1cnNpdmVN", - "ZXNzYWdlEjIKAWEYASABKAsyJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0UmVj", - "dXJzaXZlTWVzc2FnZRIJCgFpGAIgASgFIksKFFRlc3RNdXR1YWxSZWN1cnNp", - "b25BEjMKAmJiGAEgASgLMicucHJvdG9idWZfdW5pdHRlc3QuVGVzdE11dHVh", - "bFJlY3Vyc2lvbkIiYgoUVGVzdE11dHVhbFJlY3Vyc2lvbkISMgoBYRgBIAEo", - "CzInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RNdXR1YWxSZWN1cnNpb25BEhYK", - "Dm9wdGlvbmFsX2ludDMyGAIgASgFIrMBChJUZXN0RHVwRmllbGROdW1iZXIS", - "CQoBYRgBIAEoBRI2CgNmb28YAiABKAoyKS5wcm90b2J1Zl91bml0dGVzdC5U", - "ZXN0RHVwRmllbGROdW1iZXIuRm9vEjYKA2JhchgDIAEoCjIpLnByb3RvYnVm", - "X3VuaXR0ZXN0LlRlc3REdXBGaWVsZE51bWJlci5CYXIaEAoDRm9vEgkKAWEY", - "ASABKAUaEAoDQmFyEgkKAWEYASABKAUigAIKGFRlc3ROZXN0ZWRNZXNzYWdl", - "SGFzQml0cxJaChdvcHRpb25hbF9uZXN0ZWRfbWVzc2FnZRgBIAEoCzI5LnBy", - "b3RvYnVmX3VuaXR0ZXN0LlRlc3ROZXN0ZWRNZXNzYWdlSGFzQml0cy5OZXN0", - "ZWRNZXNzYWdlGocBCg1OZXN0ZWRNZXNzYWdlEiQKHG5lc3RlZG1lc3NhZ2Vf", - "cmVwZWF0ZWRfaW50MzIYASADKAUSUAolbmVzdGVkbWVzc2FnZV9yZXBlYXRl", - "ZF9mb3JlaWdubWVzc2FnZRgCIAMoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZv", - "cmVpZ25NZXNzYWdlIuUDChdUZXN0Q2FtZWxDYXNlRmllbGROYW1lcxIWCg5Q", - "cmltaXRpdmVGaWVsZBgBIAEoBRITCgtTdHJpbmdGaWVsZBgCIAEoCRIxCglF", - "bnVtRmllbGQYAyABKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51", - "bRI3CgxNZXNzYWdlRmllbGQYBCABKAsyIS5wcm90b2J1Zl91bml0dGVzdC5G", - "b3JlaWduTWVzc2FnZRIcChBTdHJpbmdQaWVjZUZpZWxkGAUgASgJQgIIAhIV", - "CglDb3JkRmllbGQYBiABKAlCAggBEh4KFlJlcGVhdGVkUHJpbWl0aXZlRmll", - "bGQYByADKAUSGwoTUmVwZWF0ZWRTdHJpbmdGaWVsZBgIIAMoCRI5ChFSZXBl", - "YXRlZEVudW1GaWVsZBgJIAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVp", - "Z25FbnVtEj8KFFJlcGVhdGVkTWVzc2FnZUZpZWxkGAogAygLMiEucHJvdG9i", - "dWZfdW5pdHRlc3QuRm9yZWlnbk1lc3NhZ2USJAoYUmVwZWF0ZWRTdHJpbmdQ", - "aWVjZUZpZWxkGAsgAygJQgIIAhIdChFSZXBlYXRlZENvcmRGaWVsZBgMIAMo", - "CUICCAEiVQoSVGVzdEZpZWxkT3JkZXJpbmdzEhEKCW15X3N0cmluZxgLIAEo", - "CRIOCgZteV9pbnQYASABKAMSEAoIbXlfZmxvYXQYZSABKAIqBAgCEAsqBAgM", - "EGUiowUKGFRlc3RFeHRyZW1lRGVmYXVsdFZhbHVlcxI/Cg1lc2NhcGVkX2J5", - "dGVzGAEgASgMOihcMDAwXDAwMVwwMDdcMDEwXDAxNFxuXHJcdFwwMTNcXFwn", - "XCJcMzc2EiAKDGxhcmdlX3VpbnQzMhgCIAEoDToKNDI5NDk2NzI5NRIqCgxs", - "YXJnZV91aW50NjQYAyABKAQ6FDE4NDQ2NzQ0MDczNzA5NTUxNjE1EiAKC3Nt", - "YWxsX2ludDMyGAQgASgFOgstMjE0NzQ4MzY0NxIpCgtzbWFsbF9pbnQ2NBgF", - "IAEoAzoULTkyMjMzNzIwMzY4NTQ3NzU4MDcSGAoLdXRmOF9zdHJpbmcYBiAB", - "KAk6A+GItBIVCgp6ZXJvX2Zsb2F0GAcgASgCOgEwEhQKCW9uZV9mbG9hdBgI", - "IAEoAjoBMRIYCgtzbWFsbF9mbG9hdBgJIAEoAjoDMS41Eh4KEm5lZ2F0aXZl", - "X29uZV9mbG9hdBgKIAEoAjoCLTESHAoObmVnYXRpdmVfZmxvYXQYCyABKAI6", - "BC0xLjUSGwoLbGFyZ2VfZmxvYXQYDCABKAI6BjJlKzAwOBIlChRzbWFsbF9u", - "ZWdhdGl2ZV9mbG9hdBgNIAEoAjoHLThlLTAyOBIXCgppbmZfZG91YmxlGA4g", - "ASgBOgNpbmYSHAoObmVnX2luZl9kb3VibGUYDyABKAE6BC1pbmYSFwoKbmFu", - "X2RvdWJsZRgQIAEoAToDbmFuEhYKCWluZl9mbG9hdBgRIAEoAjoDaW5mEhsK", - "DW5lZ19pbmZfZmxvYXQYEiABKAI6BC1pbmYSFgoJbmFuX2Zsb2F0GBMgASgC", - "OgNuYW4SKwoMY3BwX3RyaWdyYXBoGBQgASgJOhU/ID8gPz8gPz8gPz8/ID8/", - "LyA/Py0iSwoRU3BhcnNlRW51bU1lc3NhZ2USNgoLc3BhcnNlX2VudW0YASAB", - "KA4yIS5wcm90b2J1Zl91bml0dGVzdC5UZXN0U3BhcnNlRW51bSIZCglPbmVT", - "dHJpbmcSDAoEZGF0YRgBIAEoCSIYCghPbmVCeXRlcxIMCgRkYXRhGAEgASgM", - "IqoDCg9UZXN0UGFja2VkVHlwZXMSGAoMcGFja2VkX2ludDMyGFogAygFQgIQ", - "ARIYCgxwYWNrZWRfaW50NjQYWyADKANCAhABEhkKDXBhY2tlZF91aW50MzIY", - "XCADKA1CAhABEhkKDXBhY2tlZF91aW50NjQYXSADKARCAhABEhkKDXBhY2tl", - "ZF9zaW50MzIYXiADKBFCAhABEhkKDXBhY2tlZF9zaW50NjQYXyADKBJCAhAB", - "EhoKDnBhY2tlZF9maXhlZDMyGGAgAygHQgIQARIaCg5wYWNrZWRfZml4ZWQ2", - "NBhhIAMoBkICEAESGwoPcGFja2VkX3NmaXhlZDMyGGIgAygPQgIQARIbCg9w", - "YWNrZWRfc2ZpeGVkNjQYYyADKBBCAhABEhgKDHBhY2tlZF9mbG9hdBhkIAMo", - "AkICEAESGQoNcGFja2VkX2RvdWJsZRhlIAMoAUICEAESFwoLcGFja2VkX2Jv", - "b2wYZiADKAhCAhABEjcKC3BhY2tlZF9lbnVtGGcgAygOMh4ucHJvdG9idWZf", - "dW5pdHRlc3QuRm9yZWlnbkVudW1CAhABIsgDChFUZXN0VW5wYWNrZWRUeXBl", - "cxIaCg51bnBhY2tlZF9pbnQzMhhaIAMoBUICEAASGgoOdW5wYWNrZWRfaW50", - "NjQYWyADKANCAhAAEhsKD3VucGFja2VkX3VpbnQzMhhcIAMoDUICEAASGwoP", - "dW5wYWNrZWRfdWludDY0GF0gAygEQgIQABIbCg91bnBhY2tlZF9zaW50MzIY", - "XiADKBFCAhAAEhsKD3VucGFja2VkX3NpbnQ2NBhfIAMoEkICEAASHAoQdW5w", - "YWNrZWRfZml4ZWQzMhhgIAMoB0ICEAASHAoQdW5wYWNrZWRfZml4ZWQ2NBhh", - "IAMoBkICEAASHQoRdW5wYWNrZWRfc2ZpeGVkMzIYYiADKA9CAhAAEh0KEXVu", - "cGFja2VkX3NmaXhlZDY0GGMgAygQQgIQABIaCg51bnBhY2tlZF9mbG9hdBhk", - "IAMoAkICEAASGwoPdW5wYWNrZWRfZG91YmxlGGUgAygBQgIQABIZCg11bnBh", - "Y2tlZF9ib29sGGYgAygIQgIQABI5Cg11bnBhY2tlZF9lbnVtGGcgAygOMh4u", - "cHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbkVudW1CAhAAIiAKFFRlc3RQYWNr", - "ZWRFeHRlbnNpb25zKggIARCAgICAAiKZBAoVVGVzdER5bmFtaWNFeHRlbnNp", - "b25zEhkKEHNjYWxhcl9leHRlbnNpb24Y0A8gASgHEjcKDmVudW1fZXh0ZW5z", - "aW9uGNEPIAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtElkK", - "FmR5bmFtaWNfZW51bV9leHRlbnNpb24Y0g8gASgOMjgucHJvdG9idWZfdW5p", - "dHRlc3QuVGVzdER5bmFtaWNFeHRlbnNpb25zLkR5bmFtaWNFbnVtVHlwZRI9", - "ChFtZXNzYWdlX2V4dGVuc2lvbhjTDyABKAsyIS5wcm90b2J1Zl91bml0dGVz", - "dC5Gb3JlaWduTWVzc2FnZRJfChlkeW5hbWljX21lc3NhZ2VfZXh0ZW5zaW9u", - "GNQPIAEoCzI7LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3REeW5hbWljRXh0ZW5z", - "aW9ucy5EeW5hbWljTWVzc2FnZVR5cGUSGwoScmVwZWF0ZWRfZXh0ZW5zaW9u", - "GNUPIAMoCRIdChBwYWNrZWRfZXh0ZW5zaW9uGNYPIAMoEUICEAEaLAoSRHlu", - "YW1pY01lc3NhZ2VUeXBlEhYKDWR5bmFtaWNfZmllbGQYtBAgASgFIkcKD0R5", - "bmFtaWNFbnVtVHlwZRIQCgtEWU5BTUlDX0ZPTxCYERIQCgtEWU5BTUlDX0JB", - "UhCZERIQCgtEWU5BTUlDX0JBWhCaESLAAQojVGVzdFJlcGVhdGVkU2NhbGFy", - "RGlmZmVyZW50VGFnU2l6ZXMSGAoQcmVwZWF0ZWRfZml4ZWQzMhgMIAMoBxIW", - "Cg5yZXBlYXRlZF9pbnQzMhgNIAMoBRIZChByZXBlYXRlZF9maXhlZDY0GP4P", - "IAMoBhIXCg5yZXBlYXRlZF9pbnQ2NBj/DyADKAMSGAoOcmVwZWF0ZWRfZmxv", - "YXQY/v8PIAMoAhIZCg9yZXBlYXRlZF91aW50NjQY//8PIAMoBCIMCgpGb29S", - "ZXF1ZXN0Ig0KC0Zvb1Jlc3BvbnNlIgwKCkJhclJlcXVlc3QiDQoLQmFyUmVz", - "cG9uc2UqQAoLRm9yZWlnbkVudW0SDwoLRk9SRUlHTl9GT08QBBIPCgtGT1JF", - "SUdOX0JBUhAFEg8KC0ZPUkVJR05fQkFaEAYqRwoUVGVzdEVudW1XaXRoRHVw", - "VmFsdWUSCAoERk9PMRABEggKBEJBUjEQAhIHCgNCQVoQAxIICgRGT08yEAES", - "CAoEQkFSMhACKokBCg5UZXN0U3BhcnNlRW51bRIMCghTUEFSU0VfQRB7Eg4K", - "CFNQQVJTRV9CEKbnAxIPCghTUEFSU0VfQxCysYAGEhUKCFNQQVJTRV9EEPH/", - "/////////wESFQoIU1BBUlNFX0UQtN78////////ARIMCghTUEFSU0VfRhAA", - "EgwKCFNQQVJTRV9HEAIymQEKC1Rlc3RTZXJ2aWNlEkQKA0ZvbxIdLnByb3Rv", - "YnVmX3VuaXR0ZXN0LkZvb1JlcXVlc3QaHi5wcm90b2J1Zl91bml0dGVzdC5G", - "b29SZXNwb25zZRJECgNCYXISHS5wcm90b2J1Zl91bml0dGVzdC5CYXJSZXF1", - "ZXN0Gh4ucHJvdG9idWZfdW5pdHRlc3QuQmFyUmVzcG9uc2U6RgoYb3B0aW9u", - "YWxfaW50MzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFs", - "bEV4dGVuc2lvbnMYASABKAU6RgoYb3B0aW9uYWxfaW50NjRfZXh0ZW5zaW9u", - "EiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYAiABKAM6", - "RwoZb3B0aW9uYWxfdWludDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0", - "ZXN0LlRlc3RBbGxFeHRlbnNpb25zGAMgASgNOkcKGW9wdGlvbmFsX3VpbnQ2", - "NF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5z", - "aW9ucxgEIAEoBDpHChlvcHRpb25hbF9zaW50MzJfZXh0ZW5zaW9uEiQucHJv", - "dG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYBSABKBE6RwoZb3B0", - "aW9uYWxfc2ludDY0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", - "c3RBbGxFeHRlbnNpb25zGAYgASgSOkgKGm9wdGlvbmFsX2ZpeGVkMzJfZXh0", - "ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY", - "ByABKAc6SAoab3B0aW9uYWxfZml4ZWQ2NF9leHRlbnNpb24SJC5wcm90b2J1", - "Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgIIAEoBjpJChtvcHRpb25h", - "bF9zZml4ZWQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", - "QWxsRXh0ZW5zaW9ucxgJIAEoDzpJChtvcHRpb25hbF9zZml4ZWQ2NF9leHRl", - "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgK", - "IAEoEDpGChhvcHRpb25hbF9mbG9hdF9leHRlbnNpb24SJC5wcm90b2J1Zl91", - "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgLIAEoAjpHChlvcHRpb25hbF9k", - "b3VibGVfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4", - "dGVuc2lvbnMYDCABKAE6RQoXb3B0aW9uYWxfYm9vbF9leHRlbnNpb24SJC5w", - "cm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgNIAEoCDpHChlv", - "cHRpb25hbF9zdHJpbmdfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3Qu", - "VGVzdEFsbEV4dGVuc2lvbnMYDiABKAk6RgoYb3B0aW9uYWxfYnl0ZXNfZXh0", - "ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY", - "DyABKAw6cQoXb3B0aW9uYWxncm91cF9leHRlbnNpb24SJC5wcm90b2J1Zl91", - "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgQIAEoCjIqLnByb3RvYnVmX3Vu", - "aXR0ZXN0Lk9wdGlvbmFsR3JvdXBfZXh0ZW5zaW9uOn4KIW9wdGlvbmFsX25l", - "c3RlZF9tZXNzYWdlX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", - "c3RBbGxFeHRlbnNpb25zGBIgASgLMi0ucHJvdG9idWZfdW5pdHRlc3QuVGVz", - "dEFsbFR5cGVzLk5lc3RlZE1lc3NhZ2U6cwoib3B0aW9uYWxfZm9yZWlnbl9t", - "ZXNzYWdlX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxF", - "eHRlbnNpb25zGBMgASgLMiEucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbk1l", - "c3NhZ2U6eAohb3B0aW9uYWxfaW1wb3J0X21lc3NhZ2VfZXh0ZW5zaW9uEiQu", - "cHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYFCABKAsyJy5w", - "cm90b2J1Zl91bml0dGVzdF9pbXBvcnQuSW1wb3J0TWVzc2FnZTp4Ch5vcHRp", - "b25hbF9uZXN0ZWRfZW51bV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", - "dC5UZXN0QWxsRXh0ZW5zaW9ucxgVIAEoDjIqLnByb3RvYnVmX3VuaXR0ZXN0", - "LlRlc3RBbGxUeXBlcy5OZXN0ZWRFbnVtOm0KH29wdGlvbmFsX2ZvcmVpZ25f", - "ZW51bV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", - "ZW5zaW9ucxgWIAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVt", - "OnIKHm9wdGlvbmFsX2ltcG9ydF9lbnVtX2V4dGVuc2lvbhIkLnByb3RvYnVm", - "X3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGBcgASgOMiQucHJvdG9idWZf", - "dW5pdHRlc3RfaW1wb3J0LkltcG9ydEVudW06UQofb3B0aW9uYWxfc3RyaW5n", - "X3BpZWNlX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxF", - "eHRlbnNpb25zGBggASgJQgIIAjpJChdvcHRpb25hbF9jb3JkX2V4dGVuc2lv", - "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGBkgASgJ", - "QgIIATpGChhyZXBlYXRlZF9pbnQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91", - "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgfIAMoBTpGChhyZXBlYXRlZF9p", - "bnQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", - "ZW5zaW9ucxggIAMoAzpHChlyZXBlYXRlZF91aW50MzJfZXh0ZW5zaW9uEiQu", - "cHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYISADKA06RwoZ", - "cmVwZWF0ZWRfdWludDY0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0", - "LlRlc3RBbGxFeHRlbnNpb25zGCIgAygEOkcKGXJlcGVhdGVkX3NpbnQzMl9l", - "eHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9u", - "cxgjIAMoETpHChlyZXBlYXRlZF9zaW50NjRfZXh0ZW5zaW9uEiQucHJvdG9i", - "dWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYJCADKBI6SAoacmVwZWF0", - "ZWRfZml4ZWQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", - "QWxsRXh0ZW5zaW9ucxglIAMoBzpIChpyZXBlYXRlZF9maXhlZDY0X2V4dGVu", - "c2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCYg", - "AygGOkkKG3JlcGVhdGVkX3NmaXhlZDMyX2V4dGVuc2lvbhIkLnByb3RvYnVm", - "X3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCcgAygPOkkKG3JlcGVhdGVk", - "X3NmaXhlZDY0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", - "bGxFeHRlbnNpb25zGCggAygQOkYKGHJlcGVhdGVkX2Zsb2F0X2V4dGVuc2lv", - "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCkgAygC", - "OkcKGXJlcGVhdGVkX2RvdWJsZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0", - "dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgqIAMoATpFChdyZXBlYXRlZF9ib29s", - "X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNp", - "b25zGCsgAygIOkcKGXJlcGVhdGVkX3N0cmluZ19leHRlbnNpb24SJC5wcm90", - "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgsIAMoCTpGChhyZXBl", - "YXRlZF9ieXRlc19leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", - "QWxsRXh0ZW5zaW9ucxgtIAMoDDpxChdyZXBlYXRlZGdyb3VwX2V4dGVuc2lv", - "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGC4gAygK", - "MioucHJvdG9idWZfdW5pdHRlc3QuUmVwZWF0ZWRHcm91cF9leHRlbnNpb246", - "fgohcmVwZWF0ZWRfbmVzdGVkX21lc3NhZ2VfZXh0ZW5zaW9uEiQucHJvdG9i", - "dWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYMCADKAsyLS5wcm90b2J1", - "Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkTWVzc2FnZTpzCiJyZXBl", - "YXRlZF9mb3JlaWduX21lc3NhZ2VfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5p", - "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYMSADKAsyIS5wcm90b2J1Zl91bml0", - "dGVzdC5Gb3JlaWduTWVzc2FnZTp4CiFyZXBlYXRlZF9pbXBvcnRfbWVzc2Fn", - "ZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5z", - "aW9ucxgyIAMoCzInLnByb3RvYnVmX3VuaXR0ZXN0X2ltcG9ydC5JbXBvcnRN", - "ZXNzYWdlOngKHnJlcGVhdGVkX25lc3RlZF9lbnVtX2V4dGVuc2lvbhIkLnBy", - "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGDMgAygOMioucHJv", - "dG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzLk5lc3RlZEVudW06bQofcmVw", - "ZWF0ZWRfZm9yZWlnbl9lbnVtX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0", - "ZXN0LlRlc3RBbGxFeHRlbnNpb25zGDQgAygOMh4ucHJvdG9idWZfdW5pdHRl", - "c3QuRm9yZWlnbkVudW06cgoecmVwZWF0ZWRfaW1wb3J0X2VudW1fZXh0ZW5z", - "aW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYNSAD", - "KA4yJC5wcm90b2J1Zl91bml0dGVzdF9pbXBvcnQuSW1wb3J0RW51bTpRCh9y", - "ZXBlYXRlZF9zdHJpbmdfcGllY2VfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5p", - "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYNiADKAlCAggCOkkKF3JlcGVhdGVk", - "X2NvcmRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4", - "dGVuc2lvbnMYNyADKAlCAggBOkkKF2RlZmF1bHRfaW50MzJfZXh0ZW5zaW9u", - "EiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYPSABKAU6", - "AjQxOkkKF2RlZmF1bHRfaW50NjRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5p", - "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYPiABKAM6AjQyOkoKGGRlZmF1bHRf", - "dWludDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxF", - "eHRlbnNpb25zGD8gASgNOgI0MzpKChhkZWZhdWx0X3VpbnQ2NF9leHRlbnNp", - "b24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhAIAEo", - "BDoCNDQ6SwoYZGVmYXVsdF9zaW50MzJfZXh0ZW5zaW9uEiQucHJvdG9idWZf", - "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYQSABKBE6Ay00NTpKChhkZWZh", - "dWx0X3NpbnQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", - "QWxsRXh0ZW5zaW9ucxhCIAEoEjoCNDY6SwoZZGVmYXVsdF9maXhlZDMyX2V4", - "dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25z", - "GEMgASgHOgI0NzpLChlkZWZhdWx0X2ZpeGVkNjRfZXh0ZW5zaW9uEiQucHJv", - "dG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYRCABKAY6AjQ4OkwK", - "GmRlZmF1bHRfc2ZpeGVkMzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRl", - "c3QuVGVzdEFsbEV4dGVuc2lvbnMYRSABKA86AjQ5Ok0KGmRlZmF1bHRfc2Zp", - "eGVkNjRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4", - "dGVuc2lvbnMYRiABKBA6Ay01MDpLChdkZWZhdWx0X2Zsb2F0X2V4dGVuc2lv", - "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEcgASgC", - "OgQ1MS41Ok0KGGRlZmF1bHRfZG91YmxlX2V4dGVuc2lvbhIkLnByb3RvYnVm", - "X3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEggASgBOgU1MjAwMDpKChZk", - "ZWZhdWx0X2Jvb2xfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVz", - "dEFsbEV4dGVuc2lvbnMYSSABKAg6BHRydWU6TQoYZGVmYXVsdF9zdHJpbmdf", - "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv", - "bnMYSiABKAk6BWhlbGxvOkwKF2RlZmF1bHRfYnl0ZXNfZXh0ZW5zaW9uEiQu", - "cHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYSyABKAw6BXdv", - "cmxkOnwKHWRlZmF1bHRfbmVzdGVkX2VudW1fZXh0ZW5zaW9uEiQucHJvdG9i", - "dWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYUSABKA4yKi5wcm90b2J1", - "Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkRW51bToDQkFSOnkKHmRl", - "ZmF1bHRfZm9yZWlnbl9lbnVtX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0", - "ZXN0LlRlc3RBbGxFeHRlbnNpb25zGFIgASgOMh4ucHJvdG9idWZfdW5pdHRl", - "c3QuRm9yZWlnbkVudW06C0ZPUkVJR05fQkFSOn0KHWRlZmF1bHRfaW1wb3J0", - "X2VudW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4", - "dGVuc2lvbnMYUyABKA4yJC5wcm90b2J1Zl91bml0dGVzdF9pbXBvcnQuSW1w", - "b3J0RW51bToKSU1QT1JUX0JBUjpVCh5kZWZhdWx0X3N0cmluZ19waWVjZV9l", - "eHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9u", - "cxhUIAEoCToDYWJjQgIIAjpNChZkZWZhdWx0X2NvcmRfZXh0ZW5zaW9uEiQu", - "cHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYVSABKAk6AzEy", - "M0ICCAE6QgoTbXlfZXh0ZW5zaW9uX3N0cmluZxIlLnByb3RvYnVmX3VuaXR0", - "ZXN0LlRlc3RGaWVsZE9yZGVyaW5ncxgyIAEoCTo/ChBteV9leHRlbnNpb25f", - "aW50EiUucHJvdG9idWZfdW5pdHRlc3QuVGVzdEZpZWxkT3JkZXJpbmdzGAUg", - "ASgFOksKFnBhY2tlZF9pbnQzMl9leHRlbnNpb24SJy5wcm90b2J1Zl91bml0", - "dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhaIAMoBUICEAE6SwoWcGFja2Vk", - "X2ludDY0X2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNr", - "ZWRFeHRlbnNpb25zGFsgAygDQgIQATpMChdwYWNrZWRfdWludDMyX2V4dGVu", - "c2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNpb25z", - "GFwgAygNQgIQATpMChdwYWNrZWRfdWludDY0X2V4dGVuc2lvbhInLnByb3Rv", - "YnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNpb25zGF0gAygEQgIQATpM", - "ChdwYWNrZWRfc2ludDMyX2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0", - "LlRlc3RQYWNrZWRFeHRlbnNpb25zGF4gAygRQgIQATpMChdwYWNrZWRfc2lu", - "dDY0X2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRF", - "eHRlbnNpb25zGF8gAygSQgIQATpNChhwYWNrZWRfZml4ZWQzMl9leHRlbnNp", - "b24SJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhg", - "IAMoB0ICEAE6TQoYcGFja2VkX2ZpeGVkNjRfZXh0ZW5zaW9uEicucHJvdG9i", - "dWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMYYSADKAZCAhABOk4K", - "GXBhY2tlZF9zZml4ZWQzMl9leHRlbnNpb24SJy5wcm90b2J1Zl91bml0dGVz", - "dC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhiIAMoD0ICEAE6TgoZcGFja2VkX3Nm", - "aXhlZDY0X2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNr", - "ZWRFeHRlbnNpb25zGGMgAygQQgIQATpLChZwYWNrZWRfZmxvYXRfZXh0ZW5z", - "aW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMY", - "ZCADKAJCAhABOkwKF3BhY2tlZF9kb3VibGVfZXh0ZW5zaW9uEicucHJvdG9i", - "dWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMYZSADKAFCAhABOkoK", - "FXBhY2tlZF9ib29sX2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0LlRl", - "c3RQYWNrZWRFeHRlbnNpb25zGGYgAygIQgIQATpqChVwYWNrZWRfZW51bV9l", - "eHRlbnNpb24SJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5z", - "aW9ucxhnIAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtQgIQ", - "AUJTQg1Vbml0dGVzdFByb3RvSAGAAQGIAQGQAQHCPjYKIUdvb2dsZS5Qcm90", - "b2NvbEJ1ZmZlcnMuVGVzdFByb3RvcxIRVW5pdFRlc3RQcm90b0ZpbGU=")); - pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { - descriptor = root; - internal__static_protobuf_unittest_TestAllTypes__Descriptor = Descriptor.MessageTypes[0]; - internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes__Descriptor, - new string[] { "OptionalInt32", "OptionalInt64", "OptionalUint32", "OptionalUint64", "OptionalSint32", "OptionalSint64", "OptionalFixed32", "OptionalFixed64", "OptionalSfixed32", "OptionalSfixed64", "OptionalFloat", "OptionalDouble", "OptionalBool", "OptionalString", "OptionalBytes", "OptionalGroup", "OptionalNestedMessage", "OptionalForeignMessage", "OptionalImportMessage", "OptionalNestedEnum", "OptionalForeignEnum", "OptionalImportEnum", "OptionalStringPiece", "OptionalCord", "RepeatedInt32", "RepeatedInt64", "RepeatedUint32", "RepeatedUint64", "RepeatedSint32", "RepeatedSint64", "RepeatedFixed32", "RepeatedFixed64", "RepeatedSfixed32", "RepeatedSfixed64", "RepeatedFloat", "RepeatedDouble", "RepeatedBool", "RepeatedString", "RepeatedBytes", "RepeatedGroup", "RepeatedNestedMessage", "RepeatedForeignMessage", "RepeatedImportMessage", "RepeatedNestedEnum", "RepeatedForeignEnum", "RepeatedImportEnum", "RepeatedStringPiece", "RepeatedCord", "DefaultInt32", "DefaultInt64", "DefaultUint32", "DefaultUint64", "DefaultSint32", "DefaultSint64", "DefaultFixed32", "DefaultFixed64", "DefaultSfixed32", "DefaultSfixed64", "DefaultFloat", "DefaultDouble", "DefaultBool", "DefaultString", "DefaultBytes", "DefaultNestedEnum", "DefaultForeignEnum", "DefaultImportEnum", "DefaultStringPiece", "DefaultCord", }); - internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor, - new string[] { "Bb", }); - internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[1]; - internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[2]; - internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor = Descriptor.MessageTypes[1]; - internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor, - new string[] { "DeprecatedInt32", }); - internal__static_protobuf_unittest_ForeignMessage__Descriptor = Descriptor.MessageTypes[2]; - internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_ForeignMessage__Descriptor, - new string[] { "C", }); - internal__static_protobuf_unittest_TestAllExtensions__Descriptor = Descriptor.MessageTypes[3]; - internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllExtensions__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor = Descriptor.MessageTypes[4]; - internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor = Descriptor.MessageTypes[5]; - internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_TestNestedExtension__Descriptor = Descriptor.MessageTypes[6]; - internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedExtension__Descriptor, - new string[] { }); - global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Test = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor.Extensions[0]); - internal__static_protobuf_unittest_TestRequired__Descriptor = Descriptor.MessageTypes[7]; - internal__static_protobuf_unittest_TestRequired__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequired__Descriptor, - new string[] { "A", "Dummy2", "B", "Dummy4", "Dummy5", "Dummy6", "Dummy7", "Dummy8", "Dummy9", "Dummy10", "Dummy11", "Dummy12", "Dummy13", "Dummy14", "Dummy15", "Dummy16", "Dummy17", "Dummy18", "Dummy19", "Dummy20", "Dummy21", "Dummy22", "Dummy23", "Dummy24", "Dummy25", "Dummy26", "Dummy27", "Dummy28", "Dummy29", "Dummy30", "Dummy31", "Dummy32", "C", }); - global::Google.ProtocolBuffers.TestProtos.TestRequired.Single = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor.Extensions[0]); - global::Google.ProtocolBuffers.TestProtos.TestRequired.Multi = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor.Extensions[1]); - internal__static_protobuf_unittest_TestRequiredForeign__Descriptor = Descriptor.MessageTypes[8]; - internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequiredForeign__Descriptor, - new string[] { "OptionalMessage", "RepeatedMessage", "Dummy", }); - internal__static_protobuf_unittest_TestForeignNested__Descriptor = Descriptor.MessageTypes[9]; - internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestForeignNested__Descriptor, - new string[] { "ForeignNested", }); - internal__static_protobuf_unittest_TestEmptyMessage__Descriptor = Descriptor.MessageTypes[10]; - internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEmptyMessage__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor = Descriptor.MessageTypes[11]; - internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor = Descriptor.MessageTypes[12]; - internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor = Descriptor.MessageTypes[13]; - internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor, - new string[] { "A", "Bb", }); - internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor = Descriptor.MessageTypes[14]; - internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor, - new string[] { "A", "I", }); - internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor = Descriptor.MessageTypes[15]; - internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor, - new string[] { "Bb", }); - internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor = Descriptor.MessageTypes[16]; - internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor, - new string[] { "A", "OptionalInt32", }); - internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor = Descriptor.MessageTypes[17]; - internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor, - new string[] { "A", "Foo", "Bar", }); - internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor = internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor = internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor.NestedTypes[1]; - internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor = Descriptor.MessageTypes[18]; - internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor, - new string[] { "OptionalNestedMessage", }); - internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor, - new string[] { "NestedmessageRepeatedInt32", "NestedmessageRepeatedForeignmessage", }); - internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor = Descriptor.MessageTypes[19]; - internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor, - new string[] { "PrimitiveField", "StringField", "EnumField", "MessageField", "StringPieceField", "CordField", "RepeatedPrimitiveField", "RepeatedStringField", "RepeatedEnumField", "RepeatedMessageField", "RepeatedStringPieceField", "RepeatedCordField", }); - internal__static_protobuf_unittest_TestFieldOrderings__Descriptor = Descriptor.MessageTypes[20]; - internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestFieldOrderings__Descriptor, - new string[] { "MyString", "MyInt", "MyFloat", }); - internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor = Descriptor.MessageTypes[21]; - internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor, - new string[] { "EscapedBytes", "LargeUint32", "LargeUint64", "SmallInt32", "SmallInt64", "Utf8String", "ZeroFloat", "OneFloat", "SmallFloat", "NegativeOneFloat", "NegativeFloat", "LargeFloat", "SmallNegativeFloat", "InfDouble", "NegInfDouble", "NanDouble", "InfFloat", "NegInfFloat", "NanFloat", "CppTrigraph", }); - internal__static_protobuf_unittest_SparseEnumMessage__Descriptor = Descriptor.MessageTypes[22]; - internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_SparseEnumMessage__Descriptor, - new string[] { "SparseEnum", }); - internal__static_protobuf_unittest_OneString__Descriptor = Descriptor.MessageTypes[23]; - internal__static_protobuf_unittest_OneString__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OneString__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_OneBytes__Descriptor = Descriptor.MessageTypes[24]; - internal__static_protobuf_unittest_OneBytes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OneBytes__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_TestPackedTypes__Descriptor = Descriptor.MessageTypes[25]; - internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestPackedTypes__Descriptor, - new string[] { "PackedInt32", "PackedInt64", "PackedUint32", "PackedUint64", "PackedSint32", "PackedSint64", "PackedFixed32", "PackedFixed64", "PackedSfixed32", "PackedSfixed64", "PackedFloat", "PackedDouble", "PackedBool", "PackedEnum", }); - internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor = Descriptor.MessageTypes[26]; - internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor, - new string[] { "UnpackedInt32", "UnpackedInt64", "UnpackedUint32", "UnpackedUint64", "UnpackedSint32", "UnpackedSint64", "UnpackedFixed32", "UnpackedFixed64", "UnpackedSfixed32", "UnpackedSfixed64", "UnpackedFloat", "UnpackedDouble", "UnpackedBool", "UnpackedEnum", }); - internal__static_protobuf_unittest_TestPackedExtensions__Descriptor = Descriptor.MessageTypes[27]; - internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestPackedExtensions__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor = Descriptor.MessageTypes[28]; - internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor, - new string[] { "ScalarExtension", "EnumExtension", "DynamicEnumExtension", "MessageExtension", "DynamicMessageExtension", "RepeatedExtension", "PackedExtension", }); - internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor = internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor, - new string[] { "DynamicField", }); - internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor = Descriptor.MessageTypes[29]; - internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor, - new string[] { "RepeatedFixed32", "RepeatedInt32", "RepeatedFixed64", "RepeatedInt64", "RepeatedFloat", "RepeatedUint64", }); - internal__static_protobuf_unittest_FooRequest__Descriptor = Descriptor.MessageTypes[30]; - internal__static_protobuf_unittest_FooRequest__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooRequest__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_FooResponse__Descriptor = Descriptor.MessageTypes[31]; - internal__static_protobuf_unittest_FooResponse__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooResponse__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_BarRequest__Descriptor = Descriptor.MessageTypes[32]; - internal__static_protobuf_unittest_BarRequest__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BarRequest__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_BarResponse__Descriptor = Descriptor.MessageTypes[33]; - internal__static_protobuf_unittest_BarResponse__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BarResponse__Descriptor, - new string[] { }); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalInt32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[0]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalInt64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[1]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[2]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalUint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[3]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[4]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[5]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[6]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[7]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSfixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[8]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSfixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[9]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFloatExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[10]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalDoubleExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[11]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalBoolExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[12]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[13]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[14]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalGroupExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[15]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalNestedMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[16]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalForeignMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[17]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalImportMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[18]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalNestedEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[19]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalForeignEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[20]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalImportEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[21]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalStringPieceExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[22]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalCordExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[23]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[24]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[25]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[26]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[27]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[28]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[29]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[30]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[31]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[32]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[33]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[34]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[35]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[36]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedStringExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[37]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedBytesExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[38]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedGroupExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[39]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedNestedMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[40]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedForeignMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[41]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedImportMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[42]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedNestedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[43]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedForeignEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[44]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedImportEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[45]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedStringPieceExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[46]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedCordExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[47]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultInt32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[48]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultInt64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[49]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[50]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultUint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[51]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[52]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[53]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[54]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[55]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSfixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[56]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSfixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[57]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFloatExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[58]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultDoubleExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[59]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultBoolExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[60]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[61]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[62]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultNestedEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[63]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultForeignEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[64]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultImportEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[65]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultStringPieceExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[66]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultCordExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[67]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.MyExtensionString = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[68]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.MyExtensionInt = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[69]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[70]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[71]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[72]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[73]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[74]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[75]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[76]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[77]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[78]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[79]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[80]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[81]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[82]); - global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[83]); - pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); - RegisterAllExtensions(registry); - global::Google.ProtocolBuffers.DescriptorProtos.CSharpOptions.RegisterAllExtensions(registry); - global::Google.ProtocolBuffers.TestProtos.UnitTestImportProtoFile.RegisterAllExtensions(registry); - return registry; - }; - pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, - new pbd::FileDescriptor[] { - global::Google.ProtocolBuffers.DescriptorProtos.CSharpOptions.Descriptor, - global::Google.ProtocolBuffers.TestProtos.UnitTestImportProtoFile.Descriptor, - }, assigner); - } - #endregion - - } - #region Enums - public enum ForeignEnum { - FOREIGN_FOO = 4, - FOREIGN_BAR = 5, - FOREIGN_BAZ = 6, - } - - public enum TestEnumWithDupValue { - FOO1 = 1, - BAR1 = 2, - BAZ = 3, - FOO2 = 1, - BAR2 = 2, - } - - public enum TestSparseEnum { - SPARSE_A = 123, - SPARSE_B = 62374, - SPARSE_C = 12589234, - SPARSE_D = -15, - SPARSE_E = -53452, - SPARSE_F = 0, - SPARSE_G = 2, - } - - #endregion - - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestAllTypes : pb::GeneratedMessage { - private TestAllTypes() { } - private static readonly TestAllTypes defaultInstance = new TestAllTypes().MakeReadOnly(); - private static readonly string[] _testAllTypesFieldNames = new string[] { "default_bool", "default_bytes", "default_cord", "default_double", "default_fixed32", "default_fixed64", "default_float", "default_foreign_enum", "default_import_enum", "default_int32", "default_int64", "default_nested_enum", "default_sfixed32", "default_sfixed64", "default_sint32", "default_sint64", "default_string", "default_string_piece", "default_uint32", "default_uint64", "optional_bool", "optional_bytes", "optional_cord", "optional_double", "optional_fixed32", "optional_fixed64", "optional_float", "optional_foreign_enum", "optional_foreign_message", "optional_import_enum", "optional_import_message", "optional_int32", "optional_int64", "optional_nested_enum", "optional_nested_message", "optional_sfixed32", "optional_sfixed64", "optional_sint32", "optional_sint64", "optional_string", "optional_string_piece", "optional_uint32", "optional_uint64", "optionalgroup", "repeated_bool", "repeated_bytes", "repeated_cord", "repeated_double", "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_foreign_enum", "repeated_foreign_message", "repeated_import_enum", "repeated_import_message", "repeated_int32", "repeated_int64", "repeated_nested_enum", "repeated_nested_message", "repeated_sfixed32", "repeated_sfixed64", "repeated_sint32", "repeated_sint64", "repeated_string", "repeated_string_piece", "repeated_uint32", "repeated_uint64", "repeatedgroup" }; - private static readonly uint[] _testAllTypesFieldTags = new uint[] { 584, 602, 682, 577, 541, 545, 573, 656, 664, 488, 496, 648, 557, 561, 520, 528, 594, 674, 504, 512, 104, 122, 202, 97, 61, 65, 93, 176, 154, 184, 162, 8, 16, 168, 146, 77, 81, 40, 48, 114, 194, 24, 32, 131, 344, 362, 442, 337, 301, 305, 333, 416, 394, 424, 402, 248, 256, 408, 386, 317, 321, 280, 288, 354, 434, 264, 272, 371 }; - public static TestAllTypes DefaultInstance { - get { return defaultInstance; } - } - - public override TestAllTypes DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestAllTypes ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - public enum NestedEnum { - FOO = 1, - BAR = 2, - BAZ = 3, - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NestedMessage : pb::GeneratedMessage { - private NestedMessage() { } - private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); - private static readonly string[] _nestedMessageFieldNames = new string[] { "bb" }; - private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8 }; - public static NestedMessage DefaultInstance { - get { return defaultInstance; } - } - - public override NestedMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override NestedMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; } - } - - public const int BbFieldNumber = 1; - private bool hasBb; - private int bb_; - public bool HasBb { - get { return hasBb; } - } - public int Bb { - get { return bb_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _nestedMessageFieldNames; - if (hasBb) { - output.WriteInt32(1, field_names[0], Bb); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasBb) { - size += pb::CodedOutputStream.ComputeInt32Size(1, Bb); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static NestedMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NestedMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NestedMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NestedMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NestedMessage result; - - private NestedMessage PrepareBuilder() { - if (resultIsReadOnly) { - NestedMessage original = result; - result = new NestedMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NestedMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Descriptor; } - } - - public override NestedMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } - - public override NestedMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is NestedMessage) { - return MergeFrom((NestedMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(NestedMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasBb) { - Bb = other.Bb; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _nestedMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasBb = input.ReadInt32(ref result.bb_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasBb { - get { return result.hasBb; } - } - public int Bb { - get { return result.Bb; } - set { SetBb(value); } - } - public Builder SetBb(int value) { - PrepareBuilder(); - result.hasBb = true; - result.bb_ = value; - return this; - } - public Builder ClearBb() { - PrepareBuilder(); - result.hasBb = false; - result.bb_ = 0; - return this; - } - } - static NestedMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OptionalGroup : pb::GeneratedMessage { - private OptionalGroup() { } - private static readonly OptionalGroup defaultInstance = new OptionalGroup().MakeReadOnly(); - private static readonly string[] _optionalGroupFieldNames = new string[] { "a" }; - private static readonly uint[] _optionalGroupFieldTags = new uint[] { 136 }; - public static OptionalGroup DefaultInstance { - get { return defaultInstance; } - } - - public override OptionalGroup DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override OptionalGroup ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable; } - } - - public const int AFieldNumber = 17; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _optionalGroupFieldNames; - if (hasA) { - output.WriteInt32(17, field_names[0], A); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(17, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static OptionalGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static OptionalGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private OptionalGroup MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OptionalGroup prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OptionalGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OptionalGroup result; - - private OptionalGroup PrepareBuilder() { - if (resultIsReadOnly) { - OptionalGroup original = result; - result = new OptionalGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OptionalGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Descriptor; } - } - - public override OptionalGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance; } - } - - public override OptionalGroup BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is OptionalGroup) { - return MergeFrom((OptionalGroup) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(OptionalGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _optionalGroupFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 136: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static OptionalGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class RepeatedGroup : pb::GeneratedMessage { - private RepeatedGroup() { } - private static readonly RepeatedGroup defaultInstance = new RepeatedGroup().MakeReadOnly(); - private static readonly string[] _repeatedGroupFieldNames = new string[] { "a" }; - private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 376 }; - public static RepeatedGroup DefaultInstance { - get { return defaultInstance; } - } - - public override RepeatedGroup DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override RepeatedGroup ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable; } - } - - public const int AFieldNumber = 47; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _repeatedGroupFieldNames; - if (hasA) { - output.WriteInt32(47, field_names[0], A); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(47, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static RepeatedGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private RepeatedGroup MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(RepeatedGroup prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(RepeatedGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private RepeatedGroup result; - - private RepeatedGroup PrepareBuilder() { - if (resultIsReadOnly) { - RepeatedGroup original = result; - result = new RepeatedGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override RepeatedGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Descriptor; } - } - - public override RepeatedGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance; } - } - - public override RepeatedGroup BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is RepeatedGroup) { - return MergeFrom((RepeatedGroup) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(RepeatedGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _repeatedGroupFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 376: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static RepeatedGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - } - #endregion - - public const int OptionalInt32FieldNumber = 1; - private bool hasOptionalInt32; - private int optionalInt32_; - public bool HasOptionalInt32 { - get { return hasOptionalInt32; } - } - public int OptionalInt32 { - get { return optionalInt32_; } - } - - public const int OptionalInt64FieldNumber = 2; - private bool hasOptionalInt64; - private long optionalInt64_; - public bool HasOptionalInt64 { - get { return hasOptionalInt64; } - } - public long OptionalInt64 { - get { return optionalInt64_; } - } - - public const int OptionalUint32FieldNumber = 3; - private bool hasOptionalUint32; - private uint optionalUint32_; - public bool HasOptionalUint32 { - get { return hasOptionalUint32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalUint32 { - get { return optionalUint32_; } - } - - public const int OptionalUint64FieldNumber = 4; - private bool hasOptionalUint64; - private ulong optionalUint64_; - public bool HasOptionalUint64 { - get { return hasOptionalUint64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalUint64 { - get { return optionalUint64_; } - } - - public const int OptionalSint32FieldNumber = 5; - private bool hasOptionalSint32; - private int optionalSint32_; - public bool HasOptionalSint32 { - get { return hasOptionalSint32; } - } - public int OptionalSint32 { - get { return optionalSint32_; } - } - - public const int OptionalSint64FieldNumber = 6; - private bool hasOptionalSint64; - private long optionalSint64_; - public bool HasOptionalSint64 { - get { return hasOptionalSint64; } - } - public long OptionalSint64 { - get { return optionalSint64_; } - } - - public const int OptionalFixed32FieldNumber = 7; - private bool hasOptionalFixed32; - private uint optionalFixed32_; - public bool HasOptionalFixed32 { - get { return hasOptionalFixed32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalFixed32 { - get { return optionalFixed32_; } - } - - public const int OptionalFixed64FieldNumber = 8; - private bool hasOptionalFixed64; - private ulong optionalFixed64_; - public bool HasOptionalFixed64 { - get { return hasOptionalFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalFixed64 { - get { return optionalFixed64_; } - } - - public const int OptionalSfixed32FieldNumber = 9; - private bool hasOptionalSfixed32; - private int optionalSfixed32_; - public bool HasOptionalSfixed32 { - get { return hasOptionalSfixed32; } - } - public int OptionalSfixed32 { - get { return optionalSfixed32_; } - } - - public const int OptionalSfixed64FieldNumber = 10; - private bool hasOptionalSfixed64; - private long optionalSfixed64_; - public bool HasOptionalSfixed64 { - get { return hasOptionalSfixed64; } - } - public long OptionalSfixed64 { - get { return optionalSfixed64_; } - } - - public const int OptionalFloatFieldNumber = 11; - private bool hasOptionalFloat; - private float optionalFloat_; - public bool HasOptionalFloat { - get { return hasOptionalFloat; } - } - public float OptionalFloat { - get { return optionalFloat_; } - } - - public const int OptionalDoubleFieldNumber = 12; - private bool hasOptionalDouble; - private double optionalDouble_; - public bool HasOptionalDouble { - get { return hasOptionalDouble; } - } - public double OptionalDouble { - get { return optionalDouble_; } - } - - public const int OptionalBoolFieldNumber = 13; - private bool hasOptionalBool; - private bool optionalBool_; - public bool HasOptionalBool { - get { return hasOptionalBool; } - } - public bool OptionalBool { - get { return optionalBool_; } - } - - public const int OptionalStringFieldNumber = 14; - private bool hasOptionalString; - private string optionalString_ = ""; - public bool HasOptionalString { - get { return hasOptionalString; } - } - public string OptionalString { - get { return optionalString_; } - } - - public const int OptionalBytesFieldNumber = 15; - private bool hasOptionalBytes; - private pb::ByteString optionalBytes_ = pb::ByteString.Empty; - public bool HasOptionalBytes { - get { return hasOptionalBytes; } - } - public pb::ByteString OptionalBytes { - get { return optionalBytes_; } - } - - public const int OptionalGroupFieldNumber = 16; - private bool hasOptionalGroup; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup optionalGroup_; - public bool HasOptionalGroup { - get { return hasOptionalGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup OptionalGroup { - get { return optionalGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance; } - } - - public const int OptionalNestedMessageFieldNumber = 18; - private bool hasOptionalNestedMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage optionalNestedMessage_; - public bool HasOptionalNestedMessage { - get { return hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage { - get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } - - public const int OptionalForeignMessageFieldNumber = 19; - private bool hasOptionalForeignMessage; - private global::Google.ProtocolBuffers.TestProtos.ForeignMessage optionalForeignMessage_; - public bool HasOptionalForeignMessage { - get { return hasOptionalForeignMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage { - get { return optionalForeignMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } - } - - public const int OptionalImportMessageFieldNumber = 20; - private bool hasOptionalImportMessage; - private global::Google.ProtocolBuffers.TestProtos.ImportMessage optionalImportMessage_; - public bool HasOptionalImportMessage { - get { return hasOptionalImportMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessage OptionalImportMessage { - get { return optionalImportMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance; } - } - - public const int OptionalNestedEnumFieldNumber = 21; - private bool hasOptionalNestedEnum; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; - public bool HasOptionalNestedEnum { - get { return hasOptionalNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum { - get { return optionalNestedEnum_; } - } - - public const int OptionalForeignEnumFieldNumber = 22; - private bool hasOptionalForeignEnum; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnum optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - public bool HasOptionalForeignEnum { - get { return hasOptionalForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum { - get { return optionalForeignEnum_; } - } - - public const int OptionalImportEnumFieldNumber = 23; - private bool hasOptionalImportEnum; - private global::Google.ProtocolBuffers.TestProtos.ImportEnum optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_FOO; - public bool HasOptionalImportEnum { - get { return hasOptionalImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum OptionalImportEnum { - get { return optionalImportEnum_; } - } - - public const int OptionalStringPieceFieldNumber = 24; - private bool hasOptionalStringPiece; - private string optionalStringPiece_ = ""; - public bool HasOptionalStringPiece { - get { return hasOptionalStringPiece; } - } - public string OptionalStringPiece { - get { return optionalStringPiece_; } - } - - public const int OptionalCordFieldNumber = 25; - private bool hasOptionalCord; - private string optionalCord_ = ""; - public bool HasOptionalCord { - get { return hasOptionalCord; } - } - public string OptionalCord { - get { return optionalCord_; } - } - - public const int RepeatedInt32FieldNumber = 31; - private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt32List { - get { return pbc::Lists.AsReadOnly(repeatedInt32_); } - } - public int RepeatedInt32Count { - get { return repeatedInt32_.Count; } - } - public int GetRepeatedInt32(int index) { - return repeatedInt32_[index]; - } - - public const int RepeatedInt64FieldNumber = 32; - private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt64List { - get { return pbc::Lists.AsReadOnly(repeatedInt64_); } - } - public int RepeatedInt64Count { - get { return repeatedInt64_.Count; } - } - public long GetRepeatedInt64(int index) { - return repeatedInt64_[index]; - } - - public const int RepeatedUint32FieldNumber = 33; - private pbc::PopsicleList repeatedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedUint32List { - get { return pbc::Lists.AsReadOnly(repeatedUint32_); } - } - public int RepeatedUint32Count { - get { return repeatedUint32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedUint32(int index) { - return repeatedUint32_[index]; - } - - public const int RepeatedUint64FieldNumber = 34; - private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedUint64List { - get { return pbc::Lists.AsReadOnly(repeatedUint64_); } - } - public int RepeatedUint64Count { - get { return repeatedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return repeatedUint64_[index]; - } - - public const int RepeatedSint32FieldNumber = 35; - private pbc::PopsicleList repeatedSint32_ = new pbc::PopsicleList(); - public scg::IList RepeatedSint32List { - get { return pbc::Lists.AsReadOnly(repeatedSint32_); } - } - public int RepeatedSint32Count { - get { return repeatedSint32_.Count; } - } - public int GetRepeatedSint32(int index) { - return repeatedSint32_[index]; - } - - public const int RepeatedSint64FieldNumber = 36; - private pbc::PopsicleList repeatedSint64_ = new pbc::PopsicleList(); - public scg::IList RepeatedSint64List { - get { return pbc::Lists.AsReadOnly(repeatedSint64_); } - } - public int RepeatedSint64Count { - get { return repeatedSint64_.Count; } - } - public long GetRepeatedSint64(int index) { - return repeatedSint64_[index]; - } - - public const int RepeatedFixed32FieldNumber = 37; - private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed32List { - get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } - } - public int RepeatedFixed32Count { - get { return repeatedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return repeatedFixed32_[index]; - } - - public const int RepeatedFixed64FieldNumber = 38; - private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed64List { - get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } - } - public int RepeatedFixed64Count { - get { return repeatedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return repeatedFixed64_[index]; - } - - public const int RepeatedSfixed32FieldNumber = 39; - private pbc::PopsicleList repeatedSfixed32_ = new pbc::PopsicleList(); - public scg::IList RepeatedSfixed32List { - get { return pbc::Lists.AsReadOnly(repeatedSfixed32_); } - } - public int RepeatedSfixed32Count { - get { return repeatedSfixed32_.Count; } - } - public int GetRepeatedSfixed32(int index) { - return repeatedSfixed32_[index]; - } - - public const int RepeatedSfixed64FieldNumber = 40; - private pbc::PopsicleList repeatedSfixed64_ = new pbc::PopsicleList(); - public scg::IList RepeatedSfixed64List { - get { return pbc::Lists.AsReadOnly(repeatedSfixed64_); } - } - public int RepeatedSfixed64Count { - get { return repeatedSfixed64_.Count; } - } - public long GetRepeatedSfixed64(int index) { - return repeatedSfixed64_[index]; - } - - public const int RepeatedFloatFieldNumber = 41; - private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); - public scg::IList RepeatedFloatList { - get { return pbc::Lists.AsReadOnly(repeatedFloat_); } - } - public int RepeatedFloatCount { - get { return repeatedFloat_.Count; } - } - public float GetRepeatedFloat(int index) { - return repeatedFloat_[index]; - } - - public const int RepeatedDoubleFieldNumber = 42; - private pbc::PopsicleList repeatedDouble_ = new pbc::PopsicleList(); - public scg::IList RepeatedDoubleList { - get { return pbc::Lists.AsReadOnly(repeatedDouble_); } - } - public int RepeatedDoubleCount { - get { return repeatedDouble_.Count; } - } - public double GetRepeatedDouble(int index) { - return repeatedDouble_[index]; - } - - public const int RepeatedBoolFieldNumber = 43; - private pbc::PopsicleList repeatedBool_ = new pbc::PopsicleList(); - public scg::IList RepeatedBoolList { - get { return pbc::Lists.AsReadOnly(repeatedBool_); } - } - public int RepeatedBoolCount { - get { return repeatedBool_.Count; } - } - public bool GetRepeatedBool(int index) { - return repeatedBool_[index]; - } - - public const int RepeatedStringFieldNumber = 44; - private pbc::PopsicleList repeatedString_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringList { - get { return pbc::Lists.AsReadOnly(repeatedString_); } - } - public int RepeatedStringCount { - get { return repeatedString_.Count; } - } - public string GetRepeatedString(int index) { - return repeatedString_[index]; - } - - public const int RepeatedBytesFieldNumber = 45; - private pbc::PopsicleList repeatedBytes_ = new pbc::PopsicleList(); - public scg::IList RepeatedBytesList { - get { return pbc::Lists.AsReadOnly(repeatedBytes_); } - } - public int RepeatedBytesCount { - get { return repeatedBytes_.Count; } - } - public pb::ByteString GetRepeatedBytes(int index) { - return repeatedBytes_[index]; - } - - public const int RepeatedGroupFieldNumber = 46; - private pbc::PopsicleList repeatedGroup_ = new pbc::PopsicleList(); - public scg::IList RepeatedGroupList { - get { return repeatedGroup_; } - } - public int RepeatedGroupCount { - get { return repeatedGroup_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup GetRepeatedGroup(int index) { - return repeatedGroup_[index]; - } - - public const int RepeatedNestedMessageFieldNumber = 48; - private pbc::PopsicleList repeatedNestedMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedNestedMessageList { - get { return repeatedNestedMessage_; } - } - public int RepeatedNestedMessageCount { - get { return repeatedNestedMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) { - return repeatedNestedMessage_[index]; - } - - public const int RepeatedForeignMessageFieldNumber = 49; - private pbc::PopsicleList repeatedForeignMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedForeignMessageList { - get { return repeatedForeignMessage_; } - } - public int RepeatedForeignMessageCount { - get { return repeatedForeignMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) { - return repeatedForeignMessage_[index]; - } - - public const int RepeatedImportMessageFieldNumber = 50; - private pbc::PopsicleList repeatedImportMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedImportMessageList { - get { return repeatedImportMessage_; } - } - public int RepeatedImportMessageCount { - get { return repeatedImportMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessage GetRepeatedImportMessage(int index) { - return repeatedImportMessage_[index]; - } - - public const int RepeatedNestedEnumFieldNumber = 51; - private pbc::PopsicleList repeatedNestedEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedNestedEnumList { - get { return pbc::Lists.AsReadOnly(repeatedNestedEnum_); } - } - public int RepeatedNestedEnumCount { - get { return repeatedNestedEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) { - return repeatedNestedEnum_[index]; - } - - public const int RepeatedForeignEnumFieldNumber = 52; - private pbc::PopsicleList repeatedForeignEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedForeignEnumList { - get { return pbc::Lists.AsReadOnly(repeatedForeignEnum_); } - } - public int RepeatedForeignEnumCount { - get { return repeatedForeignEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) { - return repeatedForeignEnum_[index]; - } - - public const int RepeatedImportEnumFieldNumber = 53; - private pbc::PopsicleList repeatedImportEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedImportEnumList { - get { return pbc::Lists.AsReadOnly(repeatedImportEnum_); } - } - public int RepeatedImportEnumCount { - get { return repeatedImportEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum GetRepeatedImportEnum(int index) { - return repeatedImportEnum_[index]; - } - - public const int RepeatedStringPieceFieldNumber = 54; - private pbc::PopsicleList repeatedStringPiece_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringPieceList { - get { return pbc::Lists.AsReadOnly(repeatedStringPiece_); } - } - public int RepeatedStringPieceCount { - get { return repeatedStringPiece_.Count; } - } - public string GetRepeatedStringPiece(int index) { - return repeatedStringPiece_[index]; - } - - public const int RepeatedCordFieldNumber = 55; - private pbc::PopsicleList repeatedCord_ = new pbc::PopsicleList(); - public scg::IList RepeatedCordList { - get { return pbc::Lists.AsReadOnly(repeatedCord_); } - } - public int RepeatedCordCount { - get { return repeatedCord_.Count; } - } - public string GetRepeatedCord(int index) { - return repeatedCord_[index]; - } - - public const int DefaultInt32FieldNumber = 61; - private bool hasDefaultInt32; - private int defaultInt32_ = 41; - public bool HasDefaultInt32 { - get { return hasDefaultInt32; } - } - public int DefaultInt32 { - get { return defaultInt32_; } - } - - public const int DefaultInt64FieldNumber = 62; - private bool hasDefaultInt64; - private long defaultInt64_ = 42L; - public bool HasDefaultInt64 { - get { return hasDefaultInt64; } - } - public long DefaultInt64 { - get { return defaultInt64_; } - } - - public const int DefaultUint32FieldNumber = 63; - private bool hasDefaultUint32; - private uint defaultUint32_ = 43; - public bool HasDefaultUint32 { - get { return hasDefaultUint32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultUint32 { - get { return defaultUint32_; } - } - - public const int DefaultUint64FieldNumber = 64; - private bool hasDefaultUint64; - private ulong defaultUint64_ = 44UL; - public bool HasDefaultUint64 { - get { return hasDefaultUint64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultUint64 { - get { return defaultUint64_; } - } - - public const int DefaultSint32FieldNumber = 65; - private bool hasDefaultSint32; - private int defaultSint32_ = -45; - public bool HasDefaultSint32 { - get { return hasDefaultSint32; } - } - public int DefaultSint32 { - get { return defaultSint32_; } - } - - public const int DefaultSint64FieldNumber = 66; - private bool hasDefaultSint64; - private long defaultSint64_ = 46; - public bool HasDefaultSint64 { - get { return hasDefaultSint64; } - } - public long DefaultSint64 { - get { return defaultSint64_; } - } - - public const int DefaultFixed32FieldNumber = 67; - private bool hasDefaultFixed32; - private uint defaultFixed32_ = 47; - public bool HasDefaultFixed32 { - get { return hasDefaultFixed32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultFixed32 { - get { return defaultFixed32_; } - } - - public const int DefaultFixed64FieldNumber = 68; - private bool hasDefaultFixed64; - private ulong defaultFixed64_ = 48; - public bool HasDefaultFixed64 { - get { return hasDefaultFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultFixed64 { - get { return defaultFixed64_; } - } - - public const int DefaultSfixed32FieldNumber = 69; - private bool hasDefaultSfixed32; - private int defaultSfixed32_ = 49; - public bool HasDefaultSfixed32 { - get { return hasDefaultSfixed32; } - } - public int DefaultSfixed32 { - get { return defaultSfixed32_; } - } - - public const int DefaultSfixed64FieldNumber = 70; - private bool hasDefaultSfixed64; - private long defaultSfixed64_ = -50; - public bool HasDefaultSfixed64 { - get { return hasDefaultSfixed64; } - } - public long DefaultSfixed64 { - get { return defaultSfixed64_; } - } - - public const int DefaultFloatFieldNumber = 71; - private bool hasDefaultFloat; - private float defaultFloat_ = 51.5F; - public bool HasDefaultFloat { - get { return hasDefaultFloat; } - } - public float DefaultFloat { - get { return defaultFloat_; } - } - - public const int DefaultDoubleFieldNumber = 72; - private bool hasDefaultDouble; - private double defaultDouble_ = 52000D; - public bool HasDefaultDouble { - get { return hasDefaultDouble; } - } - public double DefaultDouble { - get { return defaultDouble_; } - } - - public const int DefaultBoolFieldNumber = 73; - private bool hasDefaultBool; - private bool defaultBool_ = true; - public bool HasDefaultBool { - get { return hasDefaultBool; } - } - public bool DefaultBool { - get { return defaultBool_; } - } - - public const int DefaultStringFieldNumber = 74; - private bool hasDefaultString; - private string defaultString_ = "hello"; - public bool HasDefaultString { - get { return hasDefaultString; } - } - public string DefaultString { - get { return defaultString_; } - } - - public const int DefaultBytesFieldNumber = 75; - private bool hasDefaultBytes; - private pb::ByteString defaultBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor.Fields[62].DefaultValue; - public bool HasDefaultBytes { - get { return hasDefaultBytes; } - } - public pb::ByteString DefaultBytes { - get { return defaultBytes_; } - } - - public const int DefaultNestedEnumFieldNumber = 81; - private bool hasDefaultNestedEnum; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.BAR; - public bool HasDefaultNestedEnum { - get { return hasDefaultNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum DefaultNestedEnum { - get { return defaultNestedEnum_; } - } - - public const int DefaultForeignEnumFieldNumber = 82; - private bool hasDefaultForeignEnum; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnum defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_BAR; - public bool HasDefaultForeignEnum { - get { return hasDefaultForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum DefaultForeignEnum { - get { return defaultForeignEnum_; } - } - - public const int DefaultImportEnumFieldNumber = 83; - private bool hasDefaultImportEnum; - private global::Google.ProtocolBuffers.TestProtos.ImportEnum defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_BAR; - public bool HasDefaultImportEnum { - get { return hasDefaultImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum DefaultImportEnum { - get { return defaultImportEnum_; } - } - - public const int DefaultStringPieceFieldNumber = 84; - private bool hasDefaultStringPiece; - private string defaultStringPiece_ = "abc"; - public bool HasDefaultStringPiece { - get { return hasDefaultStringPiece; } - } - public string DefaultStringPiece { - get { return defaultStringPiece_; } - } - - public const int DefaultCordFieldNumber = 85; - private bool hasDefaultCord; - private string defaultCord_ = "123"; - public bool HasDefaultCord { - get { return hasDefaultCord; } - } - public string DefaultCord { - get { return defaultCord_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testAllTypesFieldNames; - if (hasOptionalInt32) { - output.WriteInt32(1, field_names[31], OptionalInt32); - } - if (hasOptionalInt64) { - output.WriteInt64(2, field_names[32], OptionalInt64); - } - if (hasOptionalUint32) { - output.WriteUInt32(3, field_names[41], OptionalUint32); - } - if (hasOptionalUint64) { - output.WriteUInt64(4, field_names[42], OptionalUint64); - } - if (hasOptionalSint32) { - output.WriteSInt32(5, field_names[37], OptionalSint32); - } - if (hasOptionalSint64) { - output.WriteSInt64(6, field_names[38], OptionalSint64); - } - if (hasOptionalFixed32) { - output.WriteFixed32(7, field_names[24], OptionalFixed32); - } - if (hasOptionalFixed64) { - output.WriteFixed64(8, field_names[25], OptionalFixed64); - } - if (hasOptionalSfixed32) { - output.WriteSFixed32(9, field_names[35], OptionalSfixed32); - } - if (hasOptionalSfixed64) { - output.WriteSFixed64(10, field_names[36], OptionalSfixed64); - } - if (hasOptionalFloat) { - output.WriteFloat(11, field_names[26], OptionalFloat); - } - if (hasOptionalDouble) { - output.WriteDouble(12, field_names[23], OptionalDouble); - } - if (hasOptionalBool) { - output.WriteBool(13, field_names[20], OptionalBool); - } - if (hasOptionalString) { - output.WriteString(14, field_names[39], OptionalString); - } - if (hasOptionalBytes) { - output.WriteBytes(15, field_names[21], OptionalBytes); - } - if (hasOptionalGroup) { - output.WriteGroup(16, field_names[43], OptionalGroup); - } - if (hasOptionalNestedMessage) { - output.WriteMessage(18, field_names[34], OptionalNestedMessage); - } - if (hasOptionalForeignMessage) { - output.WriteMessage(19, field_names[28], OptionalForeignMessage); - } - if (hasOptionalImportMessage) { - output.WriteMessage(20, field_names[30], OptionalImportMessage); - } - if (hasOptionalNestedEnum) { - output.WriteEnum(21, field_names[33], (int) OptionalNestedEnum, OptionalNestedEnum); - } - if (hasOptionalForeignEnum) { - output.WriteEnum(22, field_names[27], (int) OptionalForeignEnum, OptionalForeignEnum); - } - if (hasOptionalImportEnum) { - output.WriteEnum(23, field_names[29], (int) OptionalImportEnum, OptionalImportEnum); - } - if (hasOptionalStringPiece) { - output.WriteString(24, field_names[40], OptionalStringPiece); - } - if (hasOptionalCord) { - output.WriteString(25, field_names[22], OptionalCord); - } - if (repeatedInt32_.Count > 0) { - output.WriteInt32Array(31, field_names[55], repeatedInt32_); - } - if (repeatedInt64_.Count > 0) { - output.WriteInt64Array(32, field_names[56], repeatedInt64_); - } - if (repeatedUint32_.Count > 0) { - output.WriteUInt32Array(33, field_names[65], repeatedUint32_); - } - if (repeatedUint64_.Count > 0) { - output.WriteUInt64Array(34, field_names[66], repeatedUint64_); - } - if (repeatedSint32_.Count > 0) { - output.WriteSInt32Array(35, field_names[61], repeatedSint32_); - } - if (repeatedSint64_.Count > 0) { - output.WriteSInt64Array(36, field_names[62], repeatedSint64_); - } - if (repeatedFixed32_.Count > 0) { - output.WriteFixed32Array(37, field_names[48], repeatedFixed32_); - } - if (repeatedFixed64_.Count > 0) { - output.WriteFixed64Array(38, field_names[49], repeatedFixed64_); - } - if (repeatedSfixed32_.Count > 0) { - output.WriteSFixed32Array(39, field_names[59], repeatedSfixed32_); - } - if (repeatedSfixed64_.Count > 0) { - output.WriteSFixed64Array(40, field_names[60], repeatedSfixed64_); - } - if (repeatedFloat_.Count > 0) { - output.WriteFloatArray(41, field_names[50], repeatedFloat_); - } - if (repeatedDouble_.Count > 0) { - output.WriteDoubleArray(42, field_names[47], repeatedDouble_); - } - if (repeatedBool_.Count > 0) { - output.WriteBoolArray(43, field_names[44], repeatedBool_); - } - if (repeatedString_.Count > 0) { - output.WriteStringArray(44, field_names[63], repeatedString_); - } - if (repeatedBytes_.Count > 0) { - output.WriteBytesArray(45, field_names[45], repeatedBytes_); - } - if (repeatedGroup_.Count > 0) { - output.WriteGroupArray(46, field_names[67], repeatedGroup_); - } - if (repeatedNestedMessage_.Count > 0) { - output.WriteMessageArray(48, field_names[58], repeatedNestedMessage_); - } - if (repeatedForeignMessage_.Count > 0) { - output.WriteMessageArray(49, field_names[52], repeatedForeignMessage_); - } - if (repeatedImportMessage_.Count > 0) { - output.WriteMessageArray(50, field_names[54], repeatedImportMessage_); - } - if (repeatedNestedEnum_.Count > 0) { - output.WriteEnumArray(51, field_names[57], repeatedNestedEnum_); - } - if (repeatedForeignEnum_.Count > 0) { - output.WriteEnumArray(52, field_names[51], repeatedForeignEnum_); - } - if (repeatedImportEnum_.Count > 0) { - output.WriteEnumArray(53, field_names[53], repeatedImportEnum_); - } - if (repeatedStringPiece_.Count > 0) { - output.WriteStringArray(54, field_names[64], repeatedStringPiece_); - } - if (repeatedCord_.Count > 0) { - output.WriteStringArray(55, field_names[46], repeatedCord_); - } - if (hasDefaultInt32) { - output.WriteInt32(61, field_names[9], DefaultInt32); - } - if (hasDefaultInt64) { - output.WriteInt64(62, field_names[10], DefaultInt64); - } - if (hasDefaultUint32) { - output.WriteUInt32(63, field_names[18], DefaultUint32); - } - if (hasDefaultUint64) { - output.WriteUInt64(64, field_names[19], DefaultUint64); - } - if (hasDefaultSint32) { - output.WriteSInt32(65, field_names[14], DefaultSint32); - } - if (hasDefaultSint64) { - output.WriteSInt64(66, field_names[15], DefaultSint64); - } - if (hasDefaultFixed32) { - output.WriteFixed32(67, field_names[4], DefaultFixed32); - } - if (hasDefaultFixed64) { - output.WriteFixed64(68, field_names[5], DefaultFixed64); - } - if (hasDefaultSfixed32) { - output.WriteSFixed32(69, field_names[12], DefaultSfixed32); - } - if (hasDefaultSfixed64) { - output.WriteSFixed64(70, field_names[13], DefaultSfixed64); - } - if (hasDefaultFloat) { - output.WriteFloat(71, field_names[6], DefaultFloat); - } - if (hasDefaultDouble) { - output.WriteDouble(72, field_names[3], DefaultDouble); - } - if (hasDefaultBool) { - output.WriteBool(73, field_names[0], DefaultBool); - } - if (hasDefaultString) { - output.WriteString(74, field_names[16], DefaultString); - } - if (hasDefaultBytes) { - output.WriteBytes(75, field_names[1], DefaultBytes); - } - if (hasDefaultNestedEnum) { - output.WriteEnum(81, field_names[11], (int) DefaultNestedEnum, DefaultNestedEnum); - } - if (hasDefaultForeignEnum) { - output.WriteEnum(82, field_names[7], (int) DefaultForeignEnum, DefaultForeignEnum); - } - if (hasDefaultImportEnum) { - output.WriteEnum(83, field_names[8], (int) DefaultImportEnum, DefaultImportEnum); - } - if (hasDefaultStringPiece) { - output.WriteString(84, field_names[17], DefaultStringPiece); - } - if (hasDefaultCord) { - output.WriteString(85, field_names[2], DefaultCord); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasOptionalInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(1, OptionalInt32); - } - if (hasOptionalInt64) { - size += pb::CodedOutputStream.ComputeInt64Size(2, OptionalInt64); - } - if (hasOptionalUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(3, OptionalUint32); - } - if (hasOptionalUint64) { - size += pb::CodedOutputStream.ComputeUInt64Size(4, OptionalUint64); - } - if (hasOptionalSint32) { - size += pb::CodedOutputStream.ComputeSInt32Size(5, OptionalSint32); - } - if (hasOptionalSint64) { - size += pb::CodedOutputStream.ComputeSInt64Size(6, OptionalSint64); - } - if (hasOptionalFixed32) { - size += pb::CodedOutputStream.ComputeFixed32Size(7, OptionalFixed32); - } - if (hasOptionalFixed64) { - size += pb::CodedOutputStream.ComputeFixed64Size(8, OptionalFixed64); - } - if (hasOptionalSfixed32) { - size += pb::CodedOutputStream.ComputeSFixed32Size(9, OptionalSfixed32); - } - if (hasOptionalSfixed64) { - size += pb::CodedOutputStream.ComputeSFixed64Size(10, OptionalSfixed64); - } - if (hasOptionalFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(11, OptionalFloat); - } - if (hasOptionalDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(12, OptionalDouble); - } - if (hasOptionalBool) { - size += pb::CodedOutputStream.ComputeBoolSize(13, OptionalBool); - } - if (hasOptionalString) { - size += pb::CodedOutputStream.ComputeStringSize(14, OptionalString); - } - if (hasOptionalBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(15, OptionalBytes); - } - if (hasOptionalGroup) { - size += pb::CodedOutputStream.ComputeGroupSize(16, OptionalGroup); - } - if (hasOptionalNestedMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(18, OptionalNestedMessage); - } - if (hasOptionalForeignMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(19, OptionalForeignMessage); - } - if (hasOptionalImportMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(20, OptionalImportMessage); - } - if (hasOptionalNestedEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(21, (int) OptionalNestedEnum); - } - if (hasOptionalForeignEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(22, (int) OptionalForeignEnum); - } - if (hasOptionalImportEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(23, (int) OptionalImportEnum); - } - if (hasOptionalStringPiece) { - size += pb::CodedOutputStream.ComputeStringSize(24, OptionalStringPiece); - } - if (hasOptionalCord) { - size += pb::CodedOutputStream.ComputeStringSize(25, OptionalCord); - } - { - int dataSize = 0; - foreach (int element in RepeatedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedInt32_.Count; - } - { - int dataSize = 0; - foreach (long element in RepeatedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedInt64_.Count; - } - { - int dataSize = 0; - foreach (uint element in RepeatedUint32List) { - dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedUint32_.Count; - } - { - int dataSize = 0; - foreach (ulong element in RepeatedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedUint64_.Count; - } - { - int dataSize = 0; - foreach (int element in RepeatedSint32List) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedSint32_.Count; - } - { - int dataSize = 0; - foreach (long element in RepeatedSint64List) { - dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedSint64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedFixed32_.Count; - size += dataSize; - size += 2 * repeatedFixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedFixed64_.Count; - size += dataSize; - size += 2 * repeatedFixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedSfixed32_.Count; - size += dataSize; - size += 2 * repeatedSfixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedSfixed64_.Count; - size += dataSize; - size += 2 * repeatedSfixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedFloat_.Count; - size += dataSize; - size += 2 * repeatedFloat_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedDouble_.Count; - size += dataSize; - size += 2 * repeatedDouble_.Count; - } - { - int dataSize = 0; - dataSize = 1 * repeatedBool_.Count; - size += dataSize; - size += 2 * repeatedBool_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedStringList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedString_.Count; - } - { - int dataSize = 0; - foreach (pb::ByteString element in RepeatedBytesList) { - dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedBytes_.Count; - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup element in RepeatedGroupList) { - size += pb::CodedOutputStream.ComputeGroupSize(46, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage element in RepeatedNestedMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(48, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedForeignMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(49, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.ImportMessage element in RepeatedImportMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(50, element); - } - { - int dataSize = 0; - if (repeatedNestedEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum element in repeatedNestedEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedNestedEnum_.Count; - } - } - { - int dataSize = 0; - if (repeatedForeignEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedForeignEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedForeignEnum_.Count; - } - } - { - int dataSize = 0; - if (repeatedImportEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ImportEnum element in repeatedImportEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedImportEnum_.Count; - } - } - { - int dataSize = 0; - foreach (string element in RepeatedStringPieceList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedStringPiece_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedCordList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedCord_.Count; - } - if (hasDefaultInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(61, DefaultInt32); - } - if (hasDefaultInt64) { - size += pb::CodedOutputStream.ComputeInt64Size(62, DefaultInt64); - } - if (hasDefaultUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(63, DefaultUint32); - } - if (hasDefaultUint64) { - size += pb::CodedOutputStream.ComputeUInt64Size(64, DefaultUint64); - } - if (hasDefaultSint32) { - size += pb::CodedOutputStream.ComputeSInt32Size(65, DefaultSint32); - } - if (hasDefaultSint64) { - size += pb::CodedOutputStream.ComputeSInt64Size(66, DefaultSint64); - } - if (hasDefaultFixed32) { - size += pb::CodedOutputStream.ComputeFixed32Size(67, DefaultFixed32); - } - if (hasDefaultFixed64) { - size += pb::CodedOutputStream.ComputeFixed64Size(68, DefaultFixed64); - } - if (hasDefaultSfixed32) { - size += pb::CodedOutputStream.ComputeSFixed32Size(69, DefaultSfixed32); - } - if (hasDefaultSfixed64) { - size += pb::CodedOutputStream.ComputeSFixed64Size(70, DefaultSfixed64); - } - if (hasDefaultFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(71, DefaultFloat); - } - if (hasDefaultDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(72, DefaultDouble); - } - if (hasDefaultBool) { - size += pb::CodedOutputStream.ComputeBoolSize(73, DefaultBool); - } - if (hasDefaultString) { - size += pb::CodedOutputStream.ComputeStringSize(74, DefaultString); - } - if (hasDefaultBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(75, DefaultBytes); - } - if (hasDefaultNestedEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(81, (int) DefaultNestedEnum); - } - if (hasDefaultForeignEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(82, (int) DefaultForeignEnum); - } - if (hasDefaultImportEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(83, (int) DefaultImportEnum); - } - if (hasDefaultStringPiece) { - size += pb::CodedOutputStream.ComputeStringSize(84, DefaultStringPiece); - } - if (hasDefaultCord) { - size += pb::CodedOutputStream.ComputeStringSize(85, DefaultCord); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestAllTypes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllTypes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllTypes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestAllTypes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestAllTypes MakeReadOnly() { - repeatedInt32_.MakeReadOnly(); - repeatedInt64_.MakeReadOnly(); - repeatedUint32_.MakeReadOnly(); - repeatedUint64_.MakeReadOnly(); - repeatedSint32_.MakeReadOnly(); - repeatedSint64_.MakeReadOnly(); - repeatedFixed32_.MakeReadOnly(); - repeatedFixed64_.MakeReadOnly(); - repeatedSfixed32_.MakeReadOnly(); - repeatedSfixed64_.MakeReadOnly(); - repeatedFloat_.MakeReadOnly(); - repeatedDouble_.MakeReadOnly(); - repeatedBool_.MakeReadOnly(); - repeatedString_.MakeReadOnly(); - repeatedBytes_.MakeReadOnly(); - repeatedGroup_.MakeReadOnly(); - repeatedNestedMessage_.MakeReadOnly(); - repeatedForeignMessage_.MakeReadOnly(); - repeatedImportMessage_.MakeReadOnly(); - repeatedNestedEnum_.MakeReadOnly(); - repeatedForeignEnum_.MakeReadOnly(); - repeatedImportEnum_.MakeReadOnly(); - repeatedStringPiece_.MakeReadOnly(); - repeatedCord_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestAllTypes prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestAllTypes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestAllTypes result; - - private TestAllTypes PrepareBuilder() { - if (resultIsReadOnly) { - TestAllTypes original = result; - result = new TestAllTypes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestAllTypes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor; } - } - - public override TestAllTypes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } - - public override TestAllTypes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestAllTypes) { - return MergeFrom((TestAllTypes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestAllTypes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasOptionalInt32) { - OptionalInt32 = other.OptionalInt32; - } - if (other.HasOptionalInt64) { - OptionalInt64 = other.OptionalInt64; - } - if (other.HasOptionalUint32) { - OptionalUint32 = other.OptionalUint32; - } - if (other.HasOptionalUint64) { - OptionalUint64 = other.OptionalUint64; - } - if (other.HasOptionalSint32) { - OptionalSint32 = other.OptionalSint32; - } - if (other.HasOptionalSint64) { - OptionalSint64 = other.OptionalSint64; - } - if (other.HasOptionalFixed32) { - OptionalFixed32 = other.OptionalFixed32; - } - if (other.HasOptionalFixed64) { - OptionalFixed64 = other.OptionalFixed64; - } - if (other.HasOptionalSfixed32) { - OptionalSfixed32 = other.OptionalSfixed32; - } - if (other.HasOptionalSfixed64) { - OptionalSfixed64 = other.OptionalSfixed64; - } - if (other.HasOptionalFloat) { - OptionalFloat = other.OptionalFloat; - } - if (other.HasOptionalDouble) { - OptionalDouble = other.OptionalDouble; - } - if (other.HasOptionalBool) { - OptionalBool = other.OptionalBool; - } - if (other.HasOptionalString) { - OptionalString = other.OptionalString; - } - if (other.HasOptionalBytes) { - OptionalBytes = other.OptionalBytes; - } - if (other.HasOptionalGroup) { - MergeOptionalGroup(other.OptionalGroup); - } - if (other.HasOptionalNestedMessage) { - MergeOptionalNestedMessage(other.OptionalNestedMessage); - } - if (other.HasOptionalForeignMessage) { - MergeOptionalForeignMessage(other.OptionalForeignMessage); - } - if (other.HasOptionalImportMessage) { - MergeOptionalImportMessage(other.OptionalImportMessage); - } - if (other.HasOptionalNestedEnum) { - OptionalNestedEnum = other.OptionalNestedEnum; - } - if (other.HasOptionalForeignEnum) { - OptionalForeignEnum = other.OptionalForeignEnum; - } - if (other.HasOptionalImportEnum) { - OptionalImportEnum = other.OptionalImportEnum; - } - if (other.HasOptionalStringPiece) { - OptionalStringPiece = other.OptionalStringPiece; - } - if (other.HasOptionalCord) { - OptionalCord = other.OptionalCord; - } - if (other.repeatedInt32_.Count != 0) { - result.repeatedInt32_.Add(other.repeatedInt32_); - } - if (other.repeatedInt64_.Count != 0) { - result.repeatedInt64_.Add(other.repeatedInt64_); - } - if (other.repeatedUint32_.Count != 0) { - result.repeatedUint32_.Add(other.repeatedUint32_); - } - if (other.repeatedUint64_.Count != 0) { - result.repeatedUint64_.Add(other.repeatedUint64_); - } - if (other.repeatedSint32_.Count != 0) { - result.repeatedSint32_.Add(other.repeatedSint32_); - } - if (other.repeatedSint64_.Count != 0) { - result.repeatedSint64_.Add(other.repeatedSint64_); - } - if (other.repeatedFixed32_.Count != 0) { - result.repeatedFixed32_.Add(other.repeatedFixed32_); - } - if (other.repeatedFixed64_.Count != 0) { - result.repeatedFixed64_.Add(other.repeatedFixed64_); - } - if (other.repeatedSfixed32_.Count != 0) { - result.repeatedSfixed32_.Add(other.repeatedSfixed32_); - } - if (other.repeatedSfixed64_.Count != 0) { - result.repeatedSfixed64_.Add(other.repeatedSfixed64_); - } - if (other.repeatedFloat_.Count != 0) { - result.repeatedFloat_.Add(other.repeatedFloat_); - } - if (other.repeatedDouble_.Count != 0) { - result.repeatedDouble_.Add(other.repeatedDouble_); - } - if (other.repeatedBool_.Count != 0) { - result.repeatedBool_.Add(other.repeatedBool_); - } - if (other.repeatedString_.Count != 0) { - result.repeatedString_.Add(other.repeatedString_); - } - if (other.repeatedBytes_.Count != 0) { - result.repeatedBytes_.Add(other.repeatedBytes_); - } - if (other.repeatedGroup_.Count != 0) { - result.repeatedGroup_.Add(other.repeatedGroup_); - } - if (other.repeatedNestedMessage_.Count != 0) { - result.repeatedNestedMessage_.Add(other.repeatedNestedMessage_); - } - if (other.repeatedForeignMessage_.Count != 0) { - result.repeatedForeignMessage_.Add(other.repeatedForeignMessage_); - } - if (other.repeatedImportMessage_.Count != 0) { - result.repeatedImportMessage_.Add(other.repeatedImportMessage_); - } - if (other.repeatedNestedEnum_.Count != 0) { - result.repeatedNestedEnum_.Add(other.repeatedNestedEnum_); - } - if (other.repeatedForeignEnum_.Count != 0) { - result.repeatedForeignEnum_.Add(other.repeatedForeignEnum_); - } - if (other.repeatedImportEnum_.Count != 0) { - result.repeatedImportEnum_.Add(other.repeatedImportEnum_); - } - if (other.repeatedStringPiece_.Count != 0) { - result.repeatedStringPiece_.Add(other.repeatedStringPiece_); - } - if (other.repeatedCord_.Count != 0) { - result.repeatedCord_.Add(other.repeatedCord_); - } - if (other.HasDefaultInt32) { - DefaultInt32 = other.DefaultInt32; - } - if (other.HasDefaultInt64) { - DefaultInt64 = other.DefaultInt64; - } - if (other.HasDefaultUint32) { - DefaultUint32 = other.DefaultUint32; - } - if (other.HasDefaultUint64) { - DefaultUint64 = other.DefaultUint64; - } - if (other.HasDefaultSint32) { - DefaultSint32 = other.DefaultSint32; - } - if (other.HasDefaultSint64) { - DefaultSint64 = other.DefaultSint64; - } - if (other.HasDefaultFixed32) { - DefaultFixed32 = other.DefaultFixed32; - } - if (other.HasDefaultFixed64) { - DefaultFixed64 = other.DefaultFixed64; - } - if (other.HasDefaultSfixed32) { - DefaultSfixed32 = other.DefaultSfixed32; - } - if (other.HasDefaultSfixed64) { - DefaultSfixed64 = other.DefaultSfixed64; - } - if (other.HasDefaultFloat) { - DefaultFloat = other.DefaultFloat; - } - if (other.HasDefaultDouble) { - DefaultDouble = other.DefaultDouble; - } - if (other.HasDefaultBool) { - DefaultBool = other.DefaultBool; - } - if (other.HasDefaultString) { - DefaultString = other.DefaultString; - } - if (other.HasDefaultBytes) { - DefaultBytes = other.DefaultBytes; - } - if (other.HasDefaultNestedEnum) { - DefaultNestedEnum = other.DefaultNestedEnum; - } - if (other.HasDefaultForeignEnum) { - DefaultForeignEnum = other.DefaultForeignEnum; - } - if (other.HasDefaultImportEnum) { - DefaultImportEnum = other.DefaultImportEnum; - } - if (other.HasDefaultStringPiece) { - DefaultStringPiece = other.DefaultStringPiece; - } - if (other.HasDefaultCord) { - DefaultCord = other.DefaultCord; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testAllTypesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testAllTypesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); - break; - } - case 16: { - result.hasOptionalInt64 = input.ReadInt64(ref result.optionalInt64_); - break; - } - case 24: { - result.hasOptionalUint32 = input.ReadUInt32(ref result.optionalUint32_); - break; - } - case 32: { - result.hasOptionalUint64 = input.ReadUInt64(ref result.optionalUint64_); - break; - } - case 40: { - result.hasOptionalSint32 = input.ReadSInt32(ref result.optionalSint32_); - break; - } - case 48: { - result.hasOptionalSint64 = input.ReadSInt64(ref result.optionalSint64_); - break; - } - case 61: { - result.hasOptionalFixed32 = input.ReadFixed32(ref result.optionalFixed32_); - break; - } - case 65: { - result.hasOptionalFixed64 = input.ReadFixed64(ref result.optionalFixed64_); - break; - } - case 77: { - result.hasOptionalSfixed32 = input.ReadSFixed32(ref result.optionalSfixed32_); - break; - } - case 81: { - result.hasOptionalSfixed64 = input.ReadSFixed64(ref result.optionalSfixed64_); - break; - } - case 93: { - result.hasOptionalFloat = input.ReadFloat(ref result.optionalFloat_); - break; - } - case 97: { - result.hasOptionalDouble = input.ReadDouble(ref result.optionalDouble_); - break; - } - case 104: { - result.hasOptionalBool = input.ReadBool(ref result.optionalBool_); - break; - } - case 114: { - result.hasOptionalString = input.ReadString(ref result.optionalString_); - break; - } - case 122: { - result.hasOptionalBytes = input.ReadBytes(ref result.optionalBytes_); - break; - } - case 131: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.CreateBuilder(); - if (result.hasOptionalGroup) { - subBuilder.MergeFrom(OptionalGroup); - } - input.ReadGroup(16, subBuilder, extensionRegistry); - OptionalGroup = subBuilder.BuildPartial(); - break; - } - case 146: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); - if (result.hasOptionalNestedMessage) { - subBuilder.MergeFrom(OptionalNestedMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalNestedMessage = subBuilder.BuildPartial(); - break; - } - case 154: { - global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); - if (result.hasOptionalForeignMessage) { - subBuilder.MergeFrom(OptionalForeignMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalForeignMessage = subBuilder.BuildPartial(); - break; - } - case 162: { - global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder(); - if (result.hasOptionalImportMessage) { - subBuilder.MergeFrom(OptionalImportMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalImportMessage = subBuilder.BuildPartial(); - break; - } - case 168: { - object unknown; - if(input.ReadEnum(ref result.optionalNestedEnum_, out unknown)) { - result.hasOptionalNestedEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(21, (ulong)(int)unknown); - } - break; - } - case 176: { - object unknown; - if(input.ReadEnum(ref result.optionalForeignEnum_, out unknown)) { - result.hasOptionalForeignEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(22, (ulong)(int)unknown); - } - break; - } - case 184: { - object unknown; - if(input.ReadEnum(ref result.optionalImportEnum_, out unknown)) { - result.hasOptionalImportEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(23, (ulong)(int)unknown); - } - break; - } - case 194: { - result.hasOptionalStringPiece = input.ReadString(ref result.optionalStringPiece_); - break; - } - case 202: { - result.hasOptionalCord = input.ReadString(ref result.optionalCord_); - break; - } - case 250: - case 248: { - input.ReadInt32Array(tag, field_name, result.repeatedInt32_); - break; - } - case 258: - case 256: { - input.ReadInt64Array(tag, field_name, result.repeatedInt64_); - break; - } - case 266: - case 264: { - input.ReadUInt32Array(tag, field_name, result.repeatedUint32_); - break; - } - case 274: - case 272: { - input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); - break; - } - case 282: - case 280: { - input.ReadSInt32Array(tag, field_name, result.repeatedSint32_); - break; - } - case 290: - case 288: { - input.ReadSInt64Array(tag, field_name, result.repeatedSint64_); - break; - } - case 298: - case 301: { - input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); - break; - } - case 306: - case 305: { - input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); - break; - } - case 314: - case 317: { - input.ReadSFixed32Array(tag, field_name, result.repeatedSfixed32_); - break; - } - case 322: - case 321: { - input.ReadSFixed64Array(tag, field_name, result.repeatedSfixed64_); - break; - } - case 330: - case 333: { - input.ReadFloatArray(tag, field_name, result.repeatedFloat_); - break; - } - case 338: - case 337: { - input.ReadDoubleArray(tag, field_name, result.repeatedDouble_); - break; - } - case 346: - case 344: { - input.ReadBoolArray(tag, field_name, result.repeatedBool_); - break; - } - case 354: { - input.ReadStringArray(tag, field_name, result.repeatedString_); - break; - } - case 362: { - input.ReadBytesArray(tag, field_name, result.repeatedBytes_); - break; - } - case 371: { - input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance, extensionRegistry); - break; - } - case 386: { - input.ReadMessageArray(tag, field_name, result.repeatedNestedMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance, extensionRegistry); - break; - } - case 394: { - input.ReadMessageArray(tag, field_name, result.repeatedForeignMessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); - break; - } - case 402: { - input.ReadMessageArray(tag, field_name, result.repeatedImportMessage_, global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance, extensionRegistry); - break; - } - case 410: - case 408: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedNestedEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(51, (ulong)(int)rawValue); - } - break; - } - case 418: - case 416: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedForeignEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(52, (ulong)(int)rawValue); - } - break; - } - case 426: - case 424: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedImportEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(53, (ulong)(int)rawValue); - } - break; - } - case 434: { - input.ReadStringArray(tag, field_name, result.repeatedStringPiece_); - break; - } - case 442: { - input.ReadStringArray(tag, field_name, result.repeatedCord_); - break; - } - case 488: { - result.hasDefaultInt32 = input.ReadInt32(ref result.defaultInt32_); - break; - } - case 496: { - result.hasDefaultInt64 = input.ReadInt64(ref result.defaultInt64_); - break; - } - case 504: { - result.hasDefaultUint32 = input.ReadUInt32(ref result.defaultUint32_); - break; - } - case 512: { - result.hasDefaultUint64 = input.ReadUInt64(ref result.defaultUint64_); - break; - } - case 520: { - result.hasDefaultSint32 = input.ReadSInt32(ref result.defaultSint32_); - break; - } - case 528: { - result.hasDefaultSint64 = input.ReadSInt64(ref result.defaultSint64_); - break; - } - case 541: { - result.hasDefaultFixed32 = input.ReadFixed32(ref result.defaultFixed32_); - break; - } - case 545: { - result.hasDefaultFixed64 = input.ReadFixed64(ref result.defaultFixed64_); - break; - } - case 557: { - result.hasDefaultSfixed32 = input.ReadSFixed32(ref result.defaultSfixed32_); - break; - } - case 561: { - result.hasDefaultSfixed64 = input.ReadSFixed64(ref result.defaultSfixed64_); - break; - } - case 573: { - result.hasDefaultFloat = input.ReadFloat(ref result.defaultFloat_); - break; - } - case 577: { - result.hasDefaultDouble = input.ReadDouble(ref result.defaultDouble_); - break; - } - case 584: { - result.hasDefaultBool = input.ReadBool(ref result.defaultBool_); - break; - } - case 594: { - result.hasDefaultString = input.ReadString(ref result.defaultString_); - break; - } - case 602: { - result.hasDefaultBytes = input.ReadBytes(ref result.defaultBytes_); - break; - } - case 648: { - object unknown; - if(input.ReadEnum(ref result.defaultNestedEnum_, out unknown)) { - result.hasDefaultNestedEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(81, (ulong)(int)unknown); - } - break; - } - case 656: { - object unknown; - if(input.ReadEnum(ref result.defaultForeignEnum_, out unknown)) { - result.hasDefaultForeignEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(82, (ulong)(int)unknown); - } - break; - } - case 664: { - object unknown; - if(input.ReadEnum(ref result.defaultImportEnum_, out unknown)) { - result.hasDefaultImportEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(83, (ulong)(int)unknown); - } - break; - } - case 674: { - result.hasDefaultStringPiece = input.ReadString(ref result.defaultStringPiece_); - break; - } - case 682: { - result.hasDefaultCord = input.ReadString(ref result.defaultCord_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasOptionalInt32 { - get { return result.hasOptionalInt32; } - } - public int OptionalInt32 { - get { return result.OptionalInt32; } - set { SetOptionalInt32(value); } - } - public Builder SetOptionalInt32(int value) { - PrepareBuilder(); - result.hasOptionalInt32 = true; - result.optionalInt32_ = value; - return this; - } - public Builder ClearOptionalInt32() { - PrepareBuilder(); - result.hasOptionalInt32 = false; - result.optionalInt32_ = 0; - return this; - } - - public bool HasOptionalInt64 { - get { return result.hasOptionalInt64; } - } - public long OptionalInt64 { - get { return result.OptionalInt64; } - set { SetOptionalInt64(value); } - } - public Builder SetOptionalInt64(long value) { - PrepareBuilder(); - result.hasOptionalInt64 = true; - result.optionalInt64_ = value; - return this; - } - public Builder ClearOptionalInt64() { - PrepareBuilder(); - result.hasOptionalInt64 = false; - result.optionalInt64_ = 0L; - return this; - } - - public bool HasOptionalUint32 { - get { return result.hasOptionalUint32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalUint32 { - get { return result.OptionalUint32; } - set { SetOptionalUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalUint32(uint value) { - PrepareBuilder(); - result.hasOptionalUint32 = true; - result.optionalUint32_ = value; - return this; - } - public Builder ClearOptionalUint32() { - PrepareBuilder(); - result.hasOptionalUint32 = false; - result.optionalUint32_ = 0; - return this; - } - - public bool HasOptionalUint64 { - get { return result.hasOptionalUint64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalUint64 { - get { return result.OptionalUint64; } - set { SetOptionalUint64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalUint64(ulong value) { - PrepareBuilder(); - result.hasOptionalUint64 = true; - result.optionalUint64_ = value; - return this; - } - public Builder ClearOptionalUint64() { - PrepareBuilder(); - result.hasOptionalUint64 = false; - result.optionalUint64_ = 0UL; - return this; - } - - public bool HasOptionalSint32 { - get { return result.hasOptionalSint32; } - } - public int OptionalSint32 { - get { return result.OptionalSint32; } - set { SetOptionalSint32(value); } - } - public Builder SetOptionalSint32(int value) { - PrepareBuilder(); - result.hasOptionalSint32 = true; - result.optionalSint32_ = value; - return this; - } - public Builder ClearOptionalSint32() { - PrepareBuilder(); - result.hasOptionalSint32 = false; - result.optionalSint32_ = 0; - return this; - } - - public bool HasOptionalSint64 { - get { return result.hasOptionalSint64; } - } - public long OptionalSint64 { - get { return result.OptionalSint64; } - set { SetOptionalSint64(value); } - } - public Builder SetOptionalSint64(long value) { - PrepareBuilder(); - result.hasOptionalSint64 = true; - result.optionalSint64_ = value; - return this; - } - public Builder ClearOptionalSint64() { - PrepareBuilder(); - result.hasOptionalSint64 = false; - result.optionalSint64_ = 0; - return this; - } - - public bool HasOptionalFixed32 { - get { return result.hasOptionalFixed32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalFixed32 { - get { return result.OptionalFixed32; } - set { SetOptionalFixed32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalFixed32(uint value) { - PrepareBuilder(); - result.hasOptionalFixed32 = true; - result.optionalFixed32_ = value; - return this; - } - public Builder ClearOptionalFixed32() { - PrepareBuilder(); - result.hasOptionalFixed32 = false; - result.optionalFixed32_ = 0; - return this; - } - - public bool HasOptionalFixed64 { - get { return result.hasOptionalFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalFixed64 { - get { return result.OptionalFixed64; } - set { SetOptionalFixed64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalFixed64(ulong value) { - PrepareBuilder(); - result.hasOptionalFixed64 = true; - result.optionalFixed64_ = value; - return this; - } - public Builder ClearOptionalFixed64() { - PrepareBuilder(); - result.hasOptionalFixed64 = false; - result.optionalFixed64_ = 0; - return this; - } - - public bool HasOptionalSfixed32 { - get { return result.hasOptionalSfixed32; } - } - public int OptionalSfixed32 { - get { return result.OptionalSfixed32; } - set { SetOptionalSfixed32(value); } - } - public Builder SetOptionalSfixed32(int value) { - PrepareBuilder(); - result.hasOptionalSfixed32 = true; - result.optionalSfixed32_ = value; - return this; - } - public Builder ClearOptionalSfixed32() { - PrepareBuilder(); - result.hasOptionalSfixed32 = false; - result.optionalSfixed32_ = 0; - return this; - } - - public bool HasOptionalSfixed64 { - get { return result.hasOptionalSfixed64; } - } - public long OptionalSfixed64 { - get { return result.OptionalSfixed64; } - set { SetOptionalSfixed64(value); } - } - public Builder SetOptionalSfixed64(long value) { - PrepareBuilder(); - result.hasOptionalSfixed64 = true; - result.optionalSfixed64_ = value; - return this; - } - public Builder ClearOptionalSfixed64() { - PrepareBuilder(); - result.hasOptionalSfixed64 = false; - result.optionalSfixed64_ = 0; - return this; - } - - public bool HasOptionalFloat { - get { return result.hasOptionalFloat; } - } - public float OptionalFloat { - get { return result.OptionalFloat; } - set { SetOptionalFloat(value); } - } - public Builder SetOptionalFloat(float value) { - PrepareBuilder(); - result.hasOptionalFloat = true; - result.optionalFloat_ = value; - return this; - } - public Builder ClearOptionalFloat() { - PrepareBuilder(); - result.hasOptionalFloat = false; - result.optionalFloat_ = 0F; - return this; - } - - public bool HasOptionalDouble { - get { return result.hasOptionalDouble; } - } - public double OptionalDouble { - get { return result.OptionalDouble; } - set { SetOptionalDouble(value); } - } - public Builder SetOptionalDouble(double value) { - PrepareBuilder(); - result.hasOptionalDouble = true; - result.optionalDouble_ = value; - return this; - } - public Builder ClearOptionalDouble() { - PrepareBuilder(); - result.hasOptionalDouble = false; - result.optionalDouble_ = 0D; - return this; - } - - public bool HasOptionalBool { - get { return result.hasOptionalBool; } - } - public bool OptionalBool { - get { return result.OptionalBool; } - set { SetOptionalBool(value); } - } - public Builder SetOptionalBool(bool value) { - PrepareBuilder(); - result.hasOptionalBool = true; - result.optionalBool_ = value; - return this; - } - public Builder ClearOptionalBool() { - PrepareBuilder(); - result.hasOptionalBool = false; - result.optionalBool_ = false; - return this; - } - - public bool HasOptionalString { - get { return result.hasOptionalString; } - } - public string OptionalString { - get { return result.OptionalString; } - set { SetOptionalString(value); } - } - public Builder SetOptionalString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalString = true; - result.optionalString_ = value; - return this; - } - public Builder ClearOptionalString() { - PrepareBuilder(); - result.hasOptionalString = false; - result.optionalString_ = ""; - return this; - } - - public bool HasOptionalBytes { - get { return result.hasOptionalBytes; } - } - public pb::ByteString OptionalBytes { - get { return result.OptionalBytes; } - set { SetOptionalBytes(value); } - } - public Builder SetOptionalBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalBytes = true; - result.optionalBytes_ = value; - return this; - } - public Builder ClearOptionalBytes() { - PrepareBuilder(); - result.hasOptionalBytes = false; - result.optionalBytes_ = pb::ByteString.Empty; - return this; - } - - public bool HasOptionalGroup { - get { return result.hasOptionalGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup OptionalGroup { - get { return result.OptionalGroup; } - set { SetOptionalGroup(value); } - } - public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalGroup = true; - result.optionalGroup_ = value; - return this; - } - public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalGroup = true; - result.optionalGroup_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalGroup && - result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance) { - result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial(); - } else { - result.optionalGroup_ = value; - } - result.hasOptionalGroup = true; - return this; - } - public Builder ClearOptionalGroup() { - PrepareBuilder(); - result.hasOptionalGroup = false; - result.optionalGroup_ = null; - return this; - } - - public bool HasOptionalNestedMessage { - get { return result.hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage { - get { return result.OptionalNestedMessage; } - set { SetOptionalNestedMessage(value); } - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = value; - return this; - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalNestedMessage && - result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { - result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalNestedMessage_ = value; - } - result.hasOptionalNestedMessage = true; - return this; - } - public Builder ClearOptionalNestedMessage() { - PrepareBuilder(); - result.hasOptionalNestedMessage = false; - result.optionalNestedMessage_ = null; - return this; - } - - public bool HasOptionalForeignMessage { - get { return result.hasOptionalForeignMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage { - get { return result.OptionalForeignMessage; } - set { SetOptionalForeignMessage(value); } - } - public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalForeignMessage = true; - result.optionalForeignMessage_ = value; - return this; - } - public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalForeignMessage = true; - result.optionalForeignMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalForeignMessage && - result.optionalForeignMessage_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) { - result.optionalForeignMessage_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.optionalForeignMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalForeignMessage_ = value; - } - result.hasOptionalForeignMessage = true; - return this; - } - public Builder ClearOptionalForeignMessage() { - PrepareBuilder(); - result.hasOptionalForeignMessage = false; - result.optionalForeignMessage_ = null; - return this; - } - - public bool HasOptionalImportMessage { - get { return result.hasOptionalImportMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessage OptionalImportMessage { - get { return result.OptionalImportMessage; } - set { SetOptionalImportMessage(value); } - } - public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalImportMessage = true; - result.optionalImportMessage_ = value; - return this; - } - public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalImportMessage = true; - result.optionalImportMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalImportMessage && - result.optionalImportMessage_ != global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance) { - result.optionalImportMessage_ = global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder(result.optionalImportMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalImportMessage_ = value; - } - result.hasOptionalImportMessage = true; - return this; - } - public Builder ClearOptionalImportMessage() { - PrepareBuilder(); - result.hasOptionalImportMessage = false; - result.optionalImportMessage_ = null; - return this; - } - - public bool HasOptionalNestedEnum { - get { return result.hasOptionalNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum { - get { return result.OptionalNestedEnum; } - set { SetOptionalNestedEnum(value); } - } - public Builder SetOptionalNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.hasOptionalNestedEnum = true; - result.optionalNestedEnum_ = value; - return this; - } - public Builder ClearOptionalNestedEnum() { - PrepareBuilder(); - result.hasOptionalNestedEnum = false; - result.optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; - return this; - } - - public bool HasOptionalForeignEnum { - get { return result.hasOptionalForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum { - get { return result.OptionalForeignEnum; } - set { SetOptionalForeignEnum(value); } - } - public Builder SetOptionalForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.hasOptionalForeignEnum = true; - result.optionalForeignEnum_ = value; - return this; - } - public Builder ClearOptionalForeignEnum() { - PrepareBuilder(); - result.hasOptionalForeignEnum = false; - result.optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - return this; - } - - public bool HasOptionalImportEnum { - get { return result.hasOptionalImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum OptionalImportEnum { - get { return result.OptionalImportEnum; } - set { SetOptionalImportEnum(value); } - } - public Builder SetOptionalImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { - PrepareBuilder(); - result.hasOptionalImportEnum = true; - result.optionalImportEnum_ = value; - return this; - } - public Builder ClearOptionalImportEnum() { - PrepareBuilder(); - result.hasOptionalImportEnum = false; - result.optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_FOO; - return this; - } - - public bool HasOptionalStringPiece { - get { return result.hasOptionalStringPiece; } - } - public string OptionalStringPiece { - get { return result.OptionalStringPiece; } - set { SetOptionalStringPiece(value); } - } - public Builder SetOptionalStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalStringPiece = true; - result.optionalStringPiece_ = value; - return this; - } - public Builder ClearOptionalStringPiece() { - PrepareBuilder(); - result.hasOptionalStringPiece = false; - result.optionalStringPiece_ = ""; - return this; - } - - public bool HasOptionalCord { - get { return result.hasOptionalCord; } - } - public string OptionalCord { - get { return result.OptionalCord; } - set { SetOptionalCord(value); } - } - public Builder SetOptionalCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalCord = true; - result.optionalCord_ = value; - return this; - } - public Builder ClearOptionalCord() { - PrepareBuilder(); - result.hasOptionalCord = false; - result.optionalCord_ = ""; - return this; - } - - public pbc::IPopsicleList RepeatedInt32List { - get { return PrepareBuilder().repeatedInt32_; } - } - public int RepeatedInt32Count { - get { return result.RepeatedInt32Count; } - } - public int GetRepeatedInt32(int index) { - return result.GetRepeatedInt32(index); - } - public Builder SetRepeatedInt32(int index, int value) { - PrepareBuilder(); - result.repeatedInt32_[index] = value; - return this; - } - public Builder AddRepeatedInt32(int value) { - PrepareBuilder(); - result.repeatedInt32_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt32_.Add(values); - return this; - } - public Builder ClearRepeatedInt32() { - PrepareBuilder(); - result.repeatedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedInt64List { - get { return PrepareBuilder().repeatedInt64_; } - } - public int RepeatedInt64Count { - get { return result.RepeatedInt64Count; } - } - public long GetRepeatedInt64(int index) { - return result.GetRepeatedInt64(index); - } - public Builder SetRepeatedInt64(int index, long value) { - PrepareBuilder(); - result.repeatedInt64_[index] = value; - return this; - } - public Builder AddRepeatedInt64(long value) { - PrepareBuilder(); - result.repeatedInt64_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt64_.Add(values); - return this; - } - public Builder ClearRepeatedInt64() { - PrepareBuilder(); - result.repeatedInt64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedUint32List { - get { return PrepareBuilder().repeatedUint32_; } - } - public int RepeatedUint32Count { - get { return result.RepeatedUint32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedUint32(int index) { - return result.GetRepeatedUint32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedUint32(int index, uint value) { - PrepareBuilder(); - result.repeatedUint32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedUint32(uint value) { - PrepareBuilder(); - result.repeatedUint32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedUint32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedUint32_.Add(values); - return this; - } - public Builder ClearRepeatedUint32() { - PrepareBuilder(); - result.repeatedUint32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedUint64List { - get { return PrepareBuilder().repeatedUint64_; } - } - public int RepeatedUint64Count { - get { return result.RepeatedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return result.GetRepeatedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedUint64(int index, ulong value) { - PrepareBuilder(); - result.repeatedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedUint64(ulong value) { - PrepareBuilder(); - result.repeatedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedUint64_.Add(values); - return this; - } - public Builder ClearRepeatedUint64() { - PrepareBuilder(); - result.repeatedUint64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSint32List { - get { return PrepareBuilder().repeatedSint32_; } - } - public int RepeatedSint32Count { - get { return result.RepeatedSint32Count; } - } - public int GetRepeatedSint32(int index) { - return result.GetRepeatedSint32(index); - } - public Builder SetRepeatedSint32(int index, int value) { - PrepareBuilder(); - result.repeatedSint32_[index] = value; - return this; - } - public Builder AddRepeatedSint32(int value) { - PrepareBuilder(); - result.repeatedSint32_.Add(value); - return this; - } - public Builder AddRangeRepeatedSint32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSint32_.Add(values); - return this; - } - public Builder ClearRepeatedSint32() { - PrepareBuilder(); - result.repeatedSint32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSint64List { - get { return PrepareBuilder().repeatedSint64_; } - } - public int RepeatedSint64Count { - get { return result.RepeatedSint64Count; } - } - public long GetRepeatedSint64(int index) { - return result.GetRepeatedSint64(index); - } - public Builder SetRepeatedSint64(int index, long value) { - PrepareBuilder(); - result.repeatedSint64_[index] = value; - return this; - } - public Builder AddRepeatedSint64(long value) { - PrepareBuilder(); - result.repeatedSint64_.Add(value); - return this; - } - public Builder AddRangeRepeatedSint64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSint64_.Add(values); - return this; - } - public Builder ClearRepeatedSint64() { - PrepareBuilder(); - result.repeatedSint64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed32List { - get { return PrepareBuilder().repeatedFixed32_; } - } - public int RepeatedFixed32Count { - get { return result.RepeatedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return result.GetRepeatedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed32(int index, uint value) { - PrepareBuilder(); - result.repeatedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed32(uint value) { - PrepareBuilder(); - result.repeatedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed32_.Add(values); - return this; - } - public Builder ClearRepeatedFixed32() { - PrepareBuilder(); - result.repeatedFixed32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed64List { - get { return PrepareBuilder().repeatedFixed64_; } - } - public int RepeatedFixed64Count { - get { return result.RepeatedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return result.GetRepeatedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed64(int index, ulong value) { - PrepareBuilder(); - result.repeatedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed64(ulong value) { - PrepareBuilder(); - result.repeatedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed64_.Add(values); - return this; - } - public Builder ClearRepeatedFixed64() { - PrepareBuilder(); - result.repeatedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSfixed32List { - get { return PrepareBuilder().repeatedSfixed32_; } - } - public int RepeatedSfixed32Count { - get { return result.RepeatedSfixed32Count; } - } - public int GetRepeatedSfixed32(int index) { - return result.GetRepeatedSfixed32(index); - } - public Builder SetRepeatedSfixed32(int index, int value) { - PrepareBuilder(); - result.repeatedSfixed32_[index] = value; - return this; - } - public Builder AddRepeatedSfixed32(int value) { - PrepareBuilder(); - result.repeatedSfixed32_.Add(value); - return this; - } - public Builder AddRangeRepeatedSfixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSfixed32_.Add(values); - return this; - } - public Builder ClearRepeatedSfixed32() { - PrepareBuilder(); - result.repeatedSfixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSfixed64List { - get { return PrepareBuilder().repeatedSfixed64_; } - } - public int RepeatedSfixed64Count { - get { return result.RepeatedSfixed64Count; } - } - public long GetRepeatedSfixed64(int index) { - return result.GetRepeatedSfixed64(index); - } - public Builder SetRepeatedSfixed64(int index, long value) { - PrepareBuilder(); - result.repeatedSfixed64_[index] = value; - return this; - } - public Builder AddRepeatedSfixed64(long value) { - PrepareBuilder(); - result.repeatedSfixed64_.Add(value); - return this; - } - public Builder AddRangeRepeatedSfixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSfixed64_.Add(values); - return this; - } - public Builder ClearRepeatedSfixed64() { - PrepareBuilder(); - result.repeatedSfixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedFloatList { - get { return PrepareBuilder().repeatedFloat_; } - } - public int RepeatedFloatCount { - get { return result.RepeatedFloatCount; } - } - public float GetRepeatedFloat(int index) { - return result.GetRepeatedFloat(index); - } - public Builder SetRepeatedFloat(int index, float value) { - PrepareBuilder(); - result.repeatedFloat_[index] = value; - return this; - } - public Builder AddRepeatedFloat(float value) { - PrepareBuilder(); - result.repeatedFloat_.Add(value); - return this; - } - public Builder AddRangeRepeatedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFloat_.Add(values); - return this; - } - public Builder ClearRepeatedFloat() { - PrepareBuilder(); - result.repeatedFloat_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedDoubleList { - get { return PrepareBuilder().repeatedDouble_; } - } - public int RepeatedDoubleCount { - get { return result.RepeatedDoubleCount; } - } - public double GetRepeatedDouble(int index) { - return result.GetRepeatedDouble(index); - } - public Builder SetRepeatedDouble(int index, double value) { - PrepareBuilder(); - result.repeatedDouble_[index] = value; - return this; - } - public Builder AddRepeatedDouble(double value) { - PrepareBuilder(); - result.repeatedDouble_.Add(value); - return this; - } - public Builder AddRangeRepeatedDouble(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedDouble_.Add(values); - return this; - } - public Builder ClearRepeatedDouble() { - PrepareBuilder(); - result.repeatedDouble_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedBoolList { - get { return PrepareBuilder().repeatedBool_; } - } - public int RepeatedBoolCount { - get { return result.RepeatedBoolCount; } - } - public bool GetRepeatedBool(int index) { - return result.GetRepeatedBool(index); - } - public Builder SetRepeatedBool(int index, bool value) { - PrepareBuilder(); - result.repeatedBool_[index] = value; - return this; - } - public Builder AddRepeatedBool(bool value) { - PrepareBuilder(); - result.repeatedBool_.Add(value); - return this; - } - public Builder AddRangeRepeatedBool(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedBool_.Add(values); - return this; - } - public Builder ClearRepeatedBool() { - PrepareBuilder(); - result.repeatedBool_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringList { - get { return PrepareBuilder().repeatedString_; } - } - public int RepeatedStringCount { - get { return result.RepeatedStringCount; } - } - public string GetRepeatedString(int index) { - return result.GetRepeatedString(index); - } - public Builder SetRepeatedString(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedString_[index] = value; - return this; - } - public Builder AddRepeatedString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedString_.Add(value); - return this; - } - public Builder AddRangeRepeatedString(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedString_.Add(values); - return this; - } - public Builder ClearRepeatedString() { - PrepareBuilder(); - result.repeatedString_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedBytesList { - get { return PrepareBuilder().repeatedBytes_; } - } - public int RepeatedBytesCount { - get { return result.RepeatedBytesCount; } - } - public pb::ByteString GetRepeatedBytes(int index) { - return result.GetRepeatedBytes(index); - } - public Builder SetRepeatedBytes(int index, pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedBytes_[index] = value; - return this; - } - public Builder AddRepeatedBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedBytes_.Add(value); - return this; - } - public Builder AddRangeRepeatedBytes(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedBytes_.Add(values); - return this; - } - public Builder ClearRepeatedBytes() { - PrepareBuilder(); - result.repeatedBytes_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedGroupList { - get { return PrepareBuilder().repeatedGroup_; } - } - public int RepeatedGroupCount { - get { return result.RepeatedGroupCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup GetRepeatedGroup(int index) { - return result.GetRepeatedGroup(index); - } - public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedGroup_[index] = value; - return this; - } - public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedGroup_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedGroup_.Add(value); - return this; - } - public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedGroup_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedGroup(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedGroup_.Add(values); - return this; - } - public Builder ClearRepeatedGroup() { - PrepareBuilder(); - result.repeatedGroup_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedNestedMessageList { - get { return PrepareBuilder().repeatedNestedMessage_; } - } - public int RepeatedNestedMessageCount { - get { return result.RepeatedNestedMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) { - return result.GetRepeatedNestedMessage(index); - } - public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedNestedMessage_[index] = value; - return this; - } - public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedNestedMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedNestedMessage_.Add(value); - return this; - } - public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedNestedMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedNestedMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedNestedMessage_.Add(values); - return this; - } - public Builder ClearRepeatedNestedMessage() { - PrepareBuilder(); - result.repeatedNestedMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedForeignMessageList { - get { return PrepareBuilder().repeatedForeignMessage_; } - } - public int RepeatedForeignMessageCount { - get { return result.RepeatedForeignMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) { - return result.GetRepeatedForeignMessage(index); - } - public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedForeignMessage_[index] = value; - return this; - } - public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedForeignMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedForeignMessage_.Add(value); - return this; - } - public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedForeignMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedForeignMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedForeignMessage_.Add(values); - return this; - } - public Builder ClearRepeatedForeignMessage() { - PrepareBuilder(); - result.repeatedForeignMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedImportMessageList { - get { return PrepareBuilder().repeatedImportMessage_; } - } - public int RepeatedImportMessageCount { - get { return result.RepeatedImportMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessage GetRepeatedImportMessage(int index) { - return result.GetRepeatedImportMessage(index); - } - public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedImportMessage_[index] = value; - return this; - } - public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedImportMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedImportMessage_.Add(value); - return this; - } - public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedImportMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedImportMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedImportMessage_.Add(values); - return this; - } - public Builder ClearRepeatedImportMessage() { - PrepareBuilder(); - result.repeatedImportMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedNestedEnumList { - get { return PrepareBuilder().repeatedNestedEnum_; } - } - public int RepeatedNestedEnumCount { - get { return result.RepeatedNestedEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) { - return result.GetRepeatedNestedEnum(index); - } - public Builder SetRepeatedNestedEnum(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.repeatedNestedEnum_[index] = value; - return this; - } - public Builder AddRepeatedNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.repeatedNestedEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedNestedEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedNestedEnum_.Add(values); - return this; - } - public Builder ClearRepeatedNestedEnum() { - PrepareBuilder(); - result.repeatedNestedEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedForeignEnumList { - get { return PrepareBuilder().repeatedForeignEnum_; } - } - public int RepeatedForeignEnumCount { - get { return result.RepeatedForeignEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) { - return result.GetRepeatedForeignEnum(index); - } - public Builder SetRepeatedForeignEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.repeatedForeignEnum_[index] = value; - return this; - } - public Builder AddRepeatedForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.repeatedForeignEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedForeignEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedForeignEnum_.Add(values); - return this; - } - public Builder ClearRepeatedForeignEnum() { - PrepareBuilder(); - result.repeatedForeignEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedImportEnumList { - get { return PrepareBuilder().repeatedImportEnum_; } - } - public int RepeatedImportEnumCount { - get { return result.RepeatedImportEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum GetRepeatedImportEnum(int index) { - return result.GetRepeatedImportEnum(index); - } - public Builder SetRepeatedImportEnum(int index, global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { - PrepareBuilder(); - result.repeatedImportEnum_[index] = value; - return this; - } - public Builder AddRepeatedImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { - PrepareBuilder(); - result.repeatedImportEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedImportEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedImportEnum_.Add(values); - return this; - } - public Builder ClearRepeatedImportEnum() { - PrepareBuilder(); - result.repeatedImportEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringPieceList { - get { return PrepareBuilder().repeatedStringPiece_; } - } - public int RepeatedStringPieceCount { - get { return result.RepeatedStringPieceCount; } - } - public string GetRepeatedStringPiece(int index) { - return result.GetRepeatedStringPiece(index); - } - public Builder SetRepeatedStringPiece(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPiece_[index] = value; - return this; - } - public Builder AddRepeatedStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPiece_.Add(value); - return this; - } - public Builder AddRangeRepeatedStringPiece(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedStringPiece_.Add(values); - return this; - } - public Builder ClearRepeatedStringPiece() { - PrepareBuilder(); - result.repeatedStringPiece_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedCordList { - get { return PrepareBuilder().repeatedCord_; } - } - public int RepeatedCordCount { - get { return result.RepeatedCordCount; } - } - public string GetRepeatedCord(int index) { - return result.GetRepeatedCord(index); - } - public Builder SetRepeatedCord(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCord_[index] = value; - return this; - } - public Builder AddRepeatedCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCord_.Add(value); - return this; - } - public Builder AddRangeRepeatedCord(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedCord_.Add(values); - return this; - } - public Builder ClearRepeatedCord() { - PrepareBuilder(); - result.repeatedCord_.Clear(); - return this; - } - - public bool HasDefaultInt32 { - get { return result.hasDefaultInt32; } - } - public int DefaultInt32 { - get { return result.DefaultInt32; } - set { SetDefaultInt32(value); } - } - public Builder SetDefaultInt32(int value) { - PrepareBuilder(); - result.hasDefaultInt32 = true; - result.defaultInt32_ = value; - return this; - } - public Builder ClearDefaultInt32() { - PrepareBuilder(); - result.hasDefaultInt32 = false; - result.defaultInt32_ = 41; - return this; - } - - public bool HasDefaultInt64 { - get { return result.hasDefaultInt64; } - } - public long DefaultInt64 { - get { return result.DefaultInt64; } - set { SetDefaultInt64(value); } - } - public Builder SetDefaultInt64(long value) { - PrepareBuilder(); - result.hasDefaultInt64 = true; - result.defaultInt64_ = value; - return this; - } - public Builder ClearDefaultInt64() { - PrepareBuilder(); - result.hasDefaultInt64 = false; - result.defaultInt64_ = 42L; - return this; - } - - public bool HasDefaultUint32 { - get { return result.hasDefaultUint32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultUint32 { - get { return result.DefaultUint32; } - set { SetDefaultUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultUint32(uint value) { - PrepareBuilder(); - result.hasDefaultUint32 = true; - result.defaultUint32_ = value; - return this; - } - public Builder ClearDefaultUint32() { - PrepareBuilder(); - result.hasDefaultUint32 = false; - result.defaultUint32_ = 43; - return this; - } - - public bool HasDefaultUint64 { - get { return result.hasDefaultUint64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultUint64 { - get { return result.DefaultUint64; } - set { SetDefaultUint64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultUint64(ulong value) { - PrepareBuilder(); - result.hasDefaultUint64 = true; - result.defaultUint64_ = value; - return this; - } - public Builder ClearDefaultUint64() { - PrepareBuilder(); - result.hasDefaultUint64 = false; - result.defaultUint64_ = 44UL; - return this; - } - - public bool HasDefaultSint32 { - get { return result.hasDefaultSint32; } - } - public int DefaultSint32 { - get { return result.DefaultSint32; } - set { SetDefaultSint32(value); } - } - public Builder SetDefaultSint32(int value) { - PrepareBuilder(); - result.hasDefaultSint32 = true; - result.defaultSint32_ = value; - return this; - } - public Builder ClearDefaultSint32() { - PrepareBuilder(); - result.hasDefaultSint32 = false; - result.defaultSint32_ = -45; - return this; - } - - public bool HasDefaultSint64 { - get { return result.hasDefaultSint64; } - } - public long DefaultSint64 { - get { return result.DefaultSint64; } - set { SetDefaultSint64(value); } - } - public Builder SetDefaultSint64(long value) { - PrepareBuilder(); - result.hasDefaultSint64 = true; - result.defaultSint64_ = value; - return this; - } - public Builder ClearDefaultSint64() { - PrepareBuilder(); - result.hasDefaultSint64 = false; - result.defaultSint64_ = 46; - return this; - } - - public bool HasDefaultFixed32 { - get { return result.hasDefaultFixed32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultFixed32 { - get { return result.DefaultFixed32; } - set { SetDefaultFixed32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultFixed32(uint value) { - PrepareBuilder(); - result.hasDefaultFixed32 = true; - result.defaultFixed32_ = value; - return this; - } - public Builder ClearDefaultFixed32() { - PrepareBuilder(); - result.hasDefaultFixed32 = false; - result.defaultFixed32_ = 47; - return this; - } - - public bool HasDefaultFixed64 { - get { return result.hasDefaultFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultFixed64 { - get { return result.DefaultFixed64; } - set { SetDefaultFixed64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultFixed64(ulong value) { - PrepareBuilder(); - result.hasDefaultFixed64 = true; - result.defaultFixed64_ = value; - return this; - } - public Builder ClearDefaultFixed64() { - PrepareBuilder(); - result.hasDefaultFixed64 = false; - result.defaultFixed64_ = 48; - return this; - } - - public bool HasDefaultSfixed32 { - get { return result.hasDefaultSfixed32; } - } - public int DefaultSfixed32 { - get { return result.DefaultSfixed32; } - set { SetDefaultSfixed32(value); } - } - public Builder SetDefaultSfixed32(int value) { - PrepareBuilder(); - result.hasDefaultSfixed32 = true; - result.defaultSfixed32_ = value; - return this; - } - public Builder ClearDefaultSfixed32() { - PrepareBuilder(); - result.hasDefaultSfixed32 = false; - result.defaultSfixed32_ = 49; - return this; - } - - public bool HasDefaultSfixed64 { - get { return result.hasDefaultSfixed64; } - } - public long DefaultSfixed64 { - get { return result.DefaultSfixed64; } - set { SetDefaultSfixed64(value); } - } - public Builder SetDefaultSfixed64(long value) { - PrepareBuilder(); - result.hasDefaultSfixed64 = true; - result.defaultSfixed64_ = value; - return this; - } - public Builder ClearDefaultSfixed64() { - PrepareBuilder(); - result.hasDefaultSfixed64 = false; - result.defaultSfixed64_ = -50; - return this; - } - - public bool HasDefaultFloat { - get { return result.hasDefaultFloat; } - } - public float DefaultFloat { - get { return result.DefaultFloat; } - set { SetDefaultFloat(value); } - } - public Builder SetDefaultFloat(float value) { - PrepareBuilder(); - result.hasDefaultFloat = true; - result.defaultFloat_ = value; - return this; - } - public Builder ClearDefaultFloat() { - PrepareBuilder(); - result.hasDefaultFloat = false; - result.defaultFloat_ = 51.5F; - return this; - } - - public bool HasDefaultDouble { - get { return result.hasDefaultDouble; } - } - public double DefaultDouble { - get { return result.DefaultDouble; } - set { SetDefaultDouble(value); } - } - public Builder SetDefaultDouble(double value) { - PrepareBuilder(); - result.hasDefaultDouble = true; - result.defaultDouble_ = value; - return this; - } - public Builder ClearDefaultDouble() { - PrepareBuilder(); - result.hasDefaultDouble = false; - result.defaultDouble_ = 52000D; - return this; - } - - public bool HasDefaultBool { - get { return result.hasDefaultBool; } - } - public bool DefaultBool { - get { return result.DefaultBool; } - set { SetDefaultBool(value); } - } - public Builder SetDefaultBool(bool value) { - PrepareBuilder(); - result.hasDefaultBool = true; - result.defaultBool_ = value; - return this; - } - public Builder ClearDefaultBool() { - PrepareBuilder(); - result.hasDefaultBool = false; - result.defaultBool_ = true; - return this; - } - - public bool HasDefaultString { - get { return result.hasDefaultString; } - } - public string DefaultString { - get { return result.DefaultString; } - set { SetDefaultString(value); } - } - public Builder SetDefaultString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultString = true; - result.defaultString_ = value; - return this; - } - public Builder ClearDefaultString() { - PrepareBuilder(); - result.hasDefaultString = false; - result.defaultString_ = "hello"; - return this; - } - - public bool HasDefaultBytes { - get { return result.hasDefaultBytes; } - } - public pb::ByteString DefaultBytes { - get { return result.DefaultBytes; } - set { SetDefaultBytes(value); } - } - public Builder SetDefaultBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultBytes = true; - result.defaultBytes_ = value; - return this; - } - public Builder ClearDefaultBytes() { - PrepareBuilder(); - result.hasDefaultBytes = false; - result.defaultBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor.Fields[62].DefaultValue; - return this; - } - - public bool HasDefaultNestedEnum { - get { return result.hasDefaultNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum DefaultNestedEnum { - get { return result.DefaultNestedEnum; } - set { SetDefaultNestedEnum(value); } - } - public Builder SetDefaultNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.hasDefaultNestedEnum = true; - result.defaultNestedEnum_ = value; - return this; - } - public Builder ClearDefaultNestedEnum() { - PrepareBuilder(); - result.hasDefaultNestedEnum = false; - result.defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.BAR; - return this; - } - - public bool HasDefaultForeignEnum { - get { return result.hasDefaultForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum DefaultForeignEnum { - get { return result.DefaultForeignEnum; } - set { SetDefaultForeignEnum(value); } - } - public Builder SetDefaultForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.hasDefaultForeignEnum = true; - result.defaultForeignEnum_ = value; - return this; - } - public Builder ClearDefaultForeignEnum() { - PrepareBuilder(); - result.hasDefaultForeignEnum = false; - result.defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_BAR; - return this; - } - - public bool HasDefaultImportEnum { - get { return result.hasDefaultImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum DefaultImportEnum { - get { return result.DefaultImportEnum; } - set { SetDefaultImportEnum(value); } - } - public Builder SetDefaultImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { - PrepareBuilder(); - result.hasDefaultImportEnum = true; - result.defaultImportEnum_ = value; - return this; - } - public Builder ClearDefaultImportEnum() { - PrepareBuilder(); - result.hasDefaultImportEnum = false; - result.defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_BAR; - return this; - } - - public bool HasDefaultStringPiece { - get { return result.hasDefaultStringPiece; } - } - public string DefaultStringPiece { - get { return result.DefaultStringPiece; } - set { SetDefaultStringPiece(value); } - } - public Builder SetDefaultStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultStringPiece = true; - result.defaultStringPiece_ = value; - return this; - } - public Builder ClearDefaultStringPiece() { - PrepareBuilder(); - result.hasDefaultStringPiece = false; - result.defaultStringPiece_ = "abc"; - return this; - } - - public bool HasDefaultCord { - get { return result.hasDefaultCord; } - } - public string DefaultCord { - get { return result.DefaultCord; } - set { SetDefaultCord(value); } - } - public Builder SetDefaultCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultCord = true; - result.defaultCord_ = value; - return this; - } - public Builder ClearDefaultCord() { - PrepareBuilder(); - result.hasDefaultCord = false; - result.defaultCord_ = "123"; - return this; - } - } - static TestAllTypes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestDeprecatedFields : pb::GeneratedMessage { - private TestDeprecatedFields() { } - private static readonly TestDeprecatedFields defaultInstance = new TestDeprecatedFields().MakeReadOnly(); - private static readonly string[] _testDeprecatedFieldsFieldNames = new string[] { "deprecated_int32" }; - private static readonly uint[] _testDeprecatedFieldsFieldTags = new uint[] { 8 }; - public static TestDeprecatedFields DefaultInstance { - get { return defaultInstance; } - } - - public override TestDeprecatedFields DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestDeprecatedFields ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable; } - } - - public const int DeprecatedInt32FieldNumber = 1; - private bool hasDeprecatedInt32; - private int deprecatedInt32_; - [global::System.ObsoleteAttribute()] - public bool HasDeprecatedInt32 { - get { return hasDeprecatedInt32; } - } - [global::System.ObsoleteAttribute()] - public int DeprecatedInt32 { - get { return deprecatedInt32_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testDeprecatedFieldsFieldNames; - if (hasDeprecatedInt32) { - output.WriteInt32(1, field_names[0], DeprecatedInt32); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasDeprecatedInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(1, DeprecatedInt32); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestDeprecatedFields ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestDeprecatedFields ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestDeprecatedFields ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestDeprecatedFields MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestDeprecatedFields prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestDeprecatedFields cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestDeprecatedFields result; - - private TestDeprecatedFields PrepareBuilder() { - if (resultIsReadOnly) { - TestDeprecatedFields original = result; - result = new TestDeprecatedFields(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestDeprecatedFields MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.Descriptor; } - } - - public override TestDeprecatedFields DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.DefaultInstance; } - } - - public override TestDeprecatedFields BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestDeprecatedFields) { - return MergeFrom((TestDeprecatedFields) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestDeprecatedFields other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasDeprecatedInt32) { - DeprecatedInt32 = other.DeprecatedInt32; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testDeprecatedFieldsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testDeprecatedFieldsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasDeprecatedInt32 = input.ReadInt32(ref result.deprecatedInt32_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - [global::System.ObsoleteAttribute()] - public bool HasDeprecatedInt32 { - get { return result.hasDeprecatedInt32; } - } - [global::System.ObsoleteAttribute()] - public int DeprecatedInt32 { - get { return result.DeprecatedInt32; } - set { SetDeprecatedInt32(value); } - } - [global::System.ObsoleteAttribute()] - public Builder SetDeprecatedInt32(int value) { - PrepareBuilder(); - result.hasDeprecatedInt32 = true; - result.deprecatedInt32_ = value; - return this; - } - [global::System.ObsoleteAttribute()] - public Builder ClearDeprecatedInt32() { - PrepareBuilder(); - result.hasDeprecatedInt32 = false; - result.deprecatedInt32_ = 0; - return this; - } - } - static TestDeprecatedFields() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class ForeignMessage : pb::GeneratedMessage { - private ForeignMessage() { } - private static readonly ForeignMessage defaultInstance = new ForeignMessage().MakeReadOnly(); - private static readonly string[] _foreignMessageFieldNames = new string[] { "c" }; - private static readonly uint[] _foreignMessageFieldTags = new uint[] { 8 }; - public static ForeignMessage DefaultInstance { - get { return defaultInstance; } - } - - public override ForeignMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override ForeignMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_ForeignMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable; } - } - - public const int CFieldNumber = 1; - private bool hasC; - private int c_; - public bool HasC { - get { return hasC; } - } - public int C { - get { return c_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _foreignMessageFieldNames; - if (hasC) { - output.WriteInt32(1, field_names[0], C); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasC) { - size += pb::CodedOutputStream.ComputeInt32Size(1, C); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static ForeignMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ForeignMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ForeignMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ForeignMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ForeignMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ForeignMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static ForeignMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ForeignMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private ForeignMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(ForeignMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(ForeignMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private ForeignMessage result; - - private ForeignMessage PrepareBuilder() { - if (resultIsReadOnly) { - ForeignMessage original = result; - result = new ForeignMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override ForeignMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Descriptor; } - } - - public override ForeignMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } - } - - public override ForeignMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is ForeignMessage) { - return MergeFrom((ForeignMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(ForeignMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasC) { - C = other.C; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_foreignMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _foreignMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasC = input.ReadInt32(ref result.c_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasC { - get { return result.hasC; } - } - public int C { - get { return result.C; } - set { SetC(value); } - } - public Builder SetC(int value) { - PrepareBuilder(); - result.hasC = true; - result.c_ = value; - return this; - } - public Builder ClearC() { - PrepareBuilder(); - result.hasC = false; - result.c_ = 0; - return this; - } - } - static ForeignMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestAllExtensions : pb::ExtendableMessage { - private TestAllExtensions() { } - private static readonly TestAllExtensions defaultInstance = new TestAllExtensions().MakeReadOnly(); - private static readonly string[] _testAllExtensionsFieldNames = new string[] { }; - private static readonly uint[] _testAllExtensionsFieldTags = new uint[] { }; - public static TestAllExtensions DefaultInstance { - get { return defaultInstance; } - } - - public override TestAllExtensions DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestAllExtensions ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllExtensions__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testAllExtensionsFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(536870912, output); - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestAllExtensions ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestAllExtensions ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestAllExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestAllExtensions ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestAllExtensions MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestAllExtensions prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestAllExtensions cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestAllExtensions result; - - private TestAllExtensions PrepareBuilder() { - if (resultIsReadOnly) { - TestAllExtensions original = result; - result = new TestAllExtensions(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestAllExtensions MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.Descriptor; } - } - - public override TestAllExtensions DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.DefaultInstance; } - } - - public override TestAllExtensions BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestAllExtensions) { - return MergeFrom((TestAllExtensions) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestAllExtensions other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testAllExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testAllExtensionsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static TestAllExtensions() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OptionalGroup_extension : pb::GeneratedMessage { - private OptionalGroup_extension() { } - private static readonly OptionalGroup_extension defaultInstance = new OptionalGroup_extension().MakeReadOnly(); - private static readonly string[] _optionalGroupExtensionFieldNames = new string[] { "a" }; - private static readonly uint[] _optionalGroupExtensionFieldTags = new uint[] { 136 }; - public static OptionalGroup_extension DefaultInstance { - get { return defaultInstance; } - } - - public override OptionalGroup_extension DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override OptionalGroup_extension ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable; } - } - - public const int AFieldNumber = 17; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _optionalGroupExtensionFieldNames; - if (hasA) { - output.WriteInt32(17, field_names[0], A); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(17, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static OptionalGroup_extension ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup_extension ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static OptionalGroup_extension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private OptionalGroup_extension MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OptionalGroup_extension prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OptionalGroup_extension cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OptionalGroup_extension result; - - private OptionalGroup_extension PrepareBuilder() { - if (resultIsReadOnly) { - OptionalGroup_extension original = result; - result = new OptionalGroup_extension(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OptionalGroup_extension MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.Descriptor; } - } - - public override OptionalGroup_extension DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.DefaultInstance; } - } - - public override OptionalGroup_extension BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is OptionalGroup_extension) { - return MergeFrom((OptionalGroup_extension) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(OptionalGroup_extension other) { - if (other == global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_optionalGroupExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _optionalGroupExtensionFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 136: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static OptionalGroup_extension() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class RepeatedGroup_extension : pb::GeneratedMessage { - private RepeatedGroup_extension() { } - private static readonly RepeatedGroup_extension defaultInstance = new RepeatedGroup_extension().MakeReadOnly(); - private static readonly string[] _repeatedGroupExtensionFieldNames = new string[] { "a" }; - private static readonly uint[] _repeatedGroupExtensionFieldTags = new uint[] { 376 }; - public static RepeatedGroup_extension DefaultInstance { - get { return defaultInstance; } - } - - public override RepeatedGroup_extension DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override RepeatedGroup_extension ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable; } - } - - public const int AFieldNumber = 47; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _repeatedGroupExtensionFieldNames; - if (hasA) { - output.WriteInt32(47, field_names[0], A); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(47, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static RepeatedGroup_extension ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup_extension ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static RepeatedGroup_extension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private RepeatedGroup_extension MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(RepeatedGroup_extension prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(RepeatedGroup_extension cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private RepeatedGroup_extension result; - - private RepeatedGroup_extension PrepareBuilder() { - if (resultIsReadOnly) { - RepeatedGroup_extension original = result; - result = new RepeatedGroup_extension(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override RepeatedGroup_extension MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.Descriptor; } - } - - public override RepeatedGroup_extension DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.DefaultInstance; } - } - - public override RepeatedGroup_extension BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is RepeatedGroup_extension) { - return MergeFrom((RepeatedGroup_extension) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(RepeatedGroup_extension other) { - if (other == global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _repeatedGroupExtensionFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 376: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static RepeatedGroup_extension() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestNestedExtension : pb::GeneratedMessage { - private TestNestedExtension() { } - private static readonly TestNestedExtension defaultInstance = new TestNestedExtension().MakeReadOnly(); - private static readonly string[] _testNestedExtensionFieldNames = new string[] { }; - private static readonly uint[] _testNestedExtensionFieldTags = new uint[] { }; - public static TestNestedExtension DefaultInstance { - get { return defaultInstance; } - } - - public override TestNestedExtension DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestNestedExtension ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedExtension__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable; } - } - - public const int TestFieldNumber = 1002; - public static pb::GeneratedExtensionBase Test; - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testNestedExtensionFieldNames; - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestNestedExtension ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestNestedExtension ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestNestedExtension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestNestedExtension ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestNestedExtension MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestNestedExtension prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestNestedExtension cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestNestedExtension result; - - private TestNestedExtension PrepareBuilder() { - if (resultIsReadOnly) { - TestNestedExtension original = result; - result = new TestNestedExtension(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestNestedExtension MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor; } - } - - public override TestNestedExtension DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.DefaultInstance; } - } - - public override TestNestedExtension BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestNestedExtension) { - return MergeFrom((TestNestedExtension) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestNestedExtension other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testNestedExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testNestedExtensionFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static TestNestedExtension() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestRequired : pb::GeneratedMessage { - private TestRequired() { } - private static readonly TestRequired defaultInstance = new TestRequired().MakeReadOnly(); - private static readonly string[] _testRequiredFieldNames = new string[] { "a", "b", "c", "dummy10", "dummy11", "dummy12", "dummy13", "dummy14", "dummy15", "dummy16", "dummy17", "dummy18", "dummy19", "dummy2", "dummy20", "dummy21", "dummy22", "dummy23", "dummy24", "dummy25", "dummy26", "dummy27", "dummy28", "dummy29", "dummy30", "dummy31", "dummy32", "dummy4", "dummy5", "dummy6", "dummy7", "dummy8", "dummy9" }; - private static readonly uint[] _testRequiredFieldTags = new uint[] { 8, 24, 264, 80, 88, 96, 104, 112, 120, 128, 136, 144, 152, 16, 160, 168, 176, 184, 192, 200, 208, 216, 224, 232, 240, 248, 256, 32, 40, 48, 56, 64, 72 }; - public static TestRequired DefaultInstance { - get { return defaultInstance; } - } - - public override TestRequired DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestRequired ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRequired__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRequired__FieldAccessorTable; } - } - - public const int SingleFieldNumber = 1000; - public static pb::GeneratedExtensionBase Single; - public const int MultiFieldNumber = 1001; - public static pb::GeneratedExtensionBase> Multi; - public const int AFieldNumber = 1; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public const int Dummy2FieldNumber = 2; - private bool hasDummy2; - private int dummy2_; - public bool HasDummy2 { - get { return hasDummy2; } - } - public int Dummy2 { - get { return dummy2_; } - } - - public const int BFieldNumber = 3; - private bool hasB; - private int b_; - public bool HasB { - get { return hasB; } - } - public int B { - get { return b_; } - } - - public const int Dummy4FieldNumber = 4; - private bool hasDummy4; - private int dummy4_; - public bool HasDummy4 { - get { return hasDummy4; } - } - public int Dummy4 { - get { return dummy4_; } - } - - public const int Dummy5FieldNumber = 5; - private bool hasDummy5; - private int dummy5_; - public bool HasDummy5 { - get { return hasDummy5; } - } - public int Dummy5 { - get { return dummy5_; } - } - - public const int Dummy6FieldNumber = 6; - private bool hasDummy6; - private int dummy6_; - public bool HasDummy6 { - get { return hasDummy6; } - } - public int Dummy6 { - get { return dummy6_; } - } - - public const int Dummy7FieldNumber = 7; - private bool hasDummy7; - private int dummy7_; - public bool HasDummy7 { - get { return hasDummy7; } - } - public int Dummy7 { - get { return dummy7_; } - } - - public const int Dummy8FieldNumber = 8; - private bool hasDummy8; - private int dummy8_; - public bool HasDummy8 { - get { return hasDummy8; } - } - public int Dummy8 { - get { return dummy8_; } - } - - public const int Dummy9FieldNumber = 9; - private bool hasDummy9; - private int dummy9_; - public bool HasDummy9 { - get { return hasDummy9; } - } - public int Dummy9 { - get { return dummy9_; } - } - - public const int Dummy10FieldNumber = 10; - private bool hasDummy10; - private int dummy10_; - public bool HasDummy10 { - get { return hasDummy10; } - } - public int Dummy10 { - get { return dummy10_; } - } - - public const int Dummy11FieldNumber = 11; - private bool hasDummy11; - private int dummy11_; - public bool HasDummy11 { - get { return hasDummy11; } - } - public int Dummy11 { - get { return dummy11_; } - } - - public const int Dummy12FieldNumber = 12; - private bool hasDummy12; - private int dummy12_; - public bool HasDummy12 { - get { return hasDummy12; } - } - public int Dummy12 { - get { return dummy12_; } - } - - public const int Dummy13FieldNumber = 13; - private bool hasDummy13; - private int dummy13_; - public bool HasDummy13 { - get { return hasDummy13; } - } - public int Dummy13 { - get { return dummy13_; } - } - - public const int Dummy14FieldNumber = 14; - private bool hasDummy14; - private int dummy14_; - public bool HasDummy14 { - get { return hasDummy14; } - } - public int Dummy14 { - get { return dummy14_; } - } - - public const int Dummy15FieldNumber = 15; - private bool hasDummy15; - private int dummy15_; - public bool HasDummy15 { - get { return hasDummy15; } - } - public int Dummy15 { - get { return dummy15_; } - } - - public const int Dummy16FieldNumber = 16; - private bool hasDummy16; - private int dummy16_; - public bool HasDummy16 { - get { return hasDummy16; } - } - public int Dummy16 { - get { return dummy16_; } - } - - public const int Dummy17FieldNumber = 17; - private bool hasDummy17; - private int dummy17_; - public bool HasDummy17 { - get { return hasDummy17; } - } - public int Dummy17 { - get { return dummy17_; } - } - - public const int Dummy18FieldNumber = 18; - private bool hasDummy18; - private int dummy18_; - public bool HasDummy18 { - get { return hasDummy18; } - } - public int Dummy18 { - get { return dummy18_; } - } - - public const int Dummy19FieldNumber = 19; - private bool hasDummy19; - private int dummy19_; - public bool HasDummy19 { - get { return hasDummy19; } - } - public int Dummy19 { - get { return dummy19_; } - } - - public const int Dummy20FieldNumber = 20; - private bool hasDummy20; - private int dummy20_; - public bool HasDummy20 { - get { return hasDummy20; } - } - public int Dummy20 { - get { return dummy20_; } - } - - public const int Dummy21FieldNumber = 21; - private bool hasDummy21; - private int dummy21_; - public bool HasDummy21 { - get { return hasDummy21; } - } - public int Dummy21 { - get { return dummy21_; } - } - - public const int Dummy22FieldNumber = 22; - private bool hasDummy22; - private int dummy22_; - public bool HasDummy22 { - get { return hasDummy22; } - } - public int Dummy22 { - get { return dummy22_; } - } - - public const int Dummy23FieldNumber = 23; - private bool hasDummy23; - private int dummy23_; - public bool HasDummy23 { - get { return hasDummy23; } - } - public int Dummy23 { - get { return dummy23_; } - } - - public const int Dummy24FieldNumber = 24; - private bool hasDummy24; - private int dummy24_; - public bool HasDummy24 { - get { return hasDummy24; } - } - public int Dummy24 { - get { return dummy24_; } - } - - public const int Dummy25FieldNumber = 25; - private bool hasDummy25; - private int dummy25_; - public bool HasDummy25 { - get { return hasDummy25; } - } - public int Dummy25 { - get { return dummy25_; } - } - - public const int Dummy26FieldNumber = 26; - private bool hasDummy26; - private int dummy26_; - public bool HasDummy26 { - get { return hasDummy26; } - } - public int Dummy26 { - get { return dummy26_; } - } - - public const int Dummy27FieldNumber = 27; - private bool hasDummy27; - private int dummy27_; - public bool HasDummy27 { - get { return hasDummy27; } - } - public int Dummy27 { - get { return dummy27_; } - } - - public const int Dummy28FieldNumber = 28; - private bool hasDummy28; - private int dummy28_; - public bool HasDummy28 { - get { return hasDummy28; } - } - public int Dummy28 { - get { return dummy28_; } - } - - public const int Dummy29FieldNumber = 29; - private bool hasDummy29; - private int dummy29_; - public bool HasDummy29 { - get { return hasDummy29; } - } - public int Dummy29 { - get { return dummy29_; } - } - - public const int Dummy30FieldNumber = 30; - private bool hasDummy30; - private int dummy30_; - public bool HasDummy30 { - get { return hasDummy30; } - } - public int Dummy30 { - get { return dummy30_; } - } - - public const int Dummy31FieldNumber = 31; - private bool hasDummy31; - private int dummy31_; - public bool HasDummy31 { - get { return hasDummy31; } - } - public int Dummy31 { - get { return dummy31_; } - } - - public const int Dummy32FieldNumber = 32; - private bool hasDummy32; - private int dummy32_; - public bool HasDummy32 { - get { return hasDummy32; } - } - public int Dummy32 { - get { return dummy32_; } - } - - public const int CFieldNumber = 33; - private bool hasC; - private int c_; - public bool HasC { - get { return hasC; } - } - public int C { - get { return c_; } - } - - public override bool IsInitialized { - get { - if (!hasA) return false; - if (!hasB) return false; - if (!hasC) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testRequiredFieldNames; - if (hasA) { - output.WriteInt32(1, field_names[0], A); - } - if (hasDummy2) { - output.WriteInt32(2, field_names[13], Dummy2); - } - if (hasB) { - output.WriteInt32(3, field_names[1], B); - } - if (hasDummy4) { - output.WriteInt32(4, field_names[27], Dummy4); - } - if (hasDummy5) { - output.WriteInt32(5, field_names[28], Dummy5); - } - if (hasDummy6) { - output.WriteInt32(6, field_names[29], Dummy6); - } - if (hasDummy7) { - output.WriteInt32(7, field_names[30], Dummy7); - } - if (hasDummy8) { - output.WriteInt32(8, field_names[31], Dummy8); - } - if (hasDummy9) { - output.WriteInt32(9, field_names[32], Dummy9); - } - if (hasDummy10) { - output.WriteInt32(10, field_names[3], Dummy10); - } - if (hasDummy11) { - output.WriteInt32(11, field_names[4], Dummy11); - } - if (hasDummy12) { - output.WriteInt32(12, field_names[5], Dummy12); - } - if (hasDummy13) { - output.WriteInt32(13, field_names[6], Dummy13); - } - if (hasDummy14) { - output.WriteInt32(14, field_names[7], Dummy14); - } - if (hasDummy15) { - output.WriteInt32(15, field_names[8], Dummy15); - } - if (hasDummy16) { - output.WriteInt32(16, field_names[9], Dummy16); - } - if (hasDummy17) { - output.WriteInt32(17, field_names[10], Dummy17); - } - if (hasDummy18) { - output.WriteInt32(18, field_names[11], Dummy18); - } - if (hasDummy19) { - output.WriteInt32(19, field_names[12], Dummy19); - } - if (hasDummy20) { - output.WriteInt32(20, field_names[14], Dummy20); - } - if (hasDummy21) { - output.WriteInt32(21, field_names[15], Dummy21); - } - if (hasDummy22) { - output.WriteInt32(22, field_names[16], Dummy22); - } - if (hasDummy23) { - output.WriteInt32(23, field_names[17], Dummy23); - } - if (hasDummy24) { - output.WriteInt32(24, field_names[18], Dummy24); - } - if (hasDummy25) { - output.WriteInt32(25, field_names[19], Dummy25); - } - if (hasDummy26) { - output.WriteInt32(26, field_names[20], Dummy26); - } - if (hasDummy27) { - output.WriteInt32(27, field_names[21], Dummy27); - } - if (hasDummy28) { - output.WriteInt32(28, field_names[22], Dummy28); - } - if (hasDummy29) { - output.WriteInt32(29, field_names[23], Dummy29); - } - if (hasDummy30) { - output.WriteInt32(30, field_names[24], Dummy30); - } - if (hasDummy31) { - output.WriteInt32(31, field_names[25], Dummy31); - } - if (hasDummy32) { - output.WriteInt32(32, field_names[26], Dummy32); - } - if (hasC) { - output.WriteInt32(33, field_names[2], C); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A); - } - if (hasDummy2) { - size += pb::CodedOutputStream.ComputeInt32Size(2, Dummy2); - } - if (hasB) { - size += pb::CodedOutputStream.ComputeInt32Size(3, B); - } - if (hasDummy4) { - size += pb::CodedOutputStream.ComputeInt32Size(4, Dummy4); - } - if (hasDummy5) { - size += pb::CodedOutputStream.ComputeInt32Size(5, Dummy5); - } - if (hasDummy6) { - size += pb::CodedOutputStream.ComputeInt32Size(6, Dummy6); - } - if (hasDummy7) { - size += pb::CodedOutputStream.ComputeInt32Size(7, Dummy7); - } - if (hasDummy8) { - size += pb::CodedOutputStream.ComputeInt32Size(8, Dummy8); - } - if (hasDummy9) { - size += pb::CodedOutputStream.ComputeInt32Size(9, Dummy9); - } - if (hasDummy10) { - size += pb::CodedOutputStream.ComputeInt32Size(10, Dummy10); - } - if (hasDummy11) { - size += pb::CodedOutputStream.ComputeInt32Size(11, Dummy11); - } - if (hasDummy12) { - size += pb::CodedOutputStream.ComputeInt32Size(12, Dummy12); - } - if (hasDummy13) { - size += pb::CodedOutputStream.ComputeInt32Size(13, Dummy13); - } - if (hasDummy14) { - size += pb::CodedOutputStream.ComputeInt32Size(14, Dummy14); - } - if (hasDummy15) { - size += pb::CodedOutputStream.ComputeInt32Size(15, Dummy15); - } - if (hasDummy16) { - size += pb::CodedOutputStream.ComputeInt32Size(16, Dummy16); - } - if (hasDummy17) { - size += pb::CodedOutputStream.ComputeInt32Size(17, Dummy17); - } - if (hasDummy18) { - size += pb::CodedOutputStream.ComputeInt32Size(18, Dummy18); - } - if (hasDummy19) { - size += pb::CodedOutputStream.ComputeInt32Size(19, Dummy19); - } - if (hasDummy20) { - size += pb::CodedOutputStream.ComputeInt32Size(20, Dummy20); - } - if (hasDummy21) { - size += pb::CodedOutputStream.ComputeInt32Size(21, Dummy21); - } - if (hasDummy22) { - size += pb::CodedOutputStream.ComputeInt32Size(22, Dummy22); - } - if (hasDummy23) { - size += pb::CodedOutputStream.ComputeInt32Size(23, Dummy23); - } - if (hasDummy24) { - size += pb::CodedOutputStream.ComputeInt32Size(24, Dummy24); - } - if (hasDummy25) { - size += pb::CodedOutputStream.ComputeInt32Size(25, Dummy25); - } - if (hasDummy26) { - size += pb::CodedOutputStream.ComputeInt32Size(26, Dummy26); - } - if (hasDummy27) { - size += pb::CodedOutputStream.ComputeInt32Size(27, Dummy27); - } - if (hasDummy28) { - size += pb::CodedOutputStream.ComputeInt32Size(28, Dummy28); - } - if (hasDummy29) { - size += pb::CodedOutputStream.ComputeInt32Size(29, Dummy29); - } - if (hasDummy30) { - size += pb::CodedOutputStream.ComputeInt32Size(30, Dummy30); - } - if (hasDummy31) { - size += pb::CodedOutputStream.ComputeInt32Size(31, Dummy31); - } - if (hasDummy32) { - size += pb::CodedOutputStream.ComputeInt32Size(32, Dummy32); - } - if (hasC) { - size += pb::CodedOutputStream.ComputeInt32Size(33, C); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestRequired ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequired ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequired ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequired ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequired ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequired ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestRequired ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestRequired ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestRequired ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequired ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestRequired MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestRequired prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestRequired cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestRequired result; - - private TestRequired PrepareBuilder() { - if (resultIsReadOnly) { - TestRequired original = result; - result = new TestRequired(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestRequired MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor; } - } - - public override TestRequired DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance; } - } - - public override TestRequired BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestRequired) { - return MergeFrom((TestRequired) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestRequired other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - if (other.HasDummy2) { - Dummy2 = other.Dummy2; - } - if (other.HasB) { - B = other.B; - } - if (other.HasDummy4) { - Dummy4 = other.Dummy4; - } - if (other.HasDummy5) { - Dummy5 = other.Dummy5; - } - if (other.HasDummy6) { - Dummy6 = other.Dummy6; - } - if (other.HasDummy7) { - Dummy7 = other.Dummy7; - } - if (other.HasDummy8) { - Dummy8 = other.Dummy8; - } - if (other.HasDummy9) { - Dummy9 = other.Dummy9; - } - if (other.HasDummy10) { - Dummy10 = other.Dummy10; - } - if (other.HasDummy11) { - Dummy11 = other.Dummy11; - } - if (other.HasDummy12) { - Dummy12 = other.Dummy12; - } - if (other.HasDummy13) { - Dummy13 = other.Dummy13; - } - if (other.HasDummy14) { - Dummy14 = other.Dummy14; - } - if (other.HasDummy15) { - Dummy15 = other.Dummy15; - } - if (other.HasDummy16) { - Dummy16 = other.Dummy16; - } - if (other.HasDummy17) { - Dummy17 = other.Dummy17; - } - if (other.HasDummy18) { - Dummy18 = other.Dummy18; - } - if (other.HasDummy19) { - Dummy19 = other.Dummy19; - } - if (other.HasDummy20) { - Dummy20 = other.Dummy20; - } - if (other.HasDummy21) { - Dummy21 = other.Dummy21; - } - if (other.HasDummy22) { - Dummy22 = other.Dummy22; - } - if (other.HasDummy23) { - Dummy23 = other.Dummy23; - } - if (other.HasDummy24) { - Dummy24 = other.Dummy24; - } - if (other.HasDummy25) { - Dummy25 = other.Dummy25; - } - if (other.HasDummy26) { - Dummy26 = other.Dummy26; - } - if (other.HasDummy27) { - Dummy27 = other.Dummy27; - } - if (other.HasDummy28) { - Dummy28 = other.Dummy28; - } - if (other.HasDummy29) { - Dummy29 = other.Dummy29; - } - if (other.HasDummy30) { - Dummy30 = other.Dummy30; - } - if (other.HasDummy31) { - Dummy31 = other.Dummy31; - } - if (other.HasDummy32) { - Dummy32 = other.Dummy32; - } - if (other.HasC) { - C = other.C; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testRequiredFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testRequiredFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - case 16: { - result.hasDummy2 = input.ReadInt32(ref result.dummy2_); - break; - } - case 24: { - result.hasB = input.ReadInt32(ref result.b_); - break; - } - case 32: { - result.hasDummy4 = input.ReadInt32(ref result.dummy4_); - break; - } - case 40: { - result.hasDummy5 = input.ReadInt32(ref result.dummy5_); - break; - } - case 48: { - result.hasDummy6 = input.ReadInt32(ref result.dummy6_); - break; - } - case 56: { - result.hasDummy7 = input.ReadInt32(ref result.dummy7_); - break; - } - case 64: { - result.hasDummy8 = input.ReadInt32(ref result.dummy8_); - break; - } - case 72: { - result.hasDummy9 = input.ReadInt32(ref result.dummy9_); - break; - } - case 80: { - result.hasDummy10 = input.ReadInt32(ref result.dummy10_); - break; - } - case 88: { - result.hasDummy11 = input.ReadInt32(ref result.dummy11_); - break; - } - case 96: { - result.hasDummy12 = input.ReadInt32(ref result.dummy12_); - break; - } - case 104: { - result.hasDummy13 = input.ReadInt32(ref result.dummy13_); - break; - } - case 112: { - result.hasDummy14 = input.ReadInt32(ref result.dummy14_); - break; - } - case 120: { - result.hasDummy15 = input.ReadInt32(ref result.dummy15_); - break; - } - case 128: { - result.hasDummy16 = input.ReadInt32(ref result.dummy16_); - break; - } - case 136: { - result.hasDummy17 = input.ReadInt32(ref result.dummy17_); - break; - } - case 144: { - result.hasDummy18 = input.ReadInt32(ref result.dummy18_); - break; - } - case 152: { - result.hasDummy19 = input.ReadInt32(ref result.dummy19_); - break; - } - case 160: { - result.hasDummy20 = input.ReadInt32(ref result.dummy20_); - break; - } - case 168: { - result.hasDummy21 = input.ReadInt32(ref result.dummy21_); - break; - } - case 176: { - result.hasDummy22 = input.ReadInt32(ref result.dummy22_); - break; - } - case 184: { - result.hasDummy23 = input.ReadInt32(ref result.dummy23_); - break; - } - case 192: { - result.hasDummy24 = input.ReadInt32(ref result.dummy24_); - break; - } - case 200: { - result.hasDummy25 = input.ReadInt32(ref result.dummy25_); - break; - } - case 208: { - result.hasDummy26 = input.ReadInt32(ref result.dummy26_); - break; - } - case 216: { - result.hasDummy27 = input.ReadInt32(ref result.dummy27_); - break; - } - case 224: { - result.hasDummy28 = input.ReadInt32(ref result.dummy28_); - break; - } - case 232: { - result.hasDummy29 = input.ReadInt32(ref result.dummy29_); - break; - } - case 240: { - result.hasDummy30 = input.ReadInt32(ref result.dummy30_); - break; - } - case 248: { - result.hasDummy31 = input.ReadInt32(ref result.dummy31_); - break; - } - case 256: { - result.hasDummy32 = input.ReadInt32(ref result.dummy32_); - break; - } - case 264: { - result.hasC = input.ReadInt32(ref result.c_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - - public bool HasDummy2 { - get { return result.hasDummy2; } - } - public int Dummy2 { - get { return result.Dummy2; } - set { SetDummy2(value); } - } - public Builder SetDummy2(int value) { - PrepareBuilder(); - result.hasDummy2 = true; - result.dummy2_ = value; - return this; - } - public Builder ClearDummy2() { - PrepareBuilder(); - result.hasDummy2 = false; - result.dummy2_ = 0; - return this; - } - - public bool HasB { - get { return result.hasB; } - } - public int B { - get { return result.B; } - set { SetB(value); } - } - public Builder SetB(int value) { - PrepareBuilder(); - result.hasB = true; - result.b_ = value; - return this; - } - public Builder ClearB() { - PrepareBuilder(); - result.hasB = false; - result.b_ = 0; - return this; - } - - public bool HasDummy4 { - get { return result.hasDummy4; } - } - public int Dummy4 { - get { return result.Dummy4; } - set { SetDummy4(value); } - } - public Builder SetDummy4(int value) { - PrepareBuilder(); - result.hasDummy4 = true; - result.dummy4_ = value; - return this; - } - public Builder ClearDummy4() { - PrepareBuilder(); - result.hasDummy4 = false; - result.dummy4_ = 0; - return this; - } - - public bool HasDummy5 { - get { return result.hasDummy5; } - } - public int Dummy5 { - get { return result.Dummy5; } - set { SetDummy5(value); } - } - public Builder SetDummy5(int value) { - PrepareBuilder(); - result.hasDummy5 = true; - result.dummy5_ = value; - return this; - } - public Builder ClearDummy5() { - PrepareBuilder(); - result.hasDummy5 = false; - result.dummy5_ = 0; - return this; - } - - public bool HasDummy6 { - get { return result.hasDummy6; } - } - public int Dummy6 { - get { return result.Dummy6; } - set { SetDummy6(value); } - } - public Builder SetDummy6(int value) { - PrepareBuilder(); - result.hasDummy6 = true; - result.dummy6_ = value; - return this; - } - public Builder ClearDummy6() { - PrepareBuilder(); - result.hasDummy6 = false; - result.dummy6_ = 0; - return this; - } - - public bool HasDummy7 { - get { return result.hasDummy7; } - } - public int Dummy7 { - get { return result.Dummy7; } - set { SetDummy7(value); } - } - public Builder SetDummy7(int value) { - PrepareBuilder(); - result.hasDummy7 = true; - result.dummy7_ = value; - return this; - } - public Builder ClearDummy7() { - PrepareBuilder(); - result.hasDummy7 = false; - result.dummy7_ = 0; - return this; - } - - public bool HasDummy8 { - get { return result.hasDummy8; } - } - public int Dummy8 { - get { return result.Dummy8; } - set { SetDummy8(value); } - } - public Builder SetDummy8(int value) { - PrepareBuilder(); - result.hasDummy8 = true; - result.dummy8_ = value; - return this; - } - public Builder ClearDummy8() { - PrepareBuilder(); - result.hasDummy8 = false; - result.dummy8_ = 0; - return this; - } - - public bool HasDummy9 { - get { return result.hasDummy9; } - } - public int Dummy9 { - get { return result.Dummy9; } - set { SetDummy9(value); } - } - public Builder SetDummy9(int value) { - PrepareBuilder(); - result.hasDummy9 = true; - result.dummy9_ = value; - return this; - } - public Builder ClearDummy9() { - PrepareBuilder(); - result.hasDummy9 = false; - result.dummy9_ = 0; - return this; - } - - public bool HasDummy10 { - get { return result.hasDummy10; } - } - public int Dummy10 { - get { return result.Dummy10; } - set { SetDummy10(value); } - } - public Builder SetDummy10(int value) { - PrepareBuilder(); - result.hasDummy10 = true; - result.dummy10_ = value; - return this; - } - public Builder ClearDummy10() { - PrepareBuilder(); - result.hasDummy10 = false; - result.dummy10_ = 0; - return this; - } - - public bool HasDummy11 { - get { return result.hasDummy11; } - } - public int Dummy11 { - get { return result.Dummy11; } - set { SetDummy11(value); } - } - public Builder SetDummy11(int value) { - PrepareBuilder(); - result.hasDummy11 = true; - result.dummy11_ = value; - return this; - } - public Builder ClearDummy11() { - PrepareBuilder(); - result.hasDummy11 = false; - result.dummy11_ = 0; - return this; - } - - public bool HasDummy12 { - get { return result.hasDummy12; } - } - public int Dummy12 { - get { return result.Dummy12; } - set { SetDummy12(value); } - } - public Builder SetDummy12(int value) { - PrepareBuilder(); - result.hasDummy12 = true; - result.dummy12_ = value; - return this; - } - public Builder ClearDummy12() { - PrepareBuilder(); - result.hasDummy12 = false; - result.dummy12_ = 0; - return this; - } - - public bool HasDummy13 { - get { return result.hasDummy13; } - } - public int Dummy13 { - get { return result.Dummy13; } - set { SetDummy13(value); } - } - public Builder SetDummy13(int value) { - PrepareBuilder(); - result.hasDummy13 = true; - result.dummy13_ = value; - return this; - } - public Builder ClearDummy13() { - PrepareBuilder(); - result.hasDummy13 = false; - result.dummy13_ = 0; - return this; - } - - public bool HasDummy14 { - get { return result.hasDummy14; } - } - public int Dummy14 { - get { return result.Dummy14; } - set { SetDummy14(value); } - } - public Builder SetDummy14(int value) { - PrepareBuilder(); - result.hasDummy14 = true; - result.dummy14_ = value; - return this; - } - public Builder ClearDummy14() { - PrepareBuilder(); - result.hasDummy14 = false; - result.dummy14_ = 0; - return this; - } - - public bool HasDummy15 { - get { return result.hasDummy15; } - } - public int Dummy15 { - get { return result.Dummy15; } - set { SetDummy15(value); } - } - public Builder SetDummy15(int value) { - PrepareBuilder(); - result.hasDummy15 = true; - result.dummy15_ = value; - return this; - } - public Builder ClearDummy15() { - PrepareBuilder(); - result.hasDummy15 = false; - result.dummy15_ = 0; - return this; - } - - public bool HasDummy16 { - get { return result.hasDummy16; } - } - public int Dummy16 { - get { return result.Dummy16; } - set { SetDummy16(value); } - } - public Builder SetDummy16(int value) { - PrepareBuilder(); - result.hasDummy16 = true; - result.dummy16_ = value; - return this; - } - public Builder ClearDummy16() { - PrepareBuilder(); - result.hasDummy16 = false; - result.dummy16_ = 0; - return this; - } - - public bool HasDummy17 { - get { return result.hasDummy17; } - } - public int Dummy17 { - get { return result.Dummy17; } - set { SetDummy17(value); } - } - public Builder SetDummy17(int value) { - PrepareBuilder(); - result.hasDummy17 = true; - result.dummy17_ = value; - return this; - } - public Builder ClearDummy17() { - PrepareBuilder(); - result.hasDummy17 = false; - result.dummy17_ = 0; - return this; - } - - public bool HasDummy18 { - get { return result.hasDummy18; } - } - public int Dummy18 { - get { return result.Dummy18; } - set { SetDummy18(value); } - } - public Builder SetDummy18(int value) { - PrepareBuilder(); - result.hasDummy18 = true; - result.dummy18_ = value; - return this; - } - public Builder ClearDummy18() { - PrepareBuilder(); - result.hasDummy18 = false; - result.dummy18_ = 0; - return this; - } - - public bool HasDummy19 { - get { return result.hasDummy19; } - } - public int Dummy19 { - get { return result.Dummy19; } - set { SetDummy19(value); } - } - public Builder SetDummy19(int value) { - PrepareBuilder(); - result.hasDummy19 = true; - result.dummy19_ = value; - return this; - } - public Builder ClearDummy19() { - PrepareBuilder(); - result.hasDummy19 = false; - result.dummy19_ = 0; - return this; - } - - public bool HasDummy20 { - get { return result.hasDummy20; } - } - public int Dummy20 { - get { return result.Dummy20; } - set { SetDummy20(value); } - } - public Builder SetDummy20(int value) { - PrepareBuilder(); - result.hasDummy20 = true; - result.dummy20_ = value; - return this; - } - public Builder ClearDummy20() { - PrepareBuilder(); - result.hasDummy20 = false; - result.dummy20_ = 0; - return this; - } - - public bool HasDummy21 { - get { return result.hasDummy21; } - } - public int Dummy21 { - get { return result.Dummy21; } - set { SetDummy21(value); } - } - public Builder SetDummy21(int value) { - PrepareBuilder(); - result.hasDummy21 = true; - result.dummy21_ = value; - return this; - } - public Builder ClearDummy21() { - PrepareBuilder(); - result.hasDummy21 = false; - result.dummy21_ = 0; - return this; - } - - public bool HasDummy22 { - get { return result.hasDummy22; } - } - public int Dummy22 { - get { return result.Dummy22; } - set { SetDummy22(value); } - } - public Builder SetDummy22(int value) { - PrepareBuilder(); - result.hasDummy22 = true; - result.dummy22_ = value; - return this; - } - public Builder ClearDummy22() { - PrepareBuilder(); - result.hasDummy22 = false; - result.dummy22_ = 0; - return this; - } - - public bool HasDummy23 { - get { return result.hasDummy23; } - } - public int Dummy23 { - get { return result.Dummy23; } - set { SetDummy23(value); } - } - public Builder SetDummy23(int value) { - PrepareBuilder(); - result.hasDummy23 = true; - result.dummy23_ = value; - return this; - } - public Builder ClearDummy23() { - PrepareBuilder(); - result.hasDummy23 = false; - result.dummy23_ = 0; - return this; - } - - public bool HasDummy24 { - get { return result.hasDummy24; } - } - public int Dummy24 { - get { return result.Dummy24; } - set { SetDummy24(value); } - } - public Builder SetDummy24(int value) { - PrepareBuilder(); - result.hasDummy24 = true; - result.dummy24_ = value; - return this; - } - public Builder ClearDummy24() { - PrepareBuilder(); - result.hasDummy24 = false; - result.dummy24_ = 0; - return this; - } - - public bool HasDummy25 { - get { return result.hasDummy25; } - } - public int Dummy25 { - get { return result.Dummy25; } - set { SetDummy25(value); } - } - public Builder SetDummy25(int value) { - PrepareBuilder(); - result.hasDummy25 = true; - result.dummy25_ = value; - return this; - } - public Builder ClearDummy25() { - PrepareBuilder(); - result.hasDummy25 = false; - result.dummy25_ = 0; - return this; - } - - public bool HasDummy26 { - get { return result.hasDummy26; } - } - public int Dummy26 { - get { return result.Dummy26; } - set { SetDummy26(value); } - } - public Builder SetDummy26(int value) { - PrepareBuilder(); - result.hasDummy26 = true; - result.dummy26_ = value; - return this; - } - public Builder ClearDummy26() { - PrepareBuilder(); - result.hasDummy26 = false; - result.dummy26_ = 0; - return this; - } - - public bool HasDummy27 { - get { return result.hasDummy27; } - } - public int Dummy27 { - get { return result.Dummy27; } - set { SetDummy27(value); } - } - public Builder SetDummy27(int value) { - PrepareBuilder(); - result.hasDummy27 = true; - result.dummy27_ = value; - return this; - } - public Builder ClearDummy27() { - PrepareBuilder(); - result.hasDummy27 = false; - result.dummy27_ = 0; - return this; - } - - public bool HasDummy28 { - get { return result.hasDummy28; } - } - public int Dummy28 { - get { return result.Dummy28; } - set { SetDummy28(value); } - } - public Builder SetDummy28(int value) { - PrepareBuilder(); - result.hasDummy28 = true; - result.dummy28_ = value; - return this; - } - public Builder ClearDummy28() { - PrepareBuilder(); - result.hasDummy28 = false; - result.dummy28_ = 0; - return this; - } - - public bool HasDummy29 { - get { return result.hasDummy29; } - } - public int Dummy29 { - get { return result.Dummy29; } - set { SetDummy29(value); } - } - public Builder SetDummy29(int value) { - PrepareBuilder(); - result.hasDummy29 = true; - result.dummy29_ = value; - return this; - } - public Builder ClearDummy29() { - PrepareBuilder(); - result.hasDummy29 = false; - result.dummy29_ = 0; - return this; - } - - public bool HasDummy30 { - get { return result.hasDummy30; } - } - public int Dummy30 { - get { return result.Dummy30; } - set { SetDummy30(value); } - } - public Builder SetDummy30(int value) { - PrepareBuilder(); - result.hasDummy30 = true; - result.dummy30_ = value; - return this; - } - public Builder ClearDummy30() { - PrepareBuilder(); - result.hasDummy30 = false; - result.dummy30_ = 0; - return this; - } - - public bool HasDummy31 { - get { return result.hasDummy31; } - } - public int Dummy31 { - get { return result.Dummy31; } - set { SetDummy31(value); } - } - public Builder SetDummy31(int value) { - PrepareBuilder(); - result.hasDummy31 = true; - result.dummy31_ = value; - return this; - } - public Builder ClearDummy31() { - PrepareBuilder(); - result.hasDummy31 = false; - result.dummy31_ = 0; - return this; - } - - public bool HasDummy32 { - get { return result.hasDummy32; } - } - public int Dummy32 { - get { return result.Dummy32; } - set { SetDummy32(value); } - } - public Builder SetDummy32(int value) { - PrepareBuilder(); - result.hasDummy32 = true; - result.dummy32_ = value; - return this; - } - public Builder ClearDummy32() { - PrepareBuilder(); - result.hasDummy32 = false; - result.dummy32_ = 0; - return this; - } - - public bool HasC { - get { return result.hasC; } - } - public int C { - get { return result.C; } - set { SetC(value); } - } - public Builder SetC(int value) { - PrepareBuilder(); - result.hasC = true; - result.c_ = value; - return this; - } - public Builder ClearC() { - PrepareBuilder(); - result.hasC = false; - result.c_ = 0; - return this; - } - } - static TestRequired() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestRequiredForeign : pb::GeneratedMessage { - private TestRequiredForeign() { } - private static readonly TestRequiredForeign defaultInstance = new TestRequiredForeign().MakeReadOnly(); - private static readonly string[] _testRequiredForeignFieldNames = new string[] { "dummy", "optional_message", "repeated_message" }; - private static readonly uint[] _testRequiredForeignFieldTags = new uint[] { 24, 10, 18 }; - public static TestRequiredForeign DefaultInstance { - get { return defaultInstance; } - } - - public override TestRequiredForeign DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestRequiredForeign ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRequiredForeign__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable; } - } - - public const int OptionalMessageFieldNumber = 1; - private bool hasOptionalMessage; - private global::Google.ProtocolBuffers.TestProtos.TestRequired optionalMessage_; - public bool HasOptionalMessage { - get { return hasOptionalMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequired OptionalMessage { - get { return optionalMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance; } - } - - public const int RepeatedMessageFieldNumber = 2; - private pbc::PopsicleList repeatedMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedMessageList { - get { return repeatedMessage_; } - } - public int RepeatedMessageCount { - get { return repeatedMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequired GetRepeatedMessage(int index) { - return repeatedMessage_[index]; - } - - public const int DummyFieldNumber = 3; - private bool hasDummy; - private int dummy_; - public bool HasDummy { - get { return hasDummy; } - } - public int Dummy { - get { return dummy_; } - } - - public override bool IsInitialized { - get { - if (HasOptionalMessage) { - if (!OptionalMessage.IsInitialized) return false; - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestRequired element in RepeatedMessageList) { - if (!element.IsInitialized) return false; - } - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testRequiredForeignFieldNames; - if (hasOptionalMessage) { - output.WriteMessage(1, field_names[1], OptionalMessage); - } - if (repeatedMessage_.Count > 0) { - output.WriteMessageArray(2, field_names[2], repeatedMessage_); - } - if (hasDummy) { - output.WriteInt32(3, field_names[0], Dummy); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasOptionalMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(1, OptionalMessage); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestRequired element in RepeatedMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(2, element); - } - if (hasDummy) { - size += pb::CodedOutputStream.ComputeInt32Size(3, Dummy); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestRequiredForeign ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestRequiredForeign ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestRequiredForeign ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestRequiredForeign MakeReadOnly() { - repeatedMessage_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestRequiredForeign prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestRequiredForeign cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestRequiredForeign result; - - private TestRequiredForeign PrepareBuilder() { - if (resultIsReadOnly) { - TestRequiredForeign original = result; - result = new TestRequiredForeign(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestRequiredForeign MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.Descriptor; } - } - - public override TestRequiredForeign DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.DefaultInstance; } - } - - public override TestRequiredForeign BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestRequiredForeign) { - return MergeFrom((TestRequiredForeign) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestRequiredForeign other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasOptionalMessage) { - MergeOptionalMessage(other.OptionalMessage); - } - if (other.repeatedMessage_.Count != 0) { - result.repeatedMessage_.Add(other.repeatedMessage_); - } - if (other.HasDummy) { - Dummy = other.Dummy; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testRequiredForeignFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testRequiredForeignFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(); - if (result.hasOptionalMessage) { - subBuilder.MergeFrom(OptionalMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalMessage = subBuilder.BuildPartial(); - break; - } - case 18: { - input.ReadMessageArray(tag, field_name, result.repeatedMessage_, global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance, extensionRegistry); - break; - } - case 24: { - result.hasDummy = input.ReadInt32(ref result.dummy_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasOptionalMessage { - get { return result.hasOptionalMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequired OptionalMessage { - get { return result.OptionalMessage; } - set { SetOptionalMessage(value); } - } - public Builder SetOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalMessage = true; - result.optionalMessage_ = value; - return this; - } - public Builder SetOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalMessage = true; - result.optionalMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalMessage && - result.optionalMessage_ != global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) { - result.optionalMessage_ = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(result.optionalMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalMessage_ = value; - } - result.hasOptionalMessage = true; - return this; - } - public Builder ClearOptionalMessage() { - PrepareBuilder(); - result.hasOptionalMessage = false; - result.optionalMessage_ = null; - return this; - } - - public pbc::IPopsicleList RepeatedMessageList { - get { return PrepareBuilder().repeatedMessage_; } - } - public int RepeatedMessageCount { - get { return result.RepeatedMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequired GetRepeatedMessage(int index) { - return result.GetRepeatedMessage(index); - } - public Builder SetRepeatedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestRequired value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedMessage_[index] = value; - return this; - } - public Builder SetRepeatedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedMessage_.Add(value); - return this; - } - public Builder AddRepeatedMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedMessage_.Add(values); - return this; - } - public Builder ClearRepeatedMessage() { - PrepareBuilder(); - result.repeatedMessage_.Clear(); - return this; - } - - public bool HasDummy { - get { return result.hasDummy; } - } - public int Dummy { - get { return result.Dummy; } - set { SetDummy(value); } - } - public Builder SetDummy(int value) { - PrepareBuilder(); - result.hasDummy = true; - result.dummy_ = value; - return this; - } - public Builder ClearDummy() { - PrepareBuilder(); - result.hasDummy = false; - result.dummy_ = 0; - return this; - } - } - static TestRequiredForeign() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestForeignNested : pb::GeneratedMessage { - private TestForeignNested() { } - private static readonly TestForeignNested defaultInstance = new TestForeignNested().MakeReadOnly(); - private static readonly string[] _testForeignNestedFieldNames = new string[] { "foreign_nested" }; - private static readonly uint[] _testForeignNestedFieldTags = new uint[] { 10 }; - public static TestForeignNested DefaultInstance { - get { return defaultInstance; } - } - - public override TestForeignNested DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestForeignNested ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestForeignNested__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable; } - } - - public const int ForeignNestedFieldNumber = 1; - private bool hasForeignNested; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage foreignNested_; - public bool HasForeignNested { - get { return hasForeignNested; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage ForeignNested { - get { return foreignNested_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testForeignNestedFieldNames; - if (hasForeignNested) { - output.WriteMessage(1, field_names[0], ForeignNested); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasForeignNested) { - size += pb::CodedOutputStream.ComputeMessageSize(1, ForeignNested); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestForeignNested ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestForeignNested ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestForeignNested ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestForeignNested ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestForeignNested ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestForeignNested ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestForeignNested ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestForeignNested ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestForeignNested ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestForeignNested ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestForeignNested MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestForeignNested prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestForeignNested cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestForeignNested result; - - private TestForeignNested PrepareBuilder() { - if (resultIsReadOnly) { - TestForeignNested original = result; - result = new TestForeignNested(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestForeignNested MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestForeignNested.Descriptor; } - } - - public override TestForeignNested DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestForeignNested.DefaultInstance; } - } - - public override TestForeignNested BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestForeignNested) { - return MergeFrom((TestForeignNested) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestForeignNested other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestForeignNested.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasForeignNested) { - MergeForeignNested(other.ForeignNested); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testForeignNestedFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testForeignNestedFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); - if (result.hasForeignNested) { - subBuilder.MergeFrom(ForeignNested); - } - input.ReadMessage(subBuilder, extensionRegistry); - ForeignNested = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasForeignNested { - get { return result.hasForeignNested; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage ForeignNested { - get { return result.ForeignNested; } - set { SetForeignNested(value); } - } - public Builder SetForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasForeignNested = true; - result.foreignNested_ = value; - return this; - } - public Builder SetForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasForeignNested = true; - result.foreignNested_ = builderForValue.Build(); - return this; - } - public Builder MergeForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasForeignNested && - result.foreignNested_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { - result.foreignNested_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.foreignNested_).MergeFrom(value).BuildPartial(); - } else { - result.foreignNested_ = value; - } - result.hasForeignNested = true; - return this; - } - public Builder ClearForeignNested() { - PrepareBuilder(); - result.hasForeignNested = false; - result.foreignNested_ = null; - return this; - } - } - static TestForeignNested() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestEmptyMessage : pb::GeneratedMessage { - private TestEmptyMessage() { } - private static readonly TestEmptyMessage defaultInstance = new TestEmptyMessage().MakeReadOnly(); - private static readonly string[] _testEmptyMessageFieldNames = new string[] { }; - private static readonly uint[] _testEmptyMessageFieldTags = new uint[] { }; - public static TestEmptyMessage DefaultInstance { - get { return defaultInstance; } - } - - public override TestEmptyMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestEmptyMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestEmptyMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testEmptyMessageFieldNames; - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestEmptyMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestEmptyMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestEmptyMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestEmptyMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestEmptyMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestEmptyMessage result; - - private TestEmptyMessage PrepareBuilder() { - if (resultIsReadOnly) { - TestEmptyMessage original = result; - result = new TestEmptyMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestEmptyMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.Descriptor; } - } - - public override TestEmptyMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.DefaultInstance; } - } - - public override TestEmptyMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestEmptyMessage) { - return MergeFrom((TestEmptyMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestEmptyMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testEmptyMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static TestEmptyMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestEmptyMessageWithExtensions : pb::ExtendableMessage { - private TestEmptyMessageWithExtensions() { } - private static readonly TestEmptyMessageWithExtensions defaultInstance = new TestEmptyMessageWithExtensions().MakeReadOnly(); - private static readonly string[] _testEmptyMessageWithExtensionsFieldNames = new string[] { }; - private static readonly uint[] _testEmptyMessageWithExtensionsFieldTags = new uint[] { }; - public static TestEmptyMessageWithExtensions DefaultInstance { - get { return defaultInstance; } - } - - public override TestEmptyMessageWithExtensions DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestEmptyMessageWithExtensions ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testEmptyMessageWithExtensionsFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(536870912, output); - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestEmptyMessageWithExtensions ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestEmptyMessageWithExtensions MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestEmptyMessageWithExtensions prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestEmptyMessageWithExtensions cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestEmptyMessageWithExtensions result; - - private TestEmptyMessageWithExtensions PrepareBuilder() { - if (resultIsReadOnly) { - TestEmptyMessageWithExtensions original = result; - result = new TestEmptyMessageWithExtensions(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestEmptyMessageWithExtensions MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.Descriptor; } - } - - public override TestEmptyMessageWithExtensions DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.DefaultInstance; } - } - - public override TestEmptyMessageWithExtensions BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestEmptyMessageWithExtensions) { - return MergeFrom((TestEmptyMessageWithExtensions) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestEmptyMessageWithExtensions other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageWithExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testEmptyMessageWithExtensionsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static TestEmptyMessageWithExtensions() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestMultipleExtensionRanges : pb::ExtendableMessage { - private TestMultipleExtensionRanges() { } - private static readonly TestMultipleExtensionRanges defaultInstance = new TestMultipleExtensionRanges().MakeReadOnly(); - private static readonly string[] _testMultipleExtensionRangesFieldNames = new string[] { }; - private static readonly uint[] _testMultipleExtensionRangesFieldTags = new uint[] { }; - public static TestMultipleExtensionRanges DefaultInstance { - get { return defaultInstance; } - } - - public override TestMultipleExtensionRanges DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestMultipleExtensionRanges ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testMultipleExtensionRangesFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(43, output); - extensionWriter.WriteUntil(4244, output); - extensionWriter.WriteUntil(536870912, output); - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestMultipleExtensionRanges ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestMultipleExtensionRanges MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestMultipleExtensionRanges prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestMultipleExtensionRanges cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestMultipleExtensionRanges result; - - private TestMultipleExtensionRanges PrepareBuilder() { - if (resultIsReadOnly) { - TestMultipleExtensionRanges original = result; - result = new TestMultipleExtensionRanges(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestMultipleExtensionRanges MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.Descriptor; } - } - - public override TestMultipleExtensionRanges DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.DefaultInstance; } - } - - public override TestMultipleExtensionRanges BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestMultipleExtensionRanges) { - return MergeFrom((TestMultipleExtensionRanges) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestMultipleExtensionRanges other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testMultipleExtensionRangesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testMultipleExtensionRangesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static TestMultipleExtensionRanges() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestReallyLargeTagNumber : pb::GeneratedMessage { - private TestReallyLargeTagNumber() { } - private static readonly TestReallyLargeTagNumber defaultInstance = new TestReallyLargeTagNumber().MakeReadOnly(); - private static readonly string[] _testReallyLargeTagNumberFieldNames = new string[] { "a", "bb" }; - private static readonly uint[] _testReallyLargeTagNumberFieldTags = new uint[] { 8, 2147483640 }; - public static TestReallyLargeTagNumber DefaultInstance { - get { return defaultInstance; } - } - - public override TestReallyLargeTagNumber DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestReallyLargeTagNumber ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable; } - } - - public const int AFieldNumber = 1; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public const int BbFieldNumber = 268435455; - private bool hasBb; - private int bb_; - public bool HasBb { - get { return hasBb; } - } - public int Bb { - get { return bb_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testReallyLargeTagNumberFieldNames; - if (hasA) { - output.WriteInt32(1, field_names[0], A); - } - if (hasBb) { - output.WriteInt32(268435455, field_names[1], Bb); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A); - } - if (hasBb) { - size += pb::CodedOutputStream.ComputeInt32Size(268435455, Bb); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestReallyLargeTagNumber ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestReallyLargeTagNumber MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestReallyLargeTagNumber prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestReallyLargeTagNumber cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestReallyLargeTagNumber result; - - private TestReallyLargeTagNumber PrepareBuilder() { - if (resultIsReadOnly) { - TestReallyLargeTagNumber original = result; - result = new TestReallyLargeTagNumber(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestReallyLargeTagNumber MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.Descriptor; } - } - - public override TestReallyLargeTagNumber DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.DefaultInstance; } - } - - public override TestReallyLargeTagNumber BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestReallyLargeTagNumber) { - return MergeFrom((TestReallyLargeTagNumber) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestReallyLargeTagNumber other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - if (other.HasBb) { - Bb = other.Bb; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testReallyLargeTagNumberFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testReallyLargeTagNumberFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - case 2147483640: { - result.hasBb = input.ReadInt32(ref result.bb_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - - public bool HasBb { - get { return result.hasBb; } - } - public int Bb { - get { return result.Bb; } - set { SetBb(value); } - } - public Builder SetBb(int value) { - PrepareBuilder(); - result.hasBb = true; - result.bb_ = value; - return this; - } - public Builder ClearBb() { - PrepareBuilder(); - result.hasBb = false; - result.bb_ = 0; - return this; - } - } - static TestReallyLargeTagNumber() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestRecursiveMessage : pb::GeneratedMessage { - private TestRecursiveMessage() { } - private static readonly TestRecursiveMessage defaultInstance = new TestRecursiveMessage().MakeReadOnly(); - private static readonly string[] _testRecursiveMessageFieldNames = new string[] { "a", "i" }; - private static readonly uint[] _testRecursiveMessageFieldTags = new uint[] { 10, 16 }; - public static TestRecursiveMessage DefaultInstance { - get { return defaultInstance; } - } - - public override TestRecursiveMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestRecursiveMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable; } - } - - public const int AFieldNumber = 1; - private bool hasA; - private global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage a_; - public bool HasA { - get { return hasA; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage A { - get { return a_ ?? global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance; } - } - - public const int IFieldNumber = 2; - private bool hasI; - private int i_; - public bool HasI { - get { return hasI; } - } - public int I { - get { return i_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testRecursiveMessageFieldNames; - if (hasA) { - output.WriteMessage(1, field_names[0], A); - } - if (hasI) { - output.WriteInt32(2, field_names[1], I); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeMessageSize(1, A); - } - if (hasI) { - size += pb::CodedOutputStream.ComputeInt32Size(2, I); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestRecursiveMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestRecursiveMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestRecursiveMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestRecursiveMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestRecursiveMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestRecursiveMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestRecursiveMessage result; - - private TestRecursiveMessage PrepareBuilder() { - if (resultIsReadOnly) { - TestRecursiveMessage original = result; - result = new TestRecursiveMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestRecursiveMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Descriptor; } - } - - public override TestRecursiveMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance; } - } - - public override TestRecursiveMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestRecursiveMessage) { - return MergeFrom((TestRecursiveMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestRecursiveMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - MergeA(other.A); - } - if (other.HasI) { - I = other.I; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testRecursiveMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testRecursiveMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.CreateBuilder(); - if (result.hasA) { - subBuilder.MergeFrom(A); - } - input.ReadMessage(subBuilder, extensionRegistry); - A = subBuilder.BuildPartial(); - break; - } - case 16: { - result.hasI = input.ReadInt32(ref result.i_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasA = true; - result.a_ = builderForValue.Build(); - return this; - } - public Builder MergeA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasA && - result.a_ != global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance) { - result.a_ = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.CreateBuilder(result.a_).MergeFrom(value).BuildPartial(); - } else { - result.a_ = value; - } - result.hasA = true; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = null; - return this; - } - - public bool HasI { - get { return result.hasI; } - } - public int I { - get { return result.I; } - set { SetI(value); } - } - public Builder SetI(int value) { - PrepareBuilder(); - result.hasI = true; - result.i_ = value; - return this; - } - public Builder ClearI() { - PrepareBuilder(); - result.hasI = false; - result.i_ = 0; - return this; - } - } - static TestRecursiveMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestMutualRecursionA : pb::GeneratedMessage { - private TestMutualRecursionA() { } - private static readonly TestMutualRecursionA defaultInstance = new TestMutualRecursionA().MakeReadOnly(); - private static readonly string[] _testMutualRecursionAFieldNames = new string[] { "bb" }; - private static readonly uint[] _testMutualRecursionAFieldTags = new uint[] { 10 }; - public static TestMutualRecursionA DefaultInstance { - get { return defaultInstance; } - } - - public override TestMutualRecursionA DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestMutualRecursionA ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable; } - } - - public const int BbFieldNumber = 1; - private bool hasBb; - private global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB bb_; - public bool HasBb { - get { return hasBb; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB Bb { - get { return bb_ ?? global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testMutualRecursionAFieldNames; - if (hasBb) { - output.WriteMessage(1, field_names[0], Bb); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasBb) { - size += pb::CodedOutputStream.ComputeMessageSize(1, Bb); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestMutualRecursionA ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionA ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestMutualRecursionA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestMutualRecursionA MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestMutualRecursionA prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestMutualRecursionA cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestMutualRecursionA result; - - private TestMutualRecursionA PrepareBuilder() { - if (resultIsReadOnly) { - TestMutualRecursionA original = result; - result = new TestMutualRecursionA(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestMutualRecursionA MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Descriptor; } - } - - public override TestMutualRecursionA DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance; } - } - - public override TestMutualRecursionA BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestMutualRecursionA) { - return MergeFrom((TestMutualRecursionA) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestMutualRecursionA other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasBb) { - MergeBb(other.Bb); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testMutualRecursionAFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testMutualRecursionAFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.CreateBuilder(); - if (result.hasBb) { - subBuilder.MergeFrom(Bb); - } - input.ReadMessage(subBuilder, extensionRegistry); - Bb = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasBb { - get { return result.hasBb; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB Bb { - get { return result.Bb; } - set { SetBb(value); } - } - public Builder SetBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBb = true; - result.bb_ = value; - return this; - } - public Builder SetBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasBb = true; - result.bb_ = builderForValue.Build(); - return this; - } - public Builder MergeBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasBb && - result.bb_ != global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance) { - result.bb_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.CreateBuilder(result.bb_).MergeFrom(value).BuildPartial(); - } else { - result.bb_ = value; - } - result.hasBb = true; - return this; - } - public Builder ClearBb() { - PrepareBuilder(); - result.hasBb = false; - result.bb_ = null; - return this; - } - } - static TestMutualRecursionA() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestMutualRecursionB : pb::GeneratedMessage { - private TestMutualRecursionB() { } - private static readonly TestMutualRecursionB defaultInstance = new TestMutualRecursionB().MakeReadOnly(); - private static readonly string[] _testMutualRecursionBFieldNames = new string[] { "a", "optional_int32" }; - private static readonly uint[] _testMutualRecursionBFieldTags = new uint[] { 10, 16 }; - public static TestMutualRecursionB DefaultInstance { - get { return defaultInstance; } - } - - public override TestMutualRecursionB DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestMutualRecursionB ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable; } - } - - public const int AFieldNumber = 1; - private bool hasA; - private global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA a_; - public bool HasA { - get { return hasA; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA A { - get { return a_ ?? global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance; } - } - - public const int OptionalInt32FieldNumber = 2; - private bool hasOptionalInt32; - private int optionalInt32_; - public bool HasOptionalInt32 { - get { return hasOptionalInt32; } - } - public int OptionalInt32 { - get { return optionalInt32_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testMutualRecursionBFieldNames; - if (hasA) { - output.WriteMessage(1, field_names[0], A); - } - if (hasOptionalInt32) { - output.WriteInt32(2, field_names[1], OptionalInt32); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeMessageSize(1, A); - } - if (hasOptionalInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(2, OptionalInt32); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestMutualRecursionB ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionB ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestMutualRecursionB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestMutualRecursionB MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestMutualRecursionB prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestMutualRecursionB cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestMutualRecursionB result; - - private TestMutualRecursionB PrepareBuilder() { - if (resultIsReadOnly) { - TestMutualRecursionB original = result; - result = new TestMutualRecursionB(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestMutualRecursionB MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Descriptor; } - } - - public override TestMutualRecursionB DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance; } - } - - public override TestMutualRecursionB BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestMutualRecursionB) { - return MergeFrom((TestMutualRecursionB) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestMutualRecursionB other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - MergeA(other.A); - } - if (other.HasOptionalInt32) { - OptionalInt32 = other.OptionalInt32; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testMutualRecursionBFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testMutualRecursionBFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.CreateBuilder(); - if (result.hasA) { - subBuilder.MergeFrom(A); - } - input.ReadMessage(subBuilder, extensionRegistry); - A = subBuilder.BuildPartial(); - break; - } - case 16: { - result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasA = true; - result.a_ = builderForValue.Build(); - return this; - } - public Builder MergeA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasA && - result.a_ != global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance) { - result.a_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.CreateBuilder(result.a_).MergeFrom(value).BuildPartial(); - } else { - result.a_ = value; - } - result.hasA = true; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = null; - return this; - } - - public bool HasOptionalInt32 { - get { return result.hasOptionalInt32; } - } - public int OptionalInt32 { - get { return result.OptionalInt32; } - set { SetOptionalInt32(value); } - } - public Builder SetOptionalInt32(int value) { - PrepareBuilder(); - result.hasOptionalInt32 = true; - result.optionalInt32_ = value; - return this; - } - public Builder ClearOptionalInt32() { - PrepareBuilder(); - result.hasOptionalInt32 = false; - result.optionalInt32_ = 0; - return this; - } - } - static TestMutualRecursionB() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestDupFieldNumber : pb::GeneratedMessage { - private TestDupFieldNumber() { } - private static readonly TestDupFieldNumber defaultInstance = new TestDupFieldNumber().MakeReadOnly(); - private static readonly string[] _testDupFieldNumberFieldNames = new string[] { "a", "bar", "foo" }; - private static readonly uint[] _testDupFieldNumberFieldTags = new uint[] { 8, 27, 19 }; - public static TestDupFieldNumber DefaultInstance { - get { return defaultInstance; } - } - - public override TestDupFieldNumber DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestDupFieldNumber ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Foo : pb::GeneratedMessage { - private Foo() { } - private static readonly Foo defaultInstance = new Foo().MakeReadOnly(); - private static readonly string[] _fooFieldNames = new string[] { "a" }; - private static readonly uint[] _fooFieldTags = new uint[] { 8 }; - public static Foo DefaultInstance { - get { return defaultInstance; } - } - - public override Foo DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override Foo ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable; } - } - - public const int AFieldNumber = 1; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooFieldNames; - if (hasA) { - output.WriteInt32(1, field_names[0], A); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static Foo ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Foo ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Foo ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Foo ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Foo ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Foo ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static Foo ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static Foo ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static Foo ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Foo ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private Foo MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Foo prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Foo cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Foo result; - - private Foo PrepareBuilder() { - if (resultIsReadOnly) { - Foo original = result; - result = new Foo(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Foo MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Descriptor; } - } - - public override Foo DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance; } - } - - public override Foo BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is Foo) { - return MergeFrom((Foo) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(Foo other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static Foo() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Bar : pb::GeneratedMessage { - private Bar() { } - private static readonly Bar defaultInstance = new Bar().MakeReadOnly(); - private static readonly string[] _barFieldNames = new string[] { "a" }; - private static readonly uint[] _barFieldTags = new uint[] { 8 }; - public static Bar DefaultInstance { - get { return defaultInstance; } - } - - public override Bar DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override Bar ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable; } - } - - public const int AFieldNumber = 1; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _barFieldNames; - if (hasA) { - output.WriteInt32(1, field_names[0], A); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static Bar ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Bar ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Bar ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Bar ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Bar ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Bar ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static Bar ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static Bar ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static Bar ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Bar ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private Bar MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Bar prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Bar cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Bar result; - - private Bar PrepareBuilder() { - if (resultIsReadOnly) { - Bar original = result; - result = new Bar(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Bar MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Descriptor; } - } - - public override Bar DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance; } - } - - public override Bar BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is Bar) { - return MergeFrom((Bar) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(Bar other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_barFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _barFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static Bar() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - } - #endregion - - public const int AFieldNumber = 1; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public const int FooFieldNumber = 2; - private bool hasFoo; - private global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo foo_; - public bool HasFoo { - get { return hasFoo; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo Foo { - get { return foo_ ?? global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance; } - } - - public const int BarFieldNumber = 3; - private bool hasBar; - private global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar bar_; - public bool HasBar { - get { return hasBar; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar Bar { - get { return bar_ ?? global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testDupFieldNumberFieldNames; - if (hasA) { - output.WriteInt32(1, field_names[0], A); - } - if (hasFoo) { - output.WriteGroup(2, field_names[2], Foo); - } - if (hasBar) { - output.WriteGroup(3, field_names[1], Bar); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A); - } - if (hasFoo) { - size += pb::CodedOutputStream.ComputeGroupSize(2, Foo); - } - if (hasBar) { - size += pb::CodedOutputStream.ComputeGroupSize(3, Bar); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestDupFieldNumber ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestDupFieldNumber ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestDupFieldNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestDupFieldNumber MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestDupFieldNumber prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestDupFieldNumber cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestDupFieldNumber result; - - private TestDupFieldNumber PrepareBuilder() { - if (resultIsReadOnly) { - TestDupFieldNumber original = result; - result = new TestDupFieldNumber(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestDupFieldNumber MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Descriptor; } - } - - public override TestDupFieldNumber DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.DefaultInstance; } - } - - public override TestDupFieldNumber BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestDupFieldNumber) { - return MergeFrom((TestDupFieldNumber) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestDupFieldNumber other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - if (other.HasFoo) { - MergeFoo(other.Foo); - } - if (other.HasBar) { - MergeBar(other.Bar); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testDupFieldNumberFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testDupFieldNumberFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - case 19: { - global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.CreateBuilder(); - if (result.hasFoo) { - subBuilder.MergeFrom(Foo); - } - input.ReadGroup(2, subBuilder, extensionRegistry); - Foo = subBuilder.BuildPartial(); - break; - } - case 27: { - global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.CreateBuilder(); - if (result.hasBar) { - subBuilder.MergeFrom(Bar); - } - input.ReadGroup(3, subBuilder, extensionRegistry); - Bar = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - - public bool HasFoo { - get { return result.hasFoo; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo Foo { - get { return result.Foo; } - set { SetFoo(value); } - } - public Builder SetFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFoo = true; - result.foo_ = value; - return this; - } - public Builder SetFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasFoo = true; - result.foo_ = builderForValue.Build(); - return this; - } - public Builder MergeFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasFoo && - result.foo_ != global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance) { - result.foo_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.CreateBuilder(result.foo_).MergeFrom(value).BuildPartial(); - } else { - result.foo_ = value; - } - result.hasFoo = true; - return this; - } - public Builder ClearFoo() { - PrepareBuilder(); - result.hasFoo = false; - result.foo_ = null; - return this; - } - - public bool HasBar { - get { return result.hasBar; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar Bar { - get { return result.Bar; } - set { SetBar(value); } - } - public Builder SetBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBar = true; - result.bar_ = value; - return this; - } - public Builder SetBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasBar = true; - result.bar_ = builderForValue.Build(); - return this; - } - public Builder MergeBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasBar && - result.bar_ != global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance) { - result.bar_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.CreateBuilder(result.bar_).MergeFrom(value).BuildPartial(); - } else { - result.bar_ = value; - } - result.hasBar = true; - return this; - } - public Builder ClearBar() { - PrepareBuilder(); - result.hasBar = false; - result.bar_ = null; - return this; - } - } - static TestDupFieldNumber() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestNestedMessageHasBits : pb::GeneratedMessage { - private TestNestedMessageHasBits() { } - private static readonly TestNestedMessageHasBits defaultInstance = new TestNestedMessageHasBits().MakeReadOnly(); - private static readonly string[] _testNestedMessageHasBitsFieldNames = new string[] { "optional_nested_message" }; - private static readonly uint[] _testNestedMessageHasBitsFieldTags = new uint[] { 10 }; - public static TestNestedMessageHasBits DefaultInstance { - get { return defaultInstance; } - } - - public override TestNestedMessageHasBits DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestNestedMessageHasBits ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NestedMessage : pb::GeneratedMessage { - private NestedMessage() { } - private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); - private static readonly string[] _nestedMessageFieldNames = new string[] { "nestedmessage_repeated_foreignmessage", "nestedmessage_repeated_int32" }; - private static readonly uint[] _nestedMessageFieldTags = new uint[] { 18, 8 }; - public static NestedMessage DefaultInstance { - get { return defaultInstance; } - } - - public override NestedMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override NestedMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable; } - } - - public const int NestedmessageRepeatedInt32FieldNumber = 1; - private pbc::PopsicleList nestedmessageRepeatedInt32_ = new pbc::PopsicleList(); - public scg::IList NestedmessageRepeatedInt32List { - get { return pbc::Lists.AsReadOnly(nestedmessageRepeatedInt32_); } - } - public int NestedmessageRepeatedInt32Count { - get { return nestedmessageRepeatedInt32_.Count; } - } - public int GetNestedmessageRepeatedInt32(int index) { - return nestedmessageRepeatedInt32_[index]; - } - - public const int NestedmessageRepeatedForeignmessageFieldNumber = 2; - private pbc::PopsicleList nestedmessageRepeatedForeignmessage_ = new pbc::PopsicleList(); - public scg::IList NestedmessageRepeatedForeignmessageList { - get { return nestedmessageRepeatedForeignmessage_; } - } - public int NestedmessageRepeatedForeignmessageCount { - get { return nestedmessageRepeatedForeignmessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetNestedmessageRepeatedForeignmessage(int index) { - return nestedmessageRepeatedForeignmessage_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _nestedMessageFieldNames; - if (nestedmessageRepeatedInt32_.Count > 0) { - output.WriteInt32Array(1, field_names[1], nestedmessageRepeatedInt32_); - } - if (nestedmessageRepeatedForeignmessage_.Count > 0) { - output.WriteMessageArray(2, field_names[0], nestedmessageRepeatedForeignmessage_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (int element in NestedmessageRepeatedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 1 * nestedmessageRepeatedInt32_.Count; - } - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in NestedmessageRepeatedForeignmessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(2, element); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static NestedMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NestedMessage MakeReadOnly() { - nestedmessageRepeatedInt32_.MakeReadOnly(); - nestedmessageRepeatedForeignmessage_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NestedMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NestedMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NestedMessage result; - - private NestedMessage PrepareBuilder() { - if (resultIsReadOnly) { - NestedMessage original = result; - result = new NestedMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NestedMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Descriptor; } - } - - public override NestedMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance; } - } - - public override NestedMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is NestedMessage) { - return MergeFrom((NestedMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(NestedMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.nestedmessageRepeatedInt32_.Count != 0) { - result.nestedmessageRepeatedInt32_.Add(other.nestedmessageRepeatedInt32_); - } - if (other.nestedmessageRepeatedForeignmessage_.Count != 0) { - result.nestedmessageRepeatedForeignmessage_.Add(other.nestedmessageRepeatedForeignmessage_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _nestedMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: - case 8: { - input.ReadInt32Array(tag, field_name, result.nestedmessageRepeatedInt32_); - break; - } - case 18: { - input.ReadMessageArray(tag, field_name, result.nestedmessageRepeatedForeignmessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public pbc::IPopsicleList NestedmessageRepeatedInt32List { - get { return PrepareBuilder().nestedmessageRepeatedInt32_; } - } - public int NestedmessageRepeatedInt32Count { - get { return result.NestedmessageRepeatedInt32Count; } - } - public int GetNestedmessageRepeatedInt32(int index) { - return result.GetNestedmessageRepeatedInt32(index); - } - public Builder SetNestedmessageRepeatedInt32(int index, int value) { - PrepareBuilder(); - result.nestedmessageRepeatedInt32_[index] = value; - return this; - } - public Builder AddNestedmessageRepeatedInt32(int value) { - PrepareBuilder(); - result.nestedmessageRepeatedInt32_.Add(value); - return this; - } - public Builder AddRangeNestedmessageRepeatedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.nestedmessageRepeatedInt32_.Add(values); - return this; - } - public Builder ClearNestedmessageRepeatedInt32() { - PrepareBuilder(); - result.nestedmessageRepeatedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList NestedmessageRepeatedForeignmessageList { - get { return PrepareBuilder().nestedmessageRepeatedForeignmessage_; } - } - public int NestedmessageRepeatedForeignmessageCount { - get { return result.NestedmessageRepeatedForeignmessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetNestedmessageRepeatedForeignmessage(int index) { - return result.GetNestedmessageRepeatedForeignmessage(index); - } - public Builder SetNestedmessageRepeatedForeignmessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_[index] = value; - return this; - } - public Builder SetNestedmessageRepeatedForeignmessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddNestedmessageRepeatedForeignmessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_.Add(value); - return this; - } - public Builder AddNestedmessageRepeatedForeignmessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeNestedmessageRepeatedForeignmessage(scg::IEnumerable values) { - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_.Add(values); - return this; - } - public Builder ClearNestedmessageRepeatedForeignmessage() { - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_.Clear(); - return this; - } - } - static NestedMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - } - #endregion - - public const int OptionalNestedMessageFieldNumber = 1; - private bool hasOptionalNestedMessage; - private global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage optionalNestedMessage_; - public bool HasOptionalNestedMessage { - get { return hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage OptionalNestedMessage { - get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testNestedMessageHasBitsFieldNames; - if (hasOptionalNestedMessage) { - output.WriteMessage(1, field_names[0], OptionalNestedMessage); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasOptionalNestedMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(1, OptionalNestedMessage); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestNestedMessageHasBits ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestNestedMessageHasBits ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestNestedMessageHasBits MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestNestedMessageHasBits prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestNestedMessageHasBits cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestNestedMessageHasBits result; - - private TestNestedMessageHasBits PrepareBuilder() { - if (resultIsReadOnly) { - TestNestedMessageHasBits original = result; - result = new TestNestedMessageHasBits(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestNestedMessageHasBits MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Descriptor; } - } - - public override TestNestedMessageHasBits DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.DefaultInstance; } - } - - public override TestNestedMessageHasBits BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestNestedMessageHasBits) { - return MergeFrom((TestNestedMessageHasBits) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestNestedMessageHasBits other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasOptionalNestedMessage) { - MergeOptionalNestedMessage(other.OptionalNestedMessage); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testNestedMessageHasBitsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testNestedMessageHasBitsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.CreateBuilder(); - if (result.hasOptionalNestedMessage) { - subBuilder.MergeFrom(OptionalNestedMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalNestedMessage = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasOptionalNestedMessage { - get { return result.hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage OptionalNestedMessage { - get { return result.OptionalNestedMessage; } - set { SetOptionalNestedMessage(value); } - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = value; - return this; - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalNestedMessage && - result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance) { - result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalNestedMessage_ = value; - } - result.hasOptionalNestedMessage = true; - return this; - } - public Builder ClearOptionalNestedMessage() { - PrepareBuilder(); - result.hasOptionalNestedMessage = false; - result.optionalNestedMessage_ = null; - return this; - } - } - static TestNestedMessageHasBits() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestCamelCaseFieldNames : pb::GeneratedMessage { - private TestCamelCaseFieldNames() { } - private static readonly TestCamelCaseFieldNames defaultInstance = new TestCamelCaseFieldNames().MakeReadOnly(); - private static readonly string[] _testCamelCaseFieldNamesFieldNames = new string[] { "CordField", "EnumField", "MessageField", "PrimitiveField", "RepeatedCordField", "RepeatedEnumField", "RepeatedMessageField", "RepeatedPrimitiveField", "RepeatedStringField", "RepeatedStringPieceField", "StringField", "StringPieceField" }; - private static readonly uint[] _testCamelCaseFieldNamesFieldTags = new uint[] { 50, 24, 34, 8, 98, 72, 82, 56, 66, 90, 18, 42 }; - public static TestCamelCaseFieldNames DefaultInstance { - get { return defaultInstance; } - } - - public override TestCamelCaseFieldNames DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestCamelCaseFieldNames ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable; } - } - - public const int PrimitiveFieldFieldNumber = 1; - private bool hasPrimitiveField; - private int primitiveField_; - public bool HasPrimitiveField { - get { return hasPrimitiveField; } - } - public int PrimitiveField { - get { return primitiveField_; } - } - - public const int StringFieldFieldNumber = 2; - private bool hasStringField; - private string stringField_ = ""; - public bool HasStringField { - get { return hasStringField; } - } - public string StringField { - get { return stringField_; } - } - - public const int EnumFieldFieldNumber = 3; - private bool hasEnumField; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnum enumField_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - public bool HasEnumField { - get { return hasEnumField; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumField { - get { return enumField_; } - } - - public const int MessageFieldFieldNumber = 4; - private bool hasMessageField; - private global::Google.ProtocolBuffers.TestProtos.ForeignMessage messageField_; - public bool HasMessageField { - get { return hasMessageField; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageField { - get { return messageField_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } - } - - public const int StringPieceFieldFieldNumber = 5; - private bool hasStringPieceField; - private string stringPieceField_ = ""; - public bool HasStringPieceField { - get { return hasStringPieceField; } - } - public string StringPieceField { - get { return stringPieceField_; } - } - - public const int CordFieldFieldNumber = 6; - private bool hasCordField; - private string cordField_ = ""; - public bool HasCordField { - get { return hasCordField; } - } - public string CordField { - get { return cordField_; } - } - - public const int RepeatedPrimitiveFieldFieldNumber = 7; - private pbc::PopsicleList repeatedPrimitiveField_ = new pbc::PopsicleList(); - public scg::IList RepeatedPrimitiveFieldList { - get { return pbc::Lists.AsReadOnly(repeatedPrimitiveField_); } - } - public int RepeatedPrimitiveFieldCount { - get { return repeatedPrimitiveField_.Count; } - } - public int GetRepeatedPrimitiveField(int index) { - return repeatedPrimitiveField_[index]; - } - - public const int RepeatedStringFieldFieldNumber = 8; - private pbc::PopsicleList repeatedStringField_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringFieldList { - get { return pbc::Lists.AsReadOnly(repeatedStringField_); } - } - public int RepeatedStringFieldCount { - get { return repeatedStringField_.Count; } - } - public string GetRepeatedStringField(int index) { - return repeatedStringField_[index]; - } - - public const int RepeatedEnumFieldFieldNumber = 9; - private pbc::PopsicleList repeatedEnumField_ = new pbc::PopsicleList(); - public scg::IList RepeatedEnumFieldList { - get { return pbc::Lists.AsReadOnly(repeatedEnumField_); } - } - public int RepeatedEnumFieldCount { - get { return repeatedEnumField_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedEnumField(int index) { - return repeatedEnumField_[index]; - } - - public const int RepeatedMessageFieldFieldNumber = 10; - private pbc::PopsicleList repeatedMessageField_ = new pbc::PopsicleList(); - public scg::IList RepeatedMessageFieldList { - get { return repeatedMessageField_; } - } - public int RepeatedMessageFieldCount { - get { return repeatedMessageField_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedMessageField(int index) { - return repeatedMessageField_[index]; - } - - public const int RepeatedStringPieceFieldFieldNumber = 11; - private pbc::PopsicleList repeatedStringPieceField_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringPieceFieldList { - get { return pbc::Lists.AsReadOnly(repeatedStringPieceField_); } - } - public int RepeatedStringPieceFieldCount { - get { return repeatedStringPieceField_.Count; } - } - public string GetRepeatedStringPieceField(int index) { - return repeatedStringPieceField_[index]; - } - - public const int RepeatedCordFieldFieldNumber = 12; - private pbc::PopsicleList repeatedCordField_ = new pbc::PopsicleList(); - public scg::IList RepeatedCordFieldList { - get { return pbc::Lists.AsReadOnly(repeatedCordField_); } - } - public int RepeatedCordFieldCount { - get { return repeatedCordField_.Count; } - } - public string GetRepeatedCordField(int index) { - return repeatedCordField_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testCamelCaseFieldNamesFieldNames; - if (hasPrimitiveField) { - output.WriteInt32(1, field_names[3], PrimitiveField); - } - if (hasStringField) { - output.WriteString(2, field_names[10], StringField); - } - if (hasEnumField) { - output.WriteEnum(3, field_names[1], (int) EnumField, EnumField); - } - if (hasMessageField) { - output.WriteMessage(4, field_names[2], MessageField); - } - if (hasStringPieceField) { - output.WriteString(5, field_names[11], StringPieceField); - } - if (hasCordField) { - output.WriteString(6, field_names[0], CordField); - } - if (repeatedPrimitiveField_.Count > 0) { - output.WriteInt32Array(7, field_names[7], repeatedPrimitiveField_); - } - if (repeatedStringField_.Count > 0) { - output.WriteStringArray(8, field_names[8], repeatedStringField_); - } - if (repeatedEnumField_.Count > 0) { - output.WriteEnumArray(9, field_names[5], repeatedEnumField_); - } - if (repeatedMessageField_.Count > 0) { - output.WriteMessageArray(10, field_names[6], repeatedMessageField_); - } - if (repeatedStringPieceField_.Count > 0) { - output.WriteStringArray(11, field_names[9], repeatedStringPieceField_); - } - if (repeatedCordField_.Count > 0) { - output.WriteStringArray(12, field_names[4], repeatedCordField_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasPrimitiveField) { - size += pb::CodedOutputStream.ComputeInt32Size(1, PrimitiveField); - } - if (hasStringField) { - size += pb::CodedOutputStream.ComputeStringSize(2, StringField); - } - if (hasEnumField) { - size += pb::CodedOutputStream.ComputeEnumSize(3, (int) EnumField); - } - if (hasMessageField) { - size += pb::CodedOutputStream.ComputeMessageSize(4, MessageField); - } - if (hasStringPieceField) { - size += pb::CodedOutputStream.ComputeStringSize(5, StringPieceField); - } - if (hasCordField) { - size += pb::CodedOutputStream.ComputeStringSize(6, CordField); - } - { - int dataSize = 0; - foreach (int element in RepeatedPrimitiveFieldList) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 1 * repeatedPrimitiveField_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedStringFieldList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 1 * repeatedStringField_.Count; - } - { - int dataSize = 0; - if (repeatedEnumField_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedEnumField_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * repeatedEnumField_.Count; - } - } - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedMessageFieldList) { - size += pb::CodedOutputStream.ComputeMessageSize(10, element); - } - { - int dataSize = 0; - foreach (string element in RepeatedStringPieceFieldList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 1 * repeatedStringPieceField_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedCordFieldList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 1 * repeatedCordField_.Count; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestCamelCaseFieldNames ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestCamelCaseFieldNames MakeReadOnly() { - repeatedPrimitiveField_.MakeReadOnly(); - repeatedStringField_.MakeReadOnly(); - repeatedEnumField_.MakeReadOnly(); - repeatedMessageField_.MakeReadOnly(); - repeatedStringPieceField_.MakeReadOnly(); - repeatedCordField_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestCamelCaseFieldNames prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestCamelCaseFieldNames cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestCamelCaseFieldNames result; - - private TestCamelCaseFieldNames PrepareBuilder() { - if (resultIsReadOnly) { - TestCamelCaseFieldNames original = result; - result = new TestCamelCaseFieldNames(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestCamelCaseFieldNames MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.Descriptor; } - } - - public override TestCamelCaseFieldNames DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.DefaultInstance; } - } - - public override TestCamelCaseFieldNames BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestCamelCaseFieldNames) { - return MergeFrom((TestCamelCaseFieldNames) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestCamelCaseFieldNames other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasPrimitiveField) { - PrimitiveField = other.PrimitiveField; - } - if (other.HasStringField) { - StringField = other.StringField; - } - if (other.HasEnumField) { - EnumField = other.EnumField; - } - if (other.HasMessageField) { - MergeMessageField(other.MessageField); - } - if (other.HasStringPieceField) { - StringPieceField = other.StringPieceField; - } - if (other.HasCordField) { - CordField = other.CordField; - } - if (other.repeatedPrimitiveField_.Count != 0) { - result.repeatedPrimitiveField_.Add(other.repeatedPrimitiveField_); - } - if (other.repeatedStringField_.Count != 0) { - result.repeatedStringField_.Add(other.repeatedStringField_); - } - if (other.repeatedEnumField_.Count != 0) { - result.repeatedEnumField_.Add(other.repeatedEnumField_); - } - if (other.repeatedMessageField_.Count != 0) { - result.repeatedMessageField_.Add(other.repeatedMessageField_); - } - if (other.repeatedStringPieceField_.Count != 0) { - result.repeatedStringPieceField_.Add(other.repeatedStringPieceField_); - } - if (other.repeatedCordField_.Count != 0) { - result.repeatedCordField_.Add(other.repeatedCordField_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testCamelCaseFieldNamesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testCamelCaseFieldNamesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasPrimitiveField = input.ReadInt32(ref result.primitiveField_); - break; - } - case 18: { - result.hasStringField = input.ReadString(ref result.stringField_); - break; - } - case 24: { - object unknown; - if(input.ReadEnum(ref result.enumField_, out unknown)) { - result.hasEnumField = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(3, (ulong)(int)unknown); - } - break; - } - case 34: { - global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); - if (result.hasMessageField) { - subBuilder.MergeFrom(MessageField); - } - input.ReadMessage(subBuilder, extensionRegistry); - MessageField = subBuilder.BuildPartial(); - break; - } - case 42: { - result.hasStringPieceField = input.ReadString(ref result.stringPieceField_); - break; - } - case 50: { - result.hasCordField = input.ReadString(ref result.cordField_); - break; - } - case 58: - case 56: { - input.ReadInt32Array(tag, field_name, result.repeatedPrimitiveField_); - break; - } - case 66: { - input.ReadStringArray(tag, field_name, result.repeatedStringField_); - break; - } - case 74: - case 72: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedEnumField_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(9, (ulong)(int)rawValue); - } - break; - } - case 82: { - input.ReadMessageArray(tag, field_name, result.repeatedMessageField_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); - break; - } - case 90: { - input.ReadStringArray(tag, field_name, result.repeatedStringPieceField_); - break; - } - case 98: { - input.ReadStringArray(tag, field_name, result.repeatedCordField_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasPrimitiveField { - get { return result.hasPrimitiveField; } - } - public int PrimitiveField { - get { return result.PrimitiveField; } - set { SetPrimitiveField(value); } - } - public Builder SetPrimitiveField(int value) { - PrepareBuilder(); - result.hasPrimitiveField = true; - result.primitiveField_ = value; - return this; - } - public Builder ClearPrimitiveField() { - PrepareBuilder(); - result.hasPrimitiveField = false; - result.primitiveField_ = 0; - return this; - } - - public bool HasStringField { - get { return result.hasStringField; } - } - public string StringField { - get { return result.StringField; } - set { SetStringField(value); } - } - public Builder SetStringField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasStringField = true; - result.stringField_ = value; - return this; - } - public Builder ClearStringField() { - PrepareBuilder(); - result.hasStringField = false; - result.stringField_ = ""; - return this; - } - - public bool HasEnumField { - get { return result.hasEnumField; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumField { - get { return result.EnumField; } - set { SetEnumField(value); } - } - public Builder SetEnumField(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.hasEnumField = true; - result.enumField_ = value; - return this; - } - public Builder ClearEnumField() { - PrepareBuilder(); - result.hasEnumField = false; - result.enumField_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - return this; - } - - public bool HasMessageField { - get { return result.hasMessageField; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageField { - get { return result.MessageField; } - set { SetMessageField(value); } - } - public Builder SetMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasMessageField = true; - result.messageField_ = value; - return this; - } - public Builder SetMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasMessageField = true; - result.messageField_ = builderForValue.Build(); - return this; - } - public Builder MergeMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasMessageField && - result.messageField_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) { - result.messageField_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.messageField_).MergeFrom(value).BuildPartial(); - } else { - result.messageField_ = value; - } - result.hasMessageField = true; - return this; - } - public Builder ClearMessageField() { - PrepareBuilder(); - result.hasMessageField = false; - result.messageField_ = null; - return this; - } - - public bool HasStringPieceField { - get { return result.hasStringPieceField; } - } - public string StringPieceField { - get { return result.StringPieceField; } - set { SetStringPieceField(value); } - } - public Builder SetStringPieceField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasStringPieceField = true; - result.stringPieceField_ = value; - return this; - } - public Builder ClearStringPieceField() { - PrepareBuilder(); - result.hasStringPieceField = false; - result.stringPieceField_ = ""; - return this; - } - - public bool HasCordField { - get { return result.hasCordField; } - } - public string CordField { - get { return result.CordField; } - set { SetCordField(value); } - } - public Builder SetCordField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasCordField = true; - result.cordField_ = value; - return this; - } - public Builder ClearCordField() { - PrepareBuilder(); - result.hasCordField = false; - result.cordField_ = ""; - return this; - } - - public pbc::IPopsicleList RepeatedPrimitiveFieldList { - get { return PrepareBuilder().repeatedPrimitiveField_; } - } - public int RepeatedPrimitiveFieldCount { - get { return result.RepeatedPrimitiveFieldCount; } - } - public int GetRepeatedPrimitiveField(int index) { - return result.GetRepeatedPrimitiveField(index); - } - public Builder SetRepeatedPrimitiveField(int index, int value) { - PrepareBuilder(); - result.repeatedPrimitiveField_[index] = value; - return this; - } - public Builder AddRepeatedPrimitiveField(int value) { - PrepareBuilder(); - result.repeatedPrimitiveField_.Add(value); - return this; - } - public Builder AddRangeRepeatedPrimitiveField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedPrimitiveField_.Add(values); - return this; - } - public Builder ClearRepeatedPrimitiveField() { - PrepareBuilder(); - result.repeatedPrimitiveField_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringFieldList { - get { return PrepareBuilder().repeatedStringField_; } - } - public int RepeatedStringFieldCount { - get { return result.RepeatedStringFieldCount; } - } - public string GetRepeatedStringField(int index) { - return result.GetRepeatedStringField(index); - } - public Builder SetRepeatedStringField(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringField_[index] = value; - return this; - } - public Builder AddRepeatedStringField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringField_.Add(value); - return this; - } - public Builder AddRangeRepeatedStringField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedStringField_.Add(values); - return this; - } - public Builder ClearRepeatedStringField() { - PrepareBuilder(); - result.repeatedStringField_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedEnumFieldList { - get { return PrepareBuilder().repeatedEnumField_; } - } - public int RepeatedEnumFieldCount { - get { return result.RepeatedEnumFieldCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedEnumField(int index) { - return result.GetRepeatedEnumField(index); - } - public Builder SetRepeatedEnumField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.repeatedEnumField_[index] = value; - return this; - } - public Builder AddRepeatedEnumField(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.repeatedEnumField_.Add(value); - return this; - } - public Builder AddRangeRepeatedEnumField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedEnumField_.Add(values); - return this; - } - public Builder ClearRepeatedEnumField() { - PrepareBuilder(); - result.repeatedEnumField_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedMessageFieldList { - get { return PrepareBuilder().repeatedMessageField_; } - } - public int RepeatedMessageFieldCount { - get { return result.RepeatedMessageFieldCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedMessageField(int index) { - return result.GetRepeatedMessageField(index); - } - public Builder SetRepeatedMessageField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedMessageField_[index] = value; - return this; - } - public Builder SetRepeatedMessageField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedMessageField_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedMessageField_.Add(value); - return this; - } - public Builder AddRepeatedMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedMessageField_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedMessageField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedMessageField_.Add(values); - return this; - } - public Builder ClearRepeatedMessageField() { - PrepareBuilder(); - result.repeatedMessageField_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringPieceFieldList { - get { return PrepareBuilder().repeatedStringPieceField_; } - } - public int RepeatedStringPieceFieldCount { - get { return result.RepeatedStringPieceFieldCount; } - } - public string GetRepeatedStringPieceField(int index) { - return result.GetRepeatedStringPieceField(index); - } - public Builder SetRepeatedStringPieceField(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPieceField_[index] = value; - return this; - } - public Builder AddRepeatedStringPieceField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPieceField_.Add(value); - return this; - } - public Builder AddRangeRepeatedStringPieceField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedStringPieceField_.Add(values); - return this; - } - public Builder ClearRepeatedStringPieceField() { - PrepareBuilder(); - result.repeatedStringPieceField_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedCordFieldList { - get { return PrepareBuilder().repeatedCordField_; } - } - public int RepeatedCordFieldCount { - get { return result.RepeatedCordFieldCount; } - } - public string GetRepeatedCordField(int index) { - return result.GetRepeatedCordField(index); - } - public Builder SetRepeatedCordField(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCordField_[index] = value; - return this; - } - public Builder AddRepeatedCordField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCordField_.Add(value); - return this; - } - public Builder AddRangeRepeatedCordField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedCordField_.Add(values); - return this; - } - public Builder ClearRepeatedCordField() { - PrepareBuilder(); - result.repeatedCordField_.Clear(); - return this; - } - } - static TestCamelCaseFieldNames() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestFieldOrderings : pb::ExtendableMessage { - private TestFieldOrderings() { } - private static readonly TestFieldOrderings defaultInstance = new TestFieldOrderings().MakeReadOnly(); - private static readonly string[] _testFieldOrderingsFieldNames = new string[] { "my_float", "my_int", "my_string" }; - private static readonly uint[] _testFieldOrderingsFieldTags = new uint[] { 813, 8, 90 }; - public static TestFieldOrderings DefaultInstance { - get { return defaultInstance; } - } - - public override TestFieldOrderings DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestFieldOrderings ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestFieldOrderings__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable; } - } - - public const int MyStringFieldNumber = 11; - private bool hasMyString; - private string myString_ = ""; - public bool HasMyString { - get { return hasMyString; } - } - public string MyString { - get { return myString_; } - } - - public const int MyIntFieldNumber = 1; - private bool hasMyInt; - private long myInt_; - public bool HasMyInt { - get { return hasMyInt; } - } - public long MyInt { - get { return myInt_; } - } - - public const int MyFloatFieldNumber = 101; - private bool hasMyFloat; - private float myFloat_; - public bool HasMyFloat { - get { return hasMyFloat; } - } - public float MyFloat { - get { return myFloat_; } - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testFieldOrderingsFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - if (hasMyInt) { - output.WriteInt64(1, field_names[1], MyInt); - } - extensionWriter.WriteUntil(11, output); - if (hasMyString) { - output.WriteString(11, field_names[2], MyString); - } - extensionWriter.WriteUntil(101, output); - if (hasMyFloat) { - output.WriteFloat(101, field_names[0], MyFloat); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasMyString) { - size += pb::CodedOutputStream.ComputeStringSize(11, MyString); - } - if (hasMyInt) { - size += pb::CodedOutputStream.ComputeInt64Size(1, MyInt); - } - if (hasMyFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(101, MyFloat); - } - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestFieldOrderings ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestFieldOrderings ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestFieldOrderings ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestFieldOrderings MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestFieldOrderings prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestFieldOrderings cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestFieldOrderings result; - - private TestFieldOrderings PrepareBuilder() { - if (resultIsReadOnly) { - TestFieldOrderings original = result; - result = new TestFieldOrderings(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestFieldOrderings MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Descriptor; } - } - - public override TestFieldOrderings DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.DefaultInstance; } - } - - public override TestFieldOrderings BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestFieldOrderings) { - return MergeFrom((TestFieldOrderings) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestFieldOrderings other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasMyString) { - MyString = other.MyString; - } - if (other.HasMyInt) { - MyInt = other.MyInt; - } - if (other.HasMyFloat) { - MyFloat = other.MyFloat; - } - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testFieldOrderingsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testFieldOrderingsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasMyInt = input.ReadInt64(ref result.myInt_); - break; - } - case 90: { - result.hasMyString = input.ReadString(ref result.myString_); - break; - } - case 813: { - result.hasMyFloat = input.ReadFloat(ref result.myFloat_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasMyString { - get { return result.hasMyString; } - } - public string MyString { - get { return result.MyString; } - set { SetMyString(value); } - } - public Builder SetMyString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasMyString = true; - result.myString_ = value; - return this; - } - public Builder ClearMyString() { - PrepareBuilder(); - result.hasMyString = false; - result.myString_ = ""; - return this; - } - - public bool HasMyInt { - get { return result.hasMyInt; } - } - public long MyInt { - get { return result.MyInt; } - set { SetMyInt(value); } - } - public Builder SetMyInt(long value) { - PrepareBuilder(); - result.hasMyInt = true; - result.myInt_ = value; - return this; - } - public Builder ClearMyInt() { - PrepareBuilder(); - result.hasMyInt = false; - result.myInt_ = 0L; - return this; - } - - public bool HasMyFloat { - get { return result.hasMyFloat; } - } - public float MyFloat { - get { return result.MyFloat; } - set { SetMyFloat(value); } - } - public Builder SetMyFloat(float value) { - PrepareBuilder(); - result.hasMyFloat = true; - result.myFloat_ = value; - return this; - } - public Builder ClearMyFloat() { - PrepareBuilder(); - result.hasMyFloat = false; - result.myFloat_ = 0F; - return this; - } - } - static TestFieldOrderings() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestExtremeDefaultValues : pb::GeneratedMessage { - private TestExtremeDefaultValues() { } - private static readonly TestExtremeDefaultValues defaultInstance = new TestExtremeDefaultValues().MakeReadOnly(); - private static readonly string[] _testExtremeDefaultValuesFieldNames = new string[] { "cpp_trigraph", "escaped_bytes", "inf_double", "inf_float", "large_float", "large_uint32", "large_uint64", "nan_double", "nan_float", "neg_inf_double", "neg_inf_float", "negative_float", "negative_one_float", "one_float", "small_float", "small_int32", "small_int64", "small_negative_float", "utf8_string", "zero_float" }; - private static readonly uint[] _testExtremeDefaultValuesFieldTags = new uint[] { 162, 10, 113, 141, 101, 16, 24, 129, 157, 121, 149, 93, 85, 69, 77, 32, 40, 109, 50, 61 }; - public static TestExtremeDefaultValues DefaultInstance { - get { return defaultInstance; } - } - - public override TestExtremeDefaultValues DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestExtremeDefaultValues ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable; } - } - - public const int EscapedBytesFieldNumber = 1; - private bool hasEscapedBytes; - private pb::ByteString escapedBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[0].DefaultValue; - public bool HasEscapedBytes { - get { return hasEscapedBytes; } - } - public pb::ByteString EscapedBytes { - get { return escapedBytes_; } - } - - public const int LargeUint32FieldNumber = 2; - private bool hasLargeUint32; - private uint largeUint32_ = 4294967295; - public bool HasLargeUint32 { - get { return hasLargeUint32; } - } - [global::System.CLSCompliant(false)] - public uint LargeUint32 { - get { return largeUint32_; } - } - - public const int LargeUint64FieldNumber = 3; - private bool hasLargeUint64; - private ulong largeUint64_ = 18446744073709551615UL; - public bool HasLargeUint64 { - get { return hasLargeUint64; } - } - [global::System.CLSCompliant(false)] - public ulong LargeUint64 { - get { return largeUint64_; } - } - - public const int SmallInt32FieldNumber = 4; - private bool hasSmallInt32; - private int smallInt32_ = -2147483647; - public bool HasSmallInt32 { - get { return hasSmallInt32; } - } - public int SmallInt32 { - get { return smallInt32_; } - } - - public const int SmallInt64FieldNumber = 5; - private bool hasSmallInt64; - private long smallInt64_ = -9223372036854775807L; - public bool HasSmallInt64 { - get { return hasSmallInt64; } - } - public long SmallInt64 { - get { return smallInt64_; } - } - - public const int Utf8StringFieldNumber = 6; - private bool hasUtf8String; - private string utf8String_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[5].DefaultValue; - public bool HasUtf8String { - get { return hasUtf8String; } - } - public string Utf8String { - get { return utf8String_; } - } - - public const int ZeroFloatFieldNumber = 7; - private bool hasZeroFloat; - private float zeroFloat_; - public bool HasZeroFloat { - get { return hasZeroFloat; } - } - public float ZeroFloat { - get { return zeroFloat_; } - } - - public const int OneFloatFieldNumber = 8; - private bool hasOneFloat; - private float oneFloat_ = 1F; - public bool HasOneFloat { - get { return hasOneFloat; } - } - public float OneFloat { - get { return oneFloat_; } - } - - public const int SmallFloatFieldNumber = 9; - private bool hasSmallFloat; - private float smallFloat_ = 1.5F; - public bool HasSmallFloat { - get { return hasSmallFloat; } - } - public float SmallFloat { - get { return smallFloat_; } - } - - public const int NegativeOneFloatFieldNumber = 10; - private bool hasNegativeOneFloat; - private float negativeOneFloat_ = -1F; - public bool HasNegativeOneFloat { - get { return hasNegativeOneFloat; } - } - public float NegativeOneFloat { - get { return negativeOneFloat_; } - } - - public const int NegativeFloatFieldNumber = 11; - private bool hasNegativeFloat; - private float negativeFloat_ = -1.5F; - public bool HasNegativeFloat { - get { return hasNegativeFloat; } - } - public float NegativeFloat { - get { return negativeFloat_; } - } - - public const int LargeFloatFieldNumber = 12; - private bool hasLargeFloat; - private float largeFloat_ = 2E+08F; - public bool HasLargeFloat { - get { return hasLargeFloat; } - } - public float LargeFloat { - get { return largeFloat_; } - } - - public const int SmallNegativeFloatFieldNumber = 13; - private bool hasSmallNegativeFloat; - private float smallNegativeFloat_ = -8E-28F; - public bool HasSmallNegativeFloat { - get { return hasSmallNegativeFloat; } - } - public float SmallNegativeFloat { - get { return smallNegativeFloat_; } - } - - public const int InfDoubleFieldNumber = 14; - private bool hasInfDouble; - private double infDouble_ = double.PositiveInfinity; - public bool HasInfDouble { - get { return hasInfDouble; } - } - public double InfDouble { - get { return infDouble_; } - } - - public const int NegInfDoubleFieldNumber = 15; - private bool hasNegInfDouble; - private double negInfDouble_ = double.NegativeInfinity; - public bool HasNegInfDouble { - get { return hasNegInfDouble; } - } - public double NegInfDouble { - get { return negInfDouble_; } - } - - public const int NanDoubleFieldNumber = 16; - private bool hasNanDouble; - private double nanDouble_ = double.NaN; - public bool HasNanDouble { - get { return hasNanDouble; } - } - public double NanDouble { - get { return nanDouble_; } - } - - public const int InfFloatFieldNumber = 17; - private bool hasInfFloat; - private float infFloat_ = float.PositiveInfinity; - public bool HasInfFloat { - get { return hasInfFloat; } - } - public float InfFloat { - get { return infFloat_; } - } - - public const int NegInfFloatFieldNumber = 18; - private bool hasNegInfFloat; - private float negInfFloat_ = float.NegativeInfinity; - public bool HasNegInfFloat { - get { return hasNegInfFloat; } - } - public float NegInfFloat { - get { return negInfFloat_; } - } - - public const int NanFloatFieldNumber = 19; - private bool hasNanFloat; - private float nanFloat_ = float.NaN; - public bool HasNanFloat { - get { return hasNanFloat; } - } - public float NanFloat { - get { return nanFloat_; } - } - - public const int CppTrigraphFieldNumber = 20; - private bool hasCppTrigraph; - private string cppTrigraph_ = "? ? ?? ?? ??? ??/ ??-"; - public bool HasCppTrigraph { - get { return hasCppTrigraph; } - } - public string CppTrigraph { - get { return cppTrigraph_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testExtremeDefaultValuesFieldNames; - if (hasEscapedBytes) { - output.WriteBytes(1, field_names[1], EscapedBytes); - } - if (hasLargeUint32) { - output.WriteUInt32(2, field_names[5], LargeUint32); - } - if (hasLargeUint64) { - output.WriteUInt64(3, field_names[6], LargeUint64); - } - if (hasSmallInt32) { - output.WriteInt32(4, field_names[15], SmallInt32); - } - if (hasSmallInt64) { - output.WriteInt64(5, field_names[16], SmallInt64); - } - if (hasUtf8String) { - output.WriteString(6, field_names[18], Utf8String); - } - if (hasZeroFloat) { - output.WriteFloat(7, field_names[19], ZeroFloat); - } - if (hasOneFloat) { - output.WriteFloat(8, field_names[13], OneFloat); - } - if (hasSmallFloat) { - output.WriteFloat(9, field_names[14], SmallFloat); - } - if (hasNegativeOneFloat) { - output.WriteFloat(10, field_names[12], NegativeOneFloat); - } - if (hasNegativeFloat) { - output.WriteFloat(11, field_names[11], NegativeFloat); - } - if (hasLargeFloat) { - output.WriteFloat(12, field_names[4], LargeFloat); - } - if (hasSmallNegativeFloat) { - output.WriteFloat(13, field_names[17], SmallNegativeFloat); - } - if (hasInfDouble) { - output.WriteDouble(14, field_names[2], InfDouble); - } - if (hasNegInfDouble) { - output.WriteDouble(15, field_names[9], NegInfDouble); - } - if (hasNanDouble) { - output.WriteDouble(16, field_names[7], NanDouble); - } - if (hasInfFloat) { - output.WriteFloat(17, field_names[3], InfFloat); - } - if (hasNegInfFloat) { - output.WriteFloat(18, field_names[10], NegInfFloat); - } - if (hasNanFloat) { - output.WriteFloat(19, field_names[8], NanFloat); - } - if (hasCppTrigraph) { - output.WriteString(20, field_names[0], CppTrigraph); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasEscapedBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(1, EscapedBytes); - } - if (hasLargeUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(2, LargeUint32); - } - if (hasLargeUint64) { - size += pb::CodedOutputStream.ComputeUInt64Size(3, LargeUint64); - } - if (hasSmallInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(4, SmallInt32); - } - if (hasSmallInt64) { - size += pb::CodedOutputStream.ComputeInt64Size(5, SmallInt64); - } - if (hasUtf8String) { - size += pb::CodedOutputStream.ComputeStringSize(6, Utf8String); - } - if (hasZeroFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(7, ZeroFloat); - } - if (hasOneFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(8, OneFloat); - } - if (hasSmallFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(9, SmallFloat); - } - if (hasNegativeOneFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(10, NegativeOneFloat); - } - if (hasNegativeFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(11, NegativeFloat); - } - if (hasLargeFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(12, LargeFloat); - } - if (hasSmallNegativeFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(13, SmallNegativeFloat); - } - if (hasInfDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(14, InfDouble); - } - if (hasNegInfDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(15, NegInfDouble); - } - if (hasNanDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(16, NanDouble); - } - if (hasInfFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(17, InfFloat); - } - if (hasNegInfFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(18, NegInfFloat); - } - if (hasNanFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(19, NanFloat); - } - if (hasCppTrigraph) { - size += pb::CodedOutputStream.ComputeStringSize(20, CppTrigraph); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestExtremeDefaultValues ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestExtremeDefaultValues ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestExtremeDefaultValues MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestExtremeDefaultValues prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestExtremeDefaultValues cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestExtremeDefaultValues result; - - private TestExtremeDefaultValues PrepareBuilder() { - if (resultIsReadOnly) { - TestExtremeDefaultValues original = result; - result = new TestExtremeDefaultValues(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestExtremeDefaultValues MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor; } - } - - public override TestExtremeDefaultValues DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.DefaultInstance; } - } - - public override TestExtremeDefaultValues BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestExtremeDefaultValues) { - return MergeFrom((TestExtremeDefaultValues) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestExtremeDefaultValues other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasEscapedBytes) { - EscapedBytes = other.EscapedBytes; - } - if (other.HasLargeUint32) { - LargeUint32 = other.LargeUint32; - } - if (other.HasLargeUint64) { - LargeUint64 = other.LargeUint64; - } - if (other.HasSmallInt32) { - SmallInt32 = other.SmallInt32; - } - if (other.HasSmallInt64) { - SmallInt64 = other.SmallInt64; - } - if (other.HasUtf8String) { - Utf8String = other.Utf8String; - } - if (other.HasZeroFloat) { - ZeroFloat = other.ZeroFloat; - } - if (other.HasOneFloat) { - OneFloat = other.OneFloat; - } - if (other.HasSmallFloat) { - SmallFloat = other.SmallFloat; - } - if (other.HasNegativeOneFloat) { - NegativeOneFloat = other.NegativeOneFloat; - } - if (other.HasNegativeFloat) { - NegativeFloat = other.NegativeFloat; - } - if (other.HasLargeFloat) { - LargeFloat = other.LargeFloat; - } - if (other.HasSmallNegativeFloat) { - SmallNegativeFloat = other.SmallNegativeFloat; - } - if (other.HasInfDouble) { - InfDouble = other.InfDouble; - } - if (other.HasNegInfDouble) { - NegInfDouble = other.NegInfDouble; - } - if (other.HasNanDouble) { - NanDouble = other.NanDouble; - } - if (other.HasInfFloat) { - InfFloat = other.InfFloat; - } - if (other.HasNegInfFloat) { - NegInfFloat = other.NegInfFloat; - } - if (other.HasNanFloat) { - NanFloat = other.NanFloat; - } - if (other.HasCppTrigraph) { - CppTrigraph = other.CppTrigraph; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testExtremeDefaultValuesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testExtremeDefaultValuesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasEscapedBytes = input.ReadBytes(ref result.escapedBytes_); - break; - } - case 16: { - result.hasLargeUint32 = input.ReadUInt32(ref result.largeUint32_); - break; - } - case 24: { - result.hasLargeUint64 = input.ReadUInt64(ref result.largeUint64_); - break; - } - case 32: { - result.hasSmallInt32 = input.ReadInt32(ref result.smallInt32_); - break; - } - case 40: { - result.hasSmallInt64 = input.ReadInt64(ref result.smallInt64_); - break; - } - case 50: { - result.hasUtf8String = input.ReadString(ref result.utf8String_); - break; - } - case 61: { - result.hasZeroFloat = input.ReadFloat(ref result.zeroFloat_); - break; - } - case 69: { - result.hasOneFloat = input.ReadFloat(ref result.oneFloat_); - break; - } - case 77: { - result.hasSmallFloat = input.ReadFloat(ref result.smallFloat_); - break; - } - case 85: { - result.hasNegativeOneFloat = input.ReadFloat(ref result.negativeOneFloat_); - break; - } - case 93: { - result.hasNegativeFloat = input.ReadFloat(ref result.negativeFloat_); - break; - } - case 101: { - result.hasLargeFloat = input.ReadFloat(ref result.largeFloat_); - break; - } - case 109: { - result.hasSmallNegativeFloat = input.ReadFloat(ref result.smallNegativeFloat_); - break; - } - case 113: { - result.hasInfDouble = input.ReadDouble(ref result.infDouble_); - break; - } - case 121: { - result.hasNegInfDouble = input.ReadDouble(ref result.negInfDouble_); - break; - } - case 129: { - result.hasNanDouble = input.ReadDouble(ref result.nanDouble_); - break; - } - case 141: { - result.hasInfFloat = input.ReadFloat(ref result.infFloat_); - break; - } - case 149: { - result.hasNegInfFloat = input.ReadFloat(ref result.negInfFloat_); - break; - } - case 157: { - result.hasNanFloat = input.ReadFloat(ref result.nanFloat_); - break; - } - case 162: { - result.hasCppTrigraph = input.ReadString(ref result.cppTrigraph_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasEscapedBytes { - get { return result.hasEscapedBytes; } - } - public pb::ByteString EscapedBytes { - get { return result.EscapedBytes; } - set { SetEscapedBytes(value); } - } - public Builder SetEscapedBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasEscapedBytes = true; - result.escapedBytes_ = value; - return this; - } - public Builder ClearEscapedBytes() { - PrepareBuilder(); - result.hasEscapedBytes = false; - result.escapedBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[0].DefaultValue; - return this; - } - - public bool HasLargeUint32 { - get { return result.hasLargeUint32; } - } - [global::System.CLSCompliant(false)] - public uint LargeUint32 { - get { return result.LargeUint32; } - set { SetLargeUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetLargeUint32(uint value) { - PrepareBuilder(); - result.hasLargeUint32 = true; - result.largeUint32_ = value; - return this; - } - public Builder ClearLargeUint32() { - PrepareBuilder(); - result.hasLargeUint32 = false; - result.largeUint32_ = 4294967295; - return this; - } - - public bool HasLargeUint64 { - get { return result.hasLargeUint64; } - } - [global::System.CLSCompliant(false)] - public ulong LargeUint64 { - get { return result.LargeUint64; } - set { SetLargeUint64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetLargeUint64(ulong value) { - PrepareBuilder(); - result.hasLargeUint64 = true; - result.largeUint64_ = value; - return this; - } - public Builder ClearLargeUint64() { - PrepareBuilder(); - result.hasLargeUint64 = false; - result.largeUint64_ = 18446744073709551615UL; - return this; - } - - public bool HasSmallInt32 { - get { return result.hasSmallInt32; } - } - public int SmallInt32 { - get { return result.SmallInt32; } - set { SetSmallInt32(value); } - } - public Builder SetSmallInt32(int value) { - PrepareBuilder(); - result.hasSmallInt32 = true; - result.smallInt32_ = value; - return this; - } - public Builder ClearSmallInt32() { - PrepareBuilder(); - result.hasSmallInt32 = false; - result.smallInt32_ = -2147483647; - return this; - } - - public bool HasSmallInt64 { - get { return result.hasSmallInt64; } - } - public long SmallInt64 { - get { return result.SmallInt64; } - set { SetSmallInt64(value); } - } - public Builder SetSmallInt64(long value) { - PrepareBuilder(); - result.hasSmallInt64 = true; - result.smallInt64_ = value; - return this; - } - public Builder ClearSmallInt64() { - PrepareBuilder(); - result.hasSmallInt64 = false; - result.smallInt64_ = -9223372036854775807L; - return this; - } - - public bool HasUtf8String { - get { return result.hasUtf8String; } - } - public string Utf8String { - get { return result.Utf8String; } - set { SetUtf8String(value); } - } - public Builder SetUtf8String(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasUtf8String = true; - result.utf8String_ = value; - return this; - } - public Builder ClearUtf8String() { - PrepareBuilder(); - result.hasUtf8String = false; - result.utf8String_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[5].DefaultValue; - return this; - } - - public bool HasZeroFloat { - get { return result.hasZeroFloat; } - } - public float ZeroFloat { - get { return result.ZeroFloat; } - set { SetZeroFloat(value); } - } - public Builder SetZeroFloat(float value) { - PrepareBuilder(); - result.hasZeroFloat = true; - result.zeroFloat_ = value; - return this; - } - public Builder ClearZeroFloat() { - PrepareBuilder(); - result.hasZeroFloat = false; - result.zeroFloat_ = 0F; - return this; - } - - public bool HasOneFloat { - get { return result.hasOneFloat; } - } - public float OneFloat { - get { return result.OneFloat; } - set { SetOneFloat(value); } - } - public Builder SetOneFloat(float value) { - PrepareBuilder(); - result.hasOneFloat = true; - result.oneFloat_ = value; - return this; - } - public Builder ClearOneFloat() { - PrepareBuilder(); - result.hasOneFloat = false; - result.oneFloat_ = 1F; - return this; - } - - public bool HasSmallFloat { - get { return result.hasSmallFloat; } - } - public float SmallFloat { - get { return result.SmallFloat; } - set { SetSmallFloat(value); } - } - public Builder SetSmallFloat(float value) { - PrepareBuilder(); - result.hasSmallFloat = true; - result.smallFloat_ = value; - return this; - } - public Builder ClearSmallFloat() { - PrepareBuilder(); - result.hasSmallFloat = false; - result.smallFloat_ = 1.5F; - return this; - } - - public bool HasNegativeOneFloat { - get { return result.hasNegativeOneFloat; } - } - public float NegativeOneFloat { - get { return result.NegativeOneFloat; } - set { SetNegativeOneFloat(value); } - } - public Builder SetNegativeOneFloat(float value) { - PrepareBuilder(); - result.hasNegativeOneFloat = true; - result.negativeOneFloat_ = value; - return this; - } - public Builder ClearNegativeOneFloat() { - PrepareBuilder(); - result.hasNegativeOneFloat = false; - result.negativeOneFloat_ = -1F; - return this; - } - - public bool HasNegativeFloat { - get { return result.hasNegativeFloat; } - } - public float NegativeFloat { - get { return result.NegativeFloat; } - set { SetNegativeFloat(value); } - } - public Builder SetNegativeFloat(float value) { - PrepareBuilder(); - result.hasNegativeFloat = true; - result.negativeFloat_ = value; - return this; - } - public Builder ClearNegativeFloat() { - PrepareBuilder(); - result.hasNegativeFloat = false; - result.negativeFloat_ = -1.5F; - return this; - } - - public bool HasLargeFloat { - get { return result.hasLargeFloat; } - } - public float LargeFloat { - get { return result.LargeFloat; } - set { SetLargeFloat(value); } - } - public Builder SetLargeFloat(float value) { - PrepareBuilder(); - result.hasLargeFloat = true; - result.largeFloat_ = value; - return this; - } - public Builder ClearLargeFloat() { - PrepareBuilder(); - result.hasLargeFloat = false; - result.largeFloat_ = 2E+08F; - return this; - } - - public bool HasSmallNegativeFloat { - get { return result.hasSmallNegativeFloat; } - } - public float SmallNegativeFloat { - get { return result.SmallNegativeFloat; } - set { SetSmallNegativeFloat(value); } - } - public Builder SetSmallNegativeFloat(float value) { - PrepareBuilder(); - result.hasSmallNegativeFloat = true; - result.smallNegativeFloat_ = value; - return this; - } - public Builder ClearSmallNegativeFloat() { - PrepareBuilder(); - result.hasSmallNegativeFloat = false; - result.smallNegativeFloat_ = -8E-28F; - return this; - } - - public bool HasInfDouble { - get { return result.hasInfDouble; } - } - public double InfDouble { - get { return result.InfDouble; } - set { SetInfDouble(value); } - } - public Builder SetInfDouble(double value) { - PrepareBuilder(); - result.hasInfDouble = true; - result.infDouble_ = value; - return this; - } - public Builder ClearInfDouble() { - PrepareBuilder(); - result.hasInfDouble = false; - result.infDouble_ = double.PositiveInfinity; - return this; - } - - public bool HasNegInfDouble { - get { return result.hasNegInfDouble; } - } - public double NegInfDouble { - get { return result.NegInfDouble; } - set { SetNegInfDouble(value); } - } - public Builder SetNegInfDouble(double value) { - PrepareBuilder(); - result.hasNegInfDouble = true; - result.negInfDouble_ = value; - return this; - } - public Builder ClearNegInfDouble() { - PrepareBuilder(); - result.hasNegInfDouble = false; - result.negInfDouble_ = double.NegativeInfinity; - return this; - } - - public bool HasNanDouble { - get { return result.hasNanDouble; } - } - public double NanDouble { - get { return result.NanDouble; } - set { SetNanDouble(value); } - } - public Builder SetNanDouble(double value) { - PrepareBuilder(); - result.hasNanDouble = true; - result.nanDouble_ = value; - return this; - } - public Builder ClearNanDouble() { - PrepareBuilder(); - result.hasNanDouble = false; - result.nanDouble_ = double.NaN; - return this; - } - - public bool HasInfFloat { - get { return result.hasInfFloat; } - } - public float InfFloat { - get { return result.InfFloat; } - set { SetInfFloat(value); } - } - public Builder SetInfFloat(float value) { - PrepareBuilder(); - result.hasInfFloat = true; - result.infFloat_ = value; - return this; - } - public Builder ClearInfFloat() { - PrepareBuilder(); - result.hasInfFloat = false; - result.infFloat_ = float.PositiveInfinity; - return this; - } - - public bool HasNegInfFloat { - get { return result.hasNegInfFloat; } - } - public float NegInfFloat { - get { return result.NegInfFloat; } - set { SetNegInfFloat(value); } - } - public Builder SetNegInfFloat(float value) { - PrepareBuilder(); - result.hasNegInfFloat = true; - result.negInfFloat_ = value; - return this; - } - public Builder ClearNegInfFloat() { - PrepareBuilder(); - result.hasNegInfFloat = false; - result.negInfFloat_ = float.NegativeInfinity; - return this; - } - - public bool HasNanFloat { - get { return result.hasNanFloat; } - } - public float NanFloat { - get { return result.NanFloat; } - set { SetNanFloat(value); } - } - public Builder SetNanFloat(float value) { - PrepareBuilder(); - result.hasNanFloat = true; - result.nanFloat_ = value; - return this; - } - public Builder ClearNanFloat() { - PrepareBuilder(); - result.hasNanFloat = false; - result.nanFloat_ = float.NaN; - return this; - } - - public bool HasCppTrigraph { - get { return result.hasCppTrigraph; } - } - public string CppTrigraph { - get { return result.CppTrigraph; } - set { SetCppTrigraph(value); } - } - public Builder SetCppTrigraph(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasCppTrigraph = true; - result.cppTrigraph_ = value; - return this; - } - public Builder ClearCppTrigraph() { - PrepareBuilder(); - result.hasCppTrigraph = false; - result.cppTrigraph_ = "? ? ?? ?? ??? ??/ ??-"; - return this; - } - } - static TestExtremeDefaultValues() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class SparseEnumMessage : pb::GeneratedMessage { - private SparseEnumMessage() { } - private static readonly SparseEnumMessage defaultInstance = new SparseEnumMessage().MakeReadOnly(); - private static readonly string[] _sparseEnumMessageFieldNames = new string[] { "sparse_enum" }; - private static readonly uint[] _sparseEnumMessageFieldTags = new uint[] { 8 }; - public static SparseEnumMessage DefaultInstance { - get { return defaultInstance; } - } - - public override SparseEnumMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override SparseEnumMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_SparseEnumMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable; } - } - - public const int SparseEnumFieldNumber = 1; - private bool hasSparseEnum; - private global::Google.ProtocolBuffers.TestProtos.TestSparseEnum sparseEnum_ = global::Google.ProtocolBuffers.TestProtos.TestSparseEnum.SPARSE_A; - public bool HasSparseEnum { - get { return hasSparseEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestSparseEnum SparseEnum { - get { return sparseEnum_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _sparseEnumMessageFieldNames; - if (hasSparseEnum) { - output.WriteEnum(1, field_names[0], (int) SparseEnum, SparseEnum); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasSparseEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(1, (int) SparseEnum); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static SparseEnumMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static SparseEnumMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static SparseEnumMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private SparseEnumMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(SparseEnumMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(SparseEnumMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private SparseEnumMessage result; - - private SparseEnumMessage PrepareBuilder() { - if (resultIsReadOnly) { - SparseEnumMessage original = result; - result = new SparseEnumMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override SparseEnumMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.Descriptor; } - } - - public override SparseEnumMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.DefaultInstance; } - } - - public override SparseEnumMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is SparseEnumMessage) { - return MergeFrom((SparseEnumMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(SparseEnumMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasSparseEnum) { - SparseEnum = other.SparseEnum; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_sparseEnumMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _sparseEnumMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - object unknown; - if(input.ReadEnum(ref result.sparseEnum_, out unknown)) { - result.hasSparseEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(1, (ulong)(int)unknown); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasSparseEnum { - get { return result.hasSparseEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestSparseEnum SparseEnum { - get { return result.SparseEnum; } - set { SetSparseEnum(value); } - } - public Builder SetSparseEnum(global::Google.ProtocolBuffers.TestProtos.TestSparseEnum value) { - PrepareBuilder(); - result.hasSparseEnum = true; - result.sparseEnum_ = value; - return this; - } - public Builder ClearSparseEnum() { - PrepareBuilder(); - result.hasSparseEnum = false; - result.sparseEnum_ = global::Google.ProtocolBuffers.TestProtos.TestSparseEnum.SPARSE_A; - return this; - } - } - static SparseEnumMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OneString : pb::GeneratedMessage { - private OneString() { } - private static readonly OneString defaultInstance = new OneString().MakeReadOnly(); - private static readonly string[] _oneStringFieldNames = new string[] { "data" }; - private static readonly uint[] _oneStringFieldTags = new uint[] { 10 }; - public static OneString DefaultInstance { - get { return defaultInstance; } - } - - public override OneString DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override OneString ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OneString__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OneString__FieldAccessorTable; } - } - - public const int DataFieldNumber = 1; - private bool hasData; - private string data_ = ""; - public bool HasData { - get { return hasData; } - } - public string Data { - get { return data_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _oneStringFieldNames; - if (hasData) { - output.WriteString(1, field_names[0], Data); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasData) { - size += pb::CodedOutputStream.ComputeStringSize(1, Data); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static OneString ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OneString ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OneString ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OneString ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OneString ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OneString ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static OneString ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static OneString ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static OneString ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OneString ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private OneString MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OneString prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OneString cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OneString result; - - private OneString PrepareBuilder() { - if (resultIsReadOnly) { - OneString original = result; - result = new OneString(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OneString MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.OneString.Descriptor; } - } - - public override OneString DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.OneString.DefaultInstance; } - } - - public override OneString BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is OneString) { - return MergeFrom((OneString) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(OneString other) { - if (other == global::Google.ProtocolBuffers.TestProtos.OneString.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasData) { - Data = other.Data; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_oneStringFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _oneStringFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasData = input.ReadString(ref result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasData { - get { return result.hasData; } - } - public string Data { - get { return result.Data; } - set { SetData(value); } - } - public Builder SetData(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasData = true; - result.data_ = value; - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.hasData = false; - result.data_ = ""; - return this; - } - } - static OneString() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OneBytes : pb::GeneratedMessage { - private OneBytes() { } - private static readonly OneBytes defaultInstance = new OneBytes().MakeReadOnly(); - private static readonly string[] _oneBytesFieldNames = new string[] { "data" }; - private static readonly uint[] _oneBytesFieldTags = new uint[] { 10 }; - public static OneBytes DefaultInstance { - get { return defaultInstance; } - } - - public override OneBytes DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override OneBytes ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OneBytes__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OneBytes__FieldAccessorTable; } - } - - public const int DataFieldNumber = 1; - private bool hasData; - private pb::ByteString data_ = pb::ByteString.Empty; - public bool HasData { - get { return hasData; } - } - public pb::ByteString Data { - get { return data_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _oneBytesFieldNames; - if (hasData) { - output.WriteBytes(1, field_names[0], Data); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasData) { - size += pb::CodedOutputStream.ComputeBytesSize(1, Data); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static OneBytes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OneBytes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OneBytes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OneBytes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OneBytes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OneBytes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static OneBytes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static OneBytes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static OneBytes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OneBytes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private OneBytes MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OneBytes prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OneBytes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OneBytes result; - - private OneBytes PrepareBuilder() { - if (resultIsReadOnly) { - OneBytes original = result; - result = new OneBytes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OneBytes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.OneBytes.Descriptor; } - } - - public override OneBytes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.OneBytes.DefaultInstance; } - } - - public override OneBytes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is OneBytes) { - return MergeFrom((OneBytes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(OneBytes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.OneBytes.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasData) { - Data = other.Data; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_oneBytesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _oneBytesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasData = input.ReadBytes(ref result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasData { - get { return result.hasData; } - } - public pb::ByteString Data { - get { return result.Data; } - set { SetData(value); } - } - public Builder SetData(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasData = true; - result.data_ = value; - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.hasData = false; - result.data_ = pb::ByteString.Empty; - return this; - } - } - static OneBytes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestPackedTypes : pb::GeneratedMessage { - private TestPackedTypes() { } - private static readonly TestPackedTypes defaultInstance = new TestPackedTypes().MakeReadOnly(); - private static readonly string[] _testPackedTypesFieldNames = new string[] { "packed_bool", "packed_double", "packed_enum", "packed_fixed32", "packed_fixed64", "packed_float", "packed_int32", "packed_int64", "packed_sfixed32", "packed_sfixed64", "packed_sint32", "packed_sint64", "packed_uint32", "packed_uint64" }; - private static readonly uint[] _testPackedTypesFieldTags = new uint[] { 818, 810, 826, 770, 778, 802, 722, 730, 786, 794, 754, 762, 738, 746 }; - public static TestPackedTypes DefaultInstance { - get { return defaultInstance; } - } - - public override TestPackedTypes DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestPackedTypes ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestPackedTypes__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable; } - } - - public const int PackedInt32FieldNumber = 90; - private int packedInt32MemoizedSerializedSize; - private pbc::PopsicleList packedInt32_ = new pbc::PopsicleList(); - public scg::IList PackedInt32List { - get { return pbc::Lists.AsReadOnly(packedInt32_); } - } - public int PackedInt32Count { - get { return packedInt32_.Count; } - } - public int GetPackedInt32(int index) { - return packedInt32_[index]; - } - - public const int PackedInt64FieldNumber = 91; - private int packedInt64MemoizedSerializedSize; - private pbc::PopsicleList packedInt64_ = new pbc::PopsicleList(); - public scg::IList PackedInt64List { - get { return pbc::Lists.AsReadOnly(packedInt64_); } - } - public int PackedInt64Count { - get { return packedInt64_.Count; } - } - public long GetPackedInt64(int index) { - return packedInt64_[index]; - } - - public const int PackedUint32FieldNumber = 92; - private int packedUint32MemoizedSerializedSize; - private pbc::PopsicleList packedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedUint32List { - get { return pbc::Lists.AsReadOnly(packedUint32_); } - } - public int PackedUint32Count { - get { return packedUint32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedUint32(int index) { - return packedUint32_[index]; - } - - public const int PackedUint64FieldNumber = 93; - private int packedUint64MemoizedSerializedSize; - private pbc::PopsicleList packedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedUint64List { - get { return pbc::Lists.AsReadOnly(packedUint64_); } - } - public int PackedUint64Count { - get { return packedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedUint64(int index) { - return packedUint64_[index]; - } - - public const int PackedSint32FieldNumber = 94; - private int packedSint32MemoizedSerializedSize; - private pbc::PopsicleList packedSint32_ = new pbc::PopsicleList(); - public scg::IList PackedSint32List { - get { return pbc::Lists.AsReadOnly(packedSint32_); } - } - public int PackedSint32Count { - get { return packedSint32_.Count; } - } - public int GetPackedSint32(int index) { - return packedSint32_[index]; - } - - public const int PackedSint64FieldNumber = 95; - private int packedSint64MemoizedSerializedSize; - private pbc::PopsicleList packedSint64_ = new pbc::PopsicleList(); - public scg::IList PackedSint64List { - get { return pbc::Lists.AsReadOnly(packedSint64_); } - } - public int PackedSint64Count { - get { return packedSint64_.Count; } - } - public long GetPackedSint64(int index) { - return packedSint64_[index]; - } - - public const int PackedFixed32FieldNumber = 96; - private int packedFixed32MemoizedSerializedSize; - private pbc::PopsicleList packedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedFixed32List { - get { return pbc::Lists.AsReadOnly(packedFixed32_); } - } - public int PackedFixed32Count { - get { return packedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedFixed32(int index) { - return packedFixed32_[index]; - } - - public const int PackedFixed64FieldNumber = 97; - private int packedFixed64MemoizedSerializedSize; - private pbc::PopsicleList packedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedFixed64List { - get { return pbc::Lists.AsReadOnly(packedFixed64_); } - } - public int PackedFixed64Count { - get { return packedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedFixed64(int index) { - return packedFixed64_[index]; - } - - public const int PackedSfixed32FieldNumber = 98; - private int packedSfixed32MemoizedSerializedSize; - private pbc::PopsicleList packedSfixed32_ = new pbc::PopsicleList(); - public scg::IList PackedSfixed32List { - get { return pbc::Lists.AsReadOnly(packedSfixed32_); } - } - public int PackedSfixed32Count { - get { return packedSfixed32_.Count; } - } - public int GetPackedSfixed32(int index) { - return packedSfixed32_[index]; - } - - public const int PackedSfixed64FieldNumber = 99; - private int packedSfixed64MemoizedSerializedSize; - private pbc::PopsicleList packedSfixed64_ = new pbc::PopsicleList(); - public scg::IList PackedSfixed64List { - get { return pbc::Lists.AsReadOnly(packedSfixed64_); } - } - public int PackedSfixed64Count { - get { return packedSfixed64_.Count; } - } - public long GetPackedSfixed64(int index) { - return packedSfixed64_[index]; - } - - public const int PackedFloatFieldNumber = 100; - private int packedFloatMemoizedSerializedSize; - private pbc::PopsicleList packedFloat_ = new pbc::PopsicleList(); - public scg::IList PackedFloatList { - get { return pbc::Lists.AsReadOnly(packedFloat_); } - } - public int PackedFloatCount { - get { return packedFloat_.Count; } - } - public float GetPackedFloat(int index) { - return packedFloat_[index]; - } - - public const int PackedDoubleFieldNumber = 101; - private int packedDoubleMemoizedSerializedSize; - private pbc::PopsicleList packedDouble_ = new pbc::PopsicleList(); - public scg::IList PackedDoubleList { - get { return pbc::Lists.AsReadOnly(packedDouble_); } - } - public int PackedDoubleCount { - get { return packedDouble_.Count; } - } - public double GetPackedDouble(int index) { - return packedDouble_[index]; - } - - public const int PackedBoolFieldNumber = 102; - private int packedBoolMemoizedSerializedSize; - private pbc::PopsicleList packedBool_ = new pbc::PopsicleList(); - public scg::IList PackedBoolList { - get { return pbc::Lists.AsReadOnly(packedBool_); } - } - public int PackedBoolCount { - get { return packedBool_.Count; } - } - public bool GetPackedBool(int index) { - return packedBool_[index]; - } - - public const int PackedEnumFieldNumber = 103; - private int packedEnumMemoizedSerializedSize; - private pbc::PopsicleList packedEnum_ = new pbc::PopsicleList(); - public scg::IList PackedEnumList { - get { return pbc::Lists.AsReadOnly(packedEnum_); } - } - public int PackedEnumCount { - get { return packedEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetPackedEnum(int index) { - return packedEnum_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testPackedTypesFieldNames; - if (packedInt32_.Count > 0) { - output.WritePackedInt32Array(90, field_names[6], packedInt32MemoizedSerializedSize, packedInt32_); - } - if (packedInt64_.Count > 0) { - output.WritePackedInt64Array(91, field_names[7], packedInt64MemoizedSerializedSize, packedInt64_); - } - if (packedUint32_.Count > 0) { - output.WritePackedUInt32Array(92, field_names[12], packedUint32MemoizedSerializedSize, packedUint32_); - } - if (packedUint64_.Count > 0) { - output.WritePackedUInt64Array(93, field_names[13], packedUint64MemoizedSerializedSize, packedUint64_); - } - if (packedSint32_.Count > 0) { - output.WritePackedSInt32Array(94, field_names[10], packedSint32MemoizedSerializedSize, packedSint32_); - } - if (packedSint64_.Count > 0) { - output.WritePackedSInt64Array(95, field_names[11], packedSint64MemoizedSerializedSize, packedSint64_); - } - if (packedFixed32_.Count > 0) { - output.WritePackedFixed32Array(96, field_names[3], packedFixed32MemoizedSerializedSize, packedFixed32_); - } - if (packedFixed64_.Count > 0) { - output.WritePackedFixed64Array(97, field_names[4], packedFixed64MemoizedSerializedSize, packedFixed64_); - } - if (packedSfixed32_.Count > 0) { - output.WritePackedSFixed32Array(98, field_names[8], packedSfixed32MemoizedSerializedSize, packedSfixed32_); - } - if (packedSfixed64_.Count > 0) { - output.WritePackedSFixed64Array(99, field_names[9], packedSfixed64MemoizedSerializedSize, packedSfixed64_); - } - if (packedFloat_.Count > 0) { - output.WritePackedFloatArray(100, field_names[5], packedFloatMemoizedSerializedSize, packedFloat_); - } - if (packedDouble_.Count > 0) { - output.WritePackedDoubleArray(101, field_names[1], packedDoubleMemoizedSerializedSize, packedDouble_); - } - if (packedBool_.Count > 0) { - output.WritePackedBoolArray(102, field_names[0], packedBoolMemoizedSerializedSize, packedBool_); - } - if (packedEnum_.Count > 0) { - output.WritePackedEnumArray(103, field_names[2], packedEnumMemoizedSerializedSize, packedEnum_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (int element in PackedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - if (packedInt32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedInt32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (long element in PackedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - if (packedInt64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedInt64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (uint element in PackedUint32List) { - dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); - } - size += dataSize; - if (packedUint32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedUint32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (ulong element in PackedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - if (packedUint64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedUint64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (int element in PackedSint32List) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - if (packedSint32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSint32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (long element in PackedSint64List) { - dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); - } - size += dataSize; - if (packedSint64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSint64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 4 * packedFixed32_.Count; - size += dataSize; - if (packedFixed32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedFixed32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 8 * packedFixed64_.Count; - size += dataSize; - if (packedFixed64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedFixed64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 4 * packedSfixed32_.Count; - size += dataSize; - if (packedSfixed32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSfixed32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 8 * packedSfixed64_.Count; - size += dataSize; - if (packedSfixed64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSfixed64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 4 * packedFloat_.Count; - size += dataSize; - if (packedFloat_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedFloatMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 8 * packedDouble_.Count; - size += dataSize; - if (packedDouble_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedDoubleMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 1 * packedBool_.Count; - size += dataSize; - if (packedBool_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedBoolMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - if (packedEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in packedEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2; - size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); - } - packedEnumMemoizedSerializedSize = dataSize; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestPackedTypes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestPackedTypes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestPackedTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestPackedTypes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestPackedTypes MakeReadOnly() { - packedInt32_.MakeReadOnly(); - packedInt64_.MakeReadOnly(); - packedUint32_.MakeReadOnly(); - packedUint64_.MakeReadOnly(); - packedSint32_.MakeReadOnly(); - packedSint64_.MakeReadOnly(); - packedFixed32_.MakeReadOnly(); - packedFixed64_.MakeReadOnly(); - packedSfixed32_.MakeReadOnly(); - packedSfixed64_.MakeReadOnly(); - packedFloat_.MakeReadOnly(); - packedDouble_.MakeReadOnly(); - packedBool_.MakeReadOnly(); - packedEnum_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestPackedTypes prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestPackedTypes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestPackedTypes result; - - private TestPackedTypes PrepareBuilder() { - if (resultIsReadOnly) { - TestPackedTypes original = result; - result = new TestPackedTypes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestPackedTypes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.Descriptor; } - } - - public override TestPackedTypes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.DefaultInstance; } - } - - public override TestPackedTypes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestPackedTypes) { - return MergeFrom((TestPackedTypes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestPackedTypes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.DefaultInstance) return this; - PrepareBuilder(); - if (other.packedInt32_.Count != 0) { - result.packedInt32_.Add(other.packedInt32_); - } - if (other.packedInt64_.Count != 0) { - result.packedInt64_.Add(other.packedInt64_); - } - if (other.packedUint32_.Count != 0) { - result.packedUint32_.Add(other.packedUint32_); - } - if (other.packedUint64_.Count != 0) { - result.packedUint64_.Add(other.packedUint64_); - } - if (other.packedSint32_.Count != 0) { - result.packedSint32_.Add(other.packedSint32_); - } - if (other.packedSint64_.Count != 0) { - result.packedSint64_.Add(other.packedSint64_); - } - if (other.packedFixed32_.Count != 0) { - result.packedFixed32_.Add(other.packedFixed32_); - } - if (other.packedFixed64_.Count != 0) { - result.packedFixed64_.Add(other.packedFixed64_); - } - if (other.packedSfixed32_.Count != 0) { - result.packedSfixed32_.Add(other.packedSfixed32_); - } - if (other.packedSfixed64_.Count != 0) { - result.packedSfixed64_.Add(other.packedSfixed64_); - } - if (other.packedFloat_.Count != 0) { - result.packedFloat_.Add(other.packedFloat_); - } - if (other.packedDouble_.Count != 0) { - result.packedDouble_.Add(other.packedDouble_); - } - if (other.packedBool_.Count != 0) { - result.packedBool_.Add(other.packedBool_); - } - if (other.packedEnum_.Count != 0) { - result.packedEnum_.Add(other.packedEnum_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testPackedTypesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testPackedTypesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 722: - case 720: { - input.ReadInt32Array(tag, field_name, result.packedInt32_); - break; - } - case 730: - case 728: { - input.ReadInt64Array(tag, field_name, result.packedInt64_); - break; - } - case 738: - case 736: { - input.ReadUInt32Array(tag, field_name, result.packedUint32_); - break; - } - case 746: - case 744: { - input.ReadUInt64Array(tag, field_name, result.packedUint64_); - break; - } - case 754: - case 752: { - input.ReadSInt32Array(tag, field_name, result.packedSint32_); - break; - } - case 762: - case 760: { - input.ReadSInt64Array(tag, field_name, result.packedSint64_); - break; - } - case 770: - case 773: { - input.ReadFixed32Array(tag, field_name, result.packedFixed32_); - break; - } - case 778: - case 777: { - input.ReadFixed64Array(tag, field_name, result.packedFixed64_); - break; - } - case 786: - case 789: { - input.ReadSFixed32Array(tag, field_name, result.packedSfixed32_); - break; - } - case 794: - case 793: { - input.ReadSFixed64Array(tag, field_name, result.packedSfixed64_); - break; - } - case 802: - case 805: { - input.ReadFloatArray(tag, field_name, result.packedFloat_); - break; - } - case 810: - case 809: { - input.ReadDoubleArray(tag, field_name, result.packedDouble_); - break; - } - case 818: - case 816: { - input.ReadBoolArray(tag, field_name, result.packedBool_); - break; - } - case 826: - case 824: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.packedEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(103, (ulong)(int)rawValue); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public pbc::IPopsicleList PackedInt32List { - get { return PrepareBuilder().packedInt32_; } - } - public int PackedInt32Count { - get { return result.PackedInt32Count; } - } - public int GetPackedInt32(int index) { - return result.GetPackedInt32(index); - } - public Builder SetPackedInt32(int index, int value) { - PrepareBuilder(); - result.packedInt32_[index] = value; - return this; - } - public Builder AddPackedInt32(int value) { - PrepareBuilder(); - result.packedInt32_.Add(value); - return this; - } - public Builder AddRangePackedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedInt32_.Add(values); - return this; - } - public Builder ClearPackedInt32() { - PrepareBuilder(); - result.packedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedInt64List { - get { return PrepareBuilder().packedInt64_; } - } - public int PackedInt64Count { - get { return result.PackedInt64Count; } - } - public long GetPackedInt64(int index) { - return result.GetPackedInt64(index); - } - public Builder SetPackedInt64(int index, long value) { - PrepareBuilder(); - result.packedInt64_[index] = value; - return this; - } - public Builder AddPackedInt64(long value) { - PrepareBuilder(); - result.packedInt64_.Add(value); - return this; - } - public Builder AddRangePackedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedInt64_.Add(values); - return this; - } - public Builder ClearPackedInt64() { - PrepareBuilder(); - result.packedInt64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedUint32List { - get { return PrepareBuilder().packedUint32_; } - } - public int PackedUint32Count { - get { return result.PackedUint32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedUint32(int index) { - return result.GetPackedUint32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedUint32(int index, uint value) { - PrepareBuilder(); - result.packedUint32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedUint32(uint value) { - PrepareBuilder(); - result.packedUint32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedUint32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedUint32_.Add(values); - return this; - } - public Builder ClearPackedUint32() { - PrepareBuilder(); - result.packedUint32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedUint64List { - get { return PrepareBuilder().packedUint64_; } - } - public int PackedUint64Count { - get { return result.PackedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedUint64(int index) { - return result.GetPackedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedUint64(int index, ulong value) { - PrepareBuilder(); - result.packedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedUint64(ulong value) { - PrepareBuilder(); - result.packedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedUint64_.Add(values); - return this; - } - public Builder ClearPackedUint64() { - PrepareBuilder(); - result.packedUint64_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSint32List { - get { return PrepareBuilder().packedSint32_; } - } - public int PackedSint32Count { - get { return result.PackedSint32Count; } - } - public int GetPackedSint32(int index) { - return result.GetPackedSint32(index); - } - public Builder SetPackedSint32(int index, int value) { - PrepareBuilder(); - result.packedSint32_[index] = value; - return this; - } - public Builder AddPackedSint32(int value) { - PrepareBuilder(); - result.packedSint32_.Add(value); - return this; - } - public Builder AddRangePackedSint32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSint32_.Add(values); - return this; - } - public Builder ClearPackedSint32() { - PrepareBuilder(); - result.packedSint32_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSint64List { - get { return PrepareBuilder().packedSint64_; } - } - public int PackedSint64Count { - get { return result.PackedSint64Count; } - } - public long GetPackedSint64(int index) { - return result.GetPackedSint64(index); - } - public Builder SetPackedSint64(int index, long value) { - PrepareBuilder(); - result.packedSint64_[index] = value; - return this; - } - public Builder AddPackedSint64(long value) { - PrepareBuilder(); - result.packedSint64_.Add(value); - return this; - } - public Builder AddRangePackedSint64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSint64_.Add(values); - return this; - } - public Builder ClearPackedSint64() { - PrepareBuilder(); - result.packedSint64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedFixed32List { - get { return PrepareBuilder().packedFixed32_; } - } - public int PackedFixed32Count { - get { return result.PackedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedFixed32(int index) { - return result.GetPackedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedFixed32(int index, uint value) { - PrepareBuilder(); - result.packedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedFixed32(uint value) { - PrepareBuilder(); - result.packedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedFixed32_.Add(values); - return this; - } - public Builder ClearPackedFixed32() { - PrepareBuilder(); - result.packedFixed32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedFixed64List { - get { return PrepareBuilder().packedFixed64_; } - } - public int PackedFixed64Count { - get { return result.PackedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedFixed64(int index) { - return result.GetPackedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedFixed64(int index, ulong value) { - PrepareBuilder(); - result.packedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedFixed64(ulong value) { - PrepareBuilder(); - result.packedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedFixed64_.Add(values); - return this; - } - public Builder ClearPackedFixed64() { - PrepareBuilder(); - result.packedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSfixed32List { - get { return PrepareBuilder().packedSfixed32_; } - } - public int PackedSfixed32Count { - get { return result.PackedSfixed32Count; } - } - public int GetPackedSfixed32(int index) { - return result.GetPackedSfixed32(index); - } - public Builder SetPackedSfixed32(int index, int value) { - PrepareBuilder(); - result.packedSfixed32_[index] = value; - return this; - } - public Builder AddPackedSfixed32(int value) { - PrepareBuilder(); - result.packedSfixed32_.Add(value); - return this; - } - public Builder AddRangePackedSfixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSfixed32_.Add(values); - return this; - } - public Builder ClearPackedSfixed32() { - PrepareBuilder(); - result.packedSfixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSfixed64List { - get { return PrepareBuilder().packedSfixed64_; } - } - public int PackedSfixed64Count { - get { return result.PackedSfixed64Count; } - } - public long GetPackedSfixed64(int index) { - return result.GetPackedSfixed64(index); - } - public Builder SetPackedSfixed64(int index, long value) { - PrepareBuilder(); - result.packedSfixed64_[index] = value; - return this; - } - public Builder AddPackedSfixed64(long value) { - PrepareBuilder(); - result.packedSfixed64_.Add(value); - return this; - } - public Builder AddRangePackedSfixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSfixed64_.Add(values); - return this; - } - public Builder ClearPackedSfixed64() { - PrepareBuilder(); - result.packedSfixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedFloatList { - get { return PrepareBuilder().packedFloat_; } - } - public int PackedFloatCount { - get { return result.PackedFloatCount; } - } - public float GetPackedFloat(int index) { - return result.GetPackedFloat(index); - } - public Builder SetPackedFloat(int index, float value) { - PrepareBuilder(); - result.packedFloat_[index] = value; - return this; - } - public Builder AddPackedFloat(float value) { - PrepareBuilder(); - result.packedFloat_.Add(value); - return this; - } - public Builder AddRangePackedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.packedFloat_.Add(values); - return this; - } - public Builder ClearPackedFloat() { - PrepareBuilder(); - result.packedFloat_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedDoubleList { - get { return PrepareBuilder().packedDouble_; } - } - public int PackedDoubleCount { - get { return result.PackedDoubleCount; } - } - public double GetPackedDouble(int index) { - return result.GetPackedDouble(index); - } - public Builder SetPackedDouble(int index, double value) { - PrepareBuilder(); - result.packedDouble_[index] = value; - return this; - } - public Builder AddPackedDouble(double value) { - PrepareBuilder(); - result.packedDouble_.Add(value); - return this; - } - public Builder AddRangePackedDouble(scg::IEnumerable values) { - PrepareBuilder(); - result.packedDouble_.Add(values); - return this; - } - public Builder ClearPackedDouble() { - PrepareBuilder(); - result.packedDouble_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedBoolList { - get { return PrepareBuilder().packedBool_; } - } - public int PackedBoolCount { - get { return result.PackedBoolCount; } - } - public bool GetPackedBool(int index) { - return result.GetPackedBool(index); - } - public Builder SetPackedBool(int index, bool value) { - PrepareBuilder(); - result.packedBool_[index] = value; - return this; - } - public Builder AddPackedBool(bool value) { - PrepareBuilder(); - result.packedBool_.Add(value); - return this; - } - public Builder AddRangePackedBool(scg::IEnumerable values) { - PrepareBuilder(); - result.packedBool_.Add(values); - return this; - } - public Builder ClearPackedBool() { - PrepareBuilder(); - result.packedBool_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedEnumList { - get { return PrepareBuilder().packedEnum_; } - } - public int PackedEnumCount { - get { return result.PackedEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetPackedEnum(int index) { - return result.GetPackedEnum(index); - } - public Builder SetPackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.packedEnum_[index] = value; - return this; - } - public Builder AddPackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.packedEnum_.Add(value); - return this; - } - public Builder AddRangePackedEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.packedEnum_.Add(values); - return this; - } - public Builder ClearPackedEnum() { - PrepareBuilder(); - result.packedEnum_.Clear(); - return this; - } - } - static TestPackedTypes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestUnpackedTypes : pb::GeneratedMessage { - private TestUnpackedTypes() { } - private static readonly TestUnpackedTypes defaultInstance = new TestUnpackedTypes().MakeReadOnly(); - private static readonly string[] _testUnpackedTypesFieldNames = new string[] { "unpacked_bool", "unpacked_double", "unpacked_enum", "unpacked_fixed32", "unpacked_fixed64", "unpacked_float", "unpacked_int32", "unpacked_int64", "unpacked_sfixed32", "unpacked_sfixed64", "unpacked_sint32", "unpacked_sint64", "unpacked_uint32", "unpacked_uint64" }; - private static readonly uint[] _testUnpackedTypesFieldTags = new uint[] { 816, 809, 824, 773, 777, 805, 720, 728, 789, 793, 752, 760, 736, 744 }; - public static TestUnpackedTypes DefaultInstance { - get { return defaultInstance; } - } - - public override TestUnpackedTypes DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestUnpackedTypes ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable; } - } - - public const int UnpackedInt32FieldNumber = 90; - private pbc::PopsicleList unpackedInt32_ = new pbc::PopsicleList(); - public scg::IList UnpackedInt32List { - get { return pbc::Lists.AsReadOnly(unpackedInt32_); } - } - public int UnpackedInt32Count { - get { return unpackedInt32_.Count; } - } - public int GetUnpackedInt32(int index) { - return unpackedInt32_[index]; - } - - public const int UnpackedInt64FieldNumber = 91; - private pbc::PopsicleList unpackedInt64_ = new pbc::PopsicleList(); - public scg::IList UnpackedInt64List { - get { return pbc::Lists.AsReadOnly(unpackedInt64_); } - } - public int UnpackedInt64Count { - get { return unpackedInt64_.Count; } - } - public long GetUnpackedInt64(int index) { - return unpackedInt64_[index]; - } - - public const int UnpackedUint32FieldNumber = 92; - private pbc::PopsicleList unpackedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedUint32List { - get { return pbc::Lists.AsReadOnly(unpackedUint32_); } - } - public int UnpackedUint32Count { - get { return unpackedUint32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedUint32(int index) { - return unpackedUint32_[index]; - } - - public const int UnpackedUint64FieldNumber = 93; - private pbc::PopsicleList unpackedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedUint64List { - get { return pbc::Lists.AsReadOnly(unpackedUint64_); } - } - public int UnpackedUint64Count { - get { return unpackedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedUint64(int index) { - return unpackedUint64_[index]; - } - - public const int UnpackedSint32FieldNumber = 94; - private pbc::PopsicleList unpackedSint32_ = new pbc::PopsicleList(); - public scg::IList UnpackedSint32List { - get { return pbc::Lists.AsReadOnly(unpackedSint32_); } - } - public int UnpackedSint32Count { - get { return unpackedSint32_.Count; } - } - public int GetUnpackedSint32(int index) { - return unpackedSint32_[index]; - } - - public const int UnpackedSint64FieldNumber = 95; - private pbc::PopsicleList unpackedSint64_ = new pbc::PopsicleList(); - public scg::IList UnpackedSint64List { - get { return pbc::Lists.AsReadOnly(unpackedSint64_); } - } - public int UnpackedSint64Count { - get { return unpackedSint64_.Count; } - } - public long GetUnpackedSint64(int index) { - return unpackedSint64_[index]; - } - - public const int UnpackedFixed32FieldNumber = 96; - private pbc::PopsicleList unpackedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedFixed32List { - get { return pbc::Lists.AsReadOnly(unpackedFixed32_); } - } - public int UnpackedFixed32Count { - get { return unpackedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedFixed32(int index) { - return unpackedFixed32_[index]; - } - - public const int UnpackedFixed64FieldNumber = 97; - private pbc::PopsicleList unpackedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedFixed64List { - get { return pbc::Lists.AsReadOnly(unpackedFixed64_); } - } - public int UnpackedFixed64Count { - get { return unpackedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedFixed64(int index) { - return unpackedFixed64_[index]; - } - - public const int UnpackedSfixed32FieldNumber = 98; - private pbc::PopsicleList unpackedSfixed32_ = new pbc::PopsicleList(); - public scg::IList UnpackedSfixed32List { - get { return pbc::Lists.AsReadOnly(unpackedSfixed32_); } - } - public int UnpackedSfixed32Count { - get { return unpackedSfixed32_.Count; } - } - public int GetUnpackedSfixed32(int index) { - return unpackedSfixed32_[index]; - } - - public const int UnpackedSfixed64FieldNumber = 99; - private pbc::PopsicleList unpackedSfixed64_ = new pbc::PopsicleList(); - public scg::IList UnpackedSfixed64List { - get { return pbc::Lists.AsReadOnly(unpackedSfixed64_); } - } - public int UnpackedSfixed64Count { - get { return unpackedSfixed64_.Count; } - } - public long GetUnpackedSfixed64(int index) { - return unpackedSfixed64_[index]; - } - - public const int UnpackedFloatFieldNumber = 100; - private pbc::PopsicleList unpackedFloat_ = new pbc::PopsicleList(); - public scg::IList UnpackedFloatList { - get { return pbc::Lists.AsReadOnly(unpackedFloat_); } - } - public int UnpackedFloatCount { - get { return unpackedFloat_.Count; } - } - public float GetUnpackedFloat(int index) { - return unpackedFloat_[index]; - } - - public const int UnpackedDoubleFieldNumber = 101; - private pbc::PopsicleList unpackedDouble_ = new pbc::PopsicleList(); - public scg::IList UnpackedDoubleList { - get { return pbc::Lists.AsReadOnly(unpackedDouble_); } - } - public int UnpackedDoubleCount { - get { return unpackedDouble_.Count; } - } - public double GetUnpackedDouble(int index) { - return unpackedDouble_[index]; - } - - public const int UnpackedBoolFieldNumber = 102; - private pbc::PopsicleList unpackedBool_ = new pbc::PopsicleList(); - public scg::IList UnpackedBoolList { - get { return pbc::Lists.AsReadOnly(unpackedBool_); } - } - public int UnpackedBoolCount { - get { return unpackedBool_.Count; } - } - public bool GetUnpackedBool(int index) { - return unpackedBool_[index]; - } - - public const int UnpackedEnumFieldNumber = 103; - private pbc::PopsicleList unpackedEnum_ = new pbc::PopsicleList(); - public scg::IList UnpackedEnumList { - get { return pbc::Lists.AsReadOnly(unpackedEnum_); } - } - public int UnpackedEnumCount { - get { return unpackedEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetUnpackedEnum(int index) { - return unpackedEnum_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testUnpackedTypesFieldNames; - if (unpackedInt32_.Count > 0) { - output.WriteInt32Array(90, field_names[6], unpackedInt32_); - } - if (unpackedInt64_.Count > 0) { - output.WriteInt64Array(91, field_names[7], unpackedInt64_); - } - if (unpackedUint32_.Count > 0) { - output.WriteUInt32Array(92, field_names[12], unpackedUint32_); - } - if (unpackedUint64_.Count > 0) { - output.WriteUInt64Array(93, field_names[13], unpackedUint64_); - } - if (unpackedSint32_.Count > 0) { - output.WriteSInt32Array(94, field_names[10], unpackedSint32_); - } - if (unpackedSint64_.Count > 0) { - output.WriteSInt64Array(95, field_names[11], unpackedSint64_); - } - if (unpackedFixed32_.Count > 0) { - output.WriteFixed32Array(96, field_names[3], unpackedFixed32_); - } - if (unpackedFixed64_.Count > 0) { - output.WriteFixed64Array(97, field_names[4], unpackedFixed64_); - } - if (unpackedSfixed32_.Count > 0) { - output.WriteSFixed32Array(98, field_names[8], unpackedSfixed32_); - } - if (unpackedSfixed64_.Count > 0) { - output.WriteSFixed64Array(99, field_names[9], unpackedSfixed64_); - } - if (unpackedFloat_.Count > 0) { - output.WriteFloatArray(100, field_names[5], unpackedFloat_); - } - if (unpackedDouble_.Count > 0) { - output.WriteDoubleArray(101, field_names[1], unpackedDouble_); - } - if (unpackedBool_.Count > 0) { - output.WriteBoolArray(102, field_names[0], unpackedBool_); - } - if (unpackedEnum_.Count > 0) { - output.WriteEnumArray(103, field_names[2], unpackedEnum_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (int element in UnpackedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedInt32_.Count; - } - { - int dataSize = 0; - foreach (long element in UnpackedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedInt64_.Count; - } - { - int dataSize = 0; - foreach (uint element in UnpackedUint32List) { - dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedUint32_.Count; - } - { - int dataSize = 0; - foreach (ulong element in UnpackedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedUint64_.Count; - } - { - int dataSize = 0; - foreach (int element in UnpackedSint32List) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedSint32_.Count; - } - { - int dataSize = 0; - foreach (long element in UnpackedSint64List) { - dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedSint64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * unpackedFixed32_.Count; - size += dataSize; - size += 2 * unpackedFixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * unpackedFixed64_.Count; - size += dataSize; - size += 2 * unpackedFixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * unpackedSfixed32_.Count; - size += dataSize; - size += 2 * unpackedSfixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * unpackedSfixed64_.Count; - size += dataSize; - size += 2 * unpackedSfixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * unpackedFloat_.Count; - size += dataSize; - size += 2 * unpackedFloat_.Count; - } - { - int dataSize = 0; - dataSize = 8 * unpackedDouble_.Count; - size += dataSize; - size += 2 * unpackedDouble_.Count; - } - { - int dataSize = 0; - dataSize = 1 * unpackedBool_.Count; - size += dataSize; - size += 2 * unpackedBool_.Count; - } - { - int dataSize = 0; - if (unpackedEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in unpackedEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * unpackedEnum_.Count; - } - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestUnpackedTypes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedTypes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestUnpackedTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestUnpackedTypes MakeReadOnly() { - unpackedInt32_.MakeReadOnly(); - unpackedInt64_.MakeReadOnly(); - unpackedUint32_.MakeReadOnly(); - unpackedUint64_.MakeReadOnly(); - unpackedSint32_.MakeReadOnly(); - unpackedSint64_.MakeReadOnly(); - unpackedFixed32_.MakeReadOnly(); - unpackedFixed64_.MakeReadOnly(); - unpackedSfixed32_.MakeReadOnly(); - unpackedSfixed64_.MakeReadOnly(); - unpackedFloat_.MakeReadOnly(); - unpackedDouble_.MakeReadOnly(); - unpackedBool_.MakeReadOnly(); - unpackedEnum_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestUnpackedTypes prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestUnpackedTypes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestUnpackedTypes result; - - private TestUnpackedTypes PrepareBuilder() { - if (resultIsReadOnly) { - TestUnpackedTypes original = result; - result = new TestUnpackedTypes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestUnpackedTypes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.Descriptor; } - } - - public override TestUnpackedTypes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.DefaultInstance; } - } - - public override TestUnpackedTypes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestUnpackedTypes) { - return MergeFrom((TestUnpackedTypes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestUnpackedTypes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.DefaultInstance) return this; - PrepareBuilder(); - if (other.unpackedInt32_.Count != 0) { - result.unpackedInt32_.Add(other.unpackedInt32_); - } - if (other.unpackedInt64_.Count != 0) { - result.unpackedInt64_.Add(other.unpackedInt64_); - } - if (other.unpackedUint32_.Count != 0) { - result.unpackedUint32_.Add(other.unpackedUint32_); - } - if (other.unpackedUint64_.Count != 0) { - result.unpackedUint64_.Add(other.unpackedUint64_); - } - if (other.unpackedSint32_.Count != 0) { - result.unpackedSint32_.Add(other.unpackedSint32_); - } - if (other.unpackedSint64_.Count != 0) { - result.unpackedSint64_.Add(other.unpackedSint64_); - } - if (other.unpackedFixed32_.Count != 0) { - result.unpackedFixed32_.Add(other.unpackedFixed32_); - } - if (other.unpackedFixed64_.Count != 0) { - result.unpackedFixed64_.Add(other.unpackedFixed64_); - } - if (other.unpackedSfixed32_.Count != 0) { - result.unpackedSfixed32_.Add(other.unpackedSfixed32_); - } - if (other.unpackedSfixed64_.Count != 0) { - result.unpackedSfixed64_.Add(other.unpackedSfixed64_); - } - if (other.unpackedFloat_.Count != 0) { - result.unpackedFloat_.Add(other.unpackedFloat_); - } - if (other.unpackedDouble_.Count != 0) { - result.unpackedDouble_.Add(other.unpackedDouble_); - } - if (other.unpackedBool_.Count != 0) { - result.unpackedBool_.Add(other.unpackedBool_); - } - if (other.unpackedEnum_.Count != 0) { - result.unpackedEnum_.Add(other.unpackedEnum_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testUnpackedTypesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testUnpackedTypesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 722: - case 720: { - input.ReadInt32Array(tag, field_name, result.unpackedInt32_); - break; - } - case 730: - case 728: { - input.ReadInt64Array(tag, field_name, result.unpackedInt64_); - break; - } - case 738: - case 736: { - input.ReadUInt32Array(tag, field_name, result.unpackedUint32_); - break; - } - case 746: - case 744: { - input.ReadUInt64Array(tag, field_name, result.unpackedUint64_); - break; - } - case 754: - case 752: { - input.ReadSInt32Array(tag, field_name, result.unpackedSint32_); - break; - } - case 762: - case 760: { - input.ReadSInt64Array(tag, field_name, result.unpackedSint64_); - break; - } - case 770: - case 773: { - input.ReadFixed32Array(tag, field_name, result.unpackedFixed32_); - break; - } - case 778: - case 777: { - input.ReadFixed64Array(tag, field_name, result.unpackedFixed64_); - break; - } - case 786: - case 789: { - input.ReadSFixed32Array(tag, field_name, result.unpackedSfixed32_); - break; - } - case 794: - case 793: { - input.ReadSFixed64Array(tag, field_name, result.unpackedSfixed64_); - break; - } - case 802: - case 805: { - input.ReadFloatArray(tag, field_name, result.unpackedFloat_); - break; - } - case 810: - case 809: { - input.ReadDoubleArray(tag, field_name, result.unpackedDouble_); - break; - } - case 818: - case 816: { - input.ReadBoolArray(tag, field_name, result.unpackedBool_); - break; - } - case 826: - case 824: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.unpackedEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(103, (ulong)(int)rawValue); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public pbc::IPopsicleList UnpackedInt32List { - get { return PrepareBuilder().unpackedInt32_; } - } - public int UnpackedInt32Count { - get { return result.UnpackedInt32Count; } - } - public int GetUnpackedInt32(int index) { - return result.GetUnpackedInt32(index); - } - public Builder SetUnpackedInt32(int index, int value) { - PrepareBuilder(); - result.unpackedInt32_[index] = value; - return this; - } - public Builder AddUnpackedInt32(int value) { - PrepareBuilder(); - result.unpackedInt32_.Add(value); - return this; - } - public Builder AddRangeUnpackedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedInt32_.Add(values); - return this; - } - public Builder ClearUnpackedInt32() { - PrepareBuilder(); - result.unpackedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedInt64List { - get { return PrepareBuilder().unpackedInt64_; } - } - public int UnpackedInt64Count { - get { return result.UnpackedInt64Count; } - } - public long GetUnpackedInt64(int index) { - return result.GetUnpackedInt64(index); - } - public Builder SetUnpackedInt64(int index, long value) { - PrepareBuilder(); - result.unpackedInt64_[index] = value; - return this; - } - public Builder AddUnpackedInt64(long value) { - PrepareBuilder(); - result.unpackedInt64_.Add(value); - return this; - } - public Builder AddRangeUnpackedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedInt64_.Add(values); - return this; - } - public Builder ClearUnpackedInt64() { - PrepareBuilder(); - result.unpackedInt64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedUint32List { - get { return PrepareBuilder().unpackedUint32_; } - } - public int UnpackedUint32Count { - get { return result.UnpackedUint32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedUint32(int index) { - return result.GetUnpackedUint32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedUint32(int index, uint value) { - PrepareBuilder(); - result.unpackedUint32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedUint32(uint value) { - PrepareBuilder(); - result.unpackedUint32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedUint32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedUint32_.Add(values); - return this; - } - public Builder ClearUnpackedUint32() { - PrepareBuilder(); - result.unpackedUint32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedUint64List { - get { return PrepareBuilder().unpackedUint64_; } - } - public int UnpackedUint64Count { - get { return result.UnpackedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedUint64(int index) { - return result.GetUnpackedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedUint64(int index, ulong value) { - PrepareBuilder(); - result.unpackedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedUint64(ulong value) { - PrepareBuilder(); - result.unpackedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedUint64_.Add(values); - return this; - } - public Builder ClearUnpackedUint64() { - PrepareBuilder(); - result.unpackedUint64_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSint32List { - get { return PrepareBuilder().unpackedSint32_; } - } - public int UnpackedSint32Count { - get { return result.UnpackedSint32Count; } - } - public int GetUnpackedSint32(int index) { - return result.GetUnpackedSint32(index); - } - public Builder SetUnpackedSint32(int index, int value) { - PrepareBuilder(); - result.unpackedSint32_[index] = value; - return this; - } - public Builder AddUnpackedSint32(int value) { - PrepareBuilder(); - result.unpackedSint32_.Add(value); - return this; - } - public Builder AddRangeUnpackedSint32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSint32_.Add(values); - return this; - } - public Builder ClearUnpackedSint32() { - PrepareBuilder(); - result.unpackedSint32_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSint64List { - get { return PrepareBuilder().unpackedSint64_; } - } - public int UnpackedSint64Count { - get { return result.UnpackedSint64Count; } - } - public long GetUnpackedSint64(int index) { - return result.GetUnpackedSint64(index); - } - public Builder SetUnpackedSint64(int index, long value) { - PrepareBuilder(); - result.unpackedSint64_[index] = value; - return this; - } - public Builder AddUnpackedSint64(long value) { - PrepareBuilder(); - result.unpackedSint64_.Add(value); - return this; - } - public Builder AddRangeUnpackedSint64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSint64_.Add(values); - return this; - } - public Builder ClearUnpackedSint64() { - PrepareBuilder(); - result.unpackedSint64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedFixed32List { - get { return PrepareBuilder().unpackedFixed32_; } - } - public int UnpackedFixed32Count { - get { return result.UnpackedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedFixed32(int index) { - return result.GetUnpackedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedFixed32(int index, uint value) { - PrepareBuilder(); - result.unpackedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedFixed32(uint value) { - PrepareBuilder(); - result.unpackedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedFixed32_.Add(values); - return this; - } - public Builder ClearUnpackedFixed32() { - PrepareBuilder(); - result.unpackedFixed32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedFixed64List { - get { return PrepareBuilder().unpackedFixed64_; } - } - public int UnpackedFixed64Count { - get { return result.UnpackedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedFixed64(int index) { - return result.GetUnpackedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedFixed64(int index, ulong value) { - PrepareBuilder(); - result.unpackedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedFixed64(ulong value) { - PrepareBuilder(); - result.unpackedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedFixed64_.Add(values); - return this; - } - public Builder ClearUnpackedFixed64() { - PrepareBuilder(); - result.unpackedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSfixed32List { - get { return PrepareBuilder().unpackedSfixed32_; } - } - public int UnpackedSfixed32Count { - get { return result.UnpackedSfixed32Count; } - } - public int GetUnpackedSfixed32(int index) { - return result.GetUnpackedSfixed32(index); - } - public Builder SetUnpackedSfixed32(int index, int value) { - PrepareBuilder(); - result.unpackedSfixed32_[index] = value; - return this; - } - public Builder AddUnpackedSfixed32(int value) { - PrepareBuilder(); - result.unpackedSfixed32_.Add(value); - return this; - } - public Builder AddRangeUnpackedSfixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSfixed32_.Add(values); - return this; - } - public Builder ClearUnpackedSfixed32() { - PrepareBuilder(); - result.unpackedSfixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSfixed64List { - get { return PrepareBuilder().unpackedSfixed64_; } - } - public int UnpackedSfixed64Count { - get { return result.UnpackedSfixed64Count; } - } - public long GetUnpackedSfixed64(int index) { - return result.GetUnpackedSfixed64(index); - } - public Builder SetUnpackedSfixed64(int index, long value) { - PrepareBuilder(); - result.unpackedSfixed64_[index] = value; - return this; - } - public Builder AddUnpackedSfixed64(long value) { - PrepareBuilder(); - result.unpackedSfixed64_.Add(value); - return this; - } - public Builder AddRangeUnpackedSfixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSfixed64_.Add(values); - return this; - } - public Builder ClearUnpackedSfixed64() { - PrepareBuilder(); - result.unpackedSfixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedFloatList { - get { return PrepareBuilder().unpackedFloat_; } - } - public int UnpackedFloatCount { - get { return result.UnpackedFloatCount; } - } - public float GetUnpackedFloat(int index) { - return result.GetUnpackedFloat(index); - } - public Builder SetUnpackedFloat(int index, float value) { - PrepareBuilder(); - result.unpackedFloat_[index] = value; - return this; - } - public Builder AddUnpackedFloat(float value) { - PrepareBuilder(); - result.unpackedFloat_.Add(value); - return this; - } - public Builder AddRangeUnpackedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedFloat_.Add(values); - return this; - } - public Builder ClearUnpackedFloat() { - PrepareBuilder(); - result.unpackedFloat_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedDoubleList { - get { return PrepareBuilder().unpackedDouble_; } - } - public int UnpackedDoubleCount { - get { return result.UnpackedDoubleCount; } - } - public double GetUnpackedDouble(int index) { - return result.GetUnpackedDouble(index); - } - public Builder SetUnpackedDouble(int index, double value) { - PrepareBuilder(); - result.unpackedDouble_[index] = value; - return this; - } - public Builder AddUnpackedDouble(double value) { - PrepareBuilder(); - result.unpackedDouble_.Add(value); - return this; - } - public Builder AddRangeUnpackedDouble(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedDouble_.Add(values); - return this; - } - public Builder ClearUnpackedDouble() { - PrepareBuilder(); - result.unpackedDouble_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedBoolList { - get { return PrepareBuilder().unpackedBool_; } - } - public int UnpackedBoolCount { - get { return result.UnpackedBoolCount; } - } - public bool GetUnpackedBool(int index) { - return result.GetUnpackedBool(index); - } - public Builder SetUnpackedBool(int index, bool value) { - PrepareBuilder(); - result.unpackedBool_[index] = value; - return this; - } - public Builder AddUnpackedBool(bool value) { - PrepareBuilder(); - result.unpackedBool_.Add(value); - return this; - } - public Builder AddRangeUnpackedBool(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedBool_.Add(values); - return this; - } - public Builder ClearUnpackedBool() { - PrepareBuilder(); - result.unpackedBool_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedEnumList { - get { return PrepareBuilder().unpackedEnum_; } - } - public int UnpackedEnumCount { - get { return result.UnpackedEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetUnpackedEnum(int index) { - return result.GetUnpackedEnum(index); - } - public Builder SetUnpackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.unpackedEnum_[index] = value; - return this; - } - public Builder AddUnpackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.unpackedEnum_.Add(value); - return this; - } - public Builder AddRangeUnpackedEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedEnum_.Add(values); - return this; - } - public Builder ClearUnpackedEnum() { - PrepareBuilder(); - result.unpackedEnum_.Clear(); - return this; - } - } - static TestUnpackedTypes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestPackedExtensions : pb::ExtendableMessage { - private TestPackedExtensions() { } - private static readonly TestPackedExtensions defaultInstance = new TestPackedExtensions().MakeReadOnly(); - private static readonly string[] _testPackedExtensionsFieldNames = new string[] { }; - private static readonly uint[] _testPackedExtensionsFieldTags = new uint[] { }; - public static TestPackedExtensions DefaultInstance { - get { return defaultInstance; } - } - - public override TestPackedExtensions DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestPackedExtensions ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestPackedExtensions__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testPackedExtensionsFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(536870912, output); - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestPackedExtensions ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestPackedExtensions ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestPackedExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestPackedExtensions MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestPackedExtensions prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestPackedExtensions cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestPackedExtensions result; - - private TestPackedExtensions PrepareBuilder() { - if (resultIsReadOnly) { - TestPackedExtensions original = result; - result = new TestPackedExtensions(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestPackedExtensions MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.Descriptor; } - } - - public override TestPackedExtensions DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.DefaultInstance; } - } - - public override TestPackedExtensions BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestPackedExtensions) { - return MergeFrom((TestPackedExtensions) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestPackedExtensions other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testPackedExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testPackedExtensionsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static TestPackedExtensions() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestDynamicExtensions : pb::GeneratedMessage { - private TestDynamicExtensions() { } - private static readonly TestDynamicExtensions defaultInstance = new TestDynamicExtensions().MakeReadOnly(); - private static readonly string[] _testDynamicExtensionsFieldNames = new string[] { "dynamic_enum_extension", "dynamic_message_extension", "enum_extension", "message_extension", "packed_extension", "repeated_extension", "scalar_extension" }; - private static readonly uint[] _testDynamicExtensionsFieldTags = new uint[] { 16016, 16034, 16008, 16026, 16050, 16042, 16005 }; - public static TestDynamicExtensions DefaultInstance { - get { return defaultInstance; } - } - - public override TestDynamicExtensions DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestDynamicExtensions ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - public enum DynamicEnumType { - DYNAMIC_FOO = 2200, - DYNAMIC_BAR = 2201, - DYNAMIC_BAZ = 2202, - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class DynamicMessageType : pb::GeneratedMessage { - private DynamicMessageType() { } - private static readonly DynamicMessageType defaultInstance = new DynamicMessageType().MakeReadOnly(); - private static readonly string[] _dynamicMessageTypeFieldNames = new string[] { "dynamic_field" }; - private static readonly uint[] _dynamicMessageTypeFieldTags = new uint[] { 16800 }; - public static DynamicMessageType DefaultInstance { - get { return defaultInstance; } - } - - public override DynamicMessageType DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override DynamicMessageType ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable; } - } - - public const int DynamicFieldFieldNumber = 2100; - private bool hasDynamicField; - private int dynamicField_; - public bool HasDynamicField { - get { return hasDynamicField; } - } - public int DynamicField { - get { return dynamicField_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _dynamicMessageTypeFieldNames; - if (hasDynamicField) { - output.WriteInt32(2100, field_names[0], DynamicField); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasDynamicField) { - size += pb::CodedOutputStream.ComputeInt32Size(2100, DynamicField); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static DynamicMessageType ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static DynamicMessageType ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static DynamicMessageType ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static DynamicMessageType ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static DynamicMessageType ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static DynamicMessageType ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static DynamicMessageType ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static DynamicMessageType ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static DynamicMessageType ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static DynamicMessageType ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private DynamicMessageType MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(DynamicMessageType prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(DynamicMessageType cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private DynamicMessageType result; - - private DynamicMessageType PrepareBuilder() { - if (resultIsReadOnly) { - DynamicMessageType original = result; - result = new DynamicMessageType(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override DynamicMessageType MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Descriptor; } - } - - public override DynamicMessageType DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance; } - } - - public override DynamicMessageType BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is DynamicMessageType) { - return MergeFrom((DynamicMessageType) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(DynamicMessageType other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasDynamicField) { - DynamicField = other.DynamicField; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_dynamicMessageTypeFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _dynamicMessageTypeFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 16800: { - result.hasDynamicField = input.ReadInt32(ref result.dynamicField_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasDynamicField { - get { return result.hasDynamicField; } - } - public int DynamicField { - get { return result.DynamicField; } - set { SetDynamicField(value); } - } - public Builder SetDynamicField(int value) { - PrepareBuilder(); - result.hasDynamicField = true; - result.dynamicField_ = value; - return this; - } - public Builder ClearDynamicField() { - PrepareBuilder(); - result.hasDynamicField = false; - result.dynamicField_ = 0; - return this; - } - } - static DynamicMessageType() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - } - #endregion - - public const int ScalarExtensionFieldNumber = 2000; - private bool hasScalarExtension; - private uint scalarExtension_; - public bool HasScalarExtension { - get { return hasScalarExtension; } - } - [global::System.CLSCompliant(false)] - public uint ScalarExtension { - get { return scalarExtension_; } - } - - public const int EnumExtensionFieldNumber = 2001; - private bool hasEnumExtension; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnum enumExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - public bool HasEnumExtension { - get { return hasEnumExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumExtension { - get { return enumExtension_; } - } - - public const int DynamicEnumExtensionFieldNumber = 2002; - private bool hasDynamicEnumExtension; - private global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType dynamicEnumExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType.DYNAMIC_FOO; - public bool HasDynamicEnumExtension { - get { return hasDynamicEnumExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType DynamicEnumExtension { - get { return dynamicEnumExtension_; } - } - - public const int MessageExtensionFieldNumber = 2003; - private bool hasMessageExtension; - private global::Google.ProtocolBuffers.TestProtos.ForeignMessage messageExtension_; - public bool HasMessageExtension { - get { return hasMessageExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageExtension { - get { return messageExtension_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } - } - - public const int DynamicMessageExtensionFieldNumber = 2004; - private bool hasDynamicMessageExtension; - private global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType dynamicMessageExtension_; - public bool HasDynamicMessageExtension { - get { return hasDynamicMessageExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType DynamicMessageExtension { - get { return dynamicMessageExtension_ ?? global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance; } - } - - public const int RepeatedExtensionFieldNumber = 2005; - private pbc::PopsicleList repeatedExtension_ = new pbc::PopsicleList(); - public scg::IList RepeatedExtensionList { - get { return pbc::Lists.AsReadOnly(repeatedExtension_); } - } - public int RepeatedExtensionCount { - get { return repeatedExtension_.Count; } - } - public string GetRepeatedExtension(int index) { - return repeatedExtension_[index]; - } - - public const int PackedExtensionFieldNumber = 2006; - private int packedExtensionMemoizedSerializedSize; - private pbc::PopsicleList packedExtension_ = new pbc::PopsicleList(); - public scg::IList PackedExtensionList { - get { return pbc::Lists.AsReadOnly(packedExtension_); } - } - public int PackedExtensionCount { - get { return packedExtension_.Count; } - } - public int GetPackedExtension(int index) { - return packedExtension_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testDynamicExtensionsFieldNames; - if (hasScalarExtension) { - output.WriteFixed32(2000, field_names[6], ScalarExtension); - } - if (hasEnumExtension) { - output.WriteEnum(2001, field_names[2], (int) EnumExtension, EnumExtension); - } - if (hasDynamicEnumExtension) { - output.WriteEnum(2002, field_names[0], (int) DynamicEnumExtension, DynamicEnumExtension); - } - if (hasMessageExtension) { - output.WriteMessage(2003, field_names[3], MessageExtension); - } - if (hasDynamicMessageExtension) { - output.WriteMessage(2004, field_names[1], DynamicMessageExtension); - } - if (repeatedExtension_.Count > 0) { - output.WriteStringArray(2005, field_names[5], repeatedExtension_); - } - if (packedExtension_.Count > 0) { - output.WritePackedSInt32Array(2006, field_names[4], packedExtensionMemoizedSerializedSize, packedExtension_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasScalarExtension) { - size += pb::CodedOutputStream.ComputeFixed32Size(2000, ScalarExtension); - } - if (hasEnumExtension) { - size += pb::CodedOutputStream.ComputeEnumSize(2001, (int) EnumExtension); - } - if (hasDynamicEnumExtension) { - size += pb::CodedOutputStream.ComputeEnumSize(2002, (int) DynamicEnumExtension); - } - if (hasMessageExtension) { - size += pb::CodedOutputStream.ComputeMessageSize(2003, MessageExtension); - } - if (hasDynamicMessageExtension) { - size += pb::CodedOutputStream.ComputeMessageSize(2004, DynamicMessageExtension); - } - { - int dataSize = 0; - foreach (string element in RepeatedExtensionList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedExtension_.Count; - } - { - int dataSize = 0; - foreach (int element in PackedExtensionList) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - if (packedExtension_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedExtensionMemoizedSerializedSize = dataSize; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestDynamicExtensions ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestDynamicExtensions ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestDynamicExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestDynamicExtensions MakeReadOnly() { - repeatedExtension_.MakeReadOnly(); - packedExtension_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestDynamicExtensions prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestDynamicExtensions cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestDynamicExtensions result; - - private TestDynamicExtensions PrepareBuilder() { - if (resultIsReadOnly) { - TestDynamicExtensions original = result; - result = new TestDynamicExtensions(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestDynamicExtensions MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Descriptor; } - } - - public override TestDynamicExtensions DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.DefaultInstance; } - } - - public override TestDynamicExtensions BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestDynamicExtensions) { - return MergeFrom((TestDynamicExtensions) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestDynamicExtensions other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasScalarExtension) { - ScalarExtension = other.ScalarExtension; - } - if (other.HasEnumExtension) { - EnumExtension = other.EnumExtension; - } - if (other.HasDynamicEnumExtension) { - DynamicEnumExtension = other.DynamicEnumExtension; - } - if (other.HasMessageExtension) { - MergeMessageExtension(other.MessageExtension); - } - if (other.HasDynamicMessageExtension) { - MergeDynamicMessageExtension(other.DynamicMessageExtension); - } - if (other.repeatedExtension_.Count != 0) { - result.repeatedExtension_.Add(other.repeatedExtension_); - } - if (other.packedExtension_.Count != 0) { - result.packedExtension_.Add(other.packedExtension_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testDynamicExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testDynamicExtensionsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 16005: { - result.hasScalarExtension = input.ReadFixed32(ref result.scalarExtension_); - break; - } - case 16008: { - object unknown; - if(input.ReadEnum(ref result.enumExtension_, out unknown)) { - result.hasEnumExtension = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(2001, (ulong)(int)unknown); - } - break; - } - case 16016: { - object unknown; - if(input.ReadEnum(ref result.dynamicEnumExtension_, out unknown)) { - result.hasDynamicEnumExtension = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(2002, (ulong)(int)unknown); - } - break; - } - case 16026: { - global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); - if (result.hasMessageExtension) { - subBuilder.MergeFrom(MessageExtension); - } - input.ReadMessage(subBuilder, extensionRegistry); - MessageExtension = subBuilder.BuildPartial(); - break; - } - case 16034: { - global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.CreateBuilder(); - if (result.hasDynamicMessageExtension) { - subBuilder.MergeFrom(DynamicMessageExtension); - } - input.ReadMessage(subBuilder, extensionRegistry); - DynamicMessageExtension = subBuilder.BuildPartial(); - break; - } - case 16042: { - input.ReadStringArray(tag, field_name, result.repeatedExtension_); - break; - } - case 16050: - case 16048: { - input.ReadSInt32Array(tag, field_name, result.packedExtension_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasScalarExtension { - get { return result.hasScalarExtension; } - } - [global::System.CLSCompliant(false)] - public uint ScalarExtension { - get { return result.ScalarExtension; } - set { SetScalarExtension(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetScalarExtension(uint value) { - PrepareBuilder(); - result.hasScalarExtension = true; - result.scalarExtension_ = value; - return this; - } - public Builder ClearScalarExtension() { - PrepareBuilder(); - result.hasScalarExtension = false; - result.scalarExtension_ = 0; - return this; - } - - public bool HasEnumExtension { - get { return result.hasEnumExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumExtension { - get { return result.EnumExtension; } - set { SetEnumExtension(value); } - } - public Builder SetEnumExtension(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.hasEnumExtension = true; - result.enumExtension_ = value; - return this; - } - public Builder ClearEnumExtension() { - PrepareBuilder(); - result.hasEnumExtension = false; - result.enumExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - return this; - } - - public bool HasDynamicEnumExtension { - get { return result.hasDynamicEnumExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType DynamicEnumExtension { - get { return result.DynamicEnumExtension; } - set { SetDynamicEnumExtension(value); } - } - public Builder SetDynamicEnumExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType value) { - PrepareBuilder(); - result.hasDynamicEnumExtension = true; - result.dynamicEnumExtension_ = value; - return this; - } - public Builder ClearDynamicEnumExtension() { - PrepareBuilder(); - result.hasDynamicEnumExtension = false; - result.dynamicEnumExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType.DYNAMIC_FOO; - return this; - } - - public bool HasMessageExtension { - get { return result.hasMessageExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageExtension { - get { return result.MessageExtension; } - set { SetMessageExtension(value); } - } - public Builder SetMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasMessageExtension = true; - result.messageExtension_ = value; - return this; - } - public Builder SetMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasMessageExtension = true; - result.messageExtension_ = builderForValue.Build(); - return this; - } - public Builder MergeMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasMessageExtension && - result.messageExtension_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) { - result.messageExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.messageExtension_).MergeFrom(value).BuildPartial(); - } else { - result.messageExtension_ = value; - } - result.hasMessageExtension = true; - return this; - } - public Builder ClearMessageExtension() { - PrepareBuilder(); - result.hasMessageExtension = false; - result.messageExtension_ = null; - return this; - } - - public bool HasDynamicMessageExtension { - get { return result.hasDynamicMessageExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType DynamicMessageExtension { - get { return result.DynamicMessageExtension; } - set { SetDynamicMessageExtension(value); } - } - public Builder SetDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDynamicMessageExtension = true; - result.dynamicMessageExtension_ = value; - return this; - } - public Builder SetDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasDynamicMessageExtension = true; - result.dynamicMessageExtension_ = builderForValue.Build(); - return this; - } - public Builder MergeDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasDynamicMessageExtension && - result.dynamicMessageExtension_ != global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance) { - result.dynamicMessageExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.CreateBuilder(result.dynamicMessageExtension_).MergeFrom(value).BuildPartial(); - } else { - result.dynamicMessageExtension_ = value; - } - result.hasDynamicMessageExtension = true; - return this; - } - public Builder ClearDynamicMessageExtension() { - PrepareBuilder(); - result.hasDynamicMessageExtension = false; - result.dynamicMessageExtension_ = null; - return this; - } - - public pbc::IPopsicleList RepeatedExtensionList { - get { return PrepareBuilder().repeatedExtension_; } - } - public int RepeatedExtensionCount { - get { return result.RepeatedExtensionCount; } - } - public string GetRepeatedExtension(int index) { - return result.GetRepeatedExtension(index); - } - public Builder SetRepeatedExtension(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedExtension_[index] = value; - return this; - } - public Builder AddRepeatedExtension(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedExtension_.Add(value); - return this; - } - public Builder AddRangeRepeatedExtension(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedExtension_.Add(values); - return this; - } - public Builder ClearRepeatedExtension() { - PrepareBuilder(); - result.repeatedExtension_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedExtensionList { - get { return PrepareBuilder().packedExtension_; } - } - public int PackedExtensionCount { - get { return result.PackedExtensionCount; } - } - public int GetPackedExtension(int index) { - return result.GetPackedExtension(index); - } - public Builder SetPackedExtension(int index, int value) { - PrepareBuilder(); - result.packedExtension_[index] = value; - return this; - } - public Builder AddPackedExtension(int value) { - PrepareBuilder(); - result.packedExtension_.Add(value); - return this; - } - public Builder AddRangePackedExtension(scg::IEnumerable values) { - PrepareBuilder(); - result.packedExtension_.Add(values); - return this; - } - public Builder ClearPackedExtension() { - PrepareBuilder(); - result.packedExtension_.Clear(); - return this; - } - } - static TestDynamicExtensions() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestRepeatedScalarDifferentTagSizes : pb::GeneratedMessage { - private TestRepeatedScalarDifferentTagSizes() { } - private static readonly TestRepeatedScalarDifferentTagSizes defaultInstance = new TestRepeatedScalarDifferentTagSizes().MakeReadOnly(); - private static readonly string[] _testRepeatedScalarDifferentTagSizesFieldNames = new string[] { "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_int32", "repeated_int64", "repeated_uint64" }; - private static readonly uint[] _testRepeatedScalarDifferentTagSizesFieldTags = new uint[] { 101, 16369, 2097141, 104, 16376, 2097144 }; - public static TestRepeatedScalarDifferentTagSizes DefaultInstance { - get { return defaultInstance; } - } - - public override TestRepeatedScalarDifferentTagSizes DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestRepeatedScalarDifferentTagSizes ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable; } - } - - public const int RepeatedFixed32FieldNumber = 12; - private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed32List { - get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } - } - public int RepeatedFixed32Count { - get { return repeatedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return repeatedFixed32_[index]; - } - - public const int RepeatedInt32FieldNumber = 13; - private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt32List { - get { return pbc::Lists.AsReadOnly(repeatedInt32_); } - } - public int RepeatedInt32Count { - get { return repeatedInt32_.Count; } - } - public int GetRepeatedInt32(int index) { - return repeatedInt32_[index]; - } - - public const int RepeatedFixed64FieldNumber = 2046; - private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed64List { - get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } - } - public int RepeatedFixed64Count { - get { return repeatedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return repeatedFixed64_[index]; - } - - public const int RepeatedInt64FieldNumber = 2047; - private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt64List { - get { return pbc::Lists.AsReadOnly(repeatedInt64_); } - } - public int RepeatedInt64Count { - get { return repeatedInt64_.Count; } - } - public long GetRepeatedInt64(int index) { - return repeatedInt64_[index]; - } - - public const int RepeatedFloatFieldNumber = 262142; - private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); - public scg::IList RepeatedFloatList { - get { return pbc::Lists.AsReadOnly(repeatedFloat_); } - } - public int RepeatedFloatCount { - get { return repeatedFloat_.Count; } - } - public float GetRepeatedFloat(int index) { - return repeatedFloat_[index]; - } - - public const int RepeatedUint64FieldNumber = 262143; - private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedUint64List { - get { return pbc::Lists.AsReadOnly(repeatedUint64_); } - } - public int RepeatedUint64Count { - get { return repeatedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return repeatedUint64_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testRepeatedScalarDifferentTagSizesFieldNames; - if (repeatedFixed32_.Count > 0) { - output.WriteFixed32Array(12, field_names[0], repeatedFixed32_); - } - if (repeatedInt32_.Count > 0) { - output.WriteInt32Array(13, field_names[3], repeatedInt32_); - } - if (repeatedFixed64_.Count > 0) { - output.WriteFixed64Array(2046, field_names[1], repeatedFixed64_); - } - if (repeatedInt64_.Count > 0) { - output.WriteInt64Array(2047, field_names[4], repeatedInt64_); - } - if (repeatedFloat_.Count > 0) { - output.WriteFloatArray(262142, field_names[2], repeatedFloat_); - } - if (repeatedUint64_.Count > 0) { - output.WriteUInt64Array(262143, field_names[5], repeatedUint64_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - dataSize = 4 * repeatedFixed32_.Count; - size += dataSize; - size += 1 * repeatedFixed32_.Count; - } - { - int dataSize = 0; - foreach (int element in RepeatedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 1 * repeatedInt32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedFixed64_.Count; - size += dataSize; - size += 2 * repeatedFixed64_.Count; - } - { - int dataSize = 0; - foreach (long element in RepeatedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedInt64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedFloat_.Count; - size += dataSize; - size += 3 * repeatedFloat_.Count; - } - { - int dataSize = 0; - foreach (ulong element in RepeatedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - size += 3 * repeatedUint64_.Count; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestRepeatedScalarDifferentTagSizes MakeReadOnly() { - repeatedFixed32_.MakeReadOnly(); - repeatedInt32_.MakeReadOnly(); - repeatedFixed64_.MakeReadOnly(); - repeatedInt64_.MakeReadOnly(); - repeatedFloat_.MakeReadOnly(); - repeatedUint64_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestRepeatedScalarDifferentTagSizes prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestRepeatedScalarDifferentTagSizes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestRepeatedScalarDifferentTagSizes result; - - private TestRepeatedScalarDifferentTagSizes PrepareBuilder() { - if (resultIsReadOnly) { - TestRepeatedScalarDifferentTagSizes original = result; - result = new TestRepeatedScalarDifferentTagSizes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestRepeatedScalarDifferentTagSizes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.Descriptor; } - } - - public override TestRepeatedScalarDifferentTagSizes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.DefaultInstance; } - } - - public override TestRepeatedScalarDifferentTagSizes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestRepeatedScalarDifferentTagSizes) { - return MergeFrom((TestRepeatedScalarDifferentTagSizes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestRepeatedScalarDifferentTagSizes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.DefaultInstance) return this; - PrepareBuilder(); - if (other.repeatedFixed32_.Count != 0) { - result.repeatedFixed32_.Add(other.repeatedFixed32_); - } - if (other.repeatedInt32_.Count != 0) { - result.repeatedInt32_.Add(other.repeatedInt32_); - } - if (other.repeatedFixed64_.Count != 0) { - result.repeatedFixed64_.Add(other.repeatedFixed64_); - } - if (other.repeatedInt64_.Count != 0) { - result.repeatedInt64_.Add(other.repeatedInt64_); - } - if (other.repeatedFloat_.Count != 0) { - result.repeatedFloat_.Add(other.repeatedFloat_); - } - if (other.repeatedUint64_.Count != 0) { - result.repeatedUint64_.Add(other.repeatedUint64_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testRepeatedScalarDifferentTagSizesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testRepeatedScalarDifferentTagSizesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 98: - case 101: { - input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); - break; - } - case 106: - case 104: { - input.ReadInt32Array(tag, field_name, result.repeatedInt32_); - break; - } - case 16370: - case 16369: { - input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); - break; - } - case 16378: - case 16376: { - input.ReadInt64Array(tag, field_name, result.repeatedInt64_); - break; - } - case 2097138: - case 2097141: { - input.ReadFloatArray(tag, field_name, result.repeatedFloat_); - break; - } - case 2097146: - case 2097144: { - input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed32List { - get { return PrepareBuilder().repeatedFixed32_; } - } - public int RepeatedFixed32Count { - get { return result.RepeatedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return result.GetRepeatedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed32(int index, uint value) { - PrepareBuilder(); - result.repeatedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed32(uint value) { - PrepareBuilder(); - result.repeatedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed32_.Add(values); - return this; - } - public Builder ClearRepeatedFixed32() { - PrepareBuilder(); - result.repeatedFixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedInt32List { - get { return PrepareBuilder().repeatedInt32_; } - } - public int RepeatedInt32Count { - get { return result.RepeatedInt32Count; } - } - public int GetRepeatedInt32(int index) { - return result.GetRepeatedInt32(index); - } - public Builder SetRepeatedInt32(int index, int value) { - PrepareBuilder(); - result.repeatedInt32_[index] = value; - return this; - } - public Builder AddRepeatedInt32(int value) { - PrepareBuilder(); - result.repeatedInt32_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt32_.Add(values); - return this; - } - public Builder ClearRepeatedInt32() { - PrepareBuilder(); - result.repeatedInt32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed64List { - get { return PrepareBuilder().repeatedFixed64_; } - } - public int RepeatedFixed64Count { - get { return result.RepeatedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return result.GetRepeatedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed64(int index, ulong value) { - PrepareBuilder(); - result.repeatedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed64(ulong value) { - PrepareBuilder(); - result.repeatedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed64_.Add(values); - return this; - } - public Builder ClearRepeatedFixed64() { - PrepareBuilder(); - result.repeatedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedInt64List { - get { return PrepareBuilder().repeatedInt64_; } - } - public int RepeatedInt64Count { - get { return result.RepeatedInt64Count; } - } - public long GetRepeatedInt64(int index) { - return result.GetRepeatedInt64(index); - } - public Builder SetRepeatedInt64(int index, long value) { - PrepareBuilder(); - result.repeatedInt64_[index] = value; - return this; - } - public Builder AddRepeatedInt64(long value) { - PrepareBuilder(); - result.repeatedInt64_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt64_.Add(values); - return this; - } - public Builder ClearRepeatedInt64() { - PrepareBuilder(); - result.repeatedInt64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedFloatList { - get { return PrepareBuilder().repeatedFloat_; } - } - public int RepeatedFloatCount { - get { return result.RepeatedFloatCount; } - } - public float GetRepeatedFloat(int index) { - return result.GetRepeatedFloat(index); - } - public Builder SetRepeatedFloat(int index, float value) { - PrepareBuilder(); - result.repeatedFloat_[index] = value; - return this; - } - public Builder AddRepeatedFloat(float value) { - PrepareBuilder(); - result.repeatedFloat_.Add(value); - return this; - } - public Builder AddRangeRepeatedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFloat_.Add(values); - return this; - } - public Builder ClearRepeatedFloat() { - PrepareBuilder(); - result.repeatedFloat_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedUint64List { - get { return PrepareBuilder().repeatedUint64_; } - } - public int RepeatedUint64Count { - get { return result.RepeatedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return result.GetRepeatedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedUint64(int index, ulong value) { - PrepareBuilder(); - result.repeatedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedUint64(ulong value) { - PrepareBuilder(); - result.repeatedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedUint64_.Add(values); - return this; - } - public Builder ClearRepeatedUint64() { - PrepareBuilder(); - result.repeatedUint64_.Clear(); - return this; - } - } - static TestRepeatedScalarDifferentTagSizes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class FooRequest : pb::GeneratedMessage { - private FooRequest() { } - private static readonly FooRequest defaultInstance = new FooRequest().MakeReadOnly(); - private static readonly string[] _fooRequestFieldNames = new string[] { }; - private static readonly uint[] _fooRequestFieldTags = new uint[] { }; - public static FooRequest DefaultInstance { - get { return defaultInstance; } - } - - public override FooRequest DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override FooRequest ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_FooRequest__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_FooRequest__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooRequestFieldNames; - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static FooRequest ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooRequest ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooRequest ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static FooRequest ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static FooRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static FooRequest ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private FooRequest MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(FooRequest prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(FooRequest cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private FooRequest result; - - private FooRequest PrepareBuilder() { - if (resultIsReadOnly) { - FooRequest original = result; - result = new FooRequest(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override FooRequest MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooRequest.Descriptor; } - } - - public override FooRequest DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooRequest.DefaultInstance; } - } - - public override FooRequest BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is FooRequest) { - return MergeFrom((FooRequest) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(FooRequest other) { - if (other == global::Google.ProtocolBuffers.TestProtos.FooRequest.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooRequestFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooRequestFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static FooRequest() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class FooResponse : pb::GeneratedMessage { - private FooResponse() { } - private static readonly FooResponse defaultInstance = new FooResponse().MakeReadOnly(); - private static readonly string[] _fooResponseFieldNames = new string[] { }; - private static readonly uint[] _fooResponseFieldTags = new uint[] { }; - public static FooResponse DefaultInstance { - get { return defaultInstance; } - } - - public override FooResponse DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override FooResponse ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_FooResponse__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_FooResponse__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooResponseFieldNames; - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static FooResponse ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooResponse ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooResponse ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static FooResponse ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static FooResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static FooResponse ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private FooResponse MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(FooResponse prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(FooResponse cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private FooResponse result; - - private FooResponse PrepareBuilder() { - if (resultIsReadOnly) { - FooResponse original = result; - result = new FooResponse(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override FooResponse MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooResponse.Descriptor; } - } - - public override FooResponse DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooResponse.DefaultInstance; } - } - - public override FooResponse BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is FooResponse) { - return MergeFrom((FooResponse) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(FooResponse other) { - if (other == global::Google.ProtocolBuffers.TestProtos.FooResponse.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooResponseFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooResponseFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static FooResponse() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class BarRequest : pb::GeneratedMessage { - private BarRequest() { } - private static readonly BarRequest defaultInstance = new BarRequest().MakeReadOnly(); - private static readonly string[] _barRequestFieldNames = new string[] { }; - private static readonly uint[] _barRequestFieldTags = new uint[] { }; - public static BarRequest DefaultInstance { - get { return defaultInstance; } - } - - public override BarRequest DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override BarRequest ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_BarRequest__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_BarRequest__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _barRequestFieldNames; - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static BarRequest ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BarRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BarRequest ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BarRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BarRequest ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BarRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static BarRequest ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static BarRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static BarRequest ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BarRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private BarRequest MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(BarRequest prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(BarRequest cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private BarRequest result; - - private BarRequest PrepareBuilder() { - if (resultIsReadOnly) { - BarRequest original = result; - result = new BarRequest(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override BarRequest MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.BarRequest.Descriptor; } - } - - public override BarRequest DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.BarRequest.DefaultInstance; } - } - - public override BarRequest BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is BarRequest) { - return MergeFrom((BarRequest) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(BarRequest other) { - if (other == global::Google.ProtocolBuffers.TestProtos.BarRequest.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_barRequestFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _barRequestFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static BarRequest() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class BarResponse : pb::GeneratedMessage { - private BarResponse() { } - private static readonly BarResponse defaultInstance = new BarResponse().MakeReadOnly(); - private static readonly string[] _barResponseFieldNames = new string[] { }; - private static readonly uint[] _barResponseFieldTags = new uint[] { }; - public static BarResponse DefaultInstance { - get { return defaultInstance; } - } - - public override BarResponse DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override BarResponse ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_BarResponse__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_BarResponse__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _barResponseFieldNames; - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static BarResponse ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BarResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BarResponse ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BarResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BarResponse ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BarResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static BarResponse ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static BarResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static BarResponse ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BarResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private BarResponse MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(BarResponse prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(BarResponse cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private BarResponse result; - - private BarResponse PrepareBuilder() { - if (resultIsReadOnly) { - BarResponse original = result; - result = new BarResponse(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override BarResponse MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.BarResponse.Descriptor; } - } - - public override BarResponse DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.BarResponse.DefaultInstance; } - } - - public override BarResponse BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is BarResponse) { - return MergeFrom((BarResponse) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(BarResponse other) { - if (other == global::Google.ProtocolBuffers.TestProtos.BarResponse.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_barResponseFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _barResponseFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static BarResponse() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null); - } - } - - #endregion - - #region Services - /* - * Service generation is now disabled by default, use the following option to enable: - * option (google.protobuf.csharp_file_options).service_generator_type = GENERIC; - */ - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestRpcInteropLite.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestRpcInteropLite.cs deleted file mode 100644 index 189ff0db..00000000 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnitTestRpcInteropLite.cs +++ /dev/null @@ -1,1395 +0,0 @@ -// Generated by ProtoGen, Version=2.4.1.555, Culture=neutral, PublicKeyToken=55f7125234beb589. DO NOT EDIT! -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnitTestRpcInteropLite { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - } - #endregion - #region Static variables - #endregion - #region Extensions - internal static readonly object Descriptor; - static UnitTestRpcInteropLite() { - Descriptor = null; - } - #endregion - - } - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class SearchRequest : pb::GeneratedMessageLite { - private SearchRequest() { } - private static readonly SearchRequest defaultInstance = new SearchRequest().MakeReadOnly(); - private static readonly string[] _searchRequestFieldNames = new string[] { "Criteria" }; - private static readonly uint[] _searchRequestFieldTags = new uint[] { 10 }; - public static SearchRequest DefaultInstance { - get { return defaultInstance; } - } - - public override SearchRequest DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override SearchRequest ThisMessage { - get { return this; } - } - - public const int CriteriaFieldNumber = 1; - private pbc::PopsicleList criteria_ = new pbc::PopsicleList(); - public scg::IList CriteriaList { - get { return pbc::Lists.AsReadOnly(criteria_); } - } - public int CriteriaCount { - get { return criteria_.Count; } - } - public string GetCriteria(int index) { - return criteria_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _searchRequestFieldNames; - if (criteria_.Count > 0) { - output.WriteStringArray(1, field_names[0], criteria_); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (string element in CriteriaList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 1 * criteria_.Count; - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - foreach(string i in criteria_) - hash ^= i.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - SearchRequest other = obj as SearchRequest; - if (other == null) return false; - if(criteria_.Count != other.criteria_.Count) return false; - for(int ix=0; ix < criteria_.Count; ix++) - if(!criteria_[ix].Equals(other.criteria_[ix])) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("Criteria", criteria_, writer); - } - #endregion - - public static SearchRequest ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SearchRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SearchRequest ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SearchRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SearchRequest ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SearchRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static SearchRequest ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static SearchRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static SearchRequest ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SearchRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private SearchRequest MakeReadOnly() { - criteria_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(SearchRequest prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(SearchRequest cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private SearchRequest result; - - private SearchRequest PrepareBuilder() { - if (resultIsReadOnly) { - SearchRequest original = result; - result = new SearchRequest(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override SearchRequest MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override SearchRequest DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.SearchRequest.DefaultInstance; } - } - - public override SearchRequest BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is SearchRequest) { - return MergeFrom((SearchRequest) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(SearchRequest other) { - if (other == global::Google.ProtocolBuffers.TestProtos.SearchRequest.DefaultInstance) return this; - PrepareBuilder(); - if (other.criteria_.Count != 0) { - result.criteria_.Add(other.criteria_); - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_searchRequestFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _searchRequestFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - input.ReadStringArray(tag, field_name, result.criteria_); - break; - } - } - } - - return this; - } - - - public pbc::IPopsicleList CriteriaList { - get { return PrepareBuilder().criteria_; } - } - public int CriteriaCount { - get { return result.CriteriaCount; } - } - public string GetCriteria(int index) { - return result.GetCriteria(index); - } - public Builder SetCriteria(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.criteria_[index] = value; - return this; - } - public Builder AddCriteria(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.criteria_.Add(value); - return this; - } - public Builder AddRangeCriteria(scg::IEnumerable values) { - PrepareBuilder(); - result.criteria_.Add(values); - return this; - } - public Builder ClearCriteria() { - PrepareBuilder(); - result.criteria_.Clear(); - return this; - } - } - static SearchRequest() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestRpcInteropLite.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class SearchResponse : pb::GeneratedMessageLite { - private SearchResponse() { } - private static readonly SearchResponse defaultInstance = new SearchResponse().MakeReadOnly(); - private static readonly string[] _searchResponseFieldNames = new string[] { "results" }; - private static readonly uint[] _searchResponseFieldTags = new uint[] { 10 }; - public static SearchResponse DefaultInstance { - get { return defaultInstance; } - } - - public override SearchResponse DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override SearchResponse ThisMessage { - get { return this; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class ResultItem : pb::GeneratedMessageLite { - private ResultItem() { } - private static readonly ResultItem defaultInstance = new ResultItem().MakeReadOnly(); - private static readonly string[] _resultItemFieldNames = new string[] { "name", "url" }; - private static readonly uint[] _resultItemFieldTags = new uint[] { 18, 10 }; - public static ResultItem DefaultInstance { - get { return defaultInstance; } - } - - public override ResultItem DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override ResultItem ThisMessage { - get { return this; } - } - - public const int UrlFieldNumber = 1; - private bool hasUrl; - private string url_ = ""; - public bool HasUrl { - get { return hasUrl; } - } - public string Url { - get { return url_; } - } - - public const int NameFieldNumber = 2; - private bool hasName; - private string name_ = ""; - public bool HasName { - get { return hasName; } - } - public string Name { - get { return name_; } - } - - public override bool IsInitialized { - get { - if (!hasUrl) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _resultItemFieldNames; - if (hasUrl) { - output.WriteString(1, field_names[1], Url); - } - if (hasName) { - output.WriteString(2, field_names[0], Name); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasUrl) { - size += pb::CodedOutputStream.ComputeStringSize(1, Url); - } - if (hasName) { - size += pb::CodedOutputStream.ComputeStringSize(2, Name); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - if (hasUrl) hash ^= url_.GetHashCode(); - if (hasName) hash ^= name_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - ResultItem other = obj as ResultItem; - if (other == null) return false; - if (hasUrl != other.hasUrl || (hasUrl && !url_.Equals(other.url_))) return false; - if (hasName != other.hasName || (hasName && !name_.Equals(other.name_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("url", hasUrl, url_, writer); - PrintField("name", hasName, name_, writer); - } - #endregion - - public static ResultItem ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ResultItem ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ResultItem ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ResultItem ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ResultItem ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ResultItem ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static ResultItem ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static ResultItem ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static ResultItem ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ResultItem ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private ResultItem MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(ResultItem prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(ResultItem cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private ResultItem result; - - private ResultItem PrepareBuilder() { - if (resultIsReadOnly) { - ResultItem original = result; - result = new ResultItem(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override ResultItem MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override ResultItem DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem.DefaultInstance; } - } - - public override ResultItem BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is ResultItem) { - return MergeFrom((ResultItem) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(ResultItem other) { - if (other == global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasUrl) { - Url = other.Url; - } - if (other.HasName) { - Name = other.Name; - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_resultItemFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _resultItemFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasUrl = input.ReadString(ref result.url_); - break; - } - case 18: { - result.hasName = input.ReadString(ref result.name_); - break; - } - } - } - - return this; - } - - - public bool HasUrl { - get { return result.hasUrl; } - } - public string Url { - get { return result.Url; } - set { SetUrl(value); } - } - public Builder SetUrl(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasUrl = true; - result.url_ = value; - return this; - } - public Builder ClearUrl() { - PrepareBuilder(); - result.hasUrl = false; - result.url_ = ""; - return this; - } - - public bool HasName { - get { return result.hasName; } - } - public string Name { - get { return result.Name; } - set { SetName(value); } - } - public Builder SetName(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasName = true; - result.name_ = value; - return this; - } - public Builder ClearName() { - PrepareBuilder(); - result.hasName = false; - result.name_ = ""; - return this; - } - } - static ResultItem() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestRpcInteropLite.Descriptor, null); - } - } - - } - #endregion - - public const int ResultsFieldNumber = 1; - private pbc::PopsicleList results_ = new pbc::PopsicleList(); - public scg::IList ResultsList { - get { return results_; } - } - public int ResultsCount { - get { return results_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem GetResults(int index) { - return results_[index]; - } - - public override bool IsInitialized { - get { - foreach (global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem element in ResultsList) { - if (!element.IsInitialized) return false; - } - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _searchResponseFieldNames; - if (results_.Count > 0) { - output.WriteMessageArray(1, field_names[0], results_); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - foreach (global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem element in ResultsList) { - size += pb::CodedOutputStream.ComputeMessageSize(1, element); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - foreach(global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem i in results_) - hash ^= i.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - SearchResponse other = obj as SearchResponse; - if (other == null) return false; - if(results_.Count != other.results_.Count) return false; - for(int ix=0; ix < results_.Count; ix++) - if(!results_[ix].Equals(other.results_[ix])) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("results", results_, writer); - } - #endregion - - public static SearchResponse ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SearchResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SearchResponse ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SearchResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SearchResponse ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SearchResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static SearchResponse ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static SearchResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static SearchResponse ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SearchResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private SearchResponse MakeReadOnly() { - results_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(SearchResponse prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(SearchResponse cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private SearchResponse result; - - private SearchResponse PrepareBuilder() { - if (resultIsReadOnly) { - SearchResponse original = result; - result = new SearchResponse(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override SearchResponse MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override SearchResponse DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.SearchResponse.DefaultInstance; } - } - - public override SearchResponse BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is SearchResponse) { - return MergeFrom((SearchResponse) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(SearchResponse other) { - if (other == global::Google.ProtocolBuffers.TestProtos.SearchResponse.DefaultInstance) return this; - PrepareBuilder(); - if (other.results_.Count != 0) { - result.results_.Add(other.results_); - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_searchResponseFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _searchResponseFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - input.ReadMessageArray(tag, field_name, result.results_, global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem.DefaultInstance, extensionRegistry); - break; - } - } - } - - return this; - } - - - public pbc::IPopsicleList ResultsList { - get { return PrepareBuilder().results_; } - } - public int ResultsCount { - get { return result.ResultsCount; } - } - public global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem GetResults(int index) { - return result.GetResults(index); - } - public Builder SetResults(int index, global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.results_[index] = value; - return this; - } - public Builder SetResults(int index, global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.results_[index] = builderForValue.Build(); - return this; - } - public Builder AddResults(global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.results_.Add(value); - return this; - } - public Builder AddResults(global::Google.ProtocolBuffers.TestProtos.SearchResponse.Types.ResultItem.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.results_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeResults(scg::IEnumerable values) { - PrepareBuilder(); - result.results_.Add(values); - return this; - } - public Builder ClearResults() { - PrepareBuilder(); - result.results_.Clear(); - return this; - } - } - static SearchResponse() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestRpcInteropLite.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class RefineSearchRequest : pb::GeneratedMessageLite { - private RefineSearchRequest() { } - private static readonly RefineSearchRequest defaultInstance = new RefineSearchRequest().MakeReadOnly(); - private static readonly string[] _refineSearchRequestFieldNames = new string[] { "Criteria", "previous_results" }; - private static readonly uint[] _refineSearchRequestFieldTags = new uint[] { 10, 18 }; - public static RefineSearchRequest DefaultInstance { - get { return defaultInstance; } - } - - public override RefineSearchRequest DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override RefineSearchRequest ThisMessage { - get { return this; } - } - - public const int CriteriaFieldNumber = 1; - private pbc::PopsicleList criteria_ = new pbc::PopsicleList(); - public scg::IList CriteriaList { - get { return pbc::Lists.AsReadOnly(criteria_); } - } - public int CriteriaCount { - get { return criteria_.Count; } - } - public string GetCriteria(int index) { - return criteria_[index]; - } - - public const int PreviousResultsFieldNumber = 2; - private bool hasPreviousResults; - private global::Google.ProtocolBuffers.TestProtos.SearchResponse previousResults_; - public bool HasPreviousResults { - get { return hasPreviousResults; } - } - public global::Google.ProtocolBuffers.TestProtos.SearchResponse PreviousResults { - get { return previousResults_ ?? global::Google.ProtocolBuffers.TestProtos.SearchResponse.DefaultInstance; } - } - - public override bool IsInitialized { - get { - if (!hasPreviousResults) return false; - if (!PreviousResults.IsInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _refineSearchRequestFieldNames; - if (criteria_.Count > 0) { - output.WriteStringArray(1, field_names[0], criteria_); - } - if (hasPreviousResults) { - output.WriteMessage(2, field_names[1], PreviousResults); - } - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (string element in CriteriaList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 1 * criteria_.Count; - } - if (hasPreviousResults) { - size += pb::CodedOutputStream.ComputeMessageSize(2, PreviousResults); - } - memoizedSerializedSize = size; - return size; - } - #region Lite runtime methods - public override int GetHashCode() { - int hash = GetType().GetHashCode(); - foreach(string i in criteria_) - hash ^= i.GetHashCode(); - if (hasPreviousResults) hash ^= previousResults_.GetHashCode(); - return hash; - } - - public override bool Equals(object obj) { - RefineSearchRequest other = obj as RefineSearchRequest; - if (other == null) return false; - if(criteria_.Count != other.criteria_.Count) return false; - for(int ix=0; ix < criteria_.Count; ix++) - if(!criteria_[ix].Equals(other.criteria_[ix])) return false; - if (hasPreviousResults != other.hasPreviousResults || (hasPreviousResults && !previousResults_.Equals(other.previousResults_))) return false; - return true; - } - - public override void PrintTo(global::System.IO.TextWriter writer) { - PrintField("Criteria", criteria_, writer); - PrintField("previous_results", hasPreviousResults, previousResults_, writer); - } - #endregion - - public static RefineSearchRequest ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RefineSearchRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RefineSearchRequest ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RefineSearchRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RefineSearchRequest ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RefineSearchRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static RefineSearchRequest ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static RefineSearchRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static RefineSearchRequest ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RefineSearchRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private RefineSearchRequest MakeReadOnly() { - criteria_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(RefineSearchRequest prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilderLite { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(RefineSearchRequest cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private RefineSearchRequest result; - - private RefineSearchRequest PrepareBuilder() { - if (resultIsReadOnly) { - RefineSearchRequest original = result; - result = new RefineSearchRequest(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override RefineSearchRequest MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override RefineSearchRequest DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.RefineSearchRequest.DefaultInstance; } - } - - public override RefineSearchRequest BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessageLite other) { - if (other is RefineSearchRequest) { - return MergeFrom((RefineSearchRequest) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(RefineSearchRequest other) { - if (other == global::Google.ProtocolBuffers.TestProtos.RefineSearchRequest.DefaultInstance) return this; - PrepareBuilder(); - if (other.criteria_.Count != 0) { - result.criteria_.Add(other.criteria_); - } - if (other.HasPreviousResults) { - MergePreviousResults(other.PreviousResults); - } - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_refineSearchRequestFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _refineSearchRequestFieldTags[field_ordinal]; - else { - ParseUnknownField(input, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - return this; - } - ParseUnknownField(input, extensionRegistry, tag, field_name); - break; - } - case 10: { - input.ReadStringArray(tag, field_name, result.criteria_); - break; - } - case 18: { - global::Google.ProtocolBuffers.TestProtos.SearchResponse.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.SearchResponse.CreateBuilder(); - if (result.hasPreviousResults) { - subBuilder.MergeFrom(PreviousResults); - } - input.ReadMessage(subBuilder, extensionRegistry); - PreviousResults = subBuilder.BuildPartial(); - break; - } - } - } - - return this; - } - - - public pbc::IPopsicleList CriteriaList { - get { return PrepareBuilder().criteria_; } - } - public int CriteriaCount { - get { return result.CriteriaCount; } - } - public string GetCriteria(int index) { - return result.GetCriteria(index); - } - public Builder SetCriteria(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.criteria_[index] = value; - return this; - } - public Builder AddCriteria(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.criteria_.Add(value); - return this; - } - public Builder AddRangeCriteria(scg::IEnumerable values) { - PrepareBuilder(); - result.criteria_.Add(values); - return this; - } - public Builder ClearCriteria() { - PrepareBuilder(); - result.criteria_.Clear(); - return this; - } - - public bool HasPreviousResults { - get { return result.hasPreviousResults; } - } - public global::Google.ProtocolBuffers.TestProtos.SearchResponse PreviousResults { - get { return result.PreviousResults; } - set { SetPreviousResults(value); } - } - public Builder SetPreviousResults(global::Google.ProtocolBuffers.TestProtos.SearchResponse value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasPreviousResults = true; - result.previousResults_ = value; - return this; - } - public Builder SetPreviousResults(global::Google.ProtocolBuffers.TestProtos.SearchResponse.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasPreviousResults = true; - result.previousResults_ = builderForValue.Build(); - return this; - } - public Builder MergePreviousResults(global::Google.ProtocolBuffers.TestProtos.SearchResponse value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasPreviousResults && - result.previousResults_ != global::Google.ProtocolBuffers.TestProtos.SearchResponse.DefaultInstance) { - result.previousResults_ = global::Google.ProtocolBuffers.TestProtos.SearchResponse.CreateBuilder(result.previousResults_).MergeFrom(value).BuildPartial(); - } else { - result.previousResults_ = value; - } - result.hasPreviousResults = true; - return this; - } - public Builder ClearPreviousResults() { - PrepareBuilder(); - result.hasPreviousResults = false; - result.previousResults_ = null; - return this; - } - } - static RefineSearchRequest() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestRpcInteropLite.Descriptor, null); - } - } - - #endregion - - #region Services - public partial interface ISearchService { - global::Google.ProtocolBuffers.TestProtos.SearchResponse Search(global::Google.ProtocolBuffers.TestProtos.SearchRequest searchRequest); - global::Google.ProtocolBuffers.TestProtos.SearchResponse RefineSearch(global::Google.ProtocolBuffers.TestProtos.RefineSearchRequest refineSearchRequest); - } - - [global::System.CLSCompliant(false)] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public partial class SearchService : ISearchService, pb::IRpcDispatch, global::System.IDisposable { - private readonly bool dispose; - private readonly pb::IRpcDispatch dispatch; - public SearchService(pb::IRpcDispatch dispatch) : this(dispatch, true) { - } - public SearchService(pb::IRpcDispatch dispatch, bool dispose) { - pb::ThrowHelper.ThrowIfNull(this.dispatch = dispatch, "dispatch"); - this.dispose = dispose && dispatch is global::System.IDisposable; - } - - public void Dispose() { - if (dispose) ((global::System.IDisposable)dispatch).Dispose(); - } - - TMessage pb::IRpcDispatch.CallMethod(string method, pb::IMessageLite request, pb::IBuilderLite response) { - return dispatch.CallMethod(method, request, response); - } - - public global::Google.ProtocolBuffers.TestProtos.SearchResponse Search(global::Google.ProtocolBuffers.TestProtos.SearchRequest searchRequest) { - return dispatch.CallMethod("Search", searchRequest, global::Google.ProtocolBuffers.TestProtos.SearchResponse.CreateBuilder()); - } - - public global::Google.ProtocolBuffers.TestProtos.SearchResponse RefineSearch(global::Google.ProtocolBuffers.TestProtos.RefineSearchRequest refineSearchRequest) { - return dispatch.CallMethod("RefineSearch", refineSearchRequest, global::Google.ProtocolBuffers.TestProtos.SearchResponse.CreateBuilder()); - } - - [global::System.CLSCompliant(false)] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public partial class Dispatch : pb::IRpcDispatch, global::System.IDisposable { - private readonly bool dispose; - private readonly ISearchService implementation; - public Dispatch(ISearchService implementation) : this(implementation, true) { - } - public Dispatch(ISearchService implementation, bool dispose) { - pb::ThrowHelper.ThrowIfNull(this.implementation = implementation, "implementation"); - this.dispose = dispose && implementation is global::System.IDisposable; - } - - public void Dispose() { - if (dispose) ((global::System.IDisposable)implementation).Dispose(); - } - - public TMessage CallMethod(string methodName, pb::IMessageLite request, pb::IBuilderLite response) - where TMessage : pb::IMessageLite - where TBuilder : pb::IBuilderLite { - switch(methodName) { - case "Search": return response.MergeFrom(implementation.Search((global::Google.ProtocolBuffers.TestProtos.SearchRequest)request)).Build(); - case "RefineSearch": return response.MergeFrom(implementation.RefineSearch((global::Google.ProtocolBuffers.TestProtos.RefineSearchRequest)request)).Build(); - default: throw pb::ThrowHelper.CreateMissingMethod(typeof(ISearchService), methodName); - } - } - } - [global::System.CLSCompliant(false)] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public partial class ServerStub : pb::IRpcServerStub, global::System.IDisposable { - private readonly bool dispose; - private readonly pb::IRpcDispatch implementation; - public ServerStub(ISearchService implementation) : this(implementation, true) { - } - public ServerStub(ISearchService implementation, bool dispose) : this(new Dispatch(implementation, dispose), dispose) { - } - public ServerStub(pb::IRpcDispatch implementation) : this(implementation, true) { - } - public ServerStub(pb::IRpcDispatch implementation, bool dispose) { - pb::ThrowHelper.ThrowIfNull(this.implementation = implementation, "implementation"); - this.dispose = dispose && implementation is global::System.IDisposable; - } - - public void Dispose() { - if (dispose) ((global::System.IDisposable)implementation).Dispose(); - } - - public pb::IMessageLite CallMethod(string methodName, pb::ICodedInputStream input, pb::ExtensionRegistry registry) { - switch(methodName) { - case "Search": return implementation.CallMethod(methodName, global::Google.ProtocolBuffers.TestProtos.SearchRequest.ParseFrom(input, registry), global::Google.ProtocolBuffers.TestProtos.SearchResponse.CreateBuilder()); - case "RefineSearch": return implementation.CallMethod(methodName, global::Google.ProtocolBuffers.TestProtos.RefineSearchRequest.ParseFrom(input, registry), global::Google.ProtocolBuffers.TestProtos.SearchResponse.CreateBuilder()); - default: throw pb::ThrowHelper.CreateMissingMethod(typeof(ISearchService), methodName); - } - } - } - } - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/Unittest.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/Unittest.cs new file mode 100644 index 00000000..e828f7bf --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/Unittest.cs @@ -0,0 +1,33513 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/protobuf/unittest.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace Google.ProtocolBuffers.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Unittest { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFloatExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalDoubleExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBoolExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBytesExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalGroupExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringPieceExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalCordExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalPublicImportMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalLazyMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFloatExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedDoubleExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBoolExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBytesExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedGroupExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringPieceExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedCordExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedLazyMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFloatExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultDoubleExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBoolExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBytesExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultNestedEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultForeignEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultImportEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringPieceExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultCordExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofNestedMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofStringExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofBytesExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionString); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionInt); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFloatExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedDoubleExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedBoolExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFloatExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedDoubleExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedBoolExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Test); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.NestedStringExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestRequired.Single); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestRequired.Multi); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.OptionalExt); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.RepeatedExt); + } + #endregion + #region Extensions + public const int OptionalInt32ExtensionFieldNumber = 1; + public static pb::GeneratedExtensionBase OptionalInt32Extension; + public const int OptionalInt64ExtensionFieldNumber = 2; + public static pb::GeneratedExtensionBase OptionalInt64Extension; + public const int OptionalUint32ExtensionFieldNumber = 3; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase OptionalUint32Extension; + public const int OptionalUint64ExtensionFieldNumber = 4; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase OptionalUint64Extension; + public const int OptionalSint32ExtensionFieldNumber = 5; + public static pb::GeneratedExtensionBase OptionalSint32Extension; + public const int OptionalSint64ExtensionFieldNumber = 6; + public static pb::GeneratedExtensionBase OptionalSint64Extension; + public const int OptionalFixed32ExtensionFieldNumber = 7; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase OptionalFixed32Extension; + public const int OptionalFixed64ExtensionFieldNumber = 8; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase OptionalFixed64Extension; + public const int OptionalSfixed32ExtensionFieldNumber = 9; + public static pb::GeneratedExtensionBase OptionalSfixed32Extension; + public const int OptionalSfixed64ExtensionFieldNumber = 10; + public static pb::GeneratedExtensionBase OptionalSfixed64Extension; + public const int OptionalFloatExtensionFieldNumber = 11; + public static pb::GeneratedExtensionBase OptionalFloatExtension; + public const int OptionalDoubleExtensionFieldNumber = 12; + public static pb::GeneratedExtensionBase OptionalDoubleExtension; + public const int OptionalBoolExtensionFieldNumber = 13; + public static pb::GeneratedExtensionBase OptionalBoolExtension; + public const int OptionalStringExtensionFieldNumber = 14; + public static pb::GeneratedExtensionBase OptionalStringExtension; + public const int OptionalBytesExtensionFieldNumber = 15; + public static pb::GeneratedExtensionBase OptionalBytesExtension; + public const int OptionalGroupExtensionFieldNumber = 16; + public static pb::GeneratedExtensionBase OptionalGroupExtension; + public const int OptionalNestedMessageExtensionFieldNumber = 18; + public static pb::GeneratedExtensionBase OptionalNestedMessageExtension; + public const int OptionalForeignMessageExtensionFieldNumber = 19; + public static pb::GeneratedExtensionBase OptionalForeignMessageExtension; + public const int OptionalImportMessageExtensionFieldNumber = 20; + public static pb::GeneratedExtensionBase OptionalImportMessageExtension; + public const int OptionalNestedEnumExtensionFieldNumber = 21; + public static pb::GeneratedExtensionBase OptionalNestedEnumExtension; + public const int OptionalForeignEnumExtensionFieldNumber = 22; + public static pb::GeneratedExtensionBase OptionalForeignEnumExtension; + public const int OptionalImportEnumExtensionFieldNumber = 23; + public static pb::GeneratedExtensionBase OptionalImportEnumExtension; + public const int OptionalStringPieceExtensionFieldNumber = 24; + public static pb::GeneratedExtensionBase OptionalStringPieceExtension; + public const int OptionalCordExtensionFieldNumber = 25; + public static pb::GeneratedExtensionBase OptionalCordExtension; + public const int OptionalPublicImportMessageExtensionFieldNumber = 26; + public static pb::GeneratedExtensionBase OptionalPublicImportMessageExtension; + public const int OptionalLazyMessageExtensionFieldNumber = 27; + public static pb::GeneratedExtensionBase OptionalLazyMessageExtension; + public const int RepeatedInt32ExtensionFieldNumber = 31; + public static pb::GeneratedExtensionBase> RepeatedInt32Extension; + public const int RepeatedInt64ExtensionFieldNumber = 32; + public static pb::GeneratedExtensionBase> RepeatedInt64Extension; + public const int RepeatedUint32ExtensionFieldNumber = 33; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> RepeatedUint32Extension; + public const int RepeatedUint64ExtensionFieldNumber = 34; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> RepeatedUint64Extension; + public const int RepeatedSint32ExtensionFieldNumber = 35; + public static pb::GeneratedExtensionBase> RepeatedSint32Extension; + public const int RepeatedSint64ExtensionFieldNumber = 36; + public static pb::GeneratedExtensionBase> RepeatedSint64Extension; + public const int RepeatedFixed32ExtensionFieldNumber = 37; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> RepeatedFixed32Extension; + public const int RepeatedFixed64ExtensionFieldNumber = 38; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> RepeatedFixed64Extension; + public const int RepeatedSfixed32ExtensionFieldNumber = 39; + public static pb::GeneratedExtensionBase> RepeatedSfixed32Extension; + public const int RepeatedSfixed64ExtensionFieldNumber = 40; + public static pb::GeneratedExtensionBase> RepeatedSfixed64Extension; + public const int RepeatedFloatExtensionFieldNumber = 41; + public static pb::GeneratedExtensionBase> RepeatedFloatExtension; + public const int RepeatedDoubleExtensionFieldNumber = 42; + public static pb::GeneratedExtensionBase> RepeatedDoubleExtension; + public const int RepeatedBoolExtensionFieldNumber = 43; + public static pb::GeneratedExtensionBase> RepeatedBoolExtension; + public const int RepeatedStringExtensionFieldNumber = 44; + public static pb::GeneratedExtensionBase> RepeatedStringExtension; + public const int RepeatedBytesExtensionFieldNumber = 45; + public static pb::GeneratedExtensionBase> RepeatedBytesExtension; + public const int RepeatedGroupExtensionFieldNumber = 46; + public static pb::GeneratedExtensionBase> RepeatedGroupExtension; + public const int RepeatedNestedMessageExtensionFieldNumber = 48; + public static pb::GeneratedExtensionBase> RepeatedNestedMessageExtension; + public const int RepeatedForeignMessageExtensionFieldNumber = 49; + public static pb::GeneratedExtensionBase> RepeatedForeignMessageExtension; + public const int RepeatedImportMessageExtensionFieldNumber = 50; + public static pb::GeneratedExtensionBase> RepeatedImportMessageExtension; + public const int RepeatedNestedEnumExtensionFieldNumber = 51; + public static pb::GeneratedExtensionBase> RepeatedNestedEnumExtension; + public const int RepeatedForeignEnumExtensionFieldNumber = 52; + public static pb::GeneratedExtensionBase> RepeatedForeignEnumExtension; + public const int RepeatedImportEnumExtensionFieldNumber = 53; + public static pb::GeneratedExtensionBase> RepeatedImportEnumExtension; + public const int RepeatedStringPieceExtensionFieldNumber = 54; + public static pb::GeneratedExtensionBase> RepeatedStringPieceExtension; + public const int RepeatedCordExtensionFieldNumber = 55; + public static pb::GeneratedExtensionBase> RepeatedCordExtension; + public const int RepeatedLazyMessageExtensionFieldNumber = 57; + public static pb::GeneratedExtensionBase> RepeatedLazyMessageExtension; + public const int DefaultInt32ExtensionFieldNumber = 61; + public static pb::GeneratedExtensionBase DefaultInt32Extension; + public const int DefaultInt64ExtensionFieldNumber = 62; + public static pb::GeneratedExtensionBase DefaultInt64Extension; + public const int DefaultUint32ExtensionFieldNumber = 63; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase DefaultUint32Extension; + public const int DefaultUint64ExtensionFieldNumber = 64; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase DefaultUint64Extension; + public const int DefaultSint32ExtensionFieldNumber = 65; + public static pb::GeneratedExtensionBase DefaultSint32Extension; + public const int DefaultSint64ExtensionFieldNumber = 66; + public static pb::GeneratedExtensionBase DefaultSint64Extension; + public const int DefaultFixed32ExtensionFieldNumber = 67; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase DefaultFixed32Extension; + public const int DefaultFixed64ExtensionFieldNumber = 68; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase DefaultFixed64Extension; + public const int DefaultSfixed32ExtensionFieldNumber = 69; + public static pb::GeneratedExtensionBase DefaultSfixed32Extension; + public const int DefaultSfixed64ExtensionFieldNumber = 70; + public static pb::GeneratedExtensionBase DefaultSfixed64Extension; + public const int DefaultFloatExtensionFieldNumber = 71; + public static pb::GeneratedExtensionBase DefaultFloatExtension; + public const int DefaultDoubleExtensionFieldNumber = 72; + public static pb::GeneratedExtensionBase DefaultDoubleExtension; + public const int DefaultBoolExtensionFieldNumber = 73; + public static pb::GeneratedExtensionBase DefaultBoolExtension; + public const int DefaultStringExtensionFieldNumber = 74; + public static pb::GeneratedExtensionBase DefaultStringExtension; + public const int DefaultBytesExtensionFieldNumber = 75; + public static pb::GeneratedExtensionBase DefaultBytesExtension; + public const int DefaultNestedEnumExtensionFieldNumber = 81; + public static pb::GeneratedExtensionBase DefaultNestedEnumExtension; + public const int DefaultForeignEnumExtensionFieldNumber = 82; + public static pb::GeneratedExtensionBase DefaultForeignEnumExtension; + public const int DefaultImportEnumExtensionFieldNumber = 83; + public static pb::GeneratedExtensionBase DefaultImportEnumExtension; + public const int DefaultStringPieceExtensionFieldNumber = 84; + public static pb::GeneratedExtensionBase DefaultStringPieceExtension; + public const int DefaultCordExtensionFieldNumber = 85; + public static pb::GeneratedExtensionBase DefaultCordExtension; + public const int OneofUint32ExtensionFieldNumber = 111; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase OneofUint32Extension; + public const int OneofNestedMessageExtensionFieldNumber = 112; + public static pb::GeneratedExtensionBase OneofNestedMessageExtension; + public const int OneofStringExtensionFieldNumber = 113; + public static pb::GeneratedExtensionBase OneofStringExtension; + public const int OneofBytesExtensionFieldNumber = 114; + public static pb::GeneratedExtensionBase OneofBytesExtension; + public const int MyExtensionStringFieldNumber = 50; + public static pb::GeneratedExtensionBase MyExtensionString; + public const int MyExtensionIntFieldNumber = 5; + public static pb::GeneratedExtensionBase MyExtensionInt; + public const int PackedInt32ExtensionFieldNumber = 90; + public static pb::GeneratedExtensionBase> PackedInt32Extension; + public const int PackedInt64ExtensionFieldNumber = 91; + public static pb::GeneratedExtensionBase> PackedInt64Extension; + public const int PackedUint32ExtensionFieldNumber = 92; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> PackedUint32Extension; + public const int PackedUint64ExtensionFieldNumber = 93; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> PackedUint64Extension; + public const int PackedSint32ExtensionFieldNumber = 94; + public static pb::GeneratedExtensionBase> PackedSint32Extension; + public const int PackedSint64ExtensionFieldNumber = 95; + public static pb::GeneratedExtensionBase> PackedSint64Extension; + public const int PackedFixed32ExtensionFieldNumber = 96; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> PackedFixed32Extension; + public const int PackedFixed64ExtensionFieldNumber = 97; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> PackedFixed64Extension; + public const int PackedSfixed32ExtensionFieldNumber = 98; + public static pb::GeneratedExtensionBase> PackedSfixed32Extension; + public const int PackedSfixed64ExtensionFieldNumber = 99; + public static pb::GeneratedExtensionBase> PackedSfixed64Extension; + public const int PackedFloatExtensionFieldNumber = 100; + public static pb::GeneratedExtensionBase> PackedFloatExtension; + public const int PackedDoubleExtensionFieldNumber = 101; + public static pb::GeneratedExtensionBase> PackedDoubleExtension; + public const int PackedBoolExtensionFieldNumber = 102; + public static pb::GeneratedExtensionBase> PackedBoolExtension; + public const int PackedEnumExtensionFieldNumber = 103; + public static pb::GeneratedExtensionBase> PackedEnumExtension; + public const int UnpackedInt32ExtensionFieldNumber = 90; + public static pb::GeneratedExtensionBase> UnpackedInt32Extension; + public const int UnpackedInt64ExtensionFieldNumber = 91; + public static pb::GeneratedExtensionBase> UnpackedInt64Extension; + public const int UnpackedUint32ExtensionFieldNumber = 92; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> UnpackedUint32Extension; + public const int UnpackedUint64ExtensionFieldNumber = 93; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> UnpackedUint64Extension; + public const int UnpackedSint32ExtensionFieldNumber = 94; + public static pb::GeneratedExtensionBase> UnpackedSint32Extension; + public const int UnpackedSint64ExtensionFieldNumber = 95; + public static pb::GeneratedExtensionBase> UnpackedSint64Extension; + public const int UnpackedFixed32ExtensionFieldNumber = 96; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> UnpackedFixed32Extension; + public const int UnpackedFixed64ExtensionFieldNumber = 97; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> UnpackedFixed64Extension; + public const int UnpackedSfixed32ExtensionFieldNumber = 98; + public static pb::GeneratedExtensionBase> UnpackedSfixed32Extension; + public const int UnpackedSfixed64ExtensionFieldNumber = 99; + public static pb::GeneratedExtensionBase> UnpackedSfixed64Extension; + public const int UnpackedFloatExtensionFieldNumber = 100; + public static pb::GeneratedExtensionBase> UnpackedFloatExtension; + public const int UnpackedDoubleExtensionFieldNumber = 101; + public static pb::GeneratedExtensionBase> UnpackedDoubleExtension; + public const int UnpackedBoolExtensionFieldNumber = 102; + public static pb::GeneratedExtensionBase> UnpackedBoolExtension; + public const int UnpackedEnumExtensionFieldNumber = 103; + public static pb::GeneratedExtensionBase> UnpackedEnumExtension; + #endregion + + #region Static variables + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_NestedTestAllTypes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_ForeignMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllExtensions__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedExtension__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequired__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequired__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredForeign__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestForeignNested__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEmptyMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEagerMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEagerMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestLazyMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestLazyMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestFieldOrderings__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_SparseEnumMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OneString__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OneString__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_MoreString__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_MoreString__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OneBytes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OneBytes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_MoreBytes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_MoreBytes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Int32Message__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Int32Message__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Uint32Message__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Uint32Message__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Int64Message__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Int64Message__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Uint64Message__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Uint64Message__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BoolMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BoolMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof_FooGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneofBackwardsCompatible__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof2__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof2__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof2_FooGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof2_NestedMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredOneof__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequiredOneof__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestPackedTypes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestPackedExtensions__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestCommentInjectionMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooRequest__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooRequest__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooResponse__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooResponse__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooClientMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooClientMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooServerMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooServerMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BarRequest__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BarRequest__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BarResponse__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BarResponse__FieldAccessorTable; + #endregion + #region Descriptor + public static pbd::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbd::FileDescriptor descriptor; + + static Unittest() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ch5nb29nbGUvcHJvdG9idWYvdW5pdHRlc3QucHJvdG8SEXByb3RvYnVmX3Vu", + "aXR0ZXN0GiVnb29nbGUvcHJvdG9idWYvdW5pdHRlc3RfaW1wb3J0LnByb3Rv", + "Iu0YCgxUZXN0QWxsVHlwZXMSFgoOb3B0aW9uYWxfaW50MzIYASABKAUSFgoO", + "b3B0aW9uYWxfaW50NjQYAiABKAMSFwoPb3B0aW9uYWxfdWludDMyGAMgASgN", + "EhcKD29wdGlvbmFsX3VpbnQ2NBgEIAEoBBIXCg9vcHRpb25hbF9zaW50MzIY", + "BSABKBESFwoPb3B0aW9uYWxfc2ludDY0GAYgASgSEhgKEG9wdGlvbmFsX2Zp", + "eGVkMzIYByABKAcSGAoQb3B0aW9uYWxfZml4ZWQ2NBgIIAEoBhIZChFvcHRp", + "b25hbF9zZml4ZWQzMhgJIAEoDxIZChFvcHRpb25hbF9zZml4ZWQ2NBgKIAEo", + "EBIWCg5vcHRpb25hbF9mbG9hdBgLIAEoAhIXCg9vcHRpb25hbF9kb3VibGUY", + "DCABKAESFQoNb3B0aW9uYWxfYm9vbBgNIAEoCBIXCg9vcHRpb25hbF9zdHJp", + "bmcYDiABKAkSFgoOb3B0aW9uYWxfYnl0ZXMYDyABKAwSRAoNb3B0aW9uYWxn", + "cm91cBgQIAEoCjItLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5P", + "cHRpb25hbEdyb3VwEk4KF29wdGlvbmFsX25lc3RlZF9tZXNzYWdlGBIgASgL", + "Mi0ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzLk5lc3RlZE1lc3Nh", + "Z2USQwoYb3B0aW9uYWxfZm9yZWlnbl9tZXNzYWdlGBMgASgLMiEucHJvdG9i", + "dWZfdW5pdHRlc3QuRm9yZWlnbk1lc3NhZ2USSAoXb3B0aW9uYWxfaW1wb3J0", + "X21lc3NhZ2UYFCABKAsyJy5wcm90b2J1Zl91bml0dGVzdF9pbXBvcnQuSW1w", + "b3J0TWVzc2FnZRJIChRvcHRpb25hbF9uZXN0ZWRfZW51bRgVIAEoDjIqLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRFbnVtEj0KFW9w", + "dGlvbmFsX2ZvcmVpZ25fZW51bRgWIAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0", + "LkZvcmVpZ25FbnVtEkIKFG9wdGlvbmFsX2ltcG9ydF9lbnVtGBcgASgOMiQu", + "cHJvdG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydEVudW0SIQoVb3B0aW9u", + "YWxfc3RyaW5nX3BpZWNlGBggASgJQgIIAhIZCg1vcHRpb25hbF9jb3JkGBkg", + "ASgJQgIIARJVCh5vcHRpb25hbF9wdWJsaWNfaW1wb3J0X21lc3NhZ2UYGiAB", + "KAsyLS5wcm90b2J1Zl91bml0dGVzdF9pbXBvcnQuUHVibGljSW1wb3J0TWVz", + "c2FnZRJQChVvcHRpb25hbF9sYXp5X21lc3NhZ2UYGyABKAsyLS5wcm90b2J1", + "Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkTWVzc2FnZUICKAESFgoO", + "cmVwZWF0ZWRfaW50MzIYHyADKAUSFgoOcmVwZWF0ZWRfaW50NjQYICADKAMS", + "FwoPcmVwZWF0ZWRfdWludDMyGCEgAygNEhcKD3JlcGVhdGVkX3VpbnQ2NBgi", + "IAMoBBIXCg9yZXBlYXRlZF9zaW50MzIYIyADKBESFwoPcmVwZWF0ZWRfc2lu", + "dDY0GCQgAygSEhgKEHJlcGVhdGVkX2ZpeGVkMzIYJSADKAcSGAoQcmVwZWF0", + "ZWRfZml4ZWQ2NBgmIAMoBhIZChFyZXBlYXRlZF9zZml4ZWQzMhgnIAMoDxIZ", + "ChFyZXBlYXRlZF9zZml4ZWQ2NBgoIAMoEBIWCg5yZXBlYXRlZF9mbG9hdBgp", + "IAMoAhIXCg9yZXBlYXRlZF9kb3VibGUYKiADKAESFQoNcmVwZWF0ZWRfYm9v", + "bBgrIAMoCBIXCg9yZXBlYXRlZF9zdHJpbmcYLCADKAkSFgoOcmVwZWF0ZWRf", + "Ynl0ZXMYLSADKAwSRAoNcmVwZWF0ZWRncm91cBguIAMoCjItLnByb3RvYnVm", + "X3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5SZXBlYXRlZEdyb3VwEk4KF3JlcGVh", + "dGVkX25lc3RlZF9tZXNzYWdlGDAgAygLMi0ucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdEFsbFR5cGVzLk5lc3RlZE1lc3NhZ2USQwoYcmVwZWF0ZWRfZm9yZWln", + "bl9tZXNzYWdlGDEgAygLMiEucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbk1l", + "c3NhZ2USSAoXcmVwZWF0ZWRfaW1wb3J0X21lc3NhZ2UYMiADKAsyJy5wcm90", + "b2J1Zl91bml0dGVzdF9pbXBvcnQuSW1wb3J0TWVzc2FnZRJIChRyZXBlYXRl", + "ZF9uZXN0ZWRfZW51bRgzIAMoDjIqLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", + "bGxUeXBlcy5OZXN0ZWRFbnVtEj0KFXJlcGVhdGVkX2ZvcmVpZ25fZW51bRg0", + "IAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtEkIKFHJlcGVh", + "dGVkX2ltcG9ydF9lbnVtGDUgAygOMiQucHJvdG9idWZfdW5pdHRlc3RfaW1w", + "b3J0LkltcG9ydEVudW0SIQoVcmVwZWF0ZWRfc3RyaW5nX3BpZWNlGDYgAygJ", + "QgIIAhIZCg1yZXBlYXRlZF9jb3JkGDcgAygJQgIIARJQChVyZXBlYXRlZF9s", + "YXp5X21lc3NhZ2UYOSADKAsyLS5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxs", + "VHlwZXMuTmVzdGVkTWVzc2FnZUICKAESGQoNZGVmYXVsdF9pbnQzMhg9IAEo", + "BToCNDESGQoNZGVmYXVsdF9pbnQ2NBg+IAEoAzoCNDISGgoOZGVmYXVsdF91", + "aW50MzIYPyABKA06AjQzEhoKDmRlZmF1bHRfdWludDY0GEAgASgEOgI0NBIb", + "Cg5kZWZhdWx0X3NpbnQzMhhBIAEoEToDLTQ1EhoKDmRlZmF1bHRfc2ludDY0", + "GEIgASgSOgI0NhIbCg9kZWZhdWx0X2ZpeGVkMzIYQyABKAc6AjQ3EhsKD2Rl", + "ZmF1bHRfZml4ZWQ2NBhEIAEoBjoCNDgSHAoQZGVmYXVsdF9zZml4ZWQzMhhF", + "IAEoDzoCNDkSHQoQZGVmYXVsdF9zZml4ZWQ2NBhGIAEoEDoDLTUwEhsKDWRl", + "ZmF1bHRfZmxvYXQYRyABKAI6BDUxLjUSHQoOZGVmYXVsdF9kb3VibGUYSCAB", + "KAE6BTUyMDAwEhoKDGRlZmF1bHRfYm9vbBhJIAEoCDoEdHJ1ZRIdCg5kZWZh", + "dWx0X3N0cmluZxhKIAEoCToFaGVsbG8SHAoNZGVmYXVsdF9ieXRlcxhLIAEo", + "DDoFd29ybGQSTAoTZGVmYXVsdF9uZXN0ZWRfZW51bRhRIAEoDjIqLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRFbnVtOgNCQVISSQoU", + "ZGVmYXVsdF9mb3JlaWduX2VudW0YUiABKA4yHi5wcm90b2J1Zl91bml0dGVz", + "dC5Gb3JlaWduRW51bToLRk9SRUlHTl9CQVISTQoTZGVmYXVsdF9pbXBvcnRf", + "ZW51bRhTIAEoDjIkLnByb3RvYnVmX3VuaXR0ZXN0X2ltcG9ydC5JbXBvcnRF", + "bnVtOgpJTVBPUlRfQkFSEiUKFGRlZmF1bHRfc3RyaW5nX3BpZWNlGFQgASgJ", + "OgNhYmNCAggCEh0KDGRlZmF1bHRfY29yZBhVIAEoCToDMTIzQgIIARIWCgxv", + "bmVvZl91aW50MzIYbyABKA1IABJNChRvbmVvZl9uZXN0ZWRfbWVzc2FnZRhw", + "IAEoCzItLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRN", + "ZXNzYWdlSAASFgoMb25lb2Zfc3RyaW5nGHEgASgJSAASFQoLb25lb2ZfYnl0", + "ZXMYciABKAxIABobCg1OZXN0ZWRNZXNzYWdlEgoKAmJiGAEgASgFGhoKDU9w", + "dGlvbmFsR3JvdXASCQoBYRgRIAEoBRoaCg1SZXBlYXRlZEdyb3VwEgkKAWEY", + "LyABKAUiOQoKTmVzdGVkRW51bRIHCgNGT08QARIHCgNCQVIQAhIHCgNCQVoQ", + "AxIQCgNORUcQ////////////AUINCgtvbmVvZl9maWVsZCJ8ChJOZXN0ZWRU", + "ZXN0QWxsVHlwZXMSNAoFY2hpbGQYASABKAsyJS5wcm90b2J1Zl91bml0dGVz", + "dC5OZXN0ZWRUZXN0QWxsVHlwZXMSMAoHcGF5bG9hZBgCIAEoCzIfLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcyI0ChRUZXN0RGVwcmVjYXRlZEZp", + "ZWxkcxIcChBkZXByZWNhdGVkX2ludDMyGAEgASgFQgIYASIbCg5Gb3JlaWdu", + "TWVzc2FnZRIJCgFjGAEgASgFIh0KEVRlc3RBbGxFeHRlbnNpb25zKggIARCA", + "gICAAiIkChdPcHRpb25hbEdyb3VwX2V4dGVuc2lvbhIJCgFhGBEgASgFIiQK", + "F1JlcGVhdGVkR3JvdXBfZXh0ZW5zaW9uEgkKAWEYLyABKAUimAEKE1Rlc3RO", + "ZXN0ZWRFeHRlbnNpb24yOQoEdGVzdBIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxFeHRlbnNpb25zGOoHIAEoCToEdGVzdDJGChduZXN0ZWRfc3RyaW5n", + "X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNp", + "b25zGOsHIAEoCSLVBQoMVGVzdFJlcXVpcmVkEgkKAWEYASACKAUSDgoGZHVt", + "bXkyGAIgASgFEgkKAWIYAyACKAUSDgoGZHVtbXk0GAQgASgFEg4KBmR1bW15", + "NRgFIAEoBRIOCgZkdW1teTYYBiABKAUSDgoGZHVtbXk3GAcgASgFEg4KBmR1", + "bW15OBgIIAEoBRIOCgZkdW1teTkYCSABKAUSDwoHZHVtbXkxMBgKIAEoBRIP", + "CgdkdW1teTExGAsgASgFEg8KB2R1bW15MTIYDCABKAUSDwoHZHVtbXkxMxgN", + "IAEoBRIPCgdkdW1teTE0GA4gASgFEg8KB2R1bW15MTUYDyABKAUSDwoHZHVt", + "bXkxNhgQIAEoBRIPCgdkdW1teTE3GBEgASgFEg8KB2R1bW15MTgYEiABKAUS", + "DwoHZHVtbXkxORgTIAEoBRIPCgdkdW1teTIwGBQgASgFEg8KB2R1bW15MjEY", + "FSABKAUSDwoHZHVtbXkyMhgWIAEoBRIPCgdkdW1teTIzGBcgASgFEg8KB2R1", + "bW15MjQYGCABKAUSDwoHZHVtbXkyNRgZIAEoBRIPCgdkdW1teTI2GBogASgF", + "Eg8KB2R1bW15MjcYGyABKAUSDwoHZHVtbXkyOBgcIAEoBRIPCgdkdW1teTI5", + "GB0gASgFEg8KB2R1bW15MzAYHiABKAUSDwoHZHVtbXkzMRgfIAEoBRIPCgdk", + "dW1teTMyGCAgASgFEgkKAWMYISACKAUyVgoGc2luZ2xlEiQucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY6AcgASgLMh8ucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdFJlcXVpcmVkMlUKBW11bHRpEiQucHJvdG9idWZfdW5p", + "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY6QcgAygLMh8ucHJvdG9idWZfdW5p", + "dHRlc3QuVGVzdFJlcXVpcmVkIpoBChNUZXN0UmVxdWlyZWRGb3JlaWduEjkK", + "EG9wdGlvbmFsX21lc3NhZ2UYASABKAsyHy5wcm90b2J1Zl91bml0dGVzdC5U", + "ZXN0UmVxdWlyZWQSOQoQcmVwZWF0ZWRfbWVzc2FnZRgCIAMoCzIfLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RSZXF1aXJlZBINCgVkdW1teRgDIAEoBSJaChFU", + "ZXN0Rm9yZWlnbk5lc3RlZBJFCg5mb3JlaWduX25lc3RlZBgBIAEoCzItLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdlIhIK", + "EFRlc3RFbXB0eU1lc3NhZ2UiKgoeVGVzdEVtcHR5TWVzc2FnZVdpdGhFeHRl", + "bnNpb25zKggIARCAgICAAiI3ChtUZXN0TXVsdGlwbGVFeHRlbnNpb25SYW5n", + "ZXMqBAgqECsqBgivIBCUISoKCICABBCAgICAAiI0ChhUZXN0UmVhbGx5TGFy", + "Z2VUYWdOdW1iZXISCQoBYRgBIAEoBRINCgJiYhj///9/IAEoBSJVChRUZXN0", + "UmVjdXJzaXZlTWVzc2FnZRIyCgFhGAEgASgLMicucHJvdG9idWZfdW5pdHRl", + "c3QuVGVzdFJlY3Vyc2l2ZU1lc3NhZ2USCQoBaRgCIAEoBSJLChRUZXN0TXV0", + "dWFsUmVjdXJzaW9uQRIzCgJiYhgBIAEoCzInLnByb3RvYnVmX3VuaXR0ZXN0", + "LlRlc3RNdXR1YWxSZWN1cnNpb25CImIKFFRlc3RNdXR1YWxSZWN1cnNpb25C", + "EjIKAWEYASABKAsyJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0TXV0dWFsUmVj", + "dXJzaW9uQRIWCg5vcHRpb25hbF9pbnQzMhgCIAEoBSKzAQoSVGVzdER1cEZp", + "ZWxkTnVtYmVyEgkKAWEYASABKAUSNgoDZm9vGAIgASgKMikucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdER1cEZpZWxkTnVtYmVyLkZvbxI2CgNiYXIYAyABKAoy", + "KS5wcm90b2J1Zl91bml0dGVzdC5UZXN0RHVwRmllbGROdW1iZXIuQmFyGhAK", + "A0ZvbxIJCgFhGAEgASgFGhAKA0JhchIJCgFhGAEgASgFIkwKEFRlc3RFYWdl", + "ck1lc3NhZ2USOAoLc3ViX21lc3NhZ2UYASABKAsyHy5wcm90b2J1Zl91bml0", + "dGVzdC5UZXN0QWxsVHlwZXNCAigAIksKD1Rlc3RMYXp5TWVzc2FnZRI4Cgtz", + "dWJfbWVzc2FnZRgBIAEoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxU", + "eXBlc0ICKAEigAIKGFRlc3ROZXN0ZWRNZXNzYWdlSGFzQml0cxJaChdvcHRp", + "b25hbF9uZXN0ZWRfbWVzc2FnZRgBIAEoCzI5LnByb3RvYnVmX3VuaXR0ZXN0", + "LlRlc3ROZXN0ZWRNZXNzYWdlSGFzQml0cy5OZXN0ZWRNZXNzYWdlGocBCg1O", + "ZXN0ZWRNZXNzYWdlEiQKHG5lc3RlZG1lc3NhZ2VfcmVwZWF0ZWRfaW50MzIY", + "ASADKAUSUAolbmVzdGVkbWVzc2FnZV9yZXBlYXRlZF9mb3JlaWdubWVzc2Fn", + "ZRgCIAMoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25NZXNzYWdlIuUD", + "ChdUZXN0Q2FtZWxDYXNlRmllbGROYW1lcxIWCg5QcmltaXRpdmVGaWVsZBgB", + "IAEoBRITCgtTdHJpbmdGaWVsZBgCIAEoCRIxCglFbnVtRmllbGQYAyABKA4y", + "Hi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bRI3CgxNZXNzYWdlRmll", + "bGQYBCABKAsyIS5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduTWVzc2FnZRIc", + "ChBTdHJpbmdQaWVjZUZpZWxkGAUgASgJQgIIAhIVCglDb3JkRmllbGQYBiAB", + "KAlCAggBEh4KFlJlcGVhdGVkUHJpbWl0aXZlRmllbGQYByADKAUSGwoTUmVw", + "ZWF0ZWRTdHJpbmdGaWVsZBgIIAMoCRI5ChFSZXBlYXRlZEVudW1GaWVsZBgJ", + "IAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtEj8KFFJlcGVh", + "dGVkTWVzc2FnZUZpZWxkGAogAygLMiEucHJvdG9idWZfdW5pdHRlc3QuRm9y", + "ZWlnbk1lc3NhZ2USJAoYUmVwZWF0ZWRTdHJpbmdQaWVjZUZpZWxkGAsgAygJ", + "QgIIAhIdChFSZXBlYXRlZENvcmRGaWVsZBgMIAMoCUICCAEi1QEKElRlc3RG", + "aWVsZE9yZGVyaW5ncxIRCglteV9zdHJpbmcYCyABKAkSDgoGbXlfaW50GAEg", + "ASgDEhAKCG15X2Zsb2F0GGUgASgCElUKF29wdGlvbmFsX25lc3RlZF9tZXNz", + "YWdlGMgBIAEoCzIzLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RGaWVsZE9yZGVy", + "aW5ncy5OZXN0ZWRNZXNzYWdlGicKDU5lc3RlZE1lc3NhZ2USCgoCb28YAiAB", + "KAMSCgoCYmIYASABKAUqBAgCEAsqBAgMEGUitgcKGFRlc3RFeHRyZW1lRGVm", + "YXVsdFZhbHVlcxI/Cg1lc2NhcGVkX2J5dGVzGAEgASgMOihcMDAwXDAwMVww", + "MDdcMDEwXDAxNFxuXHJcdFwwMTNcXFwnXCJcMzc2EiAKDGxhcmdlX3VpbnQz", + "MhgCIAEoDToKNDI5NDk2NzI5NRIqCgxsYXJnZV91aW50NjQYAyABKAQ6FDE4", + "NDQ2NzQ0MDczNzA5NTUxNjE1EiAKC3NtYWxsX2ludDMyGAQgASgFOgstMjE0", + "NzQ4MzY0NxIpCgtzbWFsbF9pbnQ2NBgFIAEoAzoULTkyMjMzNzIwMzY4NTQ3", + "NzU4MDcSJwoScmVhbGx5X3NtYWxsX2ludDMyGBUgASgFOgstMjE0NzQ4MzY0", + "OBIwChJyZWFsbHlfc21hbGxfaW50NjQYFiABKAM6FC05MjIzMzcyMDM2ODU0", + "Nzc1ODA4EhgKC3V0Zjhfc3RyaW5nGAYgASgJOgPhiLQSFQoKemVyb19mbG9h", + "dBgHIAEoAjoBMBIUCglvbmVfZmxvYXQYCCABKAI6ATESGAoLc21hbGxfZmxv", + "YXQYCSABKAI6AzEuNRIeChJuZWdhdGl2ZV9vbmVfZmxvYXQYCiABKAI6Ai0x", + "EhwKDm5lZ2F0aXZlX2Zsb2F0GAsgASgCOgQtMS41EhoKC2xhcmdlX2Zsb2F0", + "GAwgASgCOgUyZSswOBIkChRzbWFsbF9uZWdhdGl2ZV9mbG9hdBgNIAEoAjoG", + "LThlLTI4EhcKCmluZl9kb3VibGUYDiABKAE6A2luZhIcCg5uZWdfaW5mX2Rv", + "dWJsZRgPIAEoAToELWluZhIXCgpuYW5fZG91YmxlGBAgASgBOgNuYW4SFgoJ", + "aW5mX2Zsb2F0GBEgASgCOgNpbmYSGwoNbmVnX2luZl9mbG9hdBgSIAEoAjoE", + "LWluZhIWCgluYW5fZmxvYXQYEyABKAI6A25hbhIrCgxjcHBfdHJpZ3JhcGgY", + "FCABKAk6FT8gPyA/PyA/PyA/Pz8gPz8vID8/LRIgChBzdHJpbmdfd2l0aF96", + "ZXJvGBcgASgJOgZoZWwAbG8SIgoPYnl0ZXNfd2l0aF96ZXJvGBggASgMOgl3", + "b3JcMDAwbGQSKAoWc3RyaW5nX3BpZWNlX3dpdGhfemVybxgZIAEoCToEYWIA", + "Y0ICCAISIAoOY29yZF93aXRoX3plcm8YGiABKAk6BDEyADNCAggBEiYKEnJl", + "cGxhY2VtZW50X3N0cmluZxgbIAEoCToKJHt1bmtub3dufSJLChFTcGFyc2VF", + "bnVtTWVzc2FnZRI2CgtzcGFyc2VfZW51bRgBIAEoDjIhLnByb3RvYnVmX3Vu", + "aXR0ZXN0LlRlc3RTcGFyc2VFbnVtIhkKCU9uZVN0cmluZxIMCgRkYXRhGAEg", + "ASgJIhoKCk1vcmVTdHJpbmcSDAoEZGF0YRgBIAMoCSIYCghPbmVCeXRlcxIM", + "CgRkYXRhGAEgASgMIhkKCU1vcmVCeXRlcxIMCgRkYXRhGAEgAygMIhwKDElu", + "dDMyTWVzc2FnZRIMCgRkYXRhGAEgASgFIh0KDVVpbnQzMk1lc3NhZ2USDAoE", + "ZGF0YRgBIAEoDSIcCgxJbnQ2NE1lc3NhZ2USDAoEZGF0YRgBIAEoAyIdCg1V", + "aW50NjRNZXNzYWdlEgwKBGRhdGEYASABKAQiGwoLQm9vbE1lc3NhZ2USDAoE", + "ZGF0YRgBIAEoCCLQAQoJVGVzdE9uZW9mEhEKB2Zvb19pbnQYASABKAVIABIU", + "Cgpmb29fc3RyaW5nGAIgASgJSAASNgoLZm9vX21lc3NhZ2UYAyABKAsyHy5w", + "cm90b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXNIABI5Cghmb29ncm91cBgE", + "IAEoCjIlLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RPbmVvZi5Gb29Hcm91cEgA", + "GiAKCEZvb0dyb3VwEgkKAWEYBSABKAUSCQoBYhgGIAEoCUIFCgNmb28i5wEK", + "HFRlc3RPbmVvZkJhY2t3YXJkc0NvbXBhdGlibGUSDwoHZm9vX2ludBgBIAEo", + "BRISCgpmb29fc3RyaW5nGAIgASgJEjQKC2Zvb19tZXNzYWdlGAMgASgLMh8u", + "cHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzEkoKCGZvb2dyb3VwGAQg", + "ASgKMjgucHJvdG9idWZfdW5pdHRlc3QuVGVzdE9uZW9mQmFja3dhcmRzQ29t", + "cGF0aWJsZS5Gb29Hcm91cBogCghGb29Hcm91cBIJCgFhGAUgASgFEgkKAWIY", + "BiABKAkingYKClRlc3RPbmVvZjISEQoHZm9vX2ludBgBIAEoBUgAEhQKCmZv", + "b19zdHJpbmcYAiABKAlIABIWCghmb29fY29yZBgDIAEoCUICCAFIABIeChBm", + "b29fc3RyaW5nX3BpZWNlGAQgASgJQgIIAkgAEhMKCWZvb19ieXRlcxgFIAEo", + "DEgAEjwKCGZvb19lbnVtGAYgASgOMigucHJvdG9idWZfdW5pdHRlc3QuVGVz", + "dE9uZW9mMi5OZXN0ZWRFbnVtSAASQgoLZm9vX21lc3NhZ2UYByABKAsyKy5w", + "cm90b2J1Zl91bml0dGVzdC5UZXN0T25lb2YyLk5lc3RlZE1lc3NhZ2VIABI6", + "Cghmb29ncm91cBgIIAEoCjImLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RPbmVv", + "ZjIuRm9vR3JvdXBIABJLChBmb29fbGF6eV9tZXNzYWdlGAsgASgLMisucHJv", + "dG9idWZfdW5pdHRlc3QuVGVzdE9uZW9mMi5OZXN0ZWRNZXNzYWdlQgIoAUgA", + "EhQKB2Jhcl9pbnQYDCABKAU6ATVIARIcCgpiYXJfc3RyaW5nGA0gASgJOgZT", + "VFJJTkdIARIcCghiYXJfY29yZBgOIAEoCToEQ09SREICCAFIARImChBiYXJf", + "c3RyaW5nX3BpZWNlGA8gASgJOgZTUElFQ0VCAggCSAESGgoJYmFyX2J5dGVz", + "GBAgASgMOgVCWVRFU0gBEkEKCGJhcl9lbnVtGBEgASgOMigucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdE9uZW9mMi5OZXN0ZWRFbnVtOgNCQVJIARIPCgdiYXpf", + "aW50GBIgASgFEhcKCmJhel9zdHJpbmcYEyABKAk6A0JBWhogCghGb29Hcm91", + "cBIJCgFhGAkgASgFEgkKAWIYCiABKAkaMwoNTmVzdGVkTWVzc2FnZRIPCgdx", + "dXhfaW50GAEgASgDEhEKCWNvcmdlX2ludBgCIAMoBSInCgpOZXN0ZWRFbnVt", + "EgcKA0ZPTxABEgcKA0JBUhACEgcKA0JBWhADQgUKA2Zvb0IFCgNiYXIiuAEK", + "EVRlc3RSZXF1aXJlZE9uZW9mEhEKB2Zvb19pbnQYASABKAVIABIUCgpmb29f", + "c3RyaW5nGAIgASgJSAASSQoLZm9vX21lc3NhZ2UYAyABKAsyMi5wcm90b2J1", + "Zl91bml0dGVzdC5UZXN0UmVxdWlyZWRPbmVvZi5OZXN0ZWRNZXNzYWdlSAAa", + "KAoNTmVzdGVkTWVzc2FnZRIXCg9yZXF1aXJlZF9kb3VibGUYASACKAFCBQoD", + "Zm9vIqoDCg9UZXN0UGFja2VkVHlwZXMSGAoMcGFja2VkX2ludDMyGFogAygF", + "QgIQARIYCgxwYWNrZWRfaW50NjQYWyADKANCAhABEhkKDXBhY2tlZF91aW50", + "MzIYXCADKA1CAhABEhkKDXBhY2tlZF91aW50NjQYXSADKARCAhABEhkKDXBh", + "Y2tlZF9zaW50MzIYXiADKBFCAhABEhkKDXBhY2tlZF9zaW50NjQYXyADKBJC", + "AhABEhoKDnBhY2tlZF9maXhlZDMyGGAgAygHQgIQARIaCg5wYWNrZWRfZml4", + "ZWQ2NBhhIAMoBkICEAESGwoPcGFja2VkX3NmaXhlZDMyGGIgAygPQgIQARIb", + "Cg9wYWNrZWRfc2ZpeGVkNjQYYyADKBBCAhABEhgKDHBhY2tlZF9mbG9hdBhk", + "IAMoAkICEAESGQoNcGFja2VkX2RvdWJsZRhlIAMoAUICEAESFwoLcGFja2Vk", + "X2Jvb2wYZiADKAhCAhABEjcKC3BhY2tlZF9lbnVtGGcgAygOMh4ucHJvdG9i", + "dWZfdW5pdHRlc3QuRm9yZWlnbkVudW1CAhABIsgDChFUZXN0VW5wYWNrZWRU", + "eXBlcxIaCg51bnBhY2tlZF9pbnQzMhhaIAMoBUICEAASGgoOdW5wYWNrZWRf", + "aW50NjQYWyADKANCAhAAEhsKD3VucGFja2VkX3VpbnQzMhhcIAMoDUICEAAS", + "GwoPdW5wYWNrZWRfdWludDY0GF0gAygEQgIQABIbCg91bnBhY2tlZF9zaW50", + "MzIYXiADKBFCAhAAEhsKD3VucGFja2VkX3NpbnQ2NBhfIAMoEkICEAASHAoQ", + "dW5wYWNrZWRfZml4ZWQzMhhgIAMoB0ICEAASHAoQdW5wYWNrZWRfZml4ZWQ2", + "NBhhIAMoBkICEAASHQoRdW5wYWNrZWRfc2ZpeGVkMzIYYiADKA9CAhAAEh0K", + "EXVucGFja2VkX3NmaXhlZDY0GGMgAygQQgIQABIaCg51bnBhY2tlZF9mbG9h", + "dBhkIAMoAkICEAASGwoPdW5wYWNrZWRfZG91YmxlGGUgAygBQgIQABIZCg11", + "bnBhY2tlZF9ib29sGGYgAygIQgIQABI5Cg11bnBhY2tlZF9lbnVtGGcgAygO", + "Mh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbkVudW1CAhAAIiAKFFRlc3RQ", + "YWNrZWRFeHRlbnNpb25zKggIARCAgICAAiIiChZUZXN0VW5wYWNrZWRFeHRl", + "bnNpb25zKggIARCAgICAAiKZBAoVVGVzdER5bmFtaWNFeHRlbnNpb25zEhkK", + "EHNjYWxhcl9leHRlbnNpb24Y0A8gASgHEjcKDmVudW1fZXh0ZW5zaW9uGNEP", + "IAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtElkKFmR5bmFt", + "aWNfZW51bV9leHRlbnNpb24Y0g8gASgOMjgucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdER5bmFtaWNFeHRlbnNpb25zLkR5bmFtaWNFbnVtVHlwZRI9ChFtZXNz", + "YWdlX2V4dGVuc2lvbhjTDyABKAsyIS5wcm90b2J1Zl91bml0dGVzdC5Gb3Jl", + "aWduTWVzc2FnZRJfChlkeW5hbWljX21lc3NhZ2VfZXh0ZW5zaW9uGNQPIAEo", + "CzI7LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3REeW5hbWljRXh0ZW5zaW9ucy5E", + "eW5hbWljTWVzc2FnZVR5cGUSGwoScmVwZWF0ZWRfZXh0ZW5zaW9uGNUPIAMo", + "CRIdChBwYWNrZWRfZXh0ZW5zaW9uGNYPIAMoEUICEAEaLAoSRHluYW1pY01l", + "c3NhZ2VUeXBlEhYKDWR5bmFtaWNfZmllbGQYtBAgASgFIkcKD0R5bmFtaWNF", + "bnVtVHlwZRIQCgtEWU5BTUlDX0ZPTxCYERIQCgtEWU5BTUlDX0JBUhCZERIQ", + "CgtEWU5BTUlDX0JBWhCaESLAAQojVGVzdFJlcGVhdGVkU2NhbGFyRGlmZmVy", + "ZW50VGFnU2l6ZXMSGAoQcmVwZWF0ZWRfZml4ZWQzMhgMIAMoBxIWCg5yZXBl", + "YXRlZF9pbnQzMhgNIAMoBRIZChByZXBlYXRlZF9maXhlZDY0GP4PIAMoBhIX", + "Cg5yZXBlYXRlZF9pbnQ2NBj/DyADKAMSGAoOcmVwZWF0ZWRfZmxvYXQY/v8P", + "IAMoAhIZCg9yZXBlYXRlZF91aW50NjQY//8PIAMoBCL3CQoQVGVzdFBhcnNp", + "bmdNZXJnZRI7ChJyZXF1aXJlZF9hbGxfdHlwZXMYASACKAsyHy5wcm90b2J1", + "Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMSOwoSb3B0aW9uYWxfYWxsX3R5cGVz", + "GAIgASgLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzEjsKEnJl", + "cGVhdGVkX2FsbF90eXBlcxgDIAMoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxUeXBlcxJICg1vcHRpb25hbGdyb3VwGAogASgKMjEucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdFBhcnNpbmdNZXJnZS5PcHRpb25hbEdyb3VwEkgKDXJl", + "cGVhdGVkZ3JvdXAYFCADKAoyMS5wcm90b2J1Zl91bml0dGVzdC5UZXN0UGFy", + "c2luZ01lcmdlLlJlcGVhdGVkR3JvdXAaqgQKF1JlcGVhdGVkRmllbGRzR2Vu", + "ZXJhdG9yEi8KBmZpZWxkMRgBIAMoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxUeXBlcxIvCgZmaWVsZDIYAiADKAsyHy5wcm90b2J1Zl91bml0dGVz", + "dC5UZXN0QWxsVHlwZXMSLwoGZmllbGQzGAMgAygLMh8ucHJvdG9idWZfdW5p", + "dHRlc3QuVGVzdEFsbFR5cGVzElIKBmdyb3VwMRgKIAMoCjJCLnByb3RvYnVm", + "X3VuaXR0ZXN0LlRlc3RQYXJzaW5nTWVyZ2UuUmVwZWF0ZWRGaWVsZHNHZW5l", + "cmF0b3IuR3JvdXAxElIKBmdyb3VwMhgUIAMoCjJCLnByb3RvYnVmX3VuaXR0", + "ZXN0LlRlc3RQYXJzaW5nTWVyZ2UuUmVwZWF0ZWRGaWVsZHNHZW5lcmF0b3Iu", + "R3JvdXAyEi4KBGV4dDEY6AcgAygLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVz", + "dEFsbFR5cGVzEi4KBGV4dDIY6QcgAygLMh8ucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdEFsbFR5cGVzGjkKBkdyb3VwMRIvCgZmaWVsZDEYCyABKAsyHy5wcm90", + "b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMaOQoGR3JvdXAyEi8KBmZpZWxk", + "MRgVIAEoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcxpSCg1P", + "cHRpb25hbEdyb3VwEkEKGG9wdGlvbmFsX2dyb3VwX2FsbF90eXBlcxgLIAEo", + "CzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcxpSCg1SZXBlYXRl", + "ZEdyb3VwEkEKGHJlcGVhdGVkX2dyb3VwX2FsbF90eXBlcxgVIAEoCzIfLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcyoJCOgHEICAgIACMlsKDG9w", + "dGlvbmFsX2V4dBIjLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYXJzaW5nTWVy", + "Z2UY6AcgASgLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzMlsK", + "DHJlcGVhdGVkX2V4dBIjLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYXJzaW5n", + "TWVyZ2UY6QcgAygLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVz", + "IkQKG1Rlc3RDb21tZW50SW5qZWN0aW9uTWVzc2FnZRIlCgFhGAEgASgJOhoq", + "LyA8LSBOZWl0aGVyIHNob3VsZCB0aGlzLiIMCgpGb29SZXF1ZXN0Ig0KC0Zv", + "b1Jlc3BvbnNlIhIKEEZvb0NsaWVudE1lc3NhZ2UiEgoQRm9vU2VydmVyTWVz", + "c2FnZSIMCgpCYXJSZXF1ZXN0Ig0KC0JhclJlc3BvbnNlKkAKC0ZvcmVpZ25F", + "bnVtEg8KC0ZPUkVJR05fRk9PEAQSDwoLRk9SRUlHTl9CQVIQBRIPCgtGT1JF", + "SUdOX0JBWhAGKksKFFRlc3RFbnVtV2l0aER1cFZhbHVlEggKBEZPTzEQARII", + "CgRCQVIxEAISBwoDQkFaEAMSCAoERk9PMhABEggKBEJBUjIQAhoCEAEqiQEK", + "DlRlc3RTcGFyc2VFbnVtEgwKCFNQQVJTRV9BEHsSDgoIU1BBUlNFX0IQpucD", + "Eg8KCFNQQVJTRV9DELKxgAYSFQoIU1BBUlNFX0QQ8f//////////ARIVCghT", + "UEFSU0VfRRC03vz///////8BEgwKCFNQQVJTRV9GEAASDAoIU1BBUlNFX0cQ", + "AjKZAQoLVGVzdFNlcnZpY2USRAoDRm9vEh0ucHJvdG9idWZfdW5pdHRlc3Qu", + "Rm9vUmVxdWVzdBoeLnByb3RvYnVmX3VuaXR0ZXN0LkZvb1Jlc3BvbnNlEkQK", + "A0JhchIdLnByb3RvYnVmX3VuaXR0ZXN0LkJhclJlcXVlc3QaHi5wcm90b2J1", + "Zl91bml0dGVzdC5CYXJSZXNwb25zZTpGChhvcHRpb25hbF9pbnQzMl9leHRl", + "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgB", + "IAEoBTpGChhvcHRpb25hbF9pbnQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91", + "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgCIAEoAzpHChlvcHRpb25hbF91", + "aW50MzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4", + "dGVuc2lvbnMYAyABKA06RwoZb3B0aW9uYWxfdWludDY0X2V4dGVuc2lvbhIk", + "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGAQgASgEOkcK", + "GW9wdGlvbmFsX3NpbnQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", + "dC5UZXN0QWxsRXh0ZW5zaW9ucxgFIAEoETpHChlvcHRpb25hbF9zaW50NjRf", + "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv", + "bnMYBiABKBI6SAoab3B0aW9uYWxfZml4ZWQzMl9leHRlbnNpb24SJC5wcm90", + "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgHIAEoBzpIChpvcHRp", + "b25hbF9maXhlZDY0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxFeHRlbnNpb25zGAggASgGOkkKG29wdGlvbmFsX3NmaXhlZDMyX2V4", + "dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25z", + "GAkgASgPOkkKG29wdGlvbmFsX3NmaXhlZDY0X2V4dGVuc2lvbhIkLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGAogASgQOkYKGG9wdGlv", + "bmFsX2Zsb2F0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", + "bGxFeHRlbnNpb25zGAsgASgCOkcKGW9wdGlvbmFsX2RvdWJsZV9leHRlbnNp", + "b24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgMIAEo", + "ATpFChdvcHRpb25hbF9ib29sX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0", + "ZXN0LlRlc3RBbGxFeHRlbnNpb25zGA0gASgIOkcKGW9wdGlvbmFsX3N0cmlu", + "Z19leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5z", + "aW9ucxgOIAEoCTpGChhvcHRpb25hbF9ieXRlc19leHRlbnNpb24SJC5wcm90", + "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgPIAEoDDpxChdvcHRp", + "b25hbGdyb3VwX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", + "bGxFeHRlbnNpb25zGBAgASgKMioucHJvdG9idWZfdW5pdHRlc3QuT3B0aW9u", + "YWxHcm91cF9leHRlbnNpb246fgohb3B0aW9uYWxfbmVzdGVkX21lc3NhZ2Vf", + "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv", + "bnMYEiABKAsyLS5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVz", + "dGVkTWVzc2FnZTpzCiJvcHRpb25hbF9mb3JlaWduX21lc3NhZ2VfZXh0ZW5z", + "aW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYEyAB", + "KAsyIS5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduTWVzc2FnZTp4CiFvcHRp", + "b25hbF9pbXBvcnRfbWVzc2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0", + "dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgUIAEoCzInLnByb3RvYnVmX3VuaXR0", + "ZXN0X2ltcG9ydC5JbXBvcnRNZXNzYWdlOngKHm9wdGlvbmFsX25lc3RlZF9l", + "bnVtX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRl", + "bnNpb25zGBUgASgOMioucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVz", + "Lk5lc3RlZEVudW06bQofb3B0aW9uYWxfZm9yZWlnbl9lbnVtX2V4dGVuc2lv", + "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGBYgASgO", + "Mh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbkVudW06cgoeb3B0aW9uYWxf", + "aW1wb3J0X2VudW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVz", + "dEFsbEV4dGVuc2lvbnMYFyABKA4yJC5wcm90b2J1Zl91bml0dGVzdF9pbXBv", + "cnQuSW1wb3J0RW51bTpRCh9vcHRpb25hbF9zdHJpbmdfcGllY2VfZXh0ZW5z", + "aW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYGCAB", + "KAlCAggCOkkKF29wdGlvbmFsX2NvcmRfZXh0ZW5zaW9uEiQucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYGSABKAlCAggBOoUBCihvcHRp", + "b25hbF9wdWJsaWNfaW1wb3J0X21lc3NhZ2VfZXh0ZW5zaW9uEiQucHJvdG9i", + "dWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYGiABKAsyLS5wcm90b2J1", + "Zl91bml0dGVzdF9pbXBvcnQuUHVibGljSW1wb3J0TWVzc2FnZTqAAQofb3B0", + "aW9uYWxfbGF6eV9tZXNzYWdlX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0", + "ZXN0LlRlc3RBbGxFeHRlbnNpb25zGBsgASgLMi0ucHJvdG9idWZfdW5pdHRl", + "c3QuVGVzdEFsbFR5cGVzLk5lc3RlZE1lc3NhZ2VCAigBOkYKGHJlcGVhdGVk", + "X2ludDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxF", + "eHRlbnNpb25zGB8gAygFOkYKGHJlcGVhdGVkX2ludDY0X2V4dGVuc2lvbhIk", + "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCAgAygDOkcK", + "GXJlcGVhdGVkX3VpbnQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", + "dC5UZXN0QWxsRXh0ZW5zaW9ucxghIAMoDTpHChlyZXBlYXRlZF91aW50NjRf", + "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv", + "bnMYIiADKAQ6RwoZcmVwZWF0ZWRfc2ludDMyX2V4dGVuc2lvbhIkLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCMgAygROkcKGXJlcGVh", + "dGVkX3NpbnQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", + "QWxsRXh0ZW5zaW9ucxgkIAMoEjpIChpyZXBlYXRlZF9maXhlZDMyX2V4dGVu", + "c2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCUg", + "AygHOkgKGnJlcGVhdGVkX2ZpeGVkNjRfZXh0ZW5zaW9uEiQucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYJiADKAY6SQobcmVwZWF0ZWRf", + "c2ZpeGVkMzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFs", + "bEV4dGVuc2lvbnMYJyADKA86SQobcmVwZWF0ZWRfc2ZpeGVkNjRfZXh0ZW5z", + "aW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYKCAD", + "KBA6RgoYcmVwZWF0ZWRfZmxvYXRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5p", + "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYKSADKAI6RwoZcmVwZWF0ZWRfZG91", + "YmxlX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRl", + "bnNpb25zGCogAygBOkUKF3JlcGVhdGVkX2Jvb2xfZXh0ZW5zaW9uEiQucHJv", + "dG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYKyADKAg6RwoZcmVw", + "ZWF0ZWRfc3RyaW5nX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxFeHRlbnNpb25zGCwgAygJOkYKGHJlcGVhdGVkX2J5dGVzX2V4dGVu", + "c2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGC0g", + "AygMOnEKF3JlcGVhdGVkZ3JvdXBfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5p", + "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYLiADKAoyKi5wcm90b2J1Zl91bml0", + "dGVzdC5SZXBlYXRlZEdyb3VwX2V4dGVuc2lvbjp+CiFyZXBlYXRlZF9uZXN0", + "ZWRfbWVzc2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", + "QWxsRXh0ZW5zaW9ucxgwIAMoCzItLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", + "bGxUeXBlcy5OZXN0ZWRNZXNzYWdlOnMKInJlcGVhdGVkX2ZvcmVpZ25fbWVz", + "c2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", + "ZW5zaW9ucxgxIAMoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25NZXNz", + "YWdlOngKIXJlcGVhdGVkX2ltcG9ydF9tZXNzYWdlX2V4dGVuc2lvbhIkLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGDIgAygLMicucHJv", + "dG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydE1lc3NhZ2U6eAoecmVwZWF0", + "ZWRfbmVzdGVkX2VudW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdEFsbEV4dGVuc2lvbnMYMyADKA4yKi5wcm90b2J1Zl91bml0dGVzdC5U", + "ZXN0QWxsVHlwZXMuTmVzdGVkRW51bTptCh9yZXBlYXRlZF9mb3JlaWduX2Vu", + "dW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVu", + "c2lvbnMYNCADKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bTpy", + "Ch5yZXBlYXRlZF9pbXBvcnRfZW51bV9leHRlbnNpb24SJC5wcm90b2J1Zl91", + "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg1IAMoDjIkLnByb3RvYnVmX3Vu", + "aXR0ZXN0X2ltcG9ydC5JbXBvcnRFbnVtOlEKH3JlcGVhdGVkX3N0cmluZ19w", + "aWVjZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", + "ZW5zaW9ucxg2IAMoCUICCAI6SQoXcmVwZWF0ZWRfY29yZF9leHRlbnNpb24S", + "JC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg3IAMoCUIC", + "CAE6gAEKH3JlcGVhdGVkX2xhenlfbWVzc2FnZV9leHRlbnNpb24SJC5wcm90", + "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg5IAMoCzItLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdlQgIoATpJ", + "ChdkZWZhdWx0X2ludDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0", + "LlRlc3RBbGxFeHRlbnNpb25zGD0gASgFOgI0MTpJChdkZWZhdWx0X2ludDY0", + "X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNp", + "b25zGD4gASgDOgI0MjpKChhkZWZhdWx0X3VpbnQzMl9leHRlbnNpb24SJC5w", + "cm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg/IAEoDToCNDM6", + "SgoYZGVmYXVsdF91aW50NjRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRl", + "c3QuVGVzdEFsbEV4dGVuc2lvbnMYQCABKAQ6AjQ0OksKGGRlZmF1bHRfc2lu", + "dDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRl", + "bnNpb25zGEEgASgROgMtNDU6SgoYZGVmYXVsdF9zaW50NjRfZXh0ZW5zaW9u", + "EiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYQiABKBI6", + "AjQ2OksKGWRlZmF1bHRfZml4ZWQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91", + "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhDIAEoBzoCNDc6SwoZZGVmYXVs", + "dF9maXhlZDY0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", + "bGxFeHRlbnNpb25zGEQgASgGOgI0ODpMChpkZWZhdWx0X3NmaXhlZDMyX2V4", + "dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25z", + "GEUgASgPOgI0OTpNChpkZWZhdWx0X3NmaXhlZDY0X2V4dGVuc2lvbhIkLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEYgASgQOgMtNTA6", + "SwoXZGVmYXVsdF9mbG9hdF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", + "dC5UZXN0QWxsRXh0ZW5zaW9ucxhHIAEoAjoENTEuNTpNChhkZWZhdWx0X2Rv", + "dWJsZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", + "ZW5zaW9ucxhIIAEoAToFNTIwMDA6SgoWZGVmYXVsdF9ib29sX2V4dGVuc2lv", + "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEkgASgI", + "OgR0cnVlOk0KGGRlZmF1bHRfc3RyaW5nX2V4dGVuc2lvbhIkLnByb3RvYnVm", + "X3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEogASgJOgVoZWxsbzpMChdk", + "ZWZhdWx0X2J5dGVzX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxFeHRlbnNpb25zGEsgASgMOgV3b3JsZDp8Ch1kZWZhdWx0X25lc3Rl", + "ZF9lbnVtX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxF", + "eHRlbnNpb25zGFEgASgOMioucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5", + "cGVzLk5lc3RlZEVudW06A0JBUjp5Ch5kZWZhdWx0X2ZvcmVpZ25fZW51bV9l", + "eHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9u", + "cxhSIAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtOgtGT1JF", + "SUdOX0JBUjp9Ch1kZWZhdWx0X2ltcG9ydF9lbnVtX2V4dGVuc2lvbhIkLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGFMgASgOMiQucHJv", + "dG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydEVudW06CklNUE9SVF9CQVI6", + "VQoeZGVmYXVsdF9zdHJpbmdfcGllY2VfZXh0ZW5zaW9uEiQucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYVCABKAk6A2FiY0ICCAI6TQoW", + "ZGVmYXVsdF9jb3JkX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxFeHRlbnNpb25zGFUgASgJOgMxMjNCAggBOkQKFm9uZW9mX3VpbnQz", + "Ml9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5z", + "aW9ucxhvIAEoDTp7Ch5vbmVvZl9uZXN0ZWRfbWVzc2FnZV9leHRlbnNpb24S", + "JC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhwIAEoCzIt", + "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdl", + "OkQKFm9uZW9mX3N0cmluZ19leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", + "dC5UZXN0QWxsRXh0ZW5zaW9ucxhxIAEoCTpDChVvbmVvZl9ieXRlc19leHRl", + "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhy", + "IAEoDDpCChNteV9leHRlbnNpb25fc3RyaW5nEiUucHJvdG9idWZfdW5pdHRl", + "c3QuVGVzdEZpZWxkT3JkZXJpbmdzGDIgASgJOj8KEG15X2V4dGVuc2lvbl9p", + "bnQSJS5wcm90b2J1Zl91bml0dGVzdC5UZXN0RmllbGRPcmRlcmluZ3MYBSAB", + "KAU6SwoWcGFja2VkX2ludDMyX2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0", + "ZXN0LlRlc3RQYWNrZWRFeHRlbnNpb25zGFogAygFQgIQATpLChZwYWNrZWRf", + "aW50NjRfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tl", + "ZEV4dGVuc2lvbnMYWyADKANCAhABOkwKF3BhY2tlZF91aW50MzJfZXh0ZW5z", + "aW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMY", + "XCADKA1CAhABOkwKF3BhY2tlZF91aW50NjRfZXh0ZW5zaW9uEicucHJvdG9i", + "dWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMYXSADKARCAhABOkwK", + "F3BhY2tlZF9zaW50MzJfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdFBhY2tlZEV4dGVuc2lvbnMYXiADKBFCAhABOkwKF3BhY2tlZF9zaW50", + "NjRfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4", + "dGVuc2lvbnMYXyADKBJCAhABOk0KGHBhY2tlZF9maXhlZDMyX2V4dGVuc2lv", + "bhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNpb25zGGAg", + "AygHQgIQATpNChhwYWNrZWRfZml4ZWQ2NF9leHRlbnNpb24SJy5wcm90b2J1", + "Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhhIAMoBkICEAE6TgoZ", + "cGFja2VkX3NmaXhlZDMyX2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0", + "LlRlc3RQYWNrZWRFeHRlbnNpb25zGGIgAygPQgIQATpOChlwYWNrZWRfc2Zp", + "eGVkNjRfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tl", + "ZEV4dGVuc2lvbnMYYyADKBBCAhABOksKFnBhY2tlZF9mbG9hdF9leHRlbnNp", + "b24SJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhk", + "IAMoAkICEAE6TAoXcGFja2VkX2RvdWJsZV9leHRlbnNpb24SJy5wcm90b2J1", + "Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhlIAMoAUICEAE6SgoV", + "cGFja2VkX2Jvb2xfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVz", + "dFBhY2tlZEV4dGVuc2lvbnMYZiADKAhCAhABOmoKFXBhY2tlZF9lbnVtX2V4", + "dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNp", + "b25zGGcgAygOMh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbkVudW1CAhAB", + "Ok8KGHVucGFja2VkX2ludDMyX2V4dGVuc2lvbhIpLnByb3RvYnVmX3VuaXR0", + "ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYWiADKAVCAhAAOk8KGHVucGFj", + "a2VkX2ludDY0X2V4dGVuc2lvbhIpLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RV", + "bnBhY2tlZEV4dGVuc2lvbnMYWyADKANCAhAAOlAKGXVucGFja2VkX3VpbnQz", + "Ml9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVzdC5UZXN0VW5wYWNrZWRF", + "eHRlbnNpb25zGFwgAygNQgIQADpQChl1bnBhY2tlZF91aW50NjRfZXh0ZW5z", + "aW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5zaW9u", + "cxhdIAMoBEICEAA6UAoZdW5wYWNrZWRfc2ludDMyX2V4dGVuc2lvbhIpLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYXiADKBFC", + "AhAAOlAKGXVucGFja2VkX3NpbnQ2NF9leHRlbnNpb24SKS5wcm90b2J1Zl91", + "bml0dGVzdC5UZXN0VW5wYWNrZWRFeHRlbnNpb25zGF8gAygSQgIQADpRChp1", + "bnBhY2tlZF9maXhlZDMyX2V4dGVuc2lvbhIpLnByb3RvYnVmX3VuaXR0ZXN0", + "LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYYCADKAdCAhAAOlEKGnVucGFja2Vk", + "X2ZpeGVkNjRfZXh0ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVu", + "cGFja2VkRXh0ZW5zaW9ucxhhIAMoBkICEAA6UgobdW5wYWNrZWRfc2ZpeGVk", + "MzJfZXh0ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2Vk", + "RXh0ZW5zaW9ucxhiIAMoD0ICEAA6UgobdW5wYWNrZWRfc2ZpeGVkNjRfZXh0", + "ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5z", + "aW9ucxhjIAMoEEICEAA6TwoYdW5wYWNrZWRfZmxvYXRfZXh0ZW5zaW9uEiku", + "cHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5zaW9ucxhkIAMo", + "AkICEAA6UAoZdW5wYWNrZWRfZG91YmxlX2V4dGVuc2lvbhIpLnByb3RvYnVm", + "X3VuaXR0ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYZSADKAFCAhAAOk4K", + "F3VucGFja2VkX2Jvb2xfZXh0ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdFVucGFja2VkRXh0ZW5zaW9ucxhmIAMoCEICEAA6bgoXdW5wYWNrZWRf", + "ZW51bV9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVzdC5UZXN0VW5wYWNr", + "ZWRFeHRlbnNpb25zGGcgAygOMh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWln", + "bkVudW1CAhAAQkFCDVVuaXR0ZXN0UHJvdG9IAYABAYgBAZABAfgBAaoCIUdv", + "b2dsZS5Qcm90b2NvbEJ1ZmZlcnMuVGVzdFByb3Rvcw==")); + pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { + descriptor = root; + internal__static_protobuf_unittest_TestAllTypes__Descriptor = Descriptor.MessageTypes[0]; + internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes__Descriptor, + new string[] { "OptionalInt32", "OptionalInt64", "OptionalUint32", "OptionalUint64", "OptionalSint32", "OptionalSint64", "OptionalFixed32", "OptionalFixed64", "OptionalSfixed32", "OptionalSfixed64", "OptionalFloat", "OptionalDouble", "OptionalBool", "OptionalString", "OptionalBytes", "OptionalGroup", "OptionalNestedMessage", "OptionalForeignMessage", "OptionalImportMessage", "OptionalNestedEnum", "OptionalForeignEnum", "OptionalImportEnum", "OptionalStringPiece", "OptionalCord", "OptionalPublicImportMessage", "OptionalLazyMessage", "RepeatedInt32", "RepeatedInt64", "RepeatedUint32", "RepeatedUint64", "RepeatedSint32", "RepeatedSint64", "RepeatedFixed32", "RepeatedFixed64", "RepeatedSfixed32", "RepeatedSfixed64", "RepeatedFloat", "RepeatedDouble", "RepeatedBool", "RepeatedString", "RepeatedBytes", "RepeatedGroup", "RepeatedNestedMessage", "RepeatedForeignMessage", "RepeatedImportMessage", "RepeatedNestedEnum", "RepeatedForeignEnum", "RepeatedImportEnum", "RepeatedStringPiece", "RepeatedCord", "RepeatedLazyMessage", "DefaultInt32", "DefaultInt64", "DefaultUint32", "DefaultUint64", "DefaultSint32", "DefaultSint64", "DefaultFixed32", "DefaultFixed64", "DefaultSfixed32", "DefaultSfixed64", "DefaultFloat", "DefaultDouble", "DefaultBool", "DefaultString", "DefaultBytes", "DefaultNestedEnum", "DefaultForeignEnum", "DefaultImportEnum", "DefaultStringPiece", "DefaultCord", "OneofUint32", "OneofNestedMessage", "OneofString", "OneofBytes", }); + internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor, + new string[] { "Bb", }); + internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[2]; + internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor = Descriptor.MessageTypes[1]; + internal__static_protobuf_unittest_NestedTestAllTypes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor, + new string[] { "Child", "Payload", }); + internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor = Descriptor.MessageTypes[2]; + internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor, + new string[] { "DeprecatedInt32", }); + internal__static_protobuf_unittest_ForeignMessage__Descriptor = Descriptor.MessageTypes[3]; + internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_ForeignMessage__Descriptor, + new string[] { "C", }); + internal__static_protobuf_unittest_TestAllExtensions__Descriptor = Descriptor.MessageTypes[4]; + internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllExtensions__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor = Descriptor.MessageTypes[5]; + internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor = Descriptor.MessageTypes[6]; + internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_TestNestedExtension__Descriptor = Descriptor.MessageTypes[7]; + internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedExtension__Descriptor, + new string[] { }); + global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Test = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor.Extensions[0]); + global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.NestedStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor.Extensions[1]); + internal__static_protobuf_unittest_TestRequired__Descriptor = Descriptor.MessageTypes[8]; + internal__static_protobuf_unittest_TestRequired__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequired__Descriptor, + new string[] { "A", "Dummy2", "B", "Dummy4", "Dummy5", "Dummy6", "Dummy7", "Dummy8", "Dummy9", "Dummy10", "Dummy11", "Dummy12", "Dummy13", "Dummy14", "Dummy15", "Dummy16", "Dummy17", "Dummy18", "Dummy19", "Dummy20", "Dummy21", "Dummy22", "Dummy23", "Dummy24", "Dummy25", "Dummy26", "Dummy27", "Dummy28", "Dummy29", "Dummy30", "Dummy31", "Dummy32", "C", }); + global::Google.ProtocolBuffers.TestProtos.TestRequired.Single = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor.Extensions[0]); + global::Google.ProtocolBuffers.TestProtos.TestRequired.Multi = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor.Extensions[1]); + internal__static_protobuf_unittest_TestRequiredForeign__Descriptor = Descriptor.MessageTypes[9]; + internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequiredForeign__Descriptor, + new string[] { "OptionalMessage", "RepeatedMessage", "Dummy", }); + internal__static_protobuf_unittest_TestForeignNested__Descriptor = Descriptor.MessageTypes[10]; + internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestForeignNested__Descriptor, + new string[] { "ForeignNested", }); + internal__static_protobuf_unittest_TestEmptyMessage__Descriptor = Descriptor.MessageTypes[11]; + internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEmptyMessage__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor = Descriptor.MessageTypes[12]; + internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor = Descriptor.MessageTypes[13]; + internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor = Descriptor.MessageTypes[14]; + internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor, + new string[] { "A", "Bb", }); + internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor = Descriptor.MessageTypes[15]; + internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor, + new string[] { "A", "I", }); + internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor = Descriptor.MessageTypes[16]; + internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor, + new string[] { "Bb", }); + internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor = Descriptor.MessageTypes[17]; + internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor, + new string[] { "A", "OptionalInt32", }); + internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor = Descriptor.MessageTypes[18]; + internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor, + new string[] { "A", "Foo", "Bar", }); + internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor = internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor = internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_TestEagerMessage__Descriptor = Descriptor.MessageTypes[19]; + internal__static_protobuf_unittest_TestEagerMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEagerMessage__Descriptor, + new string[] { "SubMessage", }); + internal__static_protobuf_unittest_TestLazyMessage__Descriptor = Descriptor.MessageTypes[20]; + internal__static_protobuf_unittest_TestLazyMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestLazyMessage__Descriptor, + new string[] { "SubMessage", }); + internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor = Descriptor.MessageTypes[21]; + internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor, + new string[] { "OptionalNestedMessage", }); + internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor, + new string[] { "NestedmessageRepeatedInt32", "NestedmessageRepeatedForeignmessage", }); + internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor = Descriptor.MessageTypes[22]; + internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor, + new string[] { "PrimitiveField", "StringField", "EnumField", "MessageField", "StringPieceField", "CordField", "RepeatedPrimitiveField", "RepeatedStringField", "RepeatedEnumField", "RepeatedMessageField", "RepeatedStringPieceField", "RepeatedCordField", }); + internal__static_protobuf_unittest_TestFieldOrderings__Descriptor = Descriptor.MessageTypes[23]; + internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestFieldOrderings__Descriptor, + new string[] { "MyString", "MyInt", "MyFloat", "OptionalNestedMessage", }); + internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestFieldOrderings__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor, + new string[] { "Oo", "Bb", }); + internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor = Descriptor.MessageTypes[24]; + internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor, + new string[] { "EscapedBytes", "LargeUint32", "LargeUint64", "SmallInt32", "SmallInt64", "ReallySmallInt32", "ReallySmallInt64", "Utf8String", "ZeroFloat", "OneFloat", "SmallFloat", "NegativeOneFloat", "NegativeFloat", "LargeFloat", "SmallNegativeFloat", "InfDouble", "NegInfDouble", "NanDouble", "InfFloat", "NegInfFloat", "NanFloat", "CppTrigraph", "StringWithZero", "BytesWithZero", "StringPieceWithZero", "CordWithZero", "ReplacementString", }); + internal__static_protobuf_unittest_SparseEnumMessage__Descriptor = Descriptor.MessageTypes[25]; + internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_SparseEnumMessage__Descriptor, + new string[] { "SparseEnum", }); + internal__static_protobuf_unittest_OneString__Descriptor = Descriptor.MessageTypes[26]; + internal__static_protobuf_unittest_OneString__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OneString__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_MoreString__Descriptor = Descriptor.MessageTypes[27]; + internal__static_protobuf_unittest_MoreString__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_MoreString__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_OneBytes__Descriptor = Descriptor.MessageTypes[28]; + internal__static_protobuf_unittest_OneBytes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OneBytes__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_MoreBytes__Descriptor = Descriptor.MessageTypes[29]; + internal__static_protobuf_unittest_MoreBytes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_MoreBytes__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_Int32Message__Descriptor = Descriptor.MessageTypes[30]; + internal__static_protobuf_unittest_Int32Message__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Int32Message__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_Uint32Message__Descriptor = Descriptor.MessageTypes[31]; + internal__static_protobuf_unittest_Uint32Message__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Uint32Message__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_Int64Message__Descriptor = Descriptor.MessageTypes[32]; + internal__static_protobuf_unittest_Int64Message__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Int64Message__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_Uint64Message__Descriptor = Descriptor.MessageTypes[33]; + internal__static_protobuf_unittest_Uint64Message__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Uint64Message__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_BoolMessage__Descriptor = Descriptor.MessageTypes[34]; + internal__static_protobuf_unittest_BoolMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BoolMessage__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_TestOneof__Descriptor = Descriptor.MessageTypes[35]; + internal__static_protobuf_unittest_TestOneof__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof__Descriptor, + new string[] { "FooInt", "FooString", "FooMessage", "FooGroup", }); + internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor = internal__static_protobuf_unittest_TestOneof__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestOneof_FooGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor, + new string[] { "A", "B", }); + internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor = Descriptor.MessageTypes[36]; + internal__static_protobuf_unittest_TestOneofBackwardsCompatible__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor, + new string[] { "FooInt", "FooString", "FooMessage", "FooGroup", }); + internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor = internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor, + new string[] { "A", "B", }); + internal__static_protobuf_unittest_TestOneof2__Descriptor = Descriptor.MessageTypes[37]; + internal__static_protobuf_unittest_TestOneof2__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof2__Descriptor, + new string[] { "FooInt", "FooString", "FooCord", "FooStringPiece", "FooBytes", "FooEnum", "FooMessage", "FooGroup", "FooLazyMessage", "BarInt", "BarString", "BarCord", "BarStringPiece", "BarBytes", "BarEnum", "BazInt", "BazString", }); + internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor = internal__static_protobuf_unittest_TestOneof2__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestOneof2_FooGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor, + new string[] { "A", "B", }); + internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestOneof2__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_TestOneof2_NestedMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor, + new string[] { "QuxInt", "CorgeInt", }); + internal__static_protobuf_unittest_TestRequiredOneof__Descriptor = Descriptor.MessageTypes[38]; + internal__static_protobuf_unittest_TestRequiredOneof__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequiredOneof__Descriptor, + new string[] { "FooInt", "FooString", "FooMessage", }); + internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestRequiredOneof__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor, + new string[] { "RequiredDouble", }); + internal__static_protobuf_unittest_TestPackedTypes__Descriptor = Descriptor.MessageTypes[39]; + internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestPackedTypes__Descriptor, + new string[] { "PackedInt32", "PackedInt64", "PackedUint32", "PackedUint64", "PackedSint32", "PackedSint64", "PackedFixed32", "PackedFixed64", "PackedSfixed32", "PackedSfixed64", "PackedFloat", "PackedDouble", "PackedBool", "PackedEnum", }); + internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor = Descriptor.MessageTypes[40]; + internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor, + new string[] { "UnpackedInt32", "UnpackedInt64", "UnpackedUint32", "UnpackedUint64", "UnpackedSint32", "UnpackedSint64", "UnpackedFixed32", "UnpackedFixed64", "UnpackedSfixed32", "UnpackedSfixed64", "UnpackedFloat", "UnpackedDouble", "UnpackedBool", "UnpackedEnum", }); + internal__static_protobuf_unittest_TestPackedExtensions__Descriptor = Descriptor.MessageTypes[41]; + internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestPackedExtensions__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor = Descriptor.MessageTypes[42]; + internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor = Descriptor.MessageTypes[43]; + internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor, + new string[] { "ScalarExtension", "EnumExtension", "DynamicEnumExtension", "MessageExtension", "DynamicMessageExtension", "RepeatedExtension", "PackedExtension", }); + internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor = internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor, + new string[] { "DynamicField", }); + internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor = Descriptor.MessageTypes[44]; + internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor, + new string[] { "RepeatedFixed32", "RepeatedInt32", "RepeatedFixed64", "RepeatedInt64", "RepeatedFloat", "RepeatedUint64", }); + internal__static_protobuf_unittest_TestParsingMerge__Descriptor = Descriptor.MessageTypes[45]; + internal__static_protobuf_unittest_TestParsingMerge__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge__Descriptor, + new string[] { "RequiredAllTypes", "OptionalAllTypes", "RepeatedAllTypes", "OptionalGroup", "RepeatedGroup", }); + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor = internal__static_protobuf_unittest_TestParsingMerge__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor, + new string[] { "Field1", "Field2", "Field3", "Group1", "Group2", "Ext1", "Ext2", }); + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor = internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor, + new string[] { "Field1", }); + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor = internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor, + new string[] { "Field1", }); + internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor = internal__static_protobuf_unittest_TestParsingMerge__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor, + new string[] { "OptionalGroupAllTypes", }); + internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor = internal__static_protobuf_unittest_TestParsingMerge__Descriptor.NestedTypes[2]; + internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor, + new string[] { "RepeatedGroupAllTypes", }); + global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.OptionalExt = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Descriptor.Extensions[0]); + global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.RepeatedExt = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Descriptor.Extensions[1]); + internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor = Descriptor.MessageTypes[46]; + internal__static_protobuf_unittest_TestCommentInjectionMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_FooRequest__Descriptor = Descriptor.MessageTypes[47]; + internal__static_protobuf_unittest_FooRequest__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooRequest__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_FooResponse__Descriptor = Descriptor.MessageTypes[48]; + internal__static_protobuf_unittest_FooResponse__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooResponse__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_FooClientMessage__Descriptor = Descriptor.MessageTypes[49]; + internal__static_protobuf_unittest_FooClientMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooClientMessage__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_FooServerMessage__Descriptor = Descriptor.MessageTypes[50]; + internal__static_protobuf_unittest_FooServerMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooServerMessage__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_BarRequest__Descriptor = Descriptor.MessageTypes[51]; + internal__static_protobuf_unittest_BarRequest__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BarRequest__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_BarResponse__Descriptor = Descriptor.MessageTypes[52]; + internal__static_protobuf_unittest_BarResponse__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BarResponse__Descriptor, + new string[] { }); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[0]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[1]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[2]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[3]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[4]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[5]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[6]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[7]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[8]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[9]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFloatExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[10]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalDoubleExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[11]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBoolExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[12]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[13]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[14]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalGroupExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[15]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[16]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[17]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[18]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[19]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[20]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[21]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringPieceExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[22]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalCordExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[23]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalPublicImportMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[24]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalLazyMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[25]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[26]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[27]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[28]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[29]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[30]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[31]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[32]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[33]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[34]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[35]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[36]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[37]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[38]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[39]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBytesExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[40]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedGroupExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[41]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[42]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[43]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[44]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[45]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[46]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[47]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringPieceExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[48]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedCordExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[49]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedLazyMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[50]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[51]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[52]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[53]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[54]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[55]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[56]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[57]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[58]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[59]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[60]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFloatExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[61]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultDoubleExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[62]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBoolExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[63]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[64]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[65]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultNestedEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[66]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultForeignEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[67]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultImportEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[68]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringPieceExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[69]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultCordExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[70]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OneofUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[71]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OneofNestedMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[72]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OneofStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[73]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OneofBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[74]); + global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionString = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[75]); + global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionInt = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[76]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[77]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[78]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[79]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[80]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[81]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[82]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[83]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[84]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[85]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[86]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[87]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[88]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[89]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[90]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[91]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[92]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[93]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[94]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[95]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[96]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[97]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[98]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[99]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[100]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[101]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[102]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[103]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[104]); + pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); + RegisterAllExtensions(registry); + global::Google.ProtocolBuffers.TestProtos.UnittestImport.RegisterAllExtensions(registry); + return registry; + }; + pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, + new pbd::FileDescriptor[] { + global::Google.ProtocolBuffers.TestProtos.UnittestImport.Descriptor, + }, assigner); + } + #endregion + + } + #region Enums + public enum ForeignEnum { + FOREIGN_FOO = 4, + FOREIGN_BAR = 5, + FOREIGN_BAZ = 6, + } + + public enum TestEnumWithDupValue { + FOO1 = 1, + BAR1 = 2, + BAZ = 3, + FOO2 = 1, + BAR2 = 2, + } + + public enum TestSparseEnum { + SPARSE_A = 123, + SPARSE_B = 62374, + SPARSE_C = 12589234, + SPARSE_D = -15, + SPARSE_E = -53452, + SPARSE_F = 0, + SPARSE_G = 2, + } + + #endregion + + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestAllTypes : pb::GeneratedMessage { + private TestAllTypes() { } + private static readonly TestAllTypes defaultInstance = new TestAllTypes().MakeReadOnly(); + private static readonly string[] _testAllTypesFieldNames = new string[] { "default_bool", "default_bytes", "default_cord", "default_double", "default_fixed32", "default_fixed64", "default_float", "default_foreign_enum", "default_import_enum", "default_int32", "default_int64", "default_nested_enum", "default_sfixed32", "default_sfixed64", "default_sint32", "default_sint64", "default_string", "default_string_piece", "default_uint32", "default_uint64", "oneof_bytes", "oneof_nested_message", "oneof_string", "oneof_uint32", "optional_bool", "optional_bytes", "optional_cord", "optional_double", "optional_fixed32", "optional_fixed64", "optional_float", "optional_foreign_enum", "optional_foreign_message", "optional_import_enum", "optional_import_message", "optional_int32", "optional_int64", "optional_lazy_message", "optional_nested_enum", "optional_nested_message", "optional_public_import_message", "optional_sfixed32", "optional_sfixed64", "optional_sint32", "optional_sint64", "optional_string", "optional_string_piece", "optional_uint32", "optional_uint64", "optionalgroup", "repeated_bool", "repeated_bytes", "repeated_cord", "repeated_double", "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_foreign_enum", "repeated_foreign_message", "repeated_import_enum", "repeated_import_message", "repeated_int32", "repeated_int64", "repeated_lazy_message", "repeated_nested_enum", "repeated_nested_message", "repeated_sfixed32", "repeated_sfixed64", "repeated_sint32", "repeated_sint64", "repeated_string", "repeated_string_piece", "repeated_uint32", "repeated_uint64", "repeatedgroup" }; + private static readonly uint[] _testAllTypesFieldTags = new uint[] { 584, 602, 682, 577, 541, 545, 573, 656, 664, 488, 496, 648, 557, 561, 520, 528, 594, 674, 504, 512, 914, 898, 906, 888, 104, 122, 202, 97, 61, 65, 93, 176, 154, 184, 162, 8, 16, 218, 168, 146, 210, 77, 81, 40, 48, 114, 194, 24, 32, 131, 344, 362, 442, 337, 301, 305, 333, 416, 394, 424, 402, 248, 256, 458, 408, 386, 317, 321, 280, 288, 354, 434, 264, 272, 371 }; + public static TestAllTypes DefaultInstance { + get { return defaultInstance; } + } + + public override TestAllTypes DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestAllTypes ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + public enum NestedEnum { + FOO = 1, + BAR = 2, + BAZ = 3, + NEG = -1, + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessage { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "bb" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8 }; + public static NestedMessage DefaultInstance { + get { return defaultInstance; } + } + + public override NestedMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override NestedMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; } + } + + public const int BbFieldNumber = 1; + private bool hasBb; + private int bb_; + public bool HasBb { + get { return hasBb; } + } + public int Bb { + get { return bb_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (hasBb) { + output.WriteInt32(1, field_names[0], Bb); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasBb) { + size += pb::CodedOutputStream.ComputeInt32Size(1, Bb); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() { + if (resultIsReadOnly) { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override NestedMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Descriptor; } + } + + public override NestedMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } + } + + public override NestedMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is NestedMessage) { + return MergeFrom((NestedMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NestedMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasBb) { + Bb = other.Bb; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasBb = input.ReadInt32(ref result.bb_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasBb { + get { return result.hasBb; } + } + public int Bb { + get { return result.Bb; } + set { SetBb(value); } + } + public Builder SetBb(int value) { + PrepareBuilder(); + result.hasBb = true; + result.bb_ = value; + return this; + } + public Builder ClearBb() { + PrepareBuilder(); + result.hasBb = false; + result.bb_ = 0; + return this; + } + } + static NestedMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OptionalGroup : pb::GeneratedMessage { + private OptionalGroup() { } + private static readonly OptionalGroup defaultInstance = new OptionalGroup().MakeReadOnly(); + private static readonly string[] _optionalGroupFieldNames = new string[] { "a" }; + private static readonly uint[] _optionalGroupFieldTags = new uint[] { 136 }; + public static OptionalGroup DefaultInstance { + get { return defaultInstance; } + } + + public override OptionalGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override OptionalGroup ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable; } + } + + public const int AFieldNumber = 17; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _optionalGroupFieldNames; + if (hasA) { + output.WriteInt32(17, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(17, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static OptionalGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OptionalGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OptionalGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OptionalGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OptionalGroup result; + + private OptionalGroup PrepareBuilder() { + if (resultIsReadOnly) { + OptionalGroup original = result; + result = new OptionalGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override OptionalGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Descriptor; } + } + + public override OptionalGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance; } + } + + public override OptionalGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is OptionalGroup) { + return MergeFrom((OptionalGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OptionalGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _optionalGroupFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 136: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static OptionalGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedGroup : pb::GeneratedMessage { + private RepeatedGroup() { } + private static readonly RepeatedGroup defaultInstance = new RepeatedGroup().MakeReadOnly(); + private static readonly string[] _repeatedGroupFieldNames = new string[] { "a" }; + private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 376 }; + public static RepeatedGroup DefaultInstance { + get { return defaultInstance; } + } + + public override RepeatedGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override RepeatedGroup ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable; } + } + + public const int AFieldNumber = 47; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _repeatedGroupFieldNames; + if (hasA) { + output.WriteInt32(47, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(47, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static RepeatedGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private RepeatedGroup result; + + private RepeatedGroup PrepareBuilder() { + if (resultIsReadOnly) { + RepeatedGroup original = result; + result = new RepeatedGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override RepeatedGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Descriptor; } + } + + public override RepeatedGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance; } + } + + public override RepeatedGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is RepeatedGroup) { + return MergeFrom((RepeatedGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(RepeatedGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _repeatedGroupFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 376: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static RepeatedGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int OptionalInt32FieldNumber = 1; + private bool hasOptionalInt32; + private int optionalInt32_; + public bool HasOptionalInt32 { + get { return hasOptionalInt32; } + } + public int OptionalInt32 { + get { return optionalInt32_; } + } + + public const int OptionalInt64FieldNumber = 2; + private bool hasOptionalInt64; + private long optionalInt64_; + public bool HasOptionalInt64 { + get { return hasOptionalInt64; } + } + public long OptionalInt64 { + get { return optionalInt64_; } + } + + public const int OptionalUint32FieldNumber = 3; + private bool hasOptionalUint32; + private uint optionalUint32_; + public bool HasOptionalUint32 { + get { return hasOptionalUint32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalUint32 { + get { return optionalUint32_; } + } + + public const int OptionalUint64FieldNumber = 4; + private bool hasOptionalUint64; + private ulong optionalUint64_; + public bool HasOptionalUint64 { + get { return hasOptionalUint64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalUint64 { + get { return optionalUint64_; } + } + + public const int OptionalSint32FieldNumber = 5; + private bool hasOptionalSint32; + private int optionalSint32_; + public bool HasOptionalSint32 { + get { return hasOptionalSint32; } + } + public int OptionalSint32 { + get { return optionalSint32_; } + } + + public const int OptionalSint64FieldNumber = 6; + private bool hasOptionalSint64; + private long optionalSint64_; + public bool HasOptionalSint64 { + get { return hasOptionalSint64; } + } + public long OptionalSint64 { + get { return optionalSint64_; } + } + + public const int OptionalFixed32FieldNumber = 7; + private bool hasOptionalFixed32; + private uint optionalFixed32_; + public bool HasOptionalFixed32 { + get { return hasOptionalFixed32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalFixed32 { + get { return optionalFixed32_; } + } + + public const int OptionalFixed64FieldNumber = 8; + private bool hasOptionalFixed64; + private ulong optionalFixed64_; + public bool HasOptionalFixed64 { + get { return hasOptionalFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalFixed64 { + get { return optionalFixed64_; } + } + + public const int OptionalSfixed32FieldNumber = 9; + private bool hasOptionalSfixed32; + private int optionalSfixed32_; + public bool HasOptionalSfixed32 { + get { return hasOptionalSfixed32; } + } + public int OptionalSfixed32 { + get { return optionalSfixed32_; } + } + + public const int OptionalSfixed64FieldNumber = 10; + private bool hasOptionalSfixed64; + private long optionalSfixed64_; + public bool HasOptionalSfixed64 { + get { return hasOptionalSfixed64; } + } + public long OptionalSfixed64 { + get { return optionalSfixed64_; } + } + + public const int OptionalFloatFieldNumber = 11; + private bool hasOptionalFloat; + private float optionalFloat_; + public bool HasOptionalFloat { + get { return hasOptionalFloat; } + } + public float OptionalFloat { + get { return optionalFloat_; } + } + + public const int OptionalDoubleFieldNumber = 12; + private bool hasOptionalDouble; + private double optionalDouble_; + public bool HasOptionalDouble { + get { return hasOptionalDouble; } + } + public double OptionalDouble { + get { return optionalDouble_; } + } + + public const int OptionalBoolFieldNumber = 13; + private bool hasOptionalBool; + private bool optionalBool_; + public bool HasOptionalBool { + get { return hasOptionalBool; } + } + public bool OptionalBool { + get { return optionalBool_; } + } + + public const int OptionalStringFieldNumber = 14; + private bool hasOptionalString; + private string optionalString_ = ""; + public bool HasOptionalString { + get { return hasOptionalString; } + } + public string OptionalString { + get { return optionalString_; } + } + + public const int OptionalBytesFieldNumber = 15; + private bool hasOptionalBytes; + private pb::ByteString optionalBytes_ = pb::ByteString.Empty; + public bool HasOptionalBytes { + get { return hasOptionalBytes; } + } + public pb::ByteString OptionalBytes { + get { return optionalBytes_; } + } + + public const int OptionalGroupFieldNumber = 16; + private bool hasOptionalGroup; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup optionalGroup_; + public bool HasOptionalGroup { + get { return hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup OptionalGroup { + get { return optionalGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance; } + } + + public const int OptionalNestedMessageFieldNumber = 18; + private bool hasOptionalNestedMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage optionalNestedMessage_; + public bool HasOptionalNestedMessage { + get { return hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage { + get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } + } + + public const int OptionalForeignMessageFieldNumber = 19; + private bool hasOptionalForeignMessage; + private global::Google.ProtocolBuffers.TestProtos.ForeignMessage optionalForeignMessage_; + public bool HasOptionalForeignMessage { + get { return hasOptionalForeignMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage { + get { return optionalForeignMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } + } + + public const int OptionalImportMessageFieldNumber = 20; + private bool hasOptionalImportMessage; + private global::Google.ProtocolBuffers.TestProtos.ImportMessage optionalImportMessage_; + public bool HasOptionalImportMessage { + get { return hasOptionalImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessage OptionalImportMessage { + get { return optionalImportMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance; } + } + + public const int OptionalNestedEnumFieldNumber = 21; + private bool hasOptionalNestedEnum; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; + public bool HasOptionalNestedEnum { + get { return hasOptionalNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum { + get { return optionalNestedEnum_; } + } + + public const int OptionalForeignEnumFieldNumber = 22; + private bool hasOptionalForeignEnum; + private global::Google.ProtocolBuffers.TestProtos.ForeignEnum optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + public bool HasOptionalForeignEnum { + get { return hasOptionalForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum { + get { return optionalForeignEnum_; } + } + + public const int OptionalImportEnumFieldNumber = 23; + private bool hasOptionalImportEnum; + private global::Google.ProtocolBuffers.TestProtos.ImportEnum optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_FOO; + public bool HasOptionalImportEnum { + get { return hasOptionalImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum OptionalImportEnum { + get { return optionalImportEnum_; } + } + + public const int OptionalStringPieceFieldNumber = 24; + private bool hasOptionalStringPiece; + private string optionalStringPiece_ = ""; + public bool HasOptionalStringPiece { + get { return hasOptionalStringPiece; } + } + public string OptionalStringPiece { + get { return optionalStringPiece_; } + } + + public const int OptionalCordFieldNumber = 25; + private bool hasOptionalCord; + private string optionalCord_ = ""; + public bool HasOptionalCord { + get { return hasOptionalCord; } + } + public string OptionalCord { + get { return optionalCord_; } + } + + public const int OptionalPublicImportMessageFieldNumber = 26; + private bool hasOptionalPublicImportMessage; + private global::Google.ProtocolBuffers.TestProtos.PublicImportMessage optionalPublicImportMessage_; + public bool HasOptionalPublicImportMessage { + get { return hasOptionalPublicImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.PublicImportMessage OptionalPublicImportMessage { + get { return optionalPublicImportMessage_ ?? global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.DefaultInstance; } + } + + public const int OptionalLazyMessageFieldNumber = 27; + private bool hasOptionalLazyMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage optionalLazyMessage_; + public bool HasOptionalLazyMessage { + get { return hasOptionalLazyMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalLazyMessage { + get { return optionalLazyMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } + } + + public const int RepeatedInt32FieldNumber = 31; + private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); + public scg::IList RepeatedInt32List { + get { return pbc::Lists.AsReadOnly(repeatedInt32_); } + } + public int RepeatedInt32Count { + get { return repeatedInt32_.Count; } + } + public int GetRepeatedInt32(int index) { + return repeatedInt32_[index]; + } + + public const int RepeatedInt64FieldNumber = 32; + private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); + public scg::IList RepeatedInt64List { + get { return pbc::Lists.AsReadOnly(repeatedInt64_); } + } + public int RepeatedInt64Count { + get { return repeatedInt64_.Count; } + } + public long GetRepeatedInt64(int index) { + return repeatedInt64_[index]; + } + + public const int RepeatedUint32FieldNumber = 33; + private pbc::PopsicleList repeatedUint32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedUint32List { + get { return pbc::Lists.AsReadOnly(repeatedUint32_); } + } + public int RepeatedUint32Count { + get { return repeatedUint32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedUint32(int index) { + return repeatedUint32_[index]; + } + + public const int RepeatedUint64FieldNumber = 34; + private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedUint64List { + get { return pbc::Lists.AsReadOnly(repeatedUint64_); } + } + public int RepeatedUint64Count { + get { return repeatedUint64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedUint64(int index) { + return repeatedUint64_[index]; + } + + public const int RepeatedSint32FieldNumber = 35; + private pbc::PopsicleList repeatedSint32_ = new pbc::PopsicleList(); + public scg::IList RepeatedSint32List { + get { return pbc::Lists.AsReadOnly(repeatedSint32_); } + } + public int RepeatedSint32Count { + get { return repeatedSint32_.Count; } + } + public int GetRepeatedSint32(int index) { + return repeatedSint32_[index]; + } + + public const int RepeatedSint64FieldNumber = 36; + private pbc::PopsicleList repeatedSint64_ = new pbc::PopsicleList(); + public scg::IList RepeatedSint64List { + get { return pbc::Lists.AsReadOnly(repeatedSint64_); } + } + public int RepeatedSint64Count { + get { return repeatedSint64_.Count; } + } + public long GetRepeatedSint64(int index) { + return repeatedSint64_[index]; + } + + public const int RepeatedFixed32FieldNumber = 37; + private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedFixed32List { + get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } + } + public int RepeatedFixed32Count { + get { return repeatedFixed32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedFixed32(int index) { + return repeatedFixed32_[index]; + } + + public const int RepeatedFixed64FieldNumber = 38; + private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedFixed64List { + get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } + } + public int RepeatedFixed64Count { + get { return repeatedFixed64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedFixed64(int index) { + return repeatedFixed64_[index]; + } + + public const int RepeatedSfixed32FieldNumber = 39; + private pbc::PopsicleList repeatedSfixed32_ = new pbc::PopsicleList(); + public scg::IList RepeatedSfixed32List { + get { return pbc::Lists.AsReadOnly(repeatedSfixed32_); } + } + public int RepeatedSfixed32Count { + get { return repeatedSfixed32_.Count; } + } + public int GetRepeatedSfixed32(int index) { + return repeatedSfixed32_[index]; + } + + public const int RepeatedSfixed64FieldNumber = 40; + private pbc::PopsicleList repeatedSfixed64_ = new pbc::PopsicleList(); + public scg::IList RepeatedSfixed64List { + get { return pbc::Lists.AsReadOnly(repeatedSfixed64_); } + } + public int RepeatedSfixed64Count { + get { return repeatedSfixed64_.Count; } + } + public long GetRepeatedSfixed64(int index) { + return repeatedSfixed64_[index]; + } + + public const int RepeatedFloatFieldNumber = 41; + private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); + public scg::IList RepeatedFloatList { + get { return pbc::Lists.AsReadOnly(repeatedFloat_); } + } + public int RepeatedFloatCount { + get { return repeatedFloat_.Count; } + } + public float GetRepeatedFloat(int index) { + return repeatedFloat_[index]; + } + + public const int RepeatedDoubleFieldNumber = 42; + private pbc::PopsicleList repeatedDouble_ = new pbc::PopsicleList(); + public scg::IList RepeatedDoubleList { + get { return pbc::Lists.AsReadOnly(repeatedDouble_); } + } + public int RepeatedDoubleCount { + get { return repeatedDouble_.Count; } + } + public double GetRepeatedDouble(int index) { + return repeatedDouble_[index]; + } + + public const int RepeatedBoolFieldNumber = 43; + private pbc::PopsicleList repeatedBool_ = new pbc::PopsicleList(); + public scg::IList RepeatedBoolList { + get { return pbc::Lists.AsReadOnly(repeatedBool_); } + } + public int RepeatedBoolCount { + get { return repeatedBool_.Count; } + } + public bool GetRepeatedBool(int index) { + return repeatedBool_[index]; + } + + public const int RepeatedStringFieldNumber = 44; + private pbc::PopsicleList repeatedString_ = new pbc::PopsicleList(); + public scg::IList RepeatedStringList { + get { return pbc::Lists.AsReadOnly(repeatedString_); } + } + public int RepeatedStringCount { + get { return repeatedString_.Count; } + } + public string GetRepeatedString(int index) { + return repeatedString_[index]; + } + + public const int RepeatedBytesFieldNumber = 45; + private pbc::PopsicleList repeatedBytes_ = new pbc::PopsicleList(); + public scg::IList RepeatedBytesList { + get { return pbc::Lists.AsReadOnly(repeatedBytes_); } + } + public int RepeatedBytesCount { + get { return repeatedBytes_.Count; } + } + public pb::ByteString GetRepeatedBytes(int index) { + return repeatedBytes_[index]; + } + + public const int RepeatedGroupFieldNumber = 46; + private pbc::PopsicleList repeatedGroup_ = new pbc::PopsicleList(); + public scg::IList RepeatedGroupList { + get { return repeatedGroup_; } + } + public int RepeatedGroupCount { + get { return repeatedGroup_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup GetRepeatedGroup(int index) { + return repeatedGroup_[index]; + } + + public const int RepeatedNestedMessageFieldNumber = 48; + private pbc::PopsicleList repeatedNestedMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedNestedMessageList { + get { return repeatedNestedMessage_; } + } + public int RepeatedNestedMessageCount { + get { return repeatedNestedMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) { + return repeatedNestedMessage_[index]; + } + + public const int RepeatedForeignMessageFieldNumber = 49; + private pbc::PopsicleList repeatedForeignMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedForeignMessageList { + get { return repeatedForeignMessage_; } + } + public int RepeatedForeignMessageCount { + get { return repeatedForeignMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) { + return repeatedForeignMessage_[index]; + } + + public const int RepeatedImportMessageFieldNumber = 50; + private pbc::PopsicleList repeatedImportMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedImportMessageList { + get { return repeatedImportMessage_; } + } + public int RepeatedImportMessageCount { + get { return repeatedImportMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessage GetRepeatedImportMessage(int index) { + return repeatedImportMessage_[index]; + } + + public const int RepeatedNestedEnumFieldNumber = 51; + private pbc::PopsicleList repeatedNestedEnum_ = new pbc::PopsicleList(); + public scg::IList RepeatedNestedEnumList { + get { return pbc::Lists.AsReadOnly(repeatedNestedEnum_); } + } + public int RepeatedNestedEnumCount { + get { return repeatedNestedEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) { + return repeatedNestedEnum_[index]; + } + + public const int RepeatedForeignEnumFieldNumber = 52; + private pbc::PopsicleList repeatedForeignEnum_ = new pbc::PopsicleList(); + public scg::IList RepeatedForeignEnumList { + get { return pbc::Lists.AsReadOnly(repeatedForeignEnum_); } + } + public int RepeatedForeignEnumCount { + get { return repeatedForeignEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) { + return repeatedForeignEnum_[index]; + } + + public const int RepeatedImportEnumFieldNumber = 53; + private pbc::PopsicleList repeatedImportEnum_ = new pbc::PopsicleList(); + public scg::IList RepeatedImportEnumList { + get { return pbc::Lists.AsReadOnly(repeatedImportEnum_); } + } + public int RepeatedImportEnumCount { + get { return repeatedImportEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum GetRepeatedImportEnum(int index) { + return repeatedImportEnum_[index]; + } + + public const int RepeatedStringPieceFieldNumber = 54; + private pbc::PopsicleList repeatedStringPiece_ = new pbc::PopsicleList(); + public scg::IList RepeatedStringPieceList { + get { return pbc::Lists.AsReadOnly(repeatedStringPiece_); } + } + public int RepeatedStringPieceCount { + get { return repeatedStringPiece_.Count; } + } + public string GetRepeatedStringPiece(int index) { + return repeatedStringPiece_[index]; + } + + public const int RepeatedCordFieldNumber = 55; + private pbc::PopsicleList repeatedCord_ = new pbc::PopsicleList(); + public scg::IList RepeatedCordList { + get { return pbc::Lists.AsReadOnly(repeatedCord_); } + } + public int RepeatedCordCount { + get { return repeatedCord_.Count; } + } + public string GetRepeatedCord(int index) { + return repeatedCord_[index]; + } + + public const int RepeatedLazyMessageFieldNumber = 57; + private pbc::PopsicleList repeatedLazyMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedLazyMessageList { + get { return repeatedLazyMessage_; } + } + public int RepeatedLazyMessageCount { + get { return repeatedLazyMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedLazyMessage(int index) { + return repeatedLazyMessage_[index]; + } + + public const int DefaultInt32FieldNumber = 61; + private bool hasDefaultInt32; + private int defaultInt32_ = 41; + public bool HasDefaultInt32 { + get { return hasDefaultInt32; } + } + public int DefaultInt32 { + get { return defaultInt32_; } + } + + public const int DefaultInt64FieldNumber = 62; + private bool hasDefaultInt64; + private long defaultInt64_ = 42L; + public bool HasDefaultInt64 { + get { return hasDefaultInt64; } + } + public long DefaultInt64 { + get { return defaultInt64_; } + } + + public const int DefaultUint32FieldNumber = 63; + private bool hasDefaultUint32; + private uint defaultUint32_ = 43; + public bool HasDefaultUint32 { + get { return hasDefaultUint32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultUint32 { + get { return defaultUint32_; } + } + + public const int DefaultUint64FieldNumber = 64; + private bool hasDefaultUint64; + private ulong defaultUint64_ = 44UL; + public bool HasDefaultUint64 { + get { return hasDefaultUint64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultUint64 { + get { return defaultUint64_; } + } + + public const int DefaultSint32FieldNumber = 65; + private bool hasDefaultSint32; + private int defaultSint32_ = -45; + public bool HasDefaultSint32 { + get { return hasDefaultSint32; } + } + public int DefaultSint32 { + get { return defaultSint32_; } + } + + public const int DefaultSint64FieldNumber = 66; + private bool hasDefaultSint64; + private long defaultSint64_ = 46L; + public bool HasDefaultSint64 { + get { return hasDefaultSint64; } + } + public long DefaultSint64 { + get { return defaultSint64_; } + } + + public const int DefaultFixed32FieldNumber = 67; + private bool hasDefaultFixed32; + private uint defaultFixed32_ = 47; + public bool HasDefaultFixed32 { + get { return hasDefaultFixed32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultFixed32 { + get { return defaultFixed32_; } + } + + public const int DefaultFixed64FieldNumber = 68; + private bool hasDefaultFixed64; + private ulong defaultFixed64_ = 48UL; + public bool HasDefaultFixed64 { + get { return hasDefaultFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultFixed64 { + get { return defaultFixed64_; } + } + + public const int DefaultSfixed32FieldNumber = 69; + private bool hasDefaultSfixed32; + private int defaultSfixed32_ = 49; + public bool HasDefaultSfixed32 { + get { return hasDefaultSfixed32; } + } + public int DefaultSfixed32 { + get { return defaultSfixed32_; } + } + + public const int DefaultSfixed64FieldNumber = 70; + private bool hasDefaultSfixed64; + private long defaultSfixed64_ = -50L; + public bool HasDefaultSfixed64 { + get { return hasDefaultSfixed64; } + } + public long DefaultSfixed64 { + get { return defaultSfixed64_; } + } + + public const int DefaultFloatFieldNumber = 71; + private bool hasDefaultFloat; + private float defaultFloat_ = 51.5F; + public bool HasDefaultFloat { + get { return hasDefaultFloat; } + } + public float DefaultFloat { + get { return defaultFloat_; } + } + + public const int DefaultDoubleFieldNumber = 72; + private bool hasDefaultDouble; + private double defaultDouble_ = 52000D; + public bool HasDefaultDouble { + get { return hasDefaultDouble; } + } + public double DefaultDouble { + get { return defaultDouble_; } + } + + public const int DefaultBoolFieldNumber = 73; + private bool hasDefaultBool; + private bool defaultBool_ = true; + public bool HasDefaultBool { + get { return hasDefaultBool; } + } + public bool DefaultBool { + get { return defaultBool_; } + } + + public const int DefaultStringFieldNumber = 74; + private bool hasDefaultString; + private string defaultString_ = "hello"; + public bool HasDefaultString { + get { return hasDefaultString; } + } + public string DefaultString { + get { return defaultString_; } + } + + public const int DefaultBytesFieldNumber = 75; + private bool hasDefaultBytes; + private pb::ByteString defaultBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor.Fields[65].DefaultValue; + public bool HasDefaultBytes { + get { return hasDefaultBytes; } + } + public pb::ByteString DefaultBytes { + get { return defaultBytes_; } + } + + public const int DefaultNestedEnumFieldNumber = 81; + private bool hasDefaultNestedEnum; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.BAR; + public bool HasDefaultNestedEnum { + get { return hasDefaultNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum DefaultNestedEnum { + get { return defaultNestedEnum_; } + } + + public const int DefaultForeignEnumFieldNumber = 82; + private bool hasDefaultForeignEnum; + private global::Google.ProtocolBuffers.TestProtos.ForeignEnum defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_BAR; + public bool HasDefaultForeignEnum { + get { return hasDefaultForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum DefaultForeignEnum { + get { return defaultForeignEnum_; } + } + + public const int DefaultImportEnumFieldNumber = 83; + private bool hasDefaultImportEnum; + private global::Google.ProtocolBuffers.TestProtos.ImportEnum defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_BAR; + public bool HasDefaultImportEnum { + get { return hasDefaultImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum DefaultImportEnum { + get { return defaultImportEnum_; } + } + + public const int DefaultStringPieceFieldNumber = 84; + private bool hasDefaultStringPiece; + private string defaultStringPiece_ = "abc"; + public bool HasDefaultStringPiece { + get { return hasDefaultStringPiece; } + } + public string DefaultStringPiece { + get { return defaultStringPiece_; } + } + + public const int DefaultCordFieldNumber = 85; + private bool hasDefaultCord; + private string defaultCord_ = "123"; + public bool HasDefaultCord { + get { return hasDefaultCord; } + } + public string DefaultCord { + get { return defaultCord_; } + } + + public const int OneofUint32FieldNumber = 111; + private bool hasOneofUint32; + private uint oneofUint32_; + public bool HasOneofUint32 { + get { return hasOneofUint32; } + } + [global::System.CLSCompliant(false)] + public uint OneofUint32 { + get { return oneofUint32_; } + } + + public const int OneofNestedMessageFieldNumber = 112; + private bool hasOneofNestedMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage oneofNestedMessage_; + public bool HasOneofNestedMessage { + get { return hasOneofNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OneofNestedMessage { + get { return oneofNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } + } + + public const int OneofStringFieldNumber = 113; + private bool hasOneofString; + private string oneofString_ = ""; + public bool HasOneofString { + get { return hasOneofString; } + } + public string OneofString { + get { return oneofString_; } + } + + public const int OneofBytesFieldNumber = 114; + private bool hasOneofBytes; + private pb::ByteString oneofBytes_ = pb::ByteString.Empty; + public bool HasOneofBytes { + get { return hasOneofBytes; } + } + public pb::ByteString OneofBytes { + get { return oneofBytes_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testAllTypesFieldNames; + if (hasOptionalInt32) { + output.WriteInt32(1, field_names[35], OptionalInt32); + } + if (hasOptionalInt64) { + output.WriteInt64(2, field_names[36], OptionalInt64); + } + if (hasOptionalUint32) { + output.WriteUInt32(3, field_names[47], OptionalUint32); + } + if (hasOptionalUint64) { + output.WriteUInt64(4, field_names[48], OptionalUint64); + } + if (hasOptionalSint32) { + output.WriteSInt32(5, field_names[43], OptionalSint32); + } + if (hasOptionalSint64) { + output.WriteSInt64(6, field_names[44], OptionalSint64); + } + if (hasOptionalFixed32) { + output.WriteFixed32(7, field_names[28], OptionalFixed32); + } + if (hasOptionalFixed64) { + output.WriteFixed64(8, field_names[29], OptionalFixed64); + } + if (hasOptionalSfixed32) { + output.WriteSFixed32(9, field_names[41], OptionalSfixed32); + } + if (hasOptionalSfixed64) { + output.WriteSFixed64(10, field_names[42], OptionalSfixed64); + } + if (hasOptionalFloat) { + output.WriteFloat(11, field_names[30], OptionalFloat); + } + if (hasOptionalDouble) { + output.WriteDouble(12, field_names[27], OptionalDouble); + } + if (hasOptionalBool) { + output.WriteBool(13, field_names[24], OptionalBool); + } + if (hasOptionalString) { + output.WriteString(14, field_names[45], OptionalString); + } + if (hasOptionalBytes) { + output.WriteBytes(15, field_names[25], OptionalBytes); + } + if (hasOptionalGroup) { + output.WriteGroup(16, field_names[49], OptionalGroup); + } + if (hasOptionalNestedMessage) { + output.WriteMessage(18, field_names[39], OptionalNestedMessage); + } + if (hasOptionalForeignMessage) { + output.WriteMessage(19, field_names[32], OptionalForeignMessage); + } + if (hasOptionalImportMessage) { + output.WriteMessage(20, field_names[34], OptionalImportMessage); + } + if (hasOptionalNestedEnum) { + output.WriteEnum(21, field_names[38], (int) OptionalNestedEnum, OptionalNestedEnum); + } + if (hasOptionalForeignEnum) { + output.WriteEnum(22, field_names[31], (int) OptionalForeignEnum, OptionalForeignEnum); + } + if (hasOptionalImportEnum) { + output.WriteEnum(23, field_names[33], (int) OptionalImportEnum, OptionalImportEnum); + } + if (hasOptionalStringPiece) { + output.WriteString(24, field_names[46], OptionalStringPiece); + } + if (hasOptionalCord) { + output.WriteString(25, field_names[26], OptionalCord); + } + if (hasOptionalPublicImportMessage) { + output.WriteMessage(26, field_names[40], OptionalPublicImportMessage); + } + if (hasOptionalLazyMessage) { + output.WriteMessage(27, field_names[37], OptionalLazyMessage); + } + if (repeatedInt32_.Count > 0) { + output.WriteInt32Array(31, field_names[61], repeatedInt32_); + } + if (repeatedInt64_.Count > 0) { + output.WriteInt64Array(32, field_names[62], repeatedInt64_); + } + if (repeatedUint32_.Count > 0) { + output.WriteUInt32Array(33, field_names[72], repeatedUint32_); + } + if (repeatedUint64_.Count > 0) { + output.WriteUInt64Array(34, field_names[73], repeatedUint64_); + } + if (repeatedSint32_.Count > 0) { + output.WriteSInt32Array(35, field_names[68], repeatedSint32_); + } + if (repeatedSint64_.Count > 0) { + output.WriteSInt64Array(36, field_names[69], repeatedSint64_); + } + if (repeatedFixed32_.Count > 0) { + output.WriteFixed32Array(37, field_names[54], repeatedFixed32_); + } + if (repeatedFixed64_.Count > 0) { + output.WriteFixed64Array(38, field_names[55], repeatedFixed64_); + } + if (repeatedSfixed32_.Count > 0) { + output.WriteSFixed32Array(39, field_names[66], repeatedSfixed32_); + } + if (repeatedSfixed64_.Count > 0) { + output.WriteSFixed64Array(40, field_names[67], repeatedSfixed64_); + } + if (repeatedFloat_.Count > 0) { + output.WriteFloatArray(41, field_names[56], repeatedFloat_); + } + if (repeatedDouble_.Count > 0) { + output.WriteDoubleArray(42, field_names[53], repeatedDouble_); + } + if (repeatedBool_.Count > 0) { + output.WriteBoolArray(43, field_names[50], repeatedBool_); + } + if (repeatedString_.Count > 0) { + output.WriteStringArray(44, field_names[70], repeatedString_); + } + if (repeatedBytes_.Count > 0) { + output.WriteBytesArray(45, field_names[51], repeatedBytes_); + } + if (repeatedGroup_.Count > 0) { + output.WriteGroupArray(46, field_names[74], repeatedGroup_); + } + if (repeatedNestedMessage_.Count > 0) { + output.WriteMessageArray(48, field_names[65], repeatedNestedMessage_); + } + if (repeatedForeignMessage_.Count > 0) { + output.WriteMessageArray(49, field_names[58], repeatedForeignMessage_); + } + if (repeatedImportMessage_.Count > 0) { + output.WriteMessageArray(50, field_names[60], repeatedImportMessage_); + } + if (repeatedNestedEnum_.Count > 0) { + output.WriteEnumArray(51, field_names[64], repeatedNestedEnum_); + } + if (repeatedForeignEnum_.Count > 0) { + output.WriteEnumArray(52, field_names[57], repeatedForeignEnum_); + } + if (repeatedImportEnum_.Count > 0) { + output.WriteEnumArray(53, field_names[59], repeatedImportEnum_); + } + if (repeatedStringPiece_.Count > 0) { + output.WriteStringArray(54, field_names[71], repeatedStringPiece_); + } + if (repeatedCord_.Count > 0) { + output.WriteStringArray(55, field_names[52], repeatedCord_); + } + if (repeatedLazyMessage_.Count > 0) { + output.WriteMessageArray(57, field_names[63], repeatedLazyMessage_); + } + if (hasDefaultInt32) { + output.WriteInt32(61, field_names[9], DefaultInt32); + } + if (hasDefaultInt64) { + output.WriteInt64(62, field_names[10], DefaultInt64); + } + if (hasDefaultUint32) { + output.WriteUInt32(63, field_names[18], DefaultUint32); + } + if (hasDefaultUint64) { + output.WriteUInt64(64, field_names[19], DefaultUint64); + } + if (hasDefaultSint32) { + output.WriteSInt32(65, field_names[14], DefaultSint32); + } + if (hasDefaultSint64) { + output.WriteSInt64(66, field_names[15], DefaultSint64); + } + if (hasDefaultFixed32) { + output.WriteFixed32(67, field_names[4], DefaultFixed32); + } + if (hasDefaultFixed64) { + output.WriteFixed64(68, field_names[5], DefaultFixed64); + } + if (hasDefaultSfixed32) { + output.WriteSFixed32(69, field_names[12], DefaultSfixed32); + } + if (hasDefaultSfixed64) { + output.WriteSFixed64(70, field_names[13], DefaultSfixed64); + } + if (hasDefaultFloat) { + output.WriteFloat(71, field_names[6], DefaultFloat); + } + if (hasDefaultDouble) { + output.WriteDouble(72, field_names[3], DefaultDouble); + } + if (hasDefaultBool) { + output.WriteBool(73, field_names[0], DefaultBool); + } + if (hasDefaultString) { + output.WriteString(74, field_names[16], DefaultString); + } + if (hasDefaultBytes) { + output.WriteBytes(75, field_names[1], DefaultBytes); + } + if (hasDefaultNestedEnum) { + output.WriteEnum(81, field_names[11], (int) DefaultNestedEnum, DefaultNestedEnum); + } + if (hasDefaultForeignEnum) { + output.WriteEnum(82, field_names[7], (int) DefaultForeignEnum, DefaultForeignEnum); + } + if (hasDefaultImportEnum) { + output.WriteEnum(83, field_names[8], (int) DefaultImportEnum, DefaultImportEnum); + } + if (hasDefaultStringPiece) { + output.WriteString(84, field_names[17], DefaultStringPiece); + } + if (hasDefaultCord) { + output.WriteString(85, field_names[2], DefaultCord); + } + if (hasOneofUint32) { + output.WriteUInt32(111, field_names[23], OneofUint32); + } + if (hasOneofNestedMessage) { + output.WriteMessage(112, field_names[21], OneofNestedMessage); + } + if (hasOneofString) { + output.WriteString(113, field_names[22], OneofString); + } + if (hasOneofBytes) { + output.WriteBytes(114, field_names[20], OneofBytes); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOptionalInt32) { + size += pb::CodedOutputStream.ComputeInt32Size(1, OptionalInt32); + } + if (hasOptionalInt64) { + size += pb::CodedOutputStream.ComputeInt64Size(2, OptionalInt64); + } + if (hasOptionalUint32) { + size += pb::CodedOutputStream.ComputeUInt32Size(3, OptionalUint32); + } + if (hasOptionalUint64) { + size += pb::CodedOutputStream.ComputeUInt64Size(4, OptionalUint64); + } + if (hasOptionalSint32) { + size += pb::CodedOutputStream.ComputeSInt32Size(5, OptionalSint32); + } + if (hasOptionalSint64) { + size += pb::CodedOutputStream.ComputeSInt64Size(6, OptionalSint64); + } + if (hasOptionalFixed32) { + size += pb::CodedOutputStream.ComputeFixed32Size(7, OptionalFixed32); + } + if (hasOptionalFixed64) { + size += pb::CodedOutputStream.ComputeFixed64Size(8, OptionalFixed64); + } + if (hasOptionalSfixed32) { + size += pb::CodedOutputStream.ComputeSFixed32Size(9, OptionalSfixed32); + } + if (hasOptionalSfixed64) { + size += pb::CodedOutputStream.ComputeSFixed64Size(10, OptionalSfixed64); + } + if (hasOptionalFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(11, OptionalFloat); + } + if (hasOptionalDouble) { + size += pb::CodedOutputStream.ComputeDoubleSize(12, OptionalDouble); + } + if (hasOptionalBool) { + size += pb::CodedOutputStream.ComputeBoolSize(13, OptionalBool); + } + if (hasOptionalString) { + size += pb::CodedOutputStream.ComputeStringSize(14, OptionalString); + } + if (hasOptionalBytes) { + size += pb::CodedOutputStream.ComputeBytesSize(15, OptionalBytes); + } + if (hasOptionalGroup) { + size += pb::CodedOutputStream.ComputeGroupSize(16, OptionalGroup); + } + if (hasOptionalNestedMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(18, OptionalNestedMessage); + } + if (hasOptionalForeignMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(19, OptionalForeignMessage); + } + if (hasOptionalImportMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(20, OptionalImportMessage); + } + if (hasOptionalNestedEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(21, (int) OptionalNestedEnum); + } + if (hasOptionalForeignEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(22, (int) OptionalForeignEnum); + } + if (hasOptionalImportEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(23, (int) OptionalImportEnum); + } + if (hasOptionalStringPiece) { + size += pb::CodedOutputStream.ComputeStringSize(24, OptionalStringPiece); + } + if (hasOptionalCord) { + size += pb::CodedOutputStream.ComputeStringSize(25, OptionalCord); + } + if (hasOptionalPublicImportMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(26, OptionalPublicImportMessage); + } + if (hasOptionalLazyMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(27, OptionalLazyMessage); + } + { + int dataSize = 0; + foreach (int element in RepeatedInt32List) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedInt32_.Count; + } + { + int dataSize = 0; + foreach (long element in RepeatedInt64List) { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedInt64_.Count; + } + { + int dataSize = 0; + foreach (uint element in RepeatedUint32List) { + dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedUint32_.Count; + } + { + int dataSize = 0; + foreach (ulong element in RepeatedUint64List) { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedUint64_.Count; + } + { + int dataSize = 0; + foreach (int element in RepeatedSint32List) { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedSint32_.Count; + } + { + int dataSize = 0; + foreach (long element in RepeatedSint64List) { + dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedSint64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedFixed32_.Count; + size += dataSize; + size += 2 * repeatedFixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedFixed64_.Count; + size += dataSize; + size += 2 * repeatedFixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedSfixed32_.Count; + size += dataSize; + size += 2 * repeatedSfixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedSfixed64_.Count; + size += dataSize; + size += 2 * repeatedSfixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedFloat_.Count; + size += dataSize; + size += 2 * repeatedFloat_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedDouble_.Count; + size += dataSize; + size += 2 * repeatedDouble_.Count; + } + { + int dataSize = 0; + dataSize = 1 * repeatedBool_.Count; + size += dataSize; + size += 2 * repeatedBool_.Count; + } + { + int dataSize = 0; + foreach (string element in RepeatedStringList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedString_.Count; + } + { + int dataSize = 0; + foreach (pb::ByteString element in RepeatedBytesList) { + dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedBytes_.Count; + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup element in RepeatedGroupList) { + size += pb::CodedOutputStream.ComputeGroupSize(46, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage element in RepeatedNestedMessageList) { + size += pb::CodedOutputStream.ComputeMessageSize(48, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedForeignMessageList) { + size += pb::CodedOutputStream.ComputeMessageSize(49, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.ImportMessage element in RepeatedImportMessageList) { + size += pb::CodedOutputStream.ComputeMessageSize(50, element); + } + { + int dataSize = 0; + if (repeatedNestedEnum_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum element in repeatedNestedEnum_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 2 * repeatedNestedEnum_.Count; + } + } + { + int dataSize = 0; + if (repeatedForeignEnum_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedForeignEnum_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 2 * repeatedForeignEnum_.Count; + } + } + { + int dataSize = 0; + if (repeatedImportEnum_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.ImportEnum element in repeatedImportEnum_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 2 * repeatedImportEnum_.Count; + } + } + { + int dataSize = 0; + foreach (string element in RepeatedStringPieceList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedStringPiece_.Count; + } + { + int dataSize = 0; + foreach (string element in RepeatedCordList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedCord_.Count; + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage element in RepeatedLazyMessageList) { + size += pb::CodedOutputStream.ComputeMessageSize(57, element); + } + if (hasDefaultInt32) { + size += pb::CodedOutputStream.ComputeInt32Size(61, DefaultInt32); + } + if (hasDefaultInt64) { + size += pb::CodedOutputStream.ComputeInt64Size(62, DefaultInt64); + } + if (hasDefaultUint32) { + size += pb::CodedOutputStream.ComputeUInt32Size(63, DefaultUint32); + } + if (hasDefaultUint64) { + size += pb::CodedOutputStream.ComputeUInt64Size(64, DefaultUint64); + } + if (hasDefaultSint32) { + size += pb::CodedOutputStream.ComputeSInt32Size(65, DefaultSint32); + } + if (hasDefaultSint64) { + size += pb::CodedOutputStream.ComputeSInt64Size(66, DefaultSint64); + } + if (hasDefaultFixed32) { + size += pb::CodedOutputStream.ComputeFixed32Size(67, DefaultFixed32); + } + if (hasDefaultFixed64) { + size += pb::CodedOutputStream.ComputeFixed64Size(68, DefaultFixed64); + } + if (hasDefaultSfixed32) { + size += pb::CodedOutputStream.ComputeSFixed32Size(69, DefaultSfixed32); + } + if (hasDefaultSfixed64) { + size += pb::CodedOutputStream.ComputeSFixed64Size(70, DefaultSfixed64); + } + if (hasDefaultFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(71, DefaultFloat); + } + if (hasDefaultDouble) { + size += pb::CodedOutputStream.ComputeDoubleSize(72, DefaultDouble); + } + if (hasDefaultBool) { + size += pb::CodedOutputStream.ComputeBoolSize(73, DefaultBool); + } + if (hasDefaultString) { + size += pb::CodedOutputStream.ComputeStringSize(74, DefaultString); + } + if (hasDefaultBytes) { + size += pb::CodedOutputStream.ComputeBytesSize(75, DefaultBytes); + } + if (hasDefaultNestedEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(81, (int) DefaultNestedEnum); + } + if (hasDefaultForeignEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(82, (int) DefaultForeignEnum); + } + if (hasDefaultImportEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(83, (int) DefaultImportEnum); + } + if (hasDefaultStringPiece) { + size += pb::CodedOutputStream.ComputeStringSize(84, DefaultStringPiece); + } + if (hasDefaultCord) { + size += pb::CodedOutputStream.ComputeStringSize(85, DefaultCord); + } + if (hasOneofUint32) { + size += pb::CodedOutputStream.ComputeUInt32Size(111, OneofUint32); + } + if (hasOneofNestedMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(112, OneofNestedMessage); + } + if (hasOneofString) { + size += pb::CodedOutputStream.ComputeStringSize(113, OneofString); + } + if (hasOneofBytes) { + size += pb::CodedOutputStream.ComputeBytesSize(114, OneofBytes); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestAllTypes ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllTypes ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllTypes ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestAllTypes ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestAllTypes MakeReadOnly() { + repeatedInt32_.MakeReadOnly(); + repeatedInt64_.MakeReadOnly(); + repeatedUint32_.MakeReadOnly(); + repeatedUint64_.MakeReadOnly(); + repeatedSint32_.MakeReadOnly(); + repeatedSint64_.MakeReadOnly(); + repeatedFixed32_.MakeReadOnly(); + repeatedFixed64_.MakeReadOnly(); + repeatedSfixed32_.MakeReadOnly(); + repeatedSfixed64_.MakeReadOnly(); + repeatedFloat_.MakeReadOnly(); + repeatedDouble_.MakeReadOnly(); + repeatedBool_.MakeReadOnly(); + repeatedString_.MakeReadOnly(); + repeatedBytes_.MakeReadOnly(); + repeatedGroup_.MakeReadOnly(); + repeatedNestedMessage_.MakeReadOnly(); + repeatedForeignMessage_.MakeReadOnly(); + repeatedImportMessage_.MakeReadOnly(); + repeatedNestedEnum_.MakeReadOnly(); + repeatedForeignEnum_.MakeReadOnly(); + repeatedImportEnum_.MakeReadOnly(); + repeatedStringPiece_.MakeReadOnly(); + repeatedCord_.MakeReadOnly(); + repeatedLazyMessage_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestAllTypes prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestAllTypes cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestAllTypes result; + + private TestAllTypes PrepareBuilder() { + if (resultIsReadOnly) { + TestAllTypes original = result; + result = new TestAllTypes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestAllTypes MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor; } + } + + public override TestAllTypes DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override TestAllTypes BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestAllTypes) { + return MergeFrom((TestAllTypes) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestAllTypes other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOptionalInt32) { + OptionalInt32 = other.OptionalInt32; + } + if (other.HasOptionalInt64) { + OptionalInt64 = other.OptionalInt64; + } + if (other.HasOptionalUint32) { + OptionalUint32 = other.OptionalUint32; + } + if (other.HasOptionalUint64) { + OptionalUint64 = other.OptionalUint64; + } + if (other.HasOptionalSint32) { + OptionalSint32 = other.OptionalSint32; + } + if (other.HasOptionalSint64) { + OptionalSint64 = other.OptionalSint64; + } + if (other.HasOptionalFixed32) { + OptionalFixed32 = other.OptionalFixed32; + } + if (other.HasOptionalFixed64) { + OptionalFixed64 = other.OptionalFixed64; + } + if (other.HasOptionalSfixed32) { + OptionalSfixed32 = other.OptionalSfixed32; + } + if (other.HasOptionalSfixed64) { + OptionalSfixed64 = other.OptionalSfixed64; + } + if (other.HasOptionalFloat) { + OptionalFloat = other.OptionalFloat; + } + if (other.HasOptionalDouble) { + OptionalDouble = other.OptionalDouble; + } + if (other.HasOptionalBool) { + OptionalBool = other.OptionalBool; + } + if (other.HasOptionalString) { + OptionalString = other.OptionalString; + } + if (other.HasOptionalBytes) { + OptionalBytes = other.OptionalBytes; + } + if (other.HasOptionalGroup) { + MergeOptionalGroup(other.OptionalGroup); + } + if (other.HasOptionalNestedMessage) { + MergeOptionalNestedMessage(other.OptionalNestedMessage); + } + if (other.HasOptionalForeignMessage) { + MergeOptionalForeignMessage(other.OptionalForeignMessage); + } + if (other.HasOptionalImportMessage) { + MergeOptionalImportMessage(other.OptionalImportMessage); + } + if (other.HasOptionalNestedEnum) { + OptionalNestedEnum = other.OptionalNestedEnum; + } + if (other.HasOptionalForeignEnum) { + OptionalForeignEnum = other.OptionalForeignEnum; + } + if (other.HasOptionalImportEnum) { + OptionalImportEnum = other.OptionalImportEnum; + } + if (other.HasOptionalStringPiece) { + OptionalStringPiece = other.OptionalStringPiece; + } + if (other.HasOptionalCord) { + OptionalCord = other.OptionalCord; + } + if (other.HasOptionalPublicImportMessage) { + MergeOptionalPublicImportMessage(other.OptionalPublicImportMessage); + } + if (other.HasOptionalLazyMessage) { + MergeOptionalLazyMessage(other.OptionalLazyMessage); + } + if (other.repeatedInt32_.Count != 0) { + result.repeatedInt32_.Add(other.repeatedInt32_); + } + if (other.repeatedInt64_.Count != 0) { + result.repeatedInt64_.Add(other.repeatedInt64_); + } + if (other.repeatedUint32_.Count != 0) { + result.repeatedUint32_.Add(other.repeatedUint32_); + } + if (other.repeatedUint64_.Count != 0) { + result.repeatedUint64_.Add(other.repeatedUint64_); + } + if (other.repeatedSint32_.Count != 0) { + result.repeatedSint32_.Add(other.repeatedSint32_); + } + if (other.repeatedSint64_.Count != 0) { + result.repeatedSint64_.Add(other.repeatedSint64_); + } + if (other.repeatedFixed32_.Count != 0) { + result.repeatedFixed32_.Add(other.repeatedFixed32_); + } + if (other.repeatedFixed64_.Count != 0) { + result.repeatedFixed64_.Add(other.repeatedFixed64_); + } + if (other.repeatedSfixed32_.Count != 0) { + result.repeatedSfixed32_.Add(other.repeatedSfixed32_); + } + if (other.repeatedSfixed64_.Count != 0) { + result.repeatedSfixed64_.Add(other.repeatedSfixed64_); + } + if (other.repeatedFloat_.Count != 0) { + result.repeatedFloat_.Add(other.repeatedFloat_); + } + if (other.repeatedDouble_.Count != 0) { + result.repeatedDouble_.Add(other.repeatedDouble_); + } + if (other.repeatedBool_.Count != 0) { + result.repeatedBool_.Add(other.repeatedBool_); + } + if (other.repeatedString_.Count != 0) { + result.repeatedString_.Add(other.repeatedString_); + } + if (other.repeatedBytes_.Count != 0) { + result.repeatedBytes_.Add(other.repeatedBytes_); + } + if (other.repeatedGroup_.Count != 0) { + result.repeatedGroup_.Add(other.repeatedGroup_); + } + if (other.repeatedNestedMessage_.Count != 0) { + result.repeatedNestedMessage_.Add(other.repeatedNestedMessage_); + } + if (other.repeatedForeignMessage_.Count != 0) { + result.repeatedForeignMessage_.Add(other.repeatedForeignMessage_); + } + if (other.repeatedImportMessage_.Count != 0) { + result.repeatedImportMessage_.Add(other.repeatedImportMessage_); + } + if (other.repeatedNestedEnum_.Count != 0) { + result.repeatedNestedEnum_.Add(other.repeatedNestedEnum_); + } + if (other.repeatedForeignEnum_.Count != 0) { + result.repeatedForeignEnum_.Add(other.repeatedForeignEnum_); + } + if (other.repeatedImportEnum_.Count != 0) { + result.repeatedImportEnum_.Add(other.repeatedImportEnum_); + } + if (other.repeatedStringPiece_.Count != 0) { + result.repeatedStringPiece_.Add(other.repeatedStringPiece_); + } + if (other.repeatedCord_.Count != 0) { + result.repeatedCord_.Add(other.repeatedCord_); + } + if (other.repeatedLazyMessage_.Count != 0) { + result.repeatedLazyMessage_.Add(other.repeatedLazyMessage_); + } + if (other.HasDefaultInt32) { + DefaultInt32 = other.DefaultInt32; + } + if (other.HasDefaultInt64) { + DefaultInt64 = other.DefaultInt64; + } + if (other.HasDefaultUint32) { + DefaultUint32 = other.DefaultUint32; + } + if (other.HasDefaultUint64) { + DefaultUint64 = other.DefaultUint64; + } + if (other.HasDefaultSint32) { + DefaultSint32 = other.DefaultSint32; + } + if (other.HasDefaultSint64) { + DefaultSint64 = other.DefaultSint64; + } + if (other.HasDefaultFixed32) { + DefaultFixed32 = other.DefaultFixed32; + } + if (other.HasDefaultFixed64) { + DefaultFixed64 = other.DefaultFixed64; + } + if (other.HasDefaultSfixed32) { + DefaultSfixed32 = other.DefaultSfixed32; + } + if (other.HasDefaultSfixed64) { + DefaultSfixed64 = other.DefaultSfixed64; + } + if (other.HasDefaultFloat) { + DefaultFloat = other.DefaultFloat; + } + if (other.HasDefaultDouble) { + DefaultDouble = other.DefaultDouble; + } + if (other.HasDefaultBool) { + DefaultBool = other.DefaultBool; + } + if (other.HasDefaultString) { + DefaultString = other.DefaultString; + } + if (other.HasDefaultBytes) { + DefaultBytes = other.DefaultBytes; + } + if (other.HasDefaultNestedEnum) { + DefaultNestedEnum = other.DefaultNestedEnum; + } + if (other.HasDefaultForeignEnum) { + DefaultForeignEnum = other.DefaultForeignEnum; + } + if (other.HasDefaultImportEnum) { + DefaultImportEnum = other.DefaultImportEnum; + } + if (other.HasDefaultStringPiece) { + DefaultStringPiece = other.DefaultStringPiece; + } + if (other.HasDefaultCord) { + DefaultCord = other.DefaultCord; + } + if (other.HasOneofUint32) { + OneofUint32 = other.OneofUint32; + } + if (other.HasOneofNestedMessage) { + MergeOneofNestedMessage(other.OneofNestedMessage); + } + if (other.HasOneofString) { + OneofString = other.OneofString; + } + if (other.HasOneofBytes) { + OneofBytes = other.OneofBytes; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testAllTypesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testAllTypesFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); + break; + } + case 16: { + result.hasOptionalInt64 = input.ReadInt64(ref result.optionalInt64_); + break; + } + case 24: { + result.hasOptionalUint32 = input.ReadUInt32(ref result.optionalUint32_); + break; + } + case 32: { + result.hasOptionalUint64 = input.ReadUInt64(ref result.optionalUint64_); + break; + } + case 40: { + result.hasOptionalSint32 = input.ReadSInt32(ref result.optionalSint32_); + break; + } + case 48: { + result.hasOptionalSint64 = input.ReadSInt64(ref result.optionalSint64_); + break; + } + case 61: { + result.hasOptionalFixed32 = input.ReadFixed32(ref result.optionalFixed32_); + break; + } + case 65: { + result.hasOptionalFixed64 = input.ReadFixed64(ref result.optionalFixed64_); + break; + } + case 77: { + result.hasOptionalSfixed32 = input.ReadSFixed32(ref result.optionalSfixed32_); + break; + } + case 81: { + result.hasOptionalSfixed64 = input.ReadSFixed64(ref result.optionalSfixed64_); + break; + } + case 93: { + result.hasOptionalFloat = input.ReadFloat(ref result.optionalFloat_); + break; + } + case 97: { + result.hasOptionalDouble = input.ReadDouble(ref result.optionalDouble_); + break; + } + case 104: { + result.hasOptionalBool = input.ReadBool(ref result.optionalBool_); + break; + } + case 114: { + result.hasOptionalString = input.ReadString(ref result.optionalString_); + break; + } + case 122: { + result.hasOptionalBytes = input.ReadBytes(ref result.optionalBytes_); + break; + } + case 131: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.CreateBuilder(); + if (result.hasOptionalGroup) { + subBuilder.MergeFrom(OptionalGroup); + } + input.ReadGroup(16, subBuilder, extensionRegistry); + OptionalGroup = subBuilder.BuildPartial(); + break; + } + case 146: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); + if (result.hasOptionalNestedMessage) { + subBuilder.MergeFrom(OptionalNestedMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalNestedMessage = subBuilder.BuildPartial(); + break; + } + case 154: { + global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); + if (result.hasOptionalForeignMessage) { + subBuilder.MergeFrom(OptionalForeignMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalForeignMessage = subBuilder.BuildPartial(); + break; + } + case 162: { + global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder(); + if (result.hasOptionalImportMessage) { + subBuilder.MergeFrom(OptionalImportMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalImportMessage = subBuilder.BuildPartial(); + break; + } + case 168: { + object unknown; + if(input.ReadEnum(ref result.optionalNestedEnum_, out unknown)) { + result.hasOptionalNestedEnum = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(21, (ulong)(int)unknown); + } + break; + } + case 176: { + object unknown; + if(input.ReadEnum(ref result.optionalForeignEnum_, out unknown)) { + result.hasOptionalForeignEnum = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(22, (ulong)(int)unknown); + } + break; + } + case 184: { + object unknown; + if(input.ReadEnum(ref result.optionalImportEnum_, out unknown)) { + result.hasOptionalImportEnum = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(23, (ulong)(int)unknown); + } + break; + } + case 194: { + result.hasOptionalStringPiece = input.ReadString(ref result.optionalStringPiece_); + break; + } + case 202: { + result.hasOptionalCord = input.ReadString(ref result.optionalCord_); + break; + } + case 210: { + global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.CreateBuilder(); + if (result.hasOptionalPublicImportMessage) { + subBuilder.MergeFrom(OptionalPublicImportMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalPublicImportMessage = subBuilder.BuildPartial(); + break; + } + case 218: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); + if (result.hasOptionalLazyMessage) { + subBuilder.MergeFrom(OptionalLazyMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalLazyMessage = subBuilder.BuildPartial(); + break; + } + case 250: + case 248: { + input.ReadInt32Array(tag, field_name, result.repeatedInt32_); + break; + } + case 258: + case 256: { + input.ReadInt64Array(tag, field_name, result.repeatedInt64_); + break; + } + case 266: + case 264: { + input.ReadUInt32Array(tag, field_name, result.repeatedUint32_); + break; + } + case 274: + case 272: { + input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); + break; + } + case 282: + case 280: { + input.ReadSInt32Array(tag, field_name, result.repeatedSint32_); + break; + } + case 290: + case 288: { + input.ReadSInt64Array(tag, field_name, result.repeatedSint64_); + break; + } + case 298: + case 301: { + input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); + break; + } + case 306: + case 305: { + input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); + break; + } + case 314: + case 317: { + input.ReadSFixed32Array(tag, field_name, result.repeatedSfixed32_); + break; + } + case 322: + case 321: { + input.ReadSFixed64Array(tag, field_name, result.repeatedSfixed64_); + break; + } + case 330: + case 333: { + input.ReadFloatArray(tag, field_name, result.repeatedFloat_); + break; + } + case 338: + case 337: { + input.ReadDoubleArray(tag, field_name, result.repeatedDouble_); + break; + } + case 346: + case 344: { + input.ReadBoolArray(tag, field_name, result.repeatedBool_); + break; + } + case 354: { + input.ReadStringArray(tag, field_name, result.repeatedString_); + break; + } + case 362: { + input.ReadBytesArray(tag, field_name, result.repeatedBytes_); + break; + } + case 371: { + input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance, extensionRegistry); + break; + } + case 386: { + input.ReadMessageArray(tag, field_name, result.repeatedNestedMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance, extensionRegistry); + break; + } + case 394: { + input.ReadMessageArray(tag, field_name, result.repeatedForeignMessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); + break; + } + case 402: { + input.ReadMessageArray(tag, field_name, result.repeatedImportMessage_, global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance, extensionRegistry); + break; + } + case 410: + case 408: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedNestedEnum_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(51, (ulong)(int)rawValue); + } + break; + } + case 418: + case 416: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedForeignEnum_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(52, (ulong)(int)rawValue); + } + break; + } + case 426: + case 424: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedImportEnum_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(53, (ulong)(int)rawValue); + } + break; + } + case 434: { + input.ReadStringArray(tag, field_name, result.repeatedStringPiece_); + break; + } + case 442: { + input.ReadStringArray(tag, field_name, result.repeatedCord_); + break; + } + case 458: { + input.ReadMessageArray(tag, field_name, result.repeatedLazyMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance, extensionRegistry); + break; + } + case 488: { + result.hasDefaultInt32 = input.ReadInt32(ref result.defaultInt32_); + break; + } + case 496: { + result.hasDefaultInt64 = input.ReadInt64(ref result.defaultInt64_); + break; + } + case 504: { + result.hasDefaultUint32 = input.ReadUInt32(ref result.defaultUint32_); + break; + } + case 512: { + result.hasDefaultUint64 = input.ReadUInt64(ref result.defaultUint64_); + break; + } + case 520: { + result.hasDefaultSint32 = input.ReadSInt32(ref result.defaultSint32_); + break; + } + case 528: { + result.hasDefaultSint64 = input.ReadSInt64(ref result.defaultSint64_); + break; + } + case 541: { + result.hasDefaultFixed32 = input.ReadFixed32(ref result.defaultFixed32_); + break; + } + case 545: { + result.hasDefaultFixed64 = input.ReadFixed64(ref result.defaultFixed64_); + break; + } + case 557: { + result.hasDefaultSfixed32 = input.ReadSFixed32(ref result.defaultSfixed32_); + break; + } + case 561: { + result.hasDefaultSfixed64 = input.ReadSFixed64(ref result.defaultSfixed64_); + break; + } + case 573: { + result.hasDefaultFloat = input.ReadFloat(ref result.defaultFloat_); + break; + } + case 577: { + result.hasDefaultDouble = input.ReadDouble(ref result.defaultDouble_); + break; + } + case 584: { + result.hasDefaultBool = input.ReadBool(ref result.defaultBool_); + break; + } + case 594: { + result.hasDefaultString = input.ReadString(ref result.defaultString_); + break; + } + case 602: { + result.hasDefaultBytes = input.ReadBytes(ref result.defaultBytes_); + break; + } + case 648: { + object unknown; + if(input.ReadEnum(ref result.defaultNestedEnum_, out unknown)) { + result.hasDefaultNestedEnum = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(81, (ulong)(int)unknown); + } + break; + } + case 656: { + object unknown; + if(input.ReadEnum(ref result.defaultForeignEnum_, out unknown)) { + result.hasDefaultForeignEnum = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(82, (ulong)(int)unknown); + } + break; + } + case 664: { + object unknown; + if(input.ReadEnum(ref result.defaultImportEnum_, out unknown)) { + result.hasDefaultImportEnum = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(83, (ulong)(int)unknown); + } + break; + } + case 674: { + result.hasDefaultStringPiece = input.ReadString(ref result.defaultStringPiece_); + break; + } + case 682: { + result.hasDefaultCord = input.ReadString(ref result.defaultCord_); + break; + } + case 888: { + result.hasOneofUint32 = input.ReadUInt32(ref result.oneofUint32_); + break; + } + case 898: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); + if (result.hasOneofNestedMessage) { + subBuilder.MergeFrom(OneofNestedMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OneofNestedMessage = subBuilder.BuildPartial(); + break; + } + case 906: { + result.hasOneofString = input.ReadString(ref result.oneofString_); + break; + } + case 914: { + result.hasOneofBytes = input.ReadBytes(ref result.oneofBytes_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasOptionalInt32 { + get { return result.hasOptionalInt32; } + } + public int OptionalInt32 { + get { return result.OptionalInt32; } + set { SetOptionalInt32(value); } + } + public Builder SetOptionalInt32(int value) { + PrepareBuilder(); + result.hasOptionalInt32 = true; + result.optionalInt32_ = value; + return this; + } + public Builder ClearOptionalInt32() { + PrepareBuilder(); + result.hasOptionalInt32 = false; + result.optionalInt32_ = 0; + return this; + } + + public bool HasOptionalInt64 { + get { return result.hasOptionalInt64; } + } + public long OptionalInt64 { + get { return result.OptionalInt64; } + set { SetOptionalInt64(value); } + } + public Builder SetOptionalInt64(long value) { + PrepareBuilder(); + result.hasOptionalInt64 = true; + result.optionalInt64_ = value; + return this; + } + public Builder ClearOptionalInt64() { + PrepareBuilder(); + result.hasOptionalInt64 = false; + result.optionalInt64_ = 0L; + return this; + } + + public bool HasOptionalUint32 { + get { return result.hasOptionalUint32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalUint32 { + get { return result.OptionalUint32; } + set { SetOptionalUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalUint32(uint value) { + PrepareBuilder(); + result.hasOptionalUint32 = true; + result.optionalUint32_ = value; + return this; + } + public Builder ClearOptionalUint32() { + PrepareBuilder(); + result.hasOptionalUint32 = false; + result.optionalUint32_ = 0; + return this; + } + + public bool HasOptionalUint64 { + get { return result.hasOptionalUint64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalUint64 { + get { return result.OptionalUint64; } + set { SetOptionalUint64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalUint64(ulong value) { + PrepareBuilder(); + result.hasOptionalUint64 = true; + result.optionalUint64_ = value; + return this; + } + public Builder ClearOptionalUint64() { + PrepareBuilder(); + result.hasOptionalUint64 = false; + result.optionalUint64_ = 0UL; + return this; + } + + public bool HasOptionalSint32 { + get { return result.hasOptionalSint32; } + } + public int OptionalSint32 { + get { return result.OptionalSint32; } + set { SetOptionalSint32(value); } + } + public Builder SetOptionalSint32(int value) { + PrepareBuilder(); + result.hasOptionalSint32 = true; + result.optionalSint32_ = value; + return this; + } + public Builder ClearOptionalSint32() { + PrepareBuilder(); + result.hasOptionalSint32 = false; + result.optionalSint32_ = 0; + return this; + } + + public bool HasOptionalSint64 { + get { return result.hasOptionalSint64; } + } + public long OptionalSint64 { + get { return result.OptionalSint64; } + set { SetOptionalSint64(value); } + } + public Builder SetOptionalSint64(long value) { + PrepareBuilder(); + result.hasOptionalSint64 = true; + result.optionalSint64_ = value; + return this; + } + public Builder ClearOptionalSint64() { + PrepareBuilder(); + result.hasOptionalSint64 = false; + result.optionalSint64_ = 0L; + return this; + } + + public bool HasOptionalFixed32 { + get { return result.hasOptionalFixed32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalFixed32 { + get { return result.OptionalFixed32; } + set { SetOptionalFixed32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalFixed32(uint value) { + PrepareBuilder(); + result.hasOptionalFixed32 = true; + result.optionalFixed32_ = value; + return this; + } + public Builder ClearOptionalFixed32() { + PrepareBuilder(); + result.hasOptionalFixed32 = false; + result.optionalFixed32_ = 0; + return this; + } + + public bool HasOptionalFixed64 { + get { return result.hasOptionalFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalFixed64 { + get { return result.OptionalFixed64; } + set { SetOptionalFixed64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalFixed64(ulong value) { + PrepareBuilder(); + result.hasOptionalFixed64 = true; + result.optionalFixed64_ = value; + return this; + } + public Builder ClearOptionalFixed64() { + PrepareBuilder(); + result.hasOptionalFixed64 = false; + result.optionalFixed64_ = 0UL; + return this; + } + + public bool HasOptionalSfixed32 { + get { return result.hasOptionalSfixed32; } + } + public int OptionalSfixed32 { + get { return result.OptionalSfixed32; } + set { SetOptionalSfixed32(value); } + } + public Builder SetOptionalSfixed32(int value) { + PrepareBuilder(); + result.hasOptionalSfixed32 = true; + result.optionalSfixed32_ = value; + return this; + } + public Builder ClearOptionalSfixed32() { + PrepareBuilder(); + result.hasOptionalSfixed32 = false; + result.optionalSfixed32_ = 0; + return this; + } + + public bool HasOptionalSfixed64 { + get { return result.hasOptionalSfixed64; } + } + public long OptionalSfixed64 { + get { return result.OptionalSfixed64; } + set { SetOptionalSfixed64(value); } + } + public Builder SetOptionalSfixed64(long value) { + PrepareBuilder(); + result.hasOptionalSfixed64 = true; + result.optionalSfixed64_ = value; + return this; + } + public Builder ClearOptionalSfixed64() { + PrepareBuilder(); + result.hasOptionalSfixed64 = false; + result.optionalSfixed64_ = 0L; + return this; + } + + public bool HasOptionalFloat { + get { return result.hasOptionalFloat; } + } + public float OptionalFloat { + get { return result.OptionalFloat; } + set { SetOptionalFloat(value); } + } + public Builder SetOptionalFloat(float value) { + PrepareBuilder(); + result.hasOptionalFloat = true; + result.optionalFloat_ = value; + return this; + } + public Builder ClearOptionalFloat() { + PrepareBuilder(); + result.hasOptionalFloat = false; + result.optionalFloat_ = 0F; + return this; + } + + public bool HasOptionalDouble { + get { return result.hasOptionalDouble; } + } + public double OptionalDouble { + get { return result.OptionalDouble; } + set { SetOptionalDouble(value); } + } + public Builder SetOptionalDouble(double value) { + PrepareBuilder(); + result.hasOptionalDouble = true; + result.optionalDouble_ = value; + return this; + } + public Builder ClearOptionalDouble() { + PrepareBuilder(); + result.hasOptionalDouble = false; + result.optionalDouble_ = 0D; + return this; + } + + public bool HasOptionalBool { + get { return result.hasOptionalBool; } + } + public bool OptionalBool { + get { return result.OptionalBool; } + set { SetOptionalBool(value); } + } + public Builder SetOptionalBool(bool value) { + PrepareBuilder(); + result.hasOptionalBool = true; + result.optionalBool_ = value; + return this; + } + public Builder ClearOptionalBool() { + PrepareBuilder(); + result.hasOptionalBool = false; + result.optionalBool_ = false; + return this; + } + + public bool HasOptionalString { + get { return result.hasOptionalString; } + } + public string OptionalString { + get { return result.OptionalString; } + set { SetOptionalString(value); } + } + public Builder SetOptionalString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalString = true; + result.optionalString_ = value; + return this; + } + public Builder ClearOptionalString() { + PrepareBuilder(); + result.hasOptionalString = false; + result.optionalString_ = ""; + return this; + } + + public bool HasOptionalBytes { + get { return result.hasOptionalBytes; } + } + public pb::ByteString OptionalBytes { + get { return result.OptionalBytes; } + set { SetOptionalBytes(value); } + } + public Builder SetOptionalBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalBytes = true; + result.optionalBytes_ = value; + return this; + } + public Builder ClearOptionalBytes() { + PrepareBuilder(); + result.hasOptionalBytes = false; + result.optionalBytes_ = pb::ByteString.Empty; + return this; + } + + public bool HasOptionalGroup { + get { return result.hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup OptionalGroup { + get { return result.OptionalGroup; } + set { SetOptionalGroup(value); } + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = value; + return this; + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalGroup && + result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance) { + result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial(); + } else { + result.optionalGroup_ = value; + } + result.hasOptionalGroup = true; + return this; + } + public Builder ClearOptionalGroup() { + PrepareBuilder(); + result.hasOptionalGroup = false; + result.optionalGroup_ = null; + return this; + } + + public bool HasOptionalNestedMessage { + get { return result.hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage { + get { return result.OptionalNestedMessage; } + set { SetOptionalNestedMessage(value); } + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = value; + return this; + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalNestedMessage && + result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { + result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalNestedMessage_ = value; + } + result.hasOptionalNestedMessage = true; + return this; + } + public Builder ClearOptionalNestedMessage() { + PrepareBuilder(); + result.hasOptionalNestedMessage = false; + result.optionalNestedMessage_ = null; + return this; + } + + public bool HasOptionalForeignMessage { + get { return result.hasOptionalForeignMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage { + get { return result.OptionalForeignMessage; } + set { SetOptionalForeignMessage(value); } + } + public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalForeignMessage = true; + result.optionalForeignMessage_ = value; + return this; + } + public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalForeignMessage = true; + result.optionalForeignMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalForeignMessage && + result.optionalForeignMessage_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) { + result.optionalForeignMessage_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.optionalForeignMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalForeignMessage_ = value; + } + result.hasOptionalForeignMessage = true; + return this; + } + public Builder ClearOptionalForeignMessage() { + PrepareBuilder(); + result.hasOptionalForeignMessage = false; + result.optionalForeignMessage_ = null; + return this; + } + + public bool HasOptionalImportMessage { + get { return result.hasOptionalImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessage OptionalImportMessage { + get { return result.OptionalImportMessage; } + set { SetOptionalImportMessage(value); } + } + public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalImportMessage = true; + result.optionalImportMessage_ = value; + return this; + } + public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalImportMessage = true; + result.optionalImportMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalImportMessage && + result.optionalImportMessage_ != global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance) { + result.optionalImportMessage_ = global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder(result.optionalImportMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalImportMessage_ = value; + } + result.hasOptionalImportMessage = true; + return this; + } + public Builder ClearOptionalImportMessage() { + PrepareBuilder(); + result.hasOptionalImportMessage = false; + result.optionalImportMessage_ = null; + return this; + } + + public bool HasOptionalNestedEnum { + get { return result.hasOptionalNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum { + get { return result.OptionalNestedEnum; } + set { SetOptionalNestedEnum(value); } + } + public Builder SetOptionalNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { + PrepareBuilder(); + result.hasOptionalNestedEnum = true; + result.optionalNestedEnum_ = value; + return this; + } + public Builder ClearOptionalNestedEnum() { + PrepareBuilder(); + result.hasOptionalNestedEnum = false; + result.optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; + return this; + } + + public bool HasOptionalForeignEnum { + get { return result.hasOptionalForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum { + get { return result.OptionalForeignEnum; } + set { SetOptionalForeignEnum(value); } + } + public Builder SetOptionalForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.hasOptionalForeignEnum = true; + result.optionalForeignEnum_ = value; + return this; + } + public Builder ClearOptionalForeignEnum() { + PrepareBuilder(); + result.hasOptionalForeignEnum = false; + result.optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + return this; + } + + public bool HasOptionalImportEnum { + get { return result.hasOptionalImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum OptionalImportEnum { + get { return result.OptionalImportEnum; } + set { SetOptionalImportEnum(value); } + } + public Builder SetOptionalImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { + PrepareBuilder(); + result.hasOptionalImportEnum = true; + result.optionalImportEnum_ = value; + return this; + } + public Builder ClearOptionalImportEnum() { + PrepareBuilder(); + result.hasOptionalImportEnum = false; + result.optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_FOO; + return this; + } + + public bool HasOptionalStringPiece { + get { return result.hasOptionalStringPiece; } + } + public string OptionalStringPiece { + get { return result.OptionalStringPiece; } + set { SetOptionalStringPiece(value); } + } + public Builder SetOptionalStringPiece(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalStringPiece = true; + result.optionalStringPiece_ = value; + return this; + } + public Builder ClearOptionalStringPiece() { + PrepareBuilder(); + result.hasOptionalStringPiece = false; + result.optionalStringPiece_ = ""; + return this; + } + + public bool HasOptionalCord { + get { return result.hasOptionalCord; } + } + public string OptionalCord { + get { return result.OptionalCord; } + set { SetOptionalCord(value); } + } + public Builder SetOptionalCord(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalCord = true; + result.optionalCord_ = value; + return this; + } + public Builder ClearOptionalCord() { + PrepareBuilder(); + result.hasOptionalCord = false; + result.optionalCord_ = ""; + return this; + } + + public bool HasOptionalPublicImportMessage { + get { return result.hasOptionalPublicImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.PublicImportMessage OptionalPublicImportMessage { + get { return result.OptionalPublicImportMessage; } + set { SetOptionalPublicImportMessage(value); } + } + public Builder SetOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalPublicImportMessage = true; + result.optionalPublicImportMessage_ = value; + return this; + } + public Builder SetOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalPublicImportMessage = true; + result.optionalPublicImportMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalPublicImportMessage && + result.optionalPublicImportMessage_ != global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.DefaultInstance) { + result.optionalPublicImportMessage_ = global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.CreateBuilder(result.optionalPublicImportMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalPublicImportMessage_ = value; + } + result.hasOptionalPublicImportMessage = true; + return this; + } + public Builder ClearOptionalPublicImportMessage() { + PrepareBuilder(); + result.hasOptionalPublicImportMessage = false; + result.optionalPublicImportMessage_ = null; + return this; + } + + public bool HasOptionalLazyMessage { + get { return result.hasOptionalLazyMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalLazyMessage { + get { return result.OptionalLazyMessage; } + set { SetOptionalLazyMessage(value); } + } + public Builder SetOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalLazyMessage = true; + result.optionalLazyMessage_ = value; + return this; + } + public Builder SetOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalLazyMessage = true; + result.optionalLazyMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalLazyMessage && + result.optionalLazyMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { + result.optionalLazyMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.optionalLazyMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalLazyMessage_ = value; + } + result.hasOptionalLazyMessage = true; + return this; + } + public Builder ClearOptionalLazyMessage() { + PrepareBuilder(); + result.hasOptionalLazyMessage = false; + result.optionalLazyMessage_ = null; + return this; + } + + public pbc::IPopsicleList RepeatedInt32List { + get { return PrepareBuilder().repeatedInt32_; } + } + public int RepeatedInt32Count { + get { return result.RepeatedInt32Count; } + } + public int GetRepeatedInt32(int index) { + return result.GetRepeatedInt32(index); + } + public Builder SetRepeatedInt32(int index, int value) { + PrepareBuilder(); + result.repeatedInt32_[index] = value; + return this; + } + public Builder AddRepeatedInt32(int value) { + PrepareBuilder(); + result.repeatedInt32_.Add(value); + return this; + } + public Builder AddRangeRepeatedInt32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedInt32_.Add(values); + return this; + } + public Builder ClearRepeatedInt32() { + PrepareBuilder(); + result.repeatedInt32_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedInt64List { + get { return PrepareBuilder().repeatedInt64_; } + } + public int RepeatedInt64Count { + get { return result.RepeatedInt64Count; } + } + public long GetRepeatedInt64(int index) { + return result.GetRepeatedInt64(index); + } + public Builder SetRepeatedInt64(int index, long value) { + PrepareBuilder(); + result.repeatedInt64_[index] = value; + return this; + } + public Builder AddRepeatedInt64(long value) { + PrepareBuilder(); + result.repeatedInt64_.Add(value); + return this; + } + public Builder AddRangeRepeatedInt64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedInt64_.Add(values); + return this; + } + public Builder ClearRepeatedInt64() { + PrepareBuilder(); + result.repeatedInt64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedUint32List { + get { return PrepareBuilder().repeatedUint32_; } + } + public int RepeatedUint32Count { + get { return result.RepeatedUint32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedUint32(int index) { + return result.GetRepeatedUint32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedUint32(int index, uint value) { + PrepareBuilder(); + result.repeatedUint32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedUint32(uint value) { + PrepareBuilder(); + result.repeatedUint32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedUint32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedUint32_.Add(values); + return this; + } + public Builder ClearRepeatedUint32() { + PrepareBuilder(); + result.repeatedUint32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedUint64List { + get { return PrepareBuilder().repeatedUint64_; } + } + public int RepeatedUint64Count { + get { return result.RepeatedUint64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedUint64(int index) { + return result.GetRepeatedUint64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedUint64(int index, ulong value) { + PrepareBuilder(); + result.repeatedUint64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedUint64(ulong value) { + PrepareBuilder(); + result.repeatedUint64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedUint64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedUint64_.Add(values); + return this; + } + public Builder ClearRepeatedUint64() { + PrepareBuilder(); + result.repeatedUint64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSint32List { + get { return PrepareBuilder().repeatedSint32_; } + } + public int RepeatedSint32Count { + get { return result.RepeatedSint32Count; } + } + public int GetRepeatedSint32(int index) { + return result.GetRepeatedSint32(index); + } + public Builder SetRepeatedSint32(int index, int value) { + PrepareBuilder(); + result.repeatedSint32_[index] = value; + return this; + } + public Builder AddRepeatedSint32(int value) { + PrepareBuilder(); + result.repeatedSint32_.Add(value); + return this; + } + public Builder AddRangeRepeatedSint32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedSint32_.Add(values); + return this; + } + public Builder ClearRepeatedSint32() { + PrepareBuilder(); + result.repeatedSint32_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSint64List { + get { return PrepareBuilder().repeatedSint64_; } + } + public int RepeatedSint64Count { + get { return result.RepeatedSint64Count; } + } + public long GetRepeatedSint64(int index) { + return result.GetRepeatedSint64(index); + } + public Builder SetRepeatedSint64(int index, long value) { + PrepareBuilder(); + result.repeatedSint64_[index] = value; + return this; + } + public Builder AddRepeatedSint64(long value) { + PrepareBuilder(); + result.repeatedSint64_.Add(value); + return this; + } + public Builder AddRangeRepeatedSint64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedSint64_.Add(values); + return this; + } + public Builder ClearRepeatedSint64() { + PrepareBuilder(); + result.repeatedSint64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedFixed32List { + get { return PrepareBuilder().repeatedFixed32_; } + } + public int RepeatedFixed32Count { + get { return result.RepeatedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedFixed32(int index) { + return result.GetRepeatedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedFixed32(int index, uint value) { + PrepareBuilder(); + result.repeatedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedFixed32(uint value) { + PrepareBuilder(); + result.repeatedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedFixed32_.Add(values); + return this; + } + public Builder ClearRepeatedFixed32() { + PrepareBuilder(); + result.repeatedFixed32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedFixed64List { + get { return PrepareBuilder().repeatedFixed64_; } + } + public int RepeatedFixed64Count { + get { return result.RepeatedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedFixed64(int index) { + return result.GetRepeatedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedFixed64(int index, ulong value) { + PrepareBuilder(); + result.repeatedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedFixed64(ulong value) { + PrepareBuilder(); + result.repeatedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedFixed64_.Add(values); + return this; + } + public Builder ClearRepeatedFixed64() { + PrepareBuilder(); + result.repeatedFixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSfixed32List { + get { return PrepareBuilder().repeatedSfixed32_; } + } + public int RepeatedSfixed32Count { + get { return result.RepeatedSfixed32Count; } + } + public int GetRepeatedSfixed32(int index) { + return result.GetRepeatedSfixed32(index); + } + public Builder SetRepeatedSfixed32(int index, int value) { + PrepareBuilder(); + result.repeatedSfixed32_[index] = value; + return this; + } + public Builder AddRepeatedSfixed32(int value) { + PrepareBuilder(); + result.repeatedSfixed32_.Add(value); + return this; + } + public Builder AddRangeRepeatedSfixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedSfixed32_.Add(values); + return this; + } + public Builder ClearRepeatedSfixed32() { + PrepareBuilder(); + result.repeatedSfixed32_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSfixed64List { + get { return PrepareBuilder().repeatedSfixed64_; } + } + public int RepeatedSfixed64Count { + get { return result.RepeatedSfixed64Count; } + } + public long GetRepeatedSfixed64(int index) { + return result.GetRepeatedSfixed64(index); + } + public Builder SetRepeatedSfixed64(int index, long value) { + PrepareBuilder(); + result.repeatedSfixed64_[index] = value; + return this; + } + public Builder AddRepeatedSfixed64(long value) { + PrepareBuilder(); + result.repeatedSfixed64_.Add(value); + return this; + } + public Builder AddRangeRepeatedSfixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedSfixed64_.Add(values); + return this; + } + public Builder ClearRepeatedSfixed64() { + PrepareBuilder(); + result.repeatedSfixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedFloatList { + get { return PrepareBuilder().repeatedFloat_; } + } + public int RepeatedFloatCount { + get { return result.RepeatedFloatCount; } + } + public float GetRepeatedFloat(int index) { + return result.GetRepeatedFloat(index); + } + public Builder SetRepeatedFloat(int index, float value) { + PrepareBuilder(); + result.repeatedFloat_[index] = value; + return this; + } + public Builder AddRepeatedFloat(float value) { + PrepareBuilder(); + result.repeatedFloat_.Add(value); + return this; + } + public Builder AddRangeRepeatedFloat(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedFloat_.Add(values); + return this; + } + public Builder ClearRepeatedFloat() { + PrepareBuilder(); + result.repeatedFloat_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedDoubleList { + get { return PrepareBuilder().repeatedDouble_; } + } + public int RepeatedDoubleCount { + get { return result.RepeatedDoubleCount; } + } + public double GetRepeatedDouble(int index) { + return result.GetRepeatedDouble(index); + } + public Builder SetRepeatedDouble(int index, double value) { + PrepareBuilder(); + result.repeatedDouble_[index] = value; + return this; + } + public Builder AddRepeatedDouble(double value) { + PrepareBuilder(); + result.repeatedDouble_.Add(value); + return this; + } + public Builder AddRangeRepeatedDouble(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedDouble_.Add(values); + return this; + } + public Builder ClearRepeatedDouble() { + PrepareBuilder(); + result.repeatedDouble_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedBoolList { + get { return PrepareBuilder().repeatedBool_; } + } + public int RepeatedBoolCount { + get { return result.RepeatedBoolCount; } + } + public bool GetRepeatedBool(int index) { + return result.GetRepeatedBool(index); + } + public Builder SetRepeatedBool(int index, bool value) { + PrepareBuilder(); + result.repeatedBool_[index] = value; + return this; + } + public Builder AddRepeatedBool(bool value) { + PrepareBuilder(); + result.repeatedBool_.Add(value); + return this; + } + public Builder AddRangeRepeatedBool(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedBool_.Add(values); + return this; + } + public Builder ClearRepeatedBool() { + PrepareBuilder(); + result.repeatedBool_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedStringList { + get { return PrepareBuilder().repeatedString_; } + } + public int RepeatedStringCount { + get { return result.RepeatedStringCount; } + } + public string GetRepeatedString(int index) { + return result.GetRepeatedString(index); + } + public Builder SetRepeatedString(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedString_[index] = value; + return this; + } + public Builder AddRepeatedString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedString_.Add(value); + return this; + } + public Builder AddRangeRepeatedString(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedString_.Add(values); + return this; + } + public Builder ClearRepeatedString() { + PrepareBuilder(); + result.repeatedString_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedBytesList { + get { return PrepareBuilder().repeatedBytes_; } + } + public int RepeatedBytesCount { + get { return result.RepeatedBytesCount; } + } + public pb::ByteString GetRepeatedBytes(int index) { + return result.GetRepeatedBytes(index); + } + public Builder SetRepeatedBytes(int index, pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedBytes_[index] = value; + return this; + } + public Builder AddRepeatedBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedBytes_.Add(value); + return this; + } + public Builder AddRangeRepeatedBytes(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedBytes_.Add(values); + return this; + } + public Builder ClearRepeatedBytes() { + PrepareBuilder(); + result.repeatedBytes_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedGroupList { + get { return PrepareBuilder().repeatedGroup_; } + } + public int RepeatedGroupCount { + get { return result.RepeatedGroupCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup GetRepeatedGroup(int index) { + return result.GetRepeatedGroup(index); + } + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_[index] = value; + return this; + } + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_.Add(value); + return this; + } + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedGroup(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedGroup_.Add(values); + return this; + } + public Builder ClearRepeatedGroup() { + PrepareBuilder(); + result.repeatedGroup_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedNestedMessageList { + get { return PrepareBuilder().repeatedNestedMessage_; } + } + public int RepeatedNestedMessageCount { + get { return result.RepeatedNestedMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) { + return result.GetRepeatedNestedMessage(index); + } + public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedNestedMessage_[index] = value; + return this; + } + public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedNestedMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedNestedMessage_.Add(value); + return this; + } + public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedNestedMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedNestedMessage(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedNestedMessage_.Add(values); + return this; + } + public Builder ClearRepeatedNestedMessage() { + PrepareBuilder(); + result.repeatedNestedMessage_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedForeignMessageList { + get { return PrepareBuilder().repeatedForeignMessage_; } + } + public int RepeatedForeignMessageCount { + get { return result.RepeatedForeignMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) { + return result.GetRepeatedForeignMessage(index); + } + public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedForeignMessage_[index] = value; + return this; + } + public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedForeignMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedForeignMessage_.Add(value); + return this; + } + public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedForeignMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedForeignMessage(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedForeignMessage_.Add(values); + return this; + } + public Builder ClearRepeatedForeignMessage() { + PrepareBuilder(); + result.repeatedForeignMessage_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedImportMessageList { + get { return PrepareBuilder().repeatedImportMessage_; } + } + public int RepeatedImportMessageCount { + get { return result.RepeatedImportMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessage GetRepeatedImportMessage(int index) { + return result.GetRepeatedImportMessage(index); + } + public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedImportMessage_[index] = value; + return this; + } + public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedImportMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedImportMessage_.Add(value); + return this; + } + public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedImportMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedImportMessage(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedImportMessage_.Add(values); + return this; + } + public Builder ClearRepeatedImportMessage() { + PrepareBuilder(); + result.repeatedImportMessage_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedNestedEnumList { + get { return PrepareBuilder().repeatedNestedEnum_; } + } + public int RepeatedNestedEnumCount { + get { return result.RepeatedNestedEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) { + return result.GetRepeatedNestedEnum(index); + } + public Builder SetRepeatedNestedEnum(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { + PrepareBuilder(); + result.repeatedNestedEnum_[index] = value; + return this; + } + public Builder AddRepeatedNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { + PrepareBuilder(); + result.repeatedNestedEnum_.Add(value); + return this; + } + public Builder AddRangeRepeatedNestedEnum(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedNestedEnum_.Add(values); + return this; + } + public Builder ClearRepeatedNestedEnum() { + PrepareBuilder(); + result.repeatedNestedEnum_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedForeignEnumList { + get { return PrepareBuilder().repeatedForeignEnum_; } + } + public int RepeatedForeignEnumCount { + get { return result.RepeatedForeignEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) { + return result.GetRepeatedForeignEnum(index); + } + public Builder SetRepeatedForeignEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.repeatedForeignEnum_[index] = value; + return this; + } + public Builder AddRepeatedForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.repeatedForeignEnum_.Add(value); + return this; + } + public Builder AddRangeRepeatedForeignEnum(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedForeignEnum_.Add(values); + return this; + } + public Builder ClearRepeatedForeignEnum() { + PrepareBuilder(); + result.repeatedForeignEnum_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedImportEnumList { + get { return PrepareBuilder().repeatedImportEnum_; } + } + public int RepeatedImportEnumCount { + get { return result.RepeatedImportEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum GetRepeatedImportEnum(int index) { + return result.GetRepeatedImportEnum(index); + } + public Builder SetRepeatedImportEnum(int index, global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { + PrepareBuilder(); + result.repeatedImportEnum_[index] = value; + return this; + } + public Builder AddRepeatedImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { + PrepareBuilder(); + result.repeatedImportEnum_.Add(value); + return this; + } + public Builder AddRangeRepeatedImportEnum(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedImportEnum_.Add(values); + return this; + } + public Builder ClearRepeatedImportEnum() { + PrepareBuilder(); + result.repeatedImportEnum_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedStringPieceList { + get { return PrepareBuilder().repeatedStringPiece_; } + } + public int RepeatedStringPieceCount { + get { return result.RepeatedStringPieceCount; } + } + public string GetRepeatedStringPiece(int index) { + return result.GetRepeatedStringPiece(index); + } + public Builder SetRepeatedStringPiece(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringPiece_[index] = value; + return this; + } + public Builder AddRepeatedStringPiece(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringPiece_.Add(value); + return this; + } + public Builder AddRangeRepeatedStringPiece(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedStringPiece_.Add(values); + return this; + } + public Builder ClearRepeatedStringPiece() { + PrepareBuilder(); + result.repeatedStringPiece_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedCordList { + get { return PrepareBuilder().repeatedCord_; } + } + public int RepeatedCordCount { + get { return result.RepeatedCordCount; } + } + public string GetRepeatedCord(int index) { + return result.GetRepeatedCord(index); + } + public Builder SetRepeatedCord(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedCord_[index] = value; + return this; + } + public Builder AddRepeatedCord(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedCord_.Add(value); + return this; + } + public Builder AddRangeRepeatedCord(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedCord_.Add(values); + return this; + } + public Builder ClearRepeatedCord() { + PrepareBuilder(); + result.repeatedCord_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedLazyMessageList { + get { return PrepareBuilder().repeatedLazyMessage_; } + } + public int RepeatedLazyMessageCount { + get { return result.RepeatedLazyMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedLazyMessage(int index) { + return result.GetRepeatedLazyMessage(index); + } + public Builder SetRepeatedLazyMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedLazyMessage_[index] = value; + return this; + } + public Builder SetRepeatedLazyMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedLazyMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedLazyMessage_.Add(value); + return this; + } + public Builder AddRepeatedLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedLazyMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedLazyMessage(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedLazyMessage_.Add(values); + return this; + } + public Builder ClearRepeatedLazyMessage() { + PrepareBuilder(); + result.repeatedLazyMessage_.Clear(); + return this; + } + + public bool HasDefaultInt32 { + get { return result.hasDefaultInt32; } + } + public int DefaultInt32 { + get { return result.DefaultInt32; } + set { SetDefaultInt32(value); } + } + public Builder SetDefaultInt32(int value) { + PrepareBuilder(); + result.hasDefaultInt32 = true; + result.defaultInt32_ = value; + return this; + } + public Builder ClearDefaultInt32() { + PrepareBuilder(); + result.hasDefaultInt32 = false; + result.defaultInt32_ = 41; + return this; + } + + public bool HasDefaultInt64 { + get { return result.hasDefaultInt64; } + } + public long DefaultInt64 { + get { return result.DefaultInt64; } + set { SetDefaultInt64(value); } + } + public Builder SetDefaultInt64(long value) { + PrepareBuilder(); + result.hasDefaultInt64 = true; + result.defaultInt64_ = value; + return this; + } + public Builder ClearDefaultInt64() { + PrepareBuilder(); + result.hasDefaultInt64 = false; + result.defaultInt64_ = 42L; + return this; + } + + public bool HasDefaultUint32 { + get { return result.hasDefaultUint32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultUint32 { + get { return result.DefaultUint32; } + set { SetDefaultUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultUint32(uint value) { + PrepareBuilder(); + result.hasDefaultUint32 = true; + result.defaultUint32_ = value; + return this; + } + public Builder ClearDefaultUint32() { + PrepareBuilder(); + result.hasDefaultUint32 = false; + result.defaultUint32_ = 43; + return this; + } + + public bool HasDefaultUint64 { + get { return result.hasDefaultUint64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultUint64 { + get { return result.DefaultUint64; } + set { SetDefaultUint64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultUint64(ulong value) { + PrepareBuilder(); + result.hasDefaultUint64 = true; + result.defaultUint64_ = value; + return this; + } + public Builder ClearDefaultUint64() { + PrepareBuilder(); + result.hasDefaultUint64 = false; + result.defaultUint64_ = 44UL; + return this; + } + + public bool HasDefaultSint32 { + get { return result.hasDefaultSint32; } + } + public int DefaultSint32 { + get { return result.DefaultSint32; } + set { SetDefaultSint32(value); } + } + public Builder SetDefaultSint32(int value) { + PrepareBuilder(); + result.hasDefaultSint32 = true; + result.defaultSint32_ = value; + return this; + } + public Builder ClearDefaultSint32() { + PrepareBuilder(); + result.hasDefaultSint32 = false; + result.defaultSint32_ = -45; + return this; + } + + public bool HasDefaultSint64 { + get { return result.hasDefaultSint64; } + } + public long DefaultSint64 { + get { return result.DefaultSint64; } + set { SetDefaultSint64(value); } + } + public Builder SetDefaultSint64(long value) { + PrepareBuilder(); + result.hasDefaultSint64 = true; + result.defaultSint64_ = value; + return this; + } + public Builder ClearDefaultSint64() { + PrepareBuilder(); + result.hasDefaultSint64 = false; + result.defaultSint64_ = 46L; + return this; + } + + public bool HasDefaultFixed32 { + get { return result.hasDefaultFixed32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultFixed32 { + get { return result.DefaultFixed32; } + set { SetDefaultFixed32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultFixed32(uint value) { + PrepareBuilder(); + result.hasDefaultFixed32 = true; + result.defaultFixed32_ = value; + return this; + } + public Builder ClearDefaultFixed32() { + PrepareBuilder(); + result.hasDefaultFixed32 = false; + result.defaultFixed32_ = 47; + return this; + } + + public bool HasDefaultFixed64 { + get { return result.hasDefaultFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultFixed64 { + get { return result.DefaultFixed64; } + set { SetDefaultFixed64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultFixed64(ulong value) { + PrepareBuilder(); + result.hasDefaultFixed64 = true; + result.defaultFixed64_ = value; + return this; + } + public Builder ClearDefaultFixed64() { + PrepareBuilder(); + result.hasDefaultFixed64 = false; + result.defaultFixed64_ = 48UL; + return this; + } + + public bool HasDefaultSfixed32 { + get { return result.hasDefaultSfixed32; } + } + public int DefaultSfixed32 { + get { return result.DefaultSfixed32; } + set { SetDefaultSfixed32(value); } + } + public Builder SetDefaultSfixed32(int value) { + PrepareBuilder(); + result.hasDefaultSfixed32 = true; + result.defaultSfixed32_ = value; + return this; + } + public Builder ClearDefaultSfixed32() { + PrepareBuilder(); + result.hasDefaultSfixed32 = false; + result.defaultSfixed32_ = 49; + return this; + } + + public bool HasDefaultSfixed64 { + get { return result.hasDefaultSfixed64; } + } + public long DefaultSfixed64 { + get { return result.DefaultSfixed64; } + set { SetDefaultSfixed64(value); } + } + public Builder SetDefaultSfixed64(long value) { + PrepareBuilder(); + result.hasDefaultSfixed64 = true; + result.defaultSfixed64_ = value; + return this; + } + public Builder ClearDefaultSfixed64() { + PrepareBuilder(); + result.hasDefaultSfixed64 = false; + result.defaultSfixed64_ = -50L; + return this; + } + + public bool HasDefaultFloat { + get { return result.hasDefaultFloat; } + } + public float DefaultFloat { + get { return result.DefaultFloat; } + set { SetDefaultFloat(value); } + } + public Builder SetDefaultFloat(float value) { + PrepareBuilder(); + result.hasDefaultFloat = true; + result.defaultFloat_ = value; + return this; + } + public Builder ClearDefaultFloat() { + PrepareBuilder(); + result.hasDefaultFloat = false; + result.defaultFloat_ = 51.5F; + return this; + } + + public bool HasDefaultDouble { + get { return result.hasDefaultDouble; } + } + public double DefaultDouble { + get { return result.DefaultDouble; } + set { SetDefaultDouble(value); } + } + public Builder SetDefaultDouble(double value) { + PrepareBuilder(); + result.hasDefaultDouble = true; + result.defaultDouble_ = value; + return this; + } + public Builder ClearDefaultDouble() { + PrepareBuilder(); + result.hasDefaultDouble = false; + result.defaultDouble_ = 52000D; + return this; + } + + public bool HasDefaultBool { + get { return result.hasDefaultBool; } + } + public bool DefaultBool { + get { return result.DefaultBool; } + set { SetDefaultBool(value); } + } + public Builder SetDefaultBool(bool value) { + PrepareBuilder(); + result.hasDefaultBool = true; + result.defaultBool_ = value; + return this; + } + public Builder ClearDefaultBool() { + PrepareBuilder(); + result.hasDefaultBool = false; + result.defaultBool_ = true; + return this; + } + + public bool HasDefaultString { + get { return result.hasDefaultString; } + } + public string DefaultString { + get { return result.DefaultString; } + set { SetDefaultString(value); } + } + public Builder SetDefaultString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultString = true; + result.defaultString_ = value; + return this; + } + public Builder ClearDefaultString() { + PrepareBuilder(); + result.hasDefaultString = false; + result.defaultString_ = "hello"; + return this; + } + + public bool HasDefaultBytes { + get { return result.hasDefaultBytes; } + } + public pb::ByteString DefaultBytes { + get { return result.DefaultBytes; } + set { SetDefaultBytes(value); } + } + public Builder SetDefaultBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultBytes = true; + result.defaultBytes_ = value; + return this; + } + public Builder ClearDefaultBytes() { + PrepareBuilder(); + result.hasDefaultBytes = false; + result.defaultBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor.Fields[65].DefaultValue; + return this; + } + + public bool HasDefaultNestedEnum { + get { return result.hasDefaultNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum DefaultNestedEnum { + get { return result.DefaultNestedEnum; } + set { SetDefaultNestedEnum(value); } + } + public Builder SetDefaultNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { + PrepareBuilder(); + result.hasDefaultNestedEnum = true; + result.defaultNestedEnum_ = value; + return this; + } + public Builder ClearDefaultNestedEnum() { + PrepareBuilder(); + result.hasDefaultNestedEnum = false; + result.defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.BAR; + return this; + } + + public bool HasDefaultForeignEnum { + get { return result.hasDefaultForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum DefaultForeignEnum { + get { return result.DefaultForeignEnum; } + set { SetDefaultForeignEnum(value); } + } + public Builder SetDefaultForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.hasDefaultForeignEnum = true; + result.defaultForeignEnum_ = value; + return this; + } + public Builder ClearDefaultForeignEnum() { + PrepareBuilder(); + result.hasDefaultForeignEnum = false; + result.defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_BAR; + return this; + } + + public bool HasDefaultImportEnum { + get { return result.hasDefaultImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum DefaultImportEnum { + get { return result.DefaultImportEnum; } + set { SetDefaultImportEnum(value); } + } + public Builder SetDefaultImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { + PrepareBuilder(); + result.hasDefaultImportEnum = true; + result.defaultImportEnum_ = value; + return this; + } + public Builder ClearDefaultImportEnum() { + PrepareBuilder(); + result.hasDefaultImportEnum = false; + result.defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_BAR; + return this; + } + + public bool HasDefaultStringPiece { + get { return result.hasDefaultStringPiece; } + } + public string DefaultStringPiece { + get { return result.DefaultStringPiece; } + set { SetDefaultStringPiece(value); } + } + public Builder SetDefaultStringPiece(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultStringPiece = true; + result.defaultStringPiece_ = value; + return this; + } + public Builder ClearDefaultStringPiece() { + PrepareBuilder(); + result.hasDefaultStringPiece = false; + result.defaultStringPiece_ = "abc"; + return this; + } + + public bool HasDefaultCord { + get { return result.hasDefaultCord; } + } + public string DefaultCord { + get { return result.DefaultCord; } + set { SetDefaultCord(value); } + } + public Builder SetDefaultCord(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultCord = true; + result.defaultCord_ = value; + return this; + } + public Builder ClearDefaultCord() { + PrepareBuilder(); + result.hasDefaultCord = false; + result.defaultCord_ = "123"; + return this; + } + + public bool HasOneofUint32 { + get { return result.hasOneofUint32; } + } + [global::System.CLSCompliant(false)] + public uint OneofUint32 { + get { return result.OneofUint32; } + set { SetOneofUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOneofUint32(uint value) { + PrepareBuilder(); + result.hasOneofUint32 = true; + result.oneofUint32_ = value; + return this; + } + public Builder ClearOneofUint32() { + PrepareBuilder(); + result.hasOneofUint32 = false; + result.oneofUint32_ = 0; + return this; + } + + public bool HasOneofNestedMessage { + get { return result.hasOneofNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OneofNestedMessage { + get { return result.OneofNestedMessage; } + set { SetOneofNestedMessage(value); } + } + public Builder SetOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOneofNestedMessage = true; + result.oneofNestedMessage_ = value; + return this; + } + public Builder SetOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOneofNestedMessage = true; + result.oneofNestedMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOneofNestedMessage && + result.oneofNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { + result.oneofNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.oneofNestedMessage_).MergeFrom(value).BuildPartial(); + } else { + result.oneofNestedMessage_ = value; + } + result.hasOneofNestedMessage = true; + return this; + } + public Builder ClearOneofNestedMessage() { + PrepareBuilder(); + result.hasOneofNestedMessage = false; + result.oneofNestedMessage_ = null; + return this; + } + + public bool HasOneofString { + get { return result.hasOneofString; } + } + public string OneofString { + get { return result.OneofString; } + set { SetOneofString(value); } + } + public Builder SetOneofString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOneofString = true; + result.oneofString_ = value; + return this; + } + public Builder ClearOneofString() { + PrepareBuilder(); + result.hasOneofString = false; + result.oneofString_ = ""; + return this; + } + + public bool HasOneofBytes { + get { return result.hasOneofBytes; } + } + public pb::ByteString OneofBytes { + get { return result.OneofBytes; } + set { SetOneofBytes(value); } + } + public Builder SetOneofBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOneofBytes = true; + result.oneofBytes_ = value; + return this; + } + public Builder ClearOneofBytes() { + PrepareBuilder(); + result.hasOneofBytes = false; + result.oneofBytes_ = pb::ByteString.Empty; + return this; + } + } + static TestAllTypes() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedTestAllTypes : pb::GeneratedMessage { + private NestedTestAllTypes() { } + private static readonly NestedTestAllTypes defaultInstance = new NestedTestAllTypes().MakeReadOnly(); + private static readonly string[] _nestedTestAllTypesFieldNames = new string[] { "child", "payload" }; + private static readonly uint[] _nestedTestAllTypesFieldTags = new uint[] { 10, 18 }; + public static NestedTestAllTypes DefaultInstance { + get { return defaultInstance; } + } + + public override NestedTestAllTypes DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override NestedTestAllTypes ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_NestedTestAllTypes__FieldAccessorTable; } + } + + public const int ChildFieldNumber = 1; + private bool hasChild; + private global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes child_; + public bool HasChild { + get { return hasChild; } + } + public global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes Child { + get { return child_ ?? global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance; } + } + + public const int PayloadFieldNumber = 2; + private bool hasPayload; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes payload_; + public bool HasPayload { + get { return hasPayload; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Payload { + get { return payload_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _nestedTestAllTypesFieldNames; + if (hasChild) { + output.WriteMessage(1, field_names[0], Child); + } + if (hasPayload) { + output.WriteMessage(2, field_names[1], Payload); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasChild) { + size += pb::CodedOutputStream.ComputeMessageSize(1, Child); + } + if (hasPayload) { + size += pb::CodedOutputStream.ComputeMessageSize(2, Payload); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedTestAllTypes ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedTestAllTypes ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedTestAllTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedTestAllTypes MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedTestAllTypes prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedTestAllTypes cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NestedTestAllTypes result; + + private NestedTestAllTypes PrepareBuilder() { + if (resultIsReadOnly) { + NestedTestAllTypes original = result; + result = new NestedTestAllTypes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override NestedTestAllTypes MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.Descriptor; } + } + + public override NestedTestAllTypes DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance; } + } + + public override NestedTestAllTypes BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is NestedTestAllTypes) { + return MergeFrom((NestedTestAllTypes) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NestedTestAllTypes other) { + if (other == global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasChild) { + MergeChild(other.Child); + } + if (other.HasPayload) { + MergePayload(other.Payload); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_nestedTestAllTypesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _nestedTestAllTypesFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.CreateBuilder(); + if (result.hasChild) { + subBuilder.MergeFrom(Child); + } + input.ReadMessage(subBuilder, extensionRegistry); + Child = subBuilder.BuildPartial(); + break; + } + case 18: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasPayload) { + subBuilder.MergeFrom(Payload); + } + input.ReadMessage(subBuilder, extensionRegistry); + Payload = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasChild { + get { return result.hasChild; } + } + public global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes Child { + get { return result.Child; } + set { SetChild(value); } + } + public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasChild = true; + result.child_ = value; + return this; + } + public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasChild = true; + result.child_ = builderForValue.Build(); + return this; + } + public Builder MergeChild(global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasChild && + result.child_ != global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance) { + result.child_ = global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.CreateBuilder(result.child_).MergeFrom(value).BuildPartial(); + } else { + result.child_ = value; + } + result.hasChild = true; + return this; + } + public Builder ClearChild() { + PrepareBuilder(); + result.hasChild = false; + result.child_ = null; + return this; + } + + public bool HasPayload { + get { return result.hasPayload; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Payload { + get { return result.Payload; } + set { SetPayload(value); } + } + public Builder SetPayload(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasPayload = true; + result.payload_ = value; + return this; + } + public Builder SetPayload(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasPayload = true; + result.payload_ = builderForValue.Build(); + return this; + } + public Builder MergePayload(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasPayload && + result.payload_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.payload_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.payload_).MergeFrom(value).BuildPartial(); + } else { + result.payload_ = value; + } + result.hasPayload = true; + return this; + } + public Builder ClearPayload() { + PrepareBuilder(); + result.hasPayload = false; + result.payload_ = null; + return this; + } + } + static NestedTestAllTypes() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestDeprecatedFields : pb::GeneratedMessage { + private TestDeprecatedFields() { } + private static readonly TestDeprecatedFields defaultInstance = new TestDeprecatedFields().MakeReadOnly(); + private static readonly string[] _testDeprecatedFieldsFieldNames = new string[] { "deprecated_int32" }; + private static readonly uint[] _testDeprecatedFieldsFieldTags = new uint[] { 8 }; + public static TestDeprecatedFields DefaultInstance { + get { return defaultInstance; } + } + + public override TestDeprecatedFields DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestDeprecatedFields ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable; } + } + + public const int DeprecatedInt32FieldNumber = 1; + private bool hasDeprecatedInt32; + private int deprecatedInt32_; + [global::System.ObsoleteAttribute()] + public bool HasDeprecatedInt32 { + get { return hasDeprecatedInt32; } + } + [global::System.ObsoleteAttribute()] + public int DeprecatedInt32 { + get { return deprecatedInt32_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testDeprecatedFieldsFieldNames; + if (hasDeprecatedInt32) { + output.WriteInt32(1, field_names[0], DeprecatedInt32); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasDeprecatedInt32) { + size += pb::CodedOutputStream.ComputeInt32Size(1, DeprecatedInt32); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestDeprecatedFields ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestDeprecatedFields ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestDeprecatedFields ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestDeprecatedFields MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestDeprecatedFields prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestDeprecatedFields cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestDeprecatedFields result; + + private TestDeprecatedFields PrepareBuilder() { + if (resultIsReadOnly) { + TestDeprecatedFields original = result; + result = new TestDeprecatedFields(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestDeprecatedFields MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.Descriptor; } + } + + public override TestDeprecatedFields DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.DefaultInstance; } + } + + public override TestDeprecatedFields BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestDeprecatedFields) { + return MergeFrom((TestDeprecatedFields) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestDeprecatedFields other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasDeprecatedInt32) { + DeprecatedInt32 = other.DeprecatedInt32; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testDeprecatedFieldsFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testDeprecatedFieldsFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasDeprecatedInt32 = input.ReadInt32(ref result.deprecatedInt32_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + [global::System.ObsoleteAttribute()] + public bool HasDeprecatedInt32 { + get { return result.hasDeprecatedInt32; } + } + [global::System.ObsoleteAttribute()] + public int DeprecatedInt32 { + get { return result.DeprecatedInt32; } + set { SetDeprecatedInt32(value); } + } + [global::System.ObsoleteAttribute()] + public Builder SetDeprecatedInt32(int value) { + PrepareBuilder(); + result.hasDeprecatedInt32 = true; + result.deprecatedInt32_ = value; + return this; + } + [global::System.ObsoleteAttribute()] + public Builder ClearDeprecatedInt32() { + PrepareBuilder(); + result.hasDeprecatedInt32 = false; + result.deprecatedInt32_ = 0; + return this; + } + } + static TestDeprecatedFields() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class ForeignMessage : pb::GeneratedMessage { + private ForeignMessage() { } + private static readonly ForeignMessage defaultInstance = new ForeignMessage().MakeReadOnly(); + private static readonly string[] _foreignMessageFieldNames = new string[] { "c" }; + private static readonly uint[] _foreignMessageFieldTags = new uint[] { 8 }; + public static ForeignMessage DefaultInstance { + get { return defaultInstance; } + } + + public override ForeignMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override ForeignMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_ForeignMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable; } + } + + public const int CFieldNumber = 1; + private bool hasC; + private int c_; + public bool HasC { + get { return hasC; } + } + public int C { + get { return c_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _foreignMessageFieldNames; + if (hasC) { + output.WriteInt32(1, field_names[0], C); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasC) { + size += pb::CodedOutputStream.ComputeInt32Size(1, C); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static ForeignMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ForeignMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ForeignMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ForeignMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ForeignMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ForeignMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static ForeignMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ForeignMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private ForeignMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(ForeignMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(ForeignMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private ForeignMessage result; + + private ForeignMessage PrepareBuilder() { + if (resultIsReadOnly) { + ForeignMessage original = result; + result = new ForeignMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override ForeignMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Descriptor; } + } + + public override ForeignMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } + } + + public override ForeignMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is ForeignMessage) { + return MergeFrom((ForeignMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(ForeignMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasC) { + C = other.C; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_foreignMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _foreignMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasC = input.ReadInt32(ref result.c_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasC { + get { return result.hasC; } + } + public int C { + get { return result.C; } + set { SetC(value); } + } + public Builder SetC(int value) { + PrepareBuilder(); + result.hasC = true; + result.c_ = value; + return this; + } + public Builder ClearC() { + PrepareBuilder(); + result.hasC = false; + result.c_ = 0; + return this; + } + } + static ForeignMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestAllExtensions : pb::ExtendableMessage { + private TestAllExtensions() { } + private static readonly TestAllExtensions defaultInstance = new TestAllExtensions().MakeReadOnly(); + private static readonly string[] _testAllExtensionsFieldNames = new string[] { }; + private static readonly uint[] _testAllExtensionsFieldTags = new uint[] { }; + public static TestAllExtensions DefaultInstance { + get { return defaultInstance; } + } + + public override TestAllExtensions DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestAllExtensions ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllExtensions__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testAllExtensionsFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestAllExtensions ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestAllExtensions ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestAllExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestAllExtensions ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestAllExtensions MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestAllExtensions prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestAllExtensions cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestAllExtensions result; + + private TestAllExtensions PrepareBuilder() { + if (resultIsReadOnly) { + TestAllExtensions original = result; + result = new TestAllExtensions(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestAllExtensions MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.Descriptor; } + } + + public override TestAllExtensions DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.DefaultInstance; } + } + + public override TestAllExtensions BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestAllExtensions) { + return MergeFrom((TestAllExtensions) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestAllExtensions other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testAllExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testAllExtensionsFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestAllExtensions() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OptionalGroup_extension : pb::GeneratedMessage { + private OptionalGroup_extension() { } + private static readonly OptionalGroup_extension defaultInstance = new OptionalGroup_extension().MakeReadOnly(); + private static readonly string[] _optionalGroupExtensionFieldNames = new string[] { "a" }; + private static readonly uint[] _optionalGroupExtensionFieldTags = new uint[] { 136 }; + public static OptionalGroup_extension DefaultInstance { + get { return defaultInstance; } + } + + public override OptionalGroup_extension DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override OptionalGroup_extension ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable; } + } + + public const int AFieldNumber = 17; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _optionalGroupExtensionFieldNames; + if (hasA) { + output.WriteInt32(17, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(17, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static OptionalGroup_extension ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup_extension ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OptionalGroup_extension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OptionalGroup_extension MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OptionalGroup_extension prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OptionalGroup_extension cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OptionalGroup_extension result; + + private OptionalGroup_extension PrepareBuilder() { + if (resultIsReadOnly) { + OptionalGroup_extension original = result; + result = new OptionalGroup_extension(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override OptionalGroup_extension MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.Descriptor; } + } + + public override OptionalGroup_extension DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.DefaultInstance; } + } + + public override OptionalGroup_extension BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is OptionalGroup_extension) { + return MergeFrom((OptionalGroup_extension) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OptionalGroup_extension other) { + if (other == global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_optionalGroupExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _optionalGroupExtensionFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 136: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static OptionalGroup_extension() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedGroup_extension : pb::GeneratedMessage { + private RepeatedGroup_extension() { } + private static readonly RepeatedGroup_extension defaultInstance = new RepeatedGroup_extension().MakeReadOnly(); + private static readonly string[] _repeatedGroupExtensionFieldNames = new string[] { "a" }; + private static readonly uint[] _repeatedGroupExtensionFieldTags = new uint[] { 376 }; + public static RepeatedGroup_extension DefaultInstance { + get { return defaultInstance; } + } + + public override RepeatedGroup_extension DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override RepeatedGroup_extension ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable; } + } + + public const int AFieldNumber = 47; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _repeatedGroupExtensionFieldNames; + if (hasA) { + output.WriteInt32(47, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(47, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static RepeatedGroup_extension ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup_extension ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedGroup_extension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedGroup_extension MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedGroup_extension prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedGroup_extension cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private RepeatedGroup_extension result; + + private RepeatedGroup_extension PrepareBuilder() { + if (resultIsReadOnly) { + RepeatedGroup_extension original = result; + result = new RepeatedGroup_extension(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override RepeatedGroup_extension MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.Descriptor; } + } + + public override RepeatedGroup_extension DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.DefaultInstance; } + } + + public override RepeatedGroup_extension BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is RepeatedGroup_extension) { + return MergeFrom((RepeatedGroup_extension) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(RepeatedGroup_extension other) { + if (other == global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _repeatedGroupExtensionFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 376: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static RepeatedGroup_extension() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestNestedExtension : pb::GeneratedMessage { + private TestNestedExtension() { } + private static readonly TestNestedExtension defaultInstance = new TestNestedExtension().MakeReadOnly(); + private static readonly string[] _testNestedExtensionFieldNames = new string[] { }; + private static readonly uint[] _testNestedExtensionFieldTags = new uint[] { }; + public static TestNestedExtension DefaultInstance { + get { return defaultInstance; } + } + + public override TestNestedExtension DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestNestedExtension ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedExtension__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable; } + } + + public const int TestFieldNumber = 1002; + public static pb::GeneratedExtensionBase Test; + public const int NestedStringExtensionFieldNumber = 1003; + public static pb::GeneratedExtensionBase NestedStringExtension; + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testNestedExtensionFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestNestedExtension ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestNestedExtension ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestNestedExtension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestNestedExtension ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestNestedExtension MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestNestedExtension prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestNestedExtension cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestNestedExtension result; + + private TestNestedExtension PrepareBuilder() { + if (resultIsReadOnly) { + TestNestedExtension original = result; + result = new TestNestedExtension(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestNestedExtension MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor; } + } + + public override TestNestedExtension DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.DefaultInstance; } + } + + public override TestNestedExtension BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestNestedExtension) { + return MergeFrom((TestNestedExtension) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestNestedExtension other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testNestedExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testNestedExtensionFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestNestedExtension() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestRequired : pb::GeneratedMessage { + private TestRequired() { } + private static readonly TestRequired defaultInstance = new TestRequired().MakeReadOnly(); + private static readonly string[] _testRequiredFieldNames = new string[] { "a", "b", "c", "dummy10", "dummy11", "dummy12", "dummy13", "dummy14", "dummy15", "dummy16", "dummy17", "dummy18", "dummy19", "dummy2", "dummy20", "dummy21", "dummy22", "dummy23", "dummy24", "dummy25", "dummy26", "dummy27", "dummy28", "dummy29", "dummy30", "dummy31", "dummy32", "dummy4", "dummy5", "dummy6", "dummy7", "dummy8", "dummy9" }; + private static readonly uint[] _testRequiredFieldTags = new uint[] { 8, 24, 264, 80, 88, 96, 104, 112, 120, 128, 136, 144, 152, 16, 160, 168, 176, 184, 192, 200, 208, 216, 224, 232, 240, 248, 256, 32, 40, 48, 56, 64, 72 }; + public static TestRequired DefaultInstance { + get { return defaultInstance; } + } + + public override TestRequired DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestRequired ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequired__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequired__FieldAccessorTable; } + } + + public const int SingleFieldNumber = 1000; + public static pb::GeneratedExtensionBase Single; + public const int MultiFieldNumber = 1001; + public static pb::GeneratedExtensionBase> Multi; + public const int AFieldNumber = 1; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public const int Dummy2FieldNumber = 2; + private bool hasDummy2; + private int dummy2_; + public bool HasDummy2 { + get { return hasDummy2; } + } + public int Dummy2 { + get { return dummy2_; } + } + + public const int BFieldNumber = 3; + private bool hasB; + private int b_; + public bool HasB { + get { return hasB; } + } + public int B { + get { return b_; } + } + + public const int Dummy4FieldNumber = 4; + private bool hasDummy4; + private int dummy4_; + public bool HasDummy4 { + get { return hasDummy4; } + } + public int Dummy4 { + get { return dummy4_; } + } + + public const int Dummy5FieldNumber = 5; + private bool hasDummy5; + private int dummy5_; + public bool HasDummy5 { + get { return hasDummy5; } + } + public int Dummy5 { + get { return dummy5_; } + } + + public const int Dummy6FieldNumber = 6; + private bool hasDummy6; + private int dummy6_; + public bool HasDummy6 { + get { return hasDummy6; } + } + public int Dummy6 { + get { return dummy6_; } + } + + public const int Dummy7FieldNumber = 7; + private bool hasDummy7; + private int dummy7_; + public bool HasDummy7 { + get { return hasDummy7; } + } + public int Dummy7 { + get { return dummy7_; } + } + + public const int Dummy8FieldNumber = 8; + private bool hasDummy8; + private int dummy8_; + public bool HasDummy8 { + get { return hasDummy8; } + } + public int Dummy8 { + get { return dummy8_; } + } + + public const int Dummy9FieldNumber = 9; + private bool hasDummy9; + private int dummy9_; + public bool HasDummy9 { + get { return hasDummy9; } + } + public int Dummy9 { + get { return dummy9_; } + } + + public const int Dummy10FieldNumber = 10; + private bool hasDummy10; + private int dummy10_; + public bool HasDummy10 { + get { return hasDummy10; } + } + public int Dummy10 { + get { return dummy10_; } + } + + public const int Dummy11FieldNumber = 11; + private bool hasDummy11; + private int dummy11_; + public bool HasDummy11 { + get { return hasDummy11; } + } + public int Dummy11 { + get { return dummy11_; } + } + + public const int Dummy12FieldNumber = 12; + private bool hasDummy12; + private int dummy12_; + public bool HasDummy12 { + get { return hasDummy12; } + } + public int Dummy12 { + get { return dummy12_; } + } + + public const int Dummy13FieldNumber = 13; + private bool hasDummy13; + private int dummy13_; + public bool HasDummy13 { + get { return hasDummy13; } + } + public int Dummy13 { + get { return dummy13_; } + } + + public const int Dummy14FieldNumber = 14; + private bool hasDummy14; + private int dummy14_; + public bool HasDummy14 { + get { return hasDummy14; } + } + public int Dummy14 { + get { return dummy14_; } + } + + public const int Dummy15FieldNumber = 15; + private bool hasDummy15; + private int dummy15_; + public bool HasDummy15 { + get { return hasDummy15; } + } + public int Dummy15 { + get { return dummy15_; } + } + + public const int Dummy16FieldNumber = 16; + private bool hasDummy16; + private int dummy16_; + public bool HasDummy16 { + get { return hasDummy16; } + } + public int Dummy16 { + get { return dummy16_; } + } + + public const int Dummy17FieldNumber = 17; + private bool hasDummy17; + private int dummy17_; + public bool HasDummy17 { + get { return hasDummy17; } + } + public int Dummy17 { + get { return dummy17_; } + } + + public const int Dummy18FieldNumber = 18; + private bool hasDummy18; + private int dummy18_; + public bool HasDummy18 { + get { return hasDummy18; } + } + public int Dummy18 { + get { return dummy18_; } + } + + public const int Dummy19FieldNumber = 19; + private bool hasDummy19; + private int dummy19_; + public bool HasDummy19 { + get { return hasDummy19; } + } + public int Dummy19 { + get { return dummy19_; } + } + + public const int Dummy20FieldNumber = 20; + private bool hasDummy20; + private int dummy20_; + public bool HasDummy20 { + get { return hasDummy20; } + } + public int Dummy20 { + get { return dummy20_; } + } + + public const int Dummy21FieldNumber = 21; + private bool hasDummy21; + private int dummy21_; + public bool HasDummy21 { + get { return hasDummy21; } + } + public int Dummy21 { + get { return dummy21_; } + } + + public const int Dummy22FieldNumber = 22; + private bool hasDummy22; + private int dummy22_; + public bool HasDummy22 { + get { return hasDummy22; } + } + public int Dummy22 { + get { return dummy22_; } + } + + public const int Dummy23FieldNumber = 23; + private bool hasDummy23; + private int dummy23_; + public bool HasDummy23 { + get { return hasDummy23; } + } + public int Dummy23 { + get { return dummy23_; } + } + + public const int Dummy24FieldNumber = 24; + private bool hasDummy24; + private int dummy24_; + public bool HasDummy24 { + get { return hasDummy24; } + } + public int Dummy24 { + get { return dummy24_; } + } + + public const int Dummy25FieldNumber = 25; + private bool hasDummy25; + private int dummy25_; + public bool HasDummy25 { + get { return hasDummy25; } + } + public int Dummy25 { + get { return dummy25_; } + } + + public const int Dummy26FieldNumber = 26; + private bool hasDummy26; + private int dummy26_; + public bool HasDummy26 { + get { return hasDummy26; } + } + public int Dummy26 { + get { return dummy26_; } + } + + public const int Dummy27FieldNumber = 27; + private bool hasDummy27; + private int dummy27_; + public bool HasDummy27 { + get { return hasDummy27; } + } + public int Dummy27 { + get { return dummy27_; } + } + + public const int Dummy28FieldNumber = 28; + private bool hasDummy28; + private int dummy28_; + public bool HasDummy28 { + get { return hasDummy28; } + } + public int Dummy28 { + get { return dummy28_; } + } + + public const int Dummy29FieldNumber = 29; + private bool hasDummy29; + private int dummy29_; + public bool HasDummy29 { + get { return hasDummy29; } + } + public int Dummy29 { + get { return dummy29_; } + } + + public const int Dummy30FieldNumber = 30; + private bool hasDummy30; + private int dummy30_; + public bool HasDummy30 { + get { return hasDummy30; } + } + public int Dummy30 { + get { return dummy30_; } + } + + public const int Dummy31FieldNumber = 31; + private bool hasDummy31; + private int dummy31_; + public bool HasDummy31 { + get { return hasDummy31; } + } + public int Dummy31 { + get { return dummy31_; } + } + + public const int Dummy32FieldNumber = 32; + private bool hasDummy32; + private int dummy32_; + public bool HasDummy32 { + get { return hasDummy32; } + } + public int Dummy32 { + get { return dummy32_; } + } + + public const int CFieldNumber = 33; + private bool hasC; + private int c_; + public bool HasC { + get { return hasC; } + } + public int C { + get { return c_; } + } + + public override bool IsInitialized { + get { + if (!hasA) return false; + if (!hasB) return false; + if (!hasC) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testRequiredFieldNames; + if (hasA) { + output.WriteInt32(1, field_names[0], A); + } + if (hasDummy2) { + output.WriteInt32(2, field_names[13], Dummy2); + } + if (hasB) { + output.WriteInt32(3, field_names[1], B); + } + if (hasDummy4) { + output.WriteInt32(4, field_names[27], Dummy4); + } + if (hasDummy5) { + output.WriteInt32(5, field_names[28], Dummy5); + } + if (hasDummy6) { + output.WriteInt32(6, field_names[29], Dummy6); + } + if (hasDummy7) { + output.WriteInt32(7, field_names[30], Dummy7); + } + if (hasDummy8) { + output.WriteInt32(8, field_names[31], Dummy8); + } + if (hasDummy9) { + output.WriteInt32(9, field_names[32], Dummy9); + } + if (hasDummy10) { + output.WriteInt32(10, field_names[3], Dummy10); + } + if (hasDummy11) { + output.WriteInt32(11, field_names[4], Dummy11); + } + if (hasDummy12) { + output.WriteInt32(12, field_names[5], Dummy12); + } + if (hasDummy13) { + output.WriteInt32(13, field_names[6], Dummy13); + } + if (hasDummy14) { + output.WriteInt32(14, field_names[7], Dummy14); + } + if (hasDummy15) { + output.WriteInt32(15, field_names[8], Dummy15); + } + if (hasDummy16) { + output.WriteInt32(16, field_names[9], Dummy16); + } + if (hasDummy17) { + output.WriteInt32(17, field_names[10], Dummy17); + } + if (hasDummy18) { + output.WriteInt32(18, field_names[11], Dummy18); + } + if (hasDummy19) { + output.WriteInt32(19, field_names[12], Dummy19); + } + if (hasDummy20) { + output.WriteInt32(20, field_names[14], Dummy20); + } + if (hasDummy21) { + output.WriteInt32(21, field_names[15], Dummy21); + } + if (hasDummy22) { + output.WriteInt32(22, field_names[16], Dummy22); + } + if (hasDummy23) { + output.WriteInt32(23, field_names[17], Dummy23); + } + if (hasDummy24) { + output.WriteInt32(24, field_names[18], Dummy24); + } + if (hasDummy25) { + output.WriteInt32(25, field_names[19], Dummy25); + } + if (hasDummy26) { + output.WriteInt32(26, field_names[20], Dummy26); + } + if (hasDummy27) { + output.WriteInt32(27, field_names[21], Dummy27); + } + if (hasDummy28) { + output.WriteInt32(28, field_names[22], Dummy28); + } + if (hasDummy29) { + output.WriteInt32(29, field_names[23], Dummy29); + } + if (hasDummy30) { + output.WriteInt32(30, field_names[24], Dummy30); + } + if (hasDummy31) { + output.WriteInt32(31, field_names[25], Dummy31); + } + if (hasDummy32) { + output.WriteInt32(32, field_names[26], Dummy32); + } + if (hasC) { + output.WriteInt32(33, field_names[2], C); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(1, A); + } + if (hasDummy2) { + size += pb::CodedOutputStream.ComputeInt32Size(2, Dummy2); + } + if (hasB) { + size += pb::CodedOutputStream.ComputeInt32Size(3, B); + } + if (hasDummy4) { + size += pb::CodedOutputStream.ComputeInt32Size(4, Dummy4); + } + if (hasDummy5) { + size += pb::CodedOutputStream.ComputeInt32Size(5, Dummy5); + } + if (hasDummy6) { + size += pb::CodedOutputStream.ComputeInt32Size(6, Dummy6); + } + if (hasDummy7) { + size += pb::CodedOutputStream.ComputeInt32Size(7, Dummy7); + } + if (hasDummy8) { + size += pb::CodedOutputStream.ComputeInt32Size(8, Dummy8); + } + if (hasDummy9) { + size += pb::CodedOutputStream.ComputeInt32Size(9, Dummy9); + } + if (hasDummy10) { + size += pb::CodedOutputStream.ComputeInt32Size(10, Dummy10); + } + if (hasDummy11) { + size += pb::CodedOutputStream.ComputeInt32Size(11, Dummy11); + } + if (hasDummy12) { + size += pb::CodedOutputStream.ComputeInt32Size(12, Dummy12); + } + if (hasDummy13) { + size += pb::CodedOutputStream.ComputeInt32Size(13, Dummy13); + } + if (hasDummy14) { + size += pb::CodedOutputStream.ComputeInt32Size(14, Dummy14); + } + if (hasDummy15) { + size += pb::CodedOutputStream.ComputeInt32Size(15, Dummy15); + } + if (hasDummy16) { + size += pb::CodedOutputStream.ComputeInt32Size(16, Dummy16); + } + if (hasDummy17) { + size += pb::CodedOutputStream.ComputeInt32Size(17, Dummy17); + } + if (hasDummy18) { + size += pb::CodedOutputStream.ComputeInt32Size(18, Dummy18); + } + if (hasDummy19) { + size += pb::CodedOutputStream.ComputeInt32Size(19, Dummy19); + } + if (hasDummy20) { + size += pb::CodedOutputStream.ComputeInt32Size(20, Dummy20); + } + if (hasDummy21) { + size += pb::CodedOutputStream.ComputeInt32Size(21, Dummy21); + } + if (hasDummy22) { + size += pb::CodedOutputStream.ComputeInt32Size(22, Dummy22); + } + if (hasDummy23) { + size += pb::CodedOutputStream.ComputeInt32Size(23, Dummy23); + } + if (hasDummy24) { + size += pb::CodedOutputStream.ComputeInt32Size(24, Dummy24); + } + if (hasDummy25) { + size += pb::CodedOutputStream.ComputeInt32Size(25, Dummy25); + } + if (hasDummy26) { + size += pb::CodedOutputStream.ComputeInt32Size(26, Dummy26); + } + if (hasDummy27) { + size += pb::CodedOutputStream.ComputeInt32Size(27, Dummy27); + } + if (hasDummy28) { + size += pb::CodedOutputStream.ComputeInt32Size(28, Dummy28); + } + if (hasDummy29) { + size += pb::CodedOutputStream.ComputeInt32Size(29, Dummy29); + } + if (hasDummy30) { + size += pb::CodedOutputStream.ComputeInt32Size(30, Dummy30); + } + if (hasDummy31) { + size += pb::CodedOutputStream.ComputeInt32Size(31, Dummy31); + } + if (hasDummy32) { + size += pb::CodedOutputStream.ComputeInt32Size(32, Dummy32); + } + if (hasC) { + size += pb::CodedOutputStream.ComputeInt32Size(33, C); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestRequired ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequired ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequired ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequired ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequired ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequired ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestRequired ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestRequired ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestRequired ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequired ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestRequired MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestRequired prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRequired cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestRequired result; + + private TestRequired PrepareBuilder() { + if (resultIsReadOnly) { + TestRequired original = result; + result = new TestRequired(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestRequired MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor; } + } + + public override TestRequired DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance; } + } + + public override TestRequired BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestRequired) { + return MergeFrom((TestRequired) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestRequired other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + if (other.HasDummy2) { + Dummy2 = other.Dummy2; + } + if (other.HasB) { + B = other.B; + } + if (other.HasDummy4) { + Dummy4 = other.Dummy4; + } + if (other.HasDummy5) { + Dummy5 = other.Dummy5; + } + if (other.HasDummy6) { + Dummy6 = other.Dummy6; + } + if (other.HasDummy7) { + Dummy7 = other.Dummy7; + } + if (other.HasDummy8) { + Dummy8 = other.Dummy8; + } + if (other.HasDummy9) { + Dummy9 = other.Dummy9; + } + if (other.HasDummy10) { + Dummy10 = other.Dummy10; + } + if (other.HasDummy11) { + Dummy11 = other.Dummy11; + } + if (other.HasDummy12) { + Dummy12 = other.Dummy12; + } + if (other.HasDummy13) { + Dummy13 = other.Dummy13; + } + if (other.HasDummy14) { + Dummy14 = other.Dummy14; + } + if (other.HasDummy15) { + Dummy15 = other.Dummy15; + } + if (other.HasDummy16) { + Dummy16 = other.Dummy16; + } + if (other.HasDummy17) { + Dummy17 = other.Dummy17; + } + if (other.HasDummy18) { + Dummy18 = other.Dummy18; + } + if (other.HasDummy19) { + Dummy19 = other.Dummy19; + } + if (other.HasDummy20) { + Dummy20 = other.Dummy20; + } + if (other.HasDummy21) { + Dummy21 = other.Dummy21; + } + if (other.HasDummy22) { + Dummy22 = other.Dummy22; + } + if (other.HasDummy23) { + Dummy23 = other.Dummy23; + } + if (other.HasDummy24) { + Dummy24 = other.Dummy24; + } + if (other.HasDummy25) { + Dummy25 = other.Dummy25; + } + if (other.HasDummy26) { + Dummy26 = other.Dummy26; + } + if (other.HasDummy27) { + Dummy27 = other.Dummy27; + } + if (other.HasDummy28) { + Dummy28 = other.Dummy28; + } + if (other.HasDummy29) { + Dummy29 = other.Dummy29; + } + if (other.HasDummy30) { + Dummy30 = other.Dummy30; + } + if (other.HasDummy31) { + Dummy31 = other.Dummy31; + } + if (other.HasDummy32) { + Dummy32 = other.Dummy32; + } + if (other.HasC) { + C = other.C; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testRequiredFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testRequiredFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 16: { + result.hasDummy2 = input.ReadInt32(ref result.dummy2_); + break; + } + case 24: { + result.hasB = input.ReadInt32(ref result.b_); + break; + } + case 32: { + result.hasDummy4 = input.ReadInt32(ref result.dummy4_); + break; + } + case 40: { + result.hasDummy5 = input.ReadInt32(ref result.dummy5_); + break; + } + case 48: { + result.hasDummy6 = input.ReadInt32(ref result.dummy6_); + break; + } + case 56: { + result.hasDummy7 = input.ReadInt32(ref result.dummy7_); + break; + } + case 64: { + result.hasDummy8 = input.ReadInt32(ref result.dummy8_); + break; + } + case 72: { + result.hasDummy9 = input.ReadInt32(ref result.dummy9_); + break; + } + case 80: { + result.hasDummy10 = input.ReadInt32(ref result.dummy10_); + break; + } + case 88: { + result.hasDummy11 = input.ReadInt32(ref result.dummy11_); + break; + } + case 96: { + result.hasDummy12 = input.ReadInt32(ref result.dummy12_); + break; + } + case 104: { + result.hasDummy13 = input.ReadInt32(ref result.dummy13_); + break; + } + case 112: { + result.hasDummy14 = input.ReadInt32(ref result.dummy14_); + break; + } + case 120: { + result.hasDummy15 = input.ReadInt32(ref result.dummy15_); + break; + } + case 128: { + result.hasDummy16 = input.ReadInt32(ref result.dummy16_); + break; + } + case 136: { + result.hasDummy17 = input.ReadInt32(ref result.dummy17_); + break; + } + case 144: { + result.hasDummy18 = input.ReadInt32(ref result.dummy18_); + break; + } + case 152: { + result.hasDummy19 = input.ReadInt32(ref result.dummy19_); + break; + } + case 160: { + result.hasDummy20 = input.ReadInt32(ref result.dummy20_); + break; + } + case 168: { + result.hasDummy21 = input.ReadInt32(ref result.dummy21_); + break; + } + case 176: { + result.hasDummy22 = input.ReadInt32(ref result.dummy22_); + break; + } + case 184: { + result.hasDummy23 = input.ReadInt32(ref result.dummy23_); + break; + } + case 192: { + result.hasDummy24 = input.ReadInt32(ref result.dummy24_); + break; + } + case 200: { + result.hasDummy25 = input.ReadInt32(ref result.dummy25_); + break; + } + case 208: { + result.hasDummy26 = input.ReadInt32(ref result.dummy26_); + break; + } + case 216: { + result.hasDummy27 = input.ReadInt32(ref result.dummy27_); + break; + } + case 224: { + result.hasDummy28 = input.ReadInt32(ref result.dummy28_); + break; + } + case 232: { + result.hasDummy29 = input.ReadInt32(ref result.dummy29_); + break; + } + case 240: { + result.hasDummy30 = input.ReadInt32(ref result.dummy30_); + break; + } + case 248: { + result.hasDummy31 = input.ReadInt32(ref result.dummy31_); + break; + } + case 256: { + result.hasDummy32 = input.ReadInt32(ref result.dummy32_); + break; + } + case 264: { + result.hasC = input.ReadInt32(ref result.c_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + + public bool HasDummy2 { + get { return result.hasDummy2; } + } + public int Dummy2 { + get { return result.Dummy2; } + set { SetDummy2(value); } + } + public Builder SetDummy2(int value) { + PrepareBuilder(); + result.hasDummy2 = true; + result.dummy2_ = value; + return this; + } + public Builder ClearDummy2() { + PrepareBuilder(); + result.hasDummy2 = false; + result.dummy2_ = 0; + return this; + } + + public bool HasB { + get { return result.hasB; } + } + public int B { + get { return result.B; } + set { SetB(value); } + } + public Builder SetB(int value) { + PrepareBuilder(); + result.hasB = true; + result.b_ = value; + return this; + } + public Builder ClearB() { + PrepareBuilder(); + result.hasB = false; + result.b_ = 0; + return this; + } + + public bool HasDummy4 { + get { return result.hasDummy4; } + } + public int Dummy4 { + get { return result.Dummy4; } + set { SetDummy4(value); } + } + public Builder SetDummy4(int value) { + PrepareBuilder(); + result.hasDummy4 = true; + result.dummy4_ = value; + return this; + } + public Builder ClearDummy4() { + PrepareBuilder(); + result.hasDummy4 = false; + result.dummy4_ = 0; + return this; + } + + public bool HasDummy5 { + get { return result.hasDummy5; } + } + public int Dummy5 { + get { return result.Dummy5; } + set { SetDummy5(value); } + } + public Builder SetDummy5(int value) { + PrepareBuilder(); + result.hasDummy5 = true; + result.dummy5_ = value; + return this; + } + public Builder ClearDummy5() { + PrepareBuilder(); + result.hasDummy5 = false; + result.dummy5_ = 0; + return this; + } + + public bool HasDummy6 { + get { return result.hasDummy6; } + } + public int Dummy6 { + get { return result.Dummy6; } + set { SetDummy6(value); } + } + public Builder SetDummy6(int value) { + PrepareBuilder(); + result.hasDummy6 = true; + result.dummy6_ = value; + return this; + } + public Builder ClearDummy6() { + PrepareBuilder(); + result.hasDummy6 = false; + result.dummy6_ = 0; + return this; + } + + public bool HasDummy7 { + get { return result.hasDummy7; } + } + public int Dummy7 { + get { return result.Dummy7; } + set { SetDummy7(value); } + } + public Builder SetDummy7(int value) { + PrepareBuilder(); + result.hasDummy7 = true; + result.dummy7_ = value; + return this; + } + public Builder ClearDummy7() { + PrepareBuilder(); + result.hasDummy7 = false; + result.dummy7_ = 0; + return this; + } + + public bool HasDummy8 { + get { return result.hasDummy8; } + } + public int Dummy8 { + get { return result.Dummy8; } + set { SetDummy8(value); } + } + public Builder SetDummy8(int value) { + PrepareBuilder(); + result.hasDummy8 = true; + result.dummy8_ = value; + return this; + } + public Builder ClearDummy8() { + PrepareBuilder(); + result.hasDummy8 = false; + result.dummy8_ = 0; + return this; + } + + public bool HasDummy9 { + get { return result.hasDummy9; } + } + public int Dummy9 { + get { return result.Dummy9; } + set { SetDummy9(value); } + } + public Builder SetDummy9(int value) { + PrepareBuilder(); + result.hasDummy9 = true; + result.dummy9_ = value; + return this; + } + public Builder ClearDummy9() { + PrepareBuilder(); + result.hasDummy9 = false; + result.dummy9_ = 0; + return this; + } + + public bool HasDummy10 { + get { return result.hasDummy10; } + } + public int Dummy10 { + get { return result.Dummy10; } + set { SetDummy10(value); } + } + public Builder SetDummy10(int value) { + PrepareBuilder(); + result.hasDummy10 = true; + result.dummy10_ = value; + return this; + } + public Builder ClearDummy10() { + PrepareBuilder(); + result.hasDummy10 = false; + result.dummy10_ = 0; + return this; + } + + public bool HasDummy11 { + get { return result.hasDummy11; } + } + public int Dummy11 { + get { return result.Dummy11; } + set { SetDummy11(value); } + } + public Builder SetDummy11(int value) { + PrepareBuilder(); + result.hasDummy11 = true; + result.dummy11_ = value; + return this; + } + public Builder ClearDummy11() { + PrepareBuilder(); + result.hasDummy11 = false; + result.dummy11_ = 0; + return this; + } + + public bool HasDummy12 { + get { return result.hasDummy12; } + } + public int Dummy12 { + get { return result.Dummy12; } + set { SetDummy12(value); } + } + public Builder SetDummy12(int value) { + PrepareBuilder(); + result.hasDummy12 = true; + result.dummy12_ = value; + return this; + } + public Builder ClearDummy12() { + PrepareBuilder(); + result.hasDummy12 = false; + result.dummy12_ = 0; + return this; + } + + public bool HasDummy13 { + get { return result.hasDummy13; } + } + public int Dummy13 { + get { return result.Dummy13; } + set { SetDummy13(value); } + } + public Builder SetDummy13(int value) { + PrepareBuilder(); + result.hasDummy13 = true; + result.dummy13_ = value; + return this; + } + public Builder ClearDummy13() { + PrepareBuilder(); + result.hasDummy13 = false; + result.dummy13_ = 0; + return this; + } + + public bool HasDummy14 { + get { return result.hasDummy14; } + } + public int Dummy14 { + get { return result.Dummy14; } + set { SetDummy14(value); } + } + public Builder SetDummy14(int value) { + PrepareBuilder(); + result.hasDummy14 = true; + result.dummy14_ = value; + return this; + } + public Builder ClearDummy14() { + PrepareBuilder(); + result.hasDummy14 = false; + result.dummy14_ = 0; + return this; + } + + public bool HasDummy15 { + get { return result.hasDummy15; } + } + public int Dummy15 { + get { return result.Dummy15; } + set { SetDummy15(value); } + } + public Builder SetDummy15(int value) { + PrepareBuilder(); + result.hasDummy15 = true; + result.dummy15_ = value; + return this; + } + public Builder ClearDummy15() { + PrepareBuilder(); + result.hasDummy15 = false; + result.dummy15_ = 0; + return this; + } + + public bool HasDummy16 { + get { return result.hasDummy16; } + } + public int Dummy16 { + get { return result.Dummy16; } + set { SetDummy16(value); } + } + public Builder SetDummy16(int value) { + PrepareBuilder(); + result.hasDummy16 = true; + result.dummy16_ = value; + return this; + } + public Builder ClearDummy16() { + PrepareBuilder(); + result.hasDummy16 = false; + result.dummy16_ = 0; + return this; + } + + public bool HasDummy17 { + get { return result.hasDummy17; } + } + public int Dummy17 { + get { return result.Dummy17; } + set { SetDummy17(value); } + } + public Builder SetDummy17(int value) { + PrepareBuilder(); + result.hasDummy17 = true; + result.dummy17_ = value; + return this; + } + public Builder ClearDummy17() { + PrepareBuilder(); + result.hasDummy17 = false; + result.dummy17_ = 0; + return this; + } + + public bool HasDummy18 { + get { return result.hasDummy18; } + } + public int Dummy18 { + get { return result.Dummy18; } + set { SetDummy18(value); } + } + public Builder SetDummy18(int value) { + PrepareBuilder(); + result.hasDummy18 = true; + result.dummy18_ = value; + return this; + } + public Builder ClearDummy18() { + PrepareBuilder(); + result.hasDummy18 = false; + result.dummy18_ = 0; + return this; + } + + public bool HasDummy19 { + get { return result.hasDummy19; } + } + public int Dummy19 { + get { return result.Dummy19; } + set { SetDummy19(value); } + } + public Builder SetDummy19(int value) { + PrepareBuilder(); + result.hasDummy19 = true; + result.dummy19_ = value; + return this; + } + public Builder ClearDummy19() { + PrepareBuilder(); + result.hasDummy19 = false; + result.dummy19_ = 0; + return this; + } + + public bool HasDummy20 { + get { return result.hasDummy20; } + } + public int Dummy20 { + get { return result.Dummy20; } + set { SetDummy20(value); } + } + public Builder SetDummy20(int value) { + PrepareBuilder(); + result.hasDummy20 = true; + result.dummy20_ = value; + return this; + } + public Builder ClearDummy20() { + PrepareBuilder(); + result.hasDummy20 = false; + result.dummy20_ = 0; + return this; + } + + public bool HasDummy21 { + get { return result.hasDummy21; } + } + public int Dummy21 { + get { return result.Dummy21; } + set { SetDummy21(value); } + } + public Builder SetDummy21(int value) { + PrepareBuilder(); + result.hasDummy21 = true; + result.dummy21_ = value; + return this; + } + public Builder ClearDummy21() { + PrepareBuilder(); + result.hasDummy21 = false; + result.dummy21_ = 0; + return this; + } + + public bool HasDummy22 { + get { return result.hasDummy22; } + } + public int Dummy22 { + get { return result.Dummy22; } + set { SetDummy22(value); } + } + public Builder SetDummy22(int value) { + PrepareBuilder(); + result.hasDummy22 = true; + result.dummy22_ = value; + return this; + } + public Builder ClearDummy22() { + PrepareBuilder(); + result.hasDummy22 = false; + result.dummy22_ = 0; + return this; + } + + public bool HasDummy23 { + get { return result.hasDummy23; } + } + public int Dummy23 { + get { return result.Dummy23; } + set { SetDummy23(value); } + } + public Builder SetDummy23(int value) { + PrepareBuilder(); + result.hasDummy23 = true; + result.dummy23_ = value; + return this; + } + public Builder ClearDummy23() { + PrepareBuilder(); + result.hasDummy23 = false; + result.dummy23_ = 0; + return this; + } + + public bool HasDummy24 { + get { return result.hasDummy24; } + } + public int Dummy24 { + get { return result.Dummy24; } + set { SetDummy24(value); } + } + public Builder SetDummy24(int value) { + PrepareBuilder(); + result.hasDummy24 = true; + result.dummy24_ = value; + return this; + } + public Builder ClearDummy24() { + PrepareBuilder(); + result.hasDummy24 = false; + result.dummy24_ = 0; + return this; + } + + public bool HasDummy25 { + get { return result.hasDummy25; } + } + public int Dummy25 { + get { return result.Dummy25; } + set { SetDummy25(value); } + } + public Builder SetDummy25(int value) { + PrepareBuilder(); + result.hasDummy25 = true; + result.dummy25_ = value; + return this; + } + public Builder ClearDummy25() { + PrepareBuilder(); + result.hasDummy25 = false; + result.dummy25_ = 0; + return this; + } + + public bool HasDummy26 { + get { return result.hasDummy26; } + } + public int Dummy26 { + get { return result.Dummy26; } + set { SetDummy26(value); } + } + public Builder SetDummy26(int value) { + PrepareBuilder(); + result.hasDummy26 = true; + result.dummy26_ = value; + return this; + } + public Builder ClearDummy26() { + PrepareBuilder(); + result.hasDummy26 = false; + result.dummy26_ = 0; + return this; + } + + public bool HasDummy27 { + get { return result.hasDummy27; } + } + public int Dummy27 { + get { return result.Dummy27; } + set { SetDummy27(value); } + } + public Builder SetDummy27(int value) { + PrepareBuilder(); + result.hasDummy27 = true; + result.dummy27_ = value; + return this; + } + public Builder ClearDummy27() { + PrepareBuilder(); + result.hasDummy27 = false; + result.dummy27_ = 0; + return this; + } + + public bool HasDummy28 { + get { return result.hasDummy28; } + } + public int Dummy28 { + get { return result.Dummy28; } + set { SetDummy28(value); } + } + public Builder SetDummy28(int value) { + PrepareBuilder(); + result.hasDummy28 = true; + result.dummy28_ = value; + return this; + } + public Builder ClearDummy28() { + PrepareBuilder(); + result.hasDummy28 = false; + result.dummy28_ = 0; + return this; + } + + public bool HasDummy29 { + get { return result.hasDummy29; } + } + public int Dummy29 { + get { return result.Dummy29; } + set { SetDummy29(value); } + } + public Builder SetDummy29(int value) { + PrepareBuilder(); + result.hasDummy29 = true; + result.dummy29_ = value; + return this; + } + public Builder ClearDummy29() { + PrepareBuilder(); + result.hasDummy29 = false; + result.dummy29_ = 0; + return this; + } + + public bool HasDummy30 { + get { return result.hasDummy30; } + } + public int Dummy30 { + get { return result.Dummy30; } + set { SetDummy30(value); } + } + public Builder SetDummy30(int value) { + PrepareBuilder(); + result.hasDummy30 = true; + result.dummy30_ = value; + return this; + } + public Builder ClearDummy30() { + PrepareBuilder(); + result.hasDummy30 = false; + result.dummy30_ = 0; + return this; + } + + public bool HasDummy31 { + get { return result.hasDummy31; } + } + public int Dummy31 { + get { return result.Dummy31; } + set { SetDummy31(value); } + } + public Builder SetDummy31(int value) { + PrepareBuilder(); + result.hasDummy31 = true; + result.dummy31_ = value; + return this; + } + public Builder ClearDummy31() { + PrepareBuilder(); + result.hasDummy31 = false; + result.dummy31_ = 0; + return this; + } + + public bool HasDummy32 { + get { return result.hasDummy32; } + } + public int Dummy32 { + get { return result.Dummy32; } + set { SetDummy32(value); } + } + public Builder SetDummy32(int value) { + PrepareBuilder(); + result.hasDummy32 = true; + result.dummy32_ = value; + return this; + } + public Builder ClearDummy32() { + PrepareBuilder(); + result.hasDummy32 = false; + result.dummy32_ = 0; + return this; + } + + public bool HasC { + get { return result.hasC; } + } + public int C { + get { return result.C; } + set { SetC(value); } + } + public Builder SetC(int value) { + PrepareBuilder(); + result.hasC = true; + result.c_ = value; + return this; + } + public Builder ClearC() { + PrepareBuilder(); + result.hasC = false; + result.c_ = 0; + return this; + } + } + static TestRequired() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestRequiredForeign : pb::GeneratedMessage { + private TestRequiredForeign() { } + private static readonly TestRequiredForeign defaultInstance = new TestRequiredForeign().MakeReadOnly(); + private static readonly string[] _testRequiredForeignFieldNames = new string[] { "dummy", "optional_message", "repeated_message" }; + private static readonly uint[] _testRequiredForeignFieldTags = new uint[] { 24, 10, 18 }; + public static TestRequiredForeign DefaultInstance { + get { return defaultInstance; } + } + + public override TestRequiredForeign DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestRequiredForeign ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredForeign__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable; } + } + + public const int OptionalMessageFieldNumber = 1; + private bool hasOptionalMessage; + private global::Google.ProtocolBuffers.TestProtos.TestRequired optionalMessage_; + public bool HasOptionalMessage { + get { return hasOptionalMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequired OptionalMessage { + get { return optionalMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance; } + } + + public const int RepeatedMessageFieldNumber = 2; + private pbc::PopsicleList repeatedMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedMessageList { + get { return repeatedMessage_; } + } + public int RepeatedMessageCount { + get { return repeatedMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequired GetRepeatedMessage(int index) { + return repeatedMessage_[index]; + } + + public const int DummyFieldNumber = 3; + private bool hasDummy; + private int dummy_; + public bool HasDummy { + get { return hasDummy; } + } + public int Dummy { + get { return dummy_; } + } + + public override bool IsInitialized { + get { + if (HasOptionalMessage) { + if (!OptionalMessage.IsInitialized) return false; + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestRequired element in RepeatedMessageList) { + if (!element.IsInitialized) return false; + } + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testRequiredForeignFieldNames; + if (hasOptionalMessage) { + output.WriteMessage(1, field_names[1], OptionalMessage); + } + if (repeatedMessage_.Count > 0) { + output.WriteMessageArray(2, field_names[2], repeatedMessage_); + } + if (hasDummy) { + output.WriteInt32(3, field_names[0], Dummy); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOptionalMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(1, OptionalMessage); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestRequired element in RepeatedMessageList) { + size += pb::CodedOutputStream.ComputeMessageSize(2, element); + } + if (hasDummy) { + size += pb::CodedOutputStream.ComputeInt32Size(3, Dummy); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestRequiredForeign ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestRequiredForeign ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestRequiredForeign ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestRequiredForeign MakeReadOnly() { + repeatedMessage_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestRequiredForeign prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRequiredForeign cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestRequiredForeign result; + + private TestRequiredForeign PrepareBuilder() { + if (resultIsReadOnly) { + TestRequiredForeign original = result; + result = new TestRequiredForeign(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestRequiredForeign MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.Descriptor; } + } + + public override TestRequiredForeign DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.DefaultInstance; } + } + + public override TestRequiredForeign BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestRequiredForeign) { + return MergeFrom((TestRequiredForeign) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestRequiredForeign other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOptionalMessage) { + MergeOptionalMessage(other.OptionalMessage); + } + if (other.repeatedMessage_.Count != 0) { + result.repeatedMessage_.Add(other.repeatedMessage_); + } + if (other.HasDummy) { + Dummy = other.Dummy; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testRequiredForeignFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testRequiredForeignFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(); + if (result.hasOptionalMessage) { + subBuilder.MergeFrom(OptionalMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalMessage = subBuilder.BuildPartial(); + break; + } + case 18: { + input.ReadMessageArray(tag, field_name, result.repeatedMessage_, global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance, extensionRegistry); + break; + } + case 24: { + result.hasDummy = input.ReadInt32(ref result.dummy_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasOptionalMessage { + get { return result.hasOptionalMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequired OptionalMessage { + get { return result.OptionalMessage; } + set { SetOptionalMessage(value); } + } + public Builder SetOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalMessage = true; + result.optionalMessage_ = value; + return this; + } + public Builder SetOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalMessage = true; + result.optionalMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalMessage && + result.optionalMessage_ != global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) { + result.optionalMessage_ = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(result.optionalMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalMessage_ = value; + } + result.hasOptionalMessage = true; + return this; + } + public Builder ClearOptionalMessage() { + PrepareBuilder(); + result.hasOptionalMessage = false; + result.optionalMessage_ = null; + return this; + } + + public pbc::IPopsicleList RepeatedMessageList { + get { return PrepareBuilder().repeatedMessage_; } + } + public int RepeatedMessageCount { + get { return result.RepeatedMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequired GetRepeatedMessage(int index) { + return result.GetRepeatedMessage(index); + } + public Builder SetRepeatedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestRequired value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedMessage_[index] = value; + return this; + } + public Builder SetRepeatedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedMessage_.Add(value); + return this; + } + public Builder AddRepeatedMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedMessage(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedMessage_.Add(values); + return this; + } + public Builder ClearRepeatedMessage() { + PrepareBuilder(); + result.repeatedMessage_.Clear(); + return this; + } + + public bool HasDummy { + get { return result.hasDummy; } + } + public int Dummy { + get { return result.Dummy; } + set { SetDummy(value); } + } + public Builder SetDummy(int value) { + PrepareBuilder(); + result.hasDummy = true; + result.dummy_ = value; + return this; + } + public Builder ClearDummy() { + PrepareBuilder(); + result.hasDummy = false; + result.dummy_ = 0; + return this; + } + } + static TestRequiredForeign() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestForeignNested : pb::GeneratedMessage { + private TestForeignNested() { } + private static readonly TestForeignNested defaultInstance = new TestForeignNested().MakeReadOnly(); + private static readonly string[] _testForeignNestedFieldNames = new string[] { "foreign_nested" }; + private static readonly uint[] _testForeignNestedFieldTags = new uint[] { 10 }; + public static TestForeignNested DefaultInstance { + get { return defaultInstance; } + } + + public override TestForeignNested DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestForeignNested ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestForeignNested__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable; } + } + + public const int ForeignNestedFieldNumber = 1; + private bool hasForeignNested; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage foreignNested_; + public bool HasForeignNested { + get { return hasForeignNested; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage ForeignNested { + get { return foreignNested_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testForeignNestedFieldNames; + if (hasForeignNested) { + output.WriteMessage(1, field_names[0], ForeignNested); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasForeignNested) { + size += pb::CodedOutputStream.ComputeMessageSize(1, ForeignNested); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestForeignNested ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestForeignNested ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestForeignNested ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestForeignNested ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestForeignNested ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestForeignNested ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestForeignNested ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestForeignNested ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestForeignNested ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestForeignNested ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestForeignNested MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestForeignNested prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestForeignNested cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestForeignNested result; + + private TestForeignNested PrepareBuilder() { + if (resultIsReadOnly) { + TestForeignNested original = result; + result = new TestForeignNested(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestForeignNested MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestForeignNested.Descriptor; } + } + + public override TestForeignNested DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestForeignNested.DefaultInstance; } + } + + public override TestForeignNested BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestForeignNested) { + return MergeFrom((TestForeignNested) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestForeignNested other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestForeignNested.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasForeignNested) { + MergeForeignNested(other.ForeignNested); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testForeignNestedFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testForeignNestedFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); + if (result.hasForeignNested) { + subBuilder.MergeFrom(ForeignNested); + } + input.ReadMessage(subBuilder, extensionRegistry); + ForeignNested = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasForeignNested { + get { return result.hasForeignNested; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage ForeignNested { + get { return result.ForeignNested; } + set { SetForeignNested(value); } + } + public Builder SetForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasForeignNested = true; + result.foreignNested_ = value; + return this; + } + public Builder SetForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasForeignNested = true; + result.foreignNested_ = builderForValue.Build(); + return this; + } + public Builder MergeForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasForeignNested && + result.foreignNested_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { + result.foreignNested_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.foreignNested_).MergeFrom(value).BuildPartial(); + } else { + result.foreignNested_ = value; + } + result.hasForeignNested = true; + return this; + } + public Builder ClearForeignNested() { + PrepareBuilder(); + result.hasForeignNested = false; + result.foreignNested_ = null; + return this; + } + } + static TestForeignNested() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestEmptyMessage : pb::GeneratedMessage { + private TestEmptyMessage() { } + private static readonly TestEmptyMessage defaultInstance = new TestEmptyMessage().MakeReadOnly(); + private static readonly string[] _testEmptyMessageFieldNames = new string[] { }; + private static readonly uint[] _testEmptyMessageFieldTags = new uint[] { }; + public static TestEmptyMessage DefaultInstance { + get { return defaultInstance; } + } + + public override TestEmptyMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestEmptyMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testEmptyMessageFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestEmptyMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestEmptyMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestEmptyMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestEmptyMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestEmptyMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestEmptyMessage result; + + private TestEmptyMessage PrepareBuilder() { + if (resultIsReadOnly) { + TestEmptyMessage original = result; + result = new TestEmptyMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestEmptyMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.Descriptor; } + } + + public override TestEmptyMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.DefaultInstance; } + } + + public override TestEmptyMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestEmptyMessage) { + return MergeFrom((TestEmptyMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestEmptyMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testEmptyMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestEmptyMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestEmptyMessageWithExtensions : pb::ExtendableMessage { + private TestEmptyMessageWithExtensions() { } + private static readonly TestEmptyMessageWithExtensions defaultInstance = new TestEmptyMessageWithExtensions().MakeReadOnly(); + private static readonly string[] _testEmptyMessageWithExtensionsFieldNames = new string[] { }; + private static readonly uint[] _testEmptyMessageWithExtensionsFieldTags = new uint[] { }; + public static TestEmptyMessageWithExtensions DefaultInstance { + get { return defaultInstance; } + } + + public override TestEmptyMessageWithExtensions DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestEmptyMessageWithExtensions ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testEmptyMessageWithExtensionsFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestEmptyMessageWithExtensions ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestEmptyMessageWithExtensions MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestEmptyMessageWithExtensions prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestEmptyMessageWithExtensions cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestEmptyMessageWithExtensions result; + + private TestEmptyMessageWithExtensions PrepareBuilder() { + if (resultIsReadOnly) { + TestEmptyMessageWithExtensions original = result; + result = new TestEmptyMessageWithExtensions(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestEmptyMessageWithExtensions MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.Descriptor; } + } + + public override TestEmptyMessageWithExtensions DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.DefaultInstance; } + } + + public override TestEmptyMessageWithExtensions BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestEmptyMessageWithExtensions) { + return MergeFrom((TestEmptyMessageWithExtensions) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestEmptyMessageWithExtensions other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageWithExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testEmptyMessageWithExtensionsFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestEmptyMessageWithExtensions() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestMultipleExtensionRanges : pb::ExtendableMessage { + private TestMultipleExtensionRanges() { } + private static readonly TestMultipleExtensionRanges defaultInstance = new TestMultipleExtensionRanges().MakeReadOnly(); + private static readonly string[] _testMultipleExtensionRangesFieldNames = new string[] { }; + private static readonly uint[] _testMultipleExtensionRangesFieldTags = new uint[] { }; + public static TestMultipleExtensionRanges DefaultInstance { + get { return defaultInstance; } + } + + public override TestMultipleExtensionRanges DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestMultipleExtensionRanges ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testMultipleExtensionRangesFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(43, output); + extensionWriter.WriteUntil(4244, output); + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestMultipleExtensionRanges ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestMultipleExtensionRanges MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestMultipleExtensionRanges prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestMultipleExtensionRanges cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestMultipleExtensionRanges result; + + private TestMultipleExtensionRanges PrepareBuilder() { + if (resultIsReadOnly) { + TestMultipleExtensionRanges original = result; + result = new TestMultipleExtensionRanges(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestMultipleExtensionRanges MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.Descriptor; } + } + + public override TestMultipleExtensionRanges DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.DefaultInstance; } + } + + public override TestMultipleExtensionRanges BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestMultipleExtensionRanges) { + return MergeFrom((TestMultipleExtensionRanges) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestMultipleExtensionRanges other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testMultipleExtensionRangesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testMultipleExtensionRangesFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestMultipleExtensionRanges() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestReallyLargeTagNumber : pb::GeneratedMessage { + private TestReallyLargeTagNumber() { } + private static readonly TestReallyLargeTagNumber defaultInstance = new TestReallyLargeTagNumber().MakeReadOnly(); + private static readonly string[] _testReallyLargeTagNumberFieldNames = new string[] { "a", "bb" }; + private static readonly uint[] _testReallyLargeTagNumberFieldTags = new uint[] { 8, 2147483640 }; + public static TestReallyLargeTagNumber DefaultInstance { + get { return defaultInstance; } + } + + public override TestReallyLargeTagNumber DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestReallyLargeTagNumber ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public const int BbFieldNumber = 268435455; + private bool hasBb; + private int bb_; + public bool HasBb { + get { return hasBb; } + } + public int Bb { + get { return bb_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testReallyLargeTagNumberFieldNames; + if (hasA) { + output.WriteInt32(1, field_names[0], A); + } + if (hasBb) { + output.WriteInt32(268435455, field_names[1], Bb); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(1, A); + } + if (hasBb) { + size += pb::CodedOutputStream.ComputeInt32Size(268435455, Bb); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestReallyLargeTagNumber ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestReallyLargeTagNumber MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestReallyLargeTagNumber prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestReallyLargeTagNumber cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestReallyLargeTagNumber result; + + private TestReallyLargeTagNumber PrepareBuilder() { + if (resultIsReadOnly) { + TestReallyLargeTagNumber original = result; + result = new TestReallyLargeTagNumber(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestReallyLargeTagNumber MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.Descriptor; } + } + + public override TestReallyLargeTagNumber DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.DefaultInstance; } + } + + public override TestReallyLargeTagNumber BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestReallyLargeTagNumber) { + return MergeFrom((TestReallyLargeTagNumber) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestReallyLargeTagNumber other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + if (other.HasBb) { + Bb = other.Bb; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testReallyLargeTagNumberFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testReallyLargeTagNumberFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 2147483640: { + result.hasBb = input.ReadInt32(ref result.bb_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + + public bool HasBb { + get { return result.hasBb; } + } + public int Bb { + get { return result.Bb; } + set { SetBb(value); } + } + public Builder SetBb(int value) { + PrepareBuilder(); + result.hasBb = true; + result.bb_ = value; + return this; + } + public Builder ClearBb() { + PrepareBuilder(); + result.hasBb = false; + result.bb_ = 0; + return this; + } + } + static TestReallyLargeTagNumber() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestRecursiveMessage : pb::GeneratedMessage { + private TestRecursiveMessage() { } + private static readonly TestRecursiveMessage defaultInstance = new TestRecursiveMessage().MakeReadOnly(); + private static readonly string[] _testRecursiveMessageFieldNames = new string[] { "a", "i" }; + private static readonly uint[] _testRecursiveMessageFieldTags = new uint[] { 10, 16 }; + public static TestRecursiveMessage DefaultInstance { + get { return defaultInstance; } + } + + public override TestRecursiveMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestRecursiveMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage a_; + public bool HasA { + get { return hasA; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage A { + get { return a_ ?? global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance; } + } + + public const int IFieldNumber = 2; + private bool hasI; + private int i_; + public bool HasI { + get { return hasI; } + } + public int I { + get { return i_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testRecursiveMessageFieldNames; + if (hasA) { + output.WriteMessage(1, field_names[0], A); + } + if (hasI) { + output.WriteInt32(2, field_names[1], I); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeMessageSize(1, A); + } + if (hasI) { + size += pb::CodedOutputStream.ComputeInt32Size(2, I); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestRecursiveMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestRecursiveMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestRecursiveMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestRecursiveMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestRecursiveMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRecursiveMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestRecursiveMessage result; + + private TestRecursiveMessage PrepareBuilder() { + if (resultIsReadOnly) { + TestRecursiveMessage original = result; + result = new TestRecursiveMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestRecursiveMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Descriptor; } + } + + public override TestRecursiveMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance; } + } + + public override TestRecursiveMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestRecursiveMessage) { + return MergeFrom((TestRecursiveMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestRecursiveMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + MergeA(other.A); + } + if (other.HasI) { + I = other.I; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testRecursiveMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testRecursiveMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.CreateBuilder(); + if (result.hasA) { + subBuilder.MergeFrom(A); + } + input.ReadMessage(subBuilder, extensionRegistry); + A = subBuilder.BuildPartial(); + break; + } + case 16: { + result.hasI = input.ReadInt32(ref result.i_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasA = true; + result.a_ = builderForValue.Build(); + return this; + } + public Builder MergeA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasA && + result.a_ != global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance) { + result.a_ = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.CreateBuilder(result.a_).MergeFrom(value).BuildPartial(); + } else { + result.a_ = value; + } + result.hasA = true; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = null; + return this; + } + + public bool HasI { + get { return result.hasI; } + } + public int I { + get { return result.I; } + set { SetI(value); } + } + public Builder SetI(int value) { + PrepareBuilder(); + result.hasI = true; + result.i_ = value; + return this; + } + public Builder ClearI() { + PrepareBuilder(); + result.hasI = false; + result.i_ = 0; + return this; + } + } + static TestRecursiveMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestMutualRecursionA : pb::GeneratedMessage { + private TestMutualRecursionA() { } + private static readonly TestMutualRecursionA defaultInstance = new TestMutualRecursionA().MakeReadOnly(); + private static readonly string[] _testMutualRecursionAFieldNames = new string[] { "bb" }; + private static readonly uint[] _testMutualRecursionAFieldTags = new uint[] { 10 }; + public static TestMutualRecursionA DefaultInstance { + get { return defaultInstance; } + } + + public override TestMutualRecursionA DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestMutualRecursionA ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable; } + } + + public const int BbFieldNumber = 1; + private bool hasBb; + private global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB bb_; + public bool HasBb { + get { return hasBb; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB Bb { + get { return bb_ ?? global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testMutualRecursionAFieldNames; + if (hasBb) { + output.WriteMessage(1, field_names[0], Bb); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasBb) { + size += pb::CodedOutputStream.ComputeMessageSize(1, Bb); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestMutualRecursionA ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionA ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestMutualRecursionA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestMutualRecursionA MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestMutualRecursionA prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestMutualRecursionA cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestMutualRecursionA result; + + private TestMutualRecursionA PrepareBuilder() { + if (resultIsReadOnly) { + TestMutualRecursionA original = result; + result = new TestMutualRecursionA(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestMutualRecursionA MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Descriptor; } + } + + public override TestMutualRecursionA DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance; } + } + + public override TestMutualRecursionA BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestMutualRecursionA) { + return MergeFrom((TestMutualRecursionA) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestMutualRecursionA other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasBb) { + MergeBb(other.Bb); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testMutualRecursionAFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testMutualRecursionAFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.CreateBuilder(); + if (result.hasBb) { + subBuilder.MergeFrom(Bb); + } + input.ReadMessage(subBuilder, extensionRegistry); + Bb = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasBb { + get { return result.hasBb; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB Bb { + get { return result.Bb; } + set { SetBb(value); } + } + public Builder SetBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBb = true; + result.bb_ = value; + return this; + } + public Builder SetBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasBb = true; + result.bb_ = builderForValue.Build(); + return this; + } + public Builder MergeBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasBb && + result.bb_ != global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance) { + result.bb_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.CreateBuilder(result.bb_).MergeFrom(value).BuildPartial(); + } else { + result.bb_ = value; + } + result.hasBb = true; + return this; + } + public Builder ClearBb() { + PrepareBuilder(); + result.hasBb = false; + result.bb_ = null; + return this; + } + } + static TestMutualRecursionA() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestMutualRecursionB : pb::GeneratedMessage { + private TestMutualRecursionB() { } + private static readonly TestMutualRecursionB defaultInstance = new TestMutualRecursionB().MakeReadOnly(); + private static readonly string[] _testMutualRecursionBFieldNames = new string[] { "a", "optional_int32" }; + private static readonly uint[] _testMutualRecursionBFieldTags = new uint[] { 10, 16 }; + public static TestMutualRecursionB DefaultInstance { + get { return defaultInstance; } + } + + public override TestMutualRecursionB DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestMutualRecursionB ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA a_; + public bool HasA { + get { return hasA; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA A { + get { return a_ ?? global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance; } + } + + public const int OptionalInt32FieldNumber = 2; + private bool hasOptionalInt32; + private int optionalInt32_; + public bool HasOptionalInt32 { + get { return hasOptionalInt32; } + } + public int OptionalInt32 { + get { return optionalInt32_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testMutualRecursionBFieldNames; + if (hasA) { + output.WriteMessage(1, field_names[0], A); + } + if (hasOptionalInt32) { + output.WriteInt32(2, field_names[1], OptionalInt32); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeMessageSize(1, A); + } + if (hasOptionalInt32) { + size += pb::CodedOutputStream.ComputeInt32Size(2, OptionalInt32); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestMutualRecursionB ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionB ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestMutualRecursionB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestMutualRecursionB MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestMutualRecursionB prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestMutualRecursionB cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestMutualRecursionB result; + + private TestMutualRecursionB PrepareBuilder() { + if (resultIsReadOnly) { + TestMutualRecursionB original = result; + result = new TestMutualRecursionB(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestMutualRecursionB MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Descriptor; } + } + + public override TestMutualRecursionB DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance; } + } + + public override TestMutualRecursionB BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestMutualRecursionB) { + return MergeFrom((TestMutualRecursionB) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestMutualRecursionB other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + MergeA(other.A); + } + if (other.HasOptionalInt32) { + OptionalInt32 = other.OptionalInt32; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testMutualRecursionBFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testMutualRecursionBFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.CreateBuilder(); + if (result.hasA) { + subBuilder.MergeFrom(A); + } + input.ReadMessage(subBuilder, extensionRegistry); + A = subBuilder.BuildPartial(); + break; + } + case 16: { + result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasA = true; + result.a_ = builderForValue.Build(); + return this; + } + public Builder MergeA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasA && + result.a_ != global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance) { + result.a_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.CreateBuilder(result.a_).MergeFrom(value).BuildPartial(); + } else { + result.a_ = value; + } + result.hasA = true; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = null; + return this; + } + + public bool HasOptionalInt32 { + get { return result.hasOptionalInt32; } + } + public int OptionalInt32 { + get { return result.OptionalInt32; } + set { SetOptionalInt32(value); } + } + public Builder SetOptionalInt32(int value) { + PrepareBuilder(); + result.hasOptionalInt32 = true; + result.optionalInt32_ = value; + return this; + } + public Builder ClearOptionalInt32() { + PrepareBuilder(); + result.hasOptionalInt32 = false; + result.optionalInt32_ = 0; + return this; + } + } + static TestMutualRecursionB() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestDupFieldNumber : pb::GeneratedMessage { + private TestDupFieldNumber() { } + private static readonly TestDupFieldNumber defaultInstance = new TestDupFieldNumber().MakeReadOnly(); + private static readonly string[] _testDupFieldNumberFieldNames = new string[] { "a", "bar", "foo" }; + private static readonly uint[] _testDupFieldNumberFieldTags = new uint[] { 8, 27, 19 }; + public static TestDupFieldNumber DefaultInstance { + get { return defaultInstance; } + } + + public override TestDupFieldNumber DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestDupFieldNumber ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Foo : pb::GeneratedMessage { + private Foo() { } + private static readonly Foo defaultInstance = new Foo().MakeReadOnly(); + private static readonly string[] _fooFieldNames = new string[] { "a" }; + private static readonly uint[] _fooFieldTags = new uint[] { 8 }; + public static Foo DefaultInstance { + get { return defaultInstance; } + } + + public override Foo DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Foo ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _fooFieldNames; + if (hasA) { + output.WriteInt32(1, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(1, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Foo ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Foo ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Foo ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Foo ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Foo ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Foo ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Foo ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Foo ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Foo ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Foo ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Foo MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Foo prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Foo cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Foo result; + + private Foo PrepareBuilder() { + if (resultIsReadOnly) { + Foo original = result; + result = new Foo(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Foo MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Descriptor; } + } + + public override Foo DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance; } + } + + public override Foo BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is Foo) { + return MergeFrom((Foo) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Foo other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_fooFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _fooFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static Foo() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Bar : pb::GeneratedMessage { + private Bar() { } + private static readonly Bar defaultInstance = new Bar().MakeReadOnly(); + private static readonly string[] _barFieldNames = new string[] { "a" }; + private static readonly uint[] _barFieldTags = new uint[] { 8 }; + public static Bar DefaultInstance { + get { return defaultInstance; } + } + + public override Bar DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Bar ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _barFieldNames; + if (hasA) { + output.WriteInt32(1, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(1, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Bar ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Bar ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Bar ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Bar ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Bar ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Bar ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Bar ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Bar ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Bar ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Bar ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Bar MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Bar prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Bar cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Bar result; + + private Bar PrepareBuilder() { + if (resultIsReadOnly) { + Bar original = result; + result = new Bar(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Bar MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Descriptor; } + } + + public override Bar DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance; } + } + + public override Bar BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is Bar) { + return MergeFrom((Bar) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Bar other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_barFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _barFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static Bar() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int AFieldNumber = 1; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public const int FooFieldNumber = 2; + private bool hasFoo; + private global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo foo_; + public bool HasFoo { + get { return hasFoo; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo Foo { + get { return foo_ ?? global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance; } + } + + public const int BarFieldNumber = 3; + private bool hasBar; + private global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar bar_; + public bool HasBar { + get { return hasBar; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar Bar { + get { return bar_ ?? global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testDupFieldNumberFieldNames; + if (hasA) { + output.WriteInt32(1, field_names[0], A); + } + if (hasFoo) { + output.WriteGroup(2, field_names[2], Foo); + } + if (hasBar) { + output.WriteGroup(3, field_names[1], Bar); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(1, A); + } + if (hasFoo) { + size += pb::CodedOutputStream.ComputeGroupSize(2, Foo); + } + if (hasBar) { + size += pb::CodedOutputStream.ComputeGroupSize(3, Bar); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestDupFieldNumber ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestDupFieldNumber ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestDupFieldNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestDupFieldNumber MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestDupFieldNumber prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestDupFieldNumber cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestDupFieldNumber result; + + private TestDupFieldNumber PrepareBuilder() { + if (resultIsReadOnly) { + TestDupFieldNumber original = result; + result = new TestDupFieldNumber(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestDupFieldNumber MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Descriptor; } + } + + public override TestDupFieldNumber DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.DefaultInstance; } + } + + public override TestDupFieldNumber BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestDupFieldNumber) { + return MergeFrom((TestDupFieldNumber) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestDupFieldNumber other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + if (other.HasFoo) { + MergeFoo(other.Foo); + } + if (other.HasBar) { + MergeBar(other.Bar); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testDupFieldNumberFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testDupFieldNumberFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 19: { + global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.CreateBuilder(); + if (result.hasFoo) { + subBuilder.MergeFrom(Foo); + } + input.ReadGroup(2, subBuilder, extensionRegistry); + Foo = subBuilder.BuildPartial(); + break; + } + case 27: { + global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.CreateBuilder(); + if (result.hasBar) { + subBuilder.MergeFrom(Bar); + } + input.ReadGroup(3, subBuilder, extensionRegistry); + Bar = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + + public bool HasFoo { + get { return result.hasFoo; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo Foo { + get { return result.Foo; } + set { SetFoo(value); } + } + public Builder SetFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFoo = true; + result.foo_ = value; + return this; + } + public Builder SetFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFoo = true; + result.foo_ = builderForValue.Build(); + return this; + } + public Builder MergeFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFoo && + result.foo_ != global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance) { + result.foo_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.CreateBuilder(result.foo_).MergeFrom(value).BuildPartial(); + } else { + result.foo_ = value; + } + result.hasFoo = true; + return this; + } + public Builder ClearFoo() { + PrepareBuilder(); + result.hasFoo = false; + result.foo_ = null; + return this; + } + + public bool HasBar { + get { return result.hasBar; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar Bar { + get { return result.Bar; } + set { SetBar(value); } + } + public Builder SetBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBar = true; + result.bar_ = value; + return this; + } + public Builder SetBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasBar = true; + result.bar_ = builderForValue.Build(); + return this; + } + public Builder MergeBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasBar && + result.bar_ != global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance) { + result.bar_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.CreateBuilder(result.bar_).MergeFrom(value).BuildPartial(); + } else { + result.bar_ = value; + } + result.hasBar = true; + return this; + } + public Builder ClearBar() { + PrepareBuilder(); + result.hasBar = false; + result.bar_ = null; + return this; + } + } + static TestDupFieldNumber() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestEagerMessage : pb::GeneratedMessage { + private TestEagerMessage() { } + private static readonly TestEagerMessage defaultInstance = new TestEagerMessage().MakeReadOnly(); + private static readonly string[] _testEagerMessageFieldNames = new string[] { "sub_message" }; + private static readonly uint[] _testEagerMessageFieldTags = new uint[] { 10 }; + public static TestEagerMessage DefaultInstance { + get { return defaultInstance; } + } + + public override TestEagerMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestEagerMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEagerMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEagerMessage__FieldAccessorTable; } + } + + public const int SubMessageFieldNumber = 1; + private bool hasSubMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes subMessage_; + public bool HasSubMessage { + get { return hasSubMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage { + get { return subMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testEagerMessageFieldNames; + if (hasSubMessage) { + output.WriteMessage(1, field_names[0], SubMessage); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasSubMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(1, SubMessage); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestEagerMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestEagerMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestEagerMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestEagerMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestEagerMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestEagerMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestEagerMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestEagerMessage result; + + private TestEagerMessage PrepareBuilder() { + if (resultIsReadOnly) { + TestEagerMessage original = result; + result = new TestEagerMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestEagerMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestEagerMessage.Descriptor; } + } + + public override TestEagerMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestEagerMessage.DefaultInstance; } + } + + public override TestEagerMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestEagerMessage) { + return MergeFrom((TestEagerMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestEagerMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestEagerMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasSubMessage) { + MergeSubMessage(other.SubMessage); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testEagerMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testEagerMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasSubMessage) { + subBuilder.MergeFrom(SubMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + SubMessage = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasSubMessage { + get { return result.hasSubMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage { + get { return result.SubMessage; } + set { SetSubMessage(value); } + } + public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasSubMessage = true; + result.subMessage_ = value; + return this; + } + public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasSubMessage = true; + result.subMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasSubMessage && + result.subMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.subMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.subMessage_).MergeFrom(value).BuildPartial(); + } else { + result.subMessage_ = value; + } + result.hasSubMessage = true; + return this; + } + public Builder ClearSubMessage() { + PrepareBuilder(); + result.hasSubMessage = false; + result.subMessage_ = null; + return this; + } + } + static TestEagerMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestLazyMessage : pb::GeneratedMessage { + private TestLazyMessage() { } + private static readonly TestLazyMessage defaultInstance = new TestLazyMessage().MakeReadOnly(); + private static readonly string[] _testLazyMessageFieldNames = new string[] { "sub_message" }; + private static readonly uint[] _testLazyMessageFieldTags = new uint[] { 10 }; + public static TestLazyMessage DefaultInstance { + get { return defaultInstance; } + } + + public override TestLazyMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestLazyMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestLazyMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestLazyMessage__FieldAccessorTable; } + } + + public const int SubMessageFieldNumber = 1; + private bool hasSubMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes subMessage_; + public bool HasSubMessage { + get { return hasSubMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage { + get { return subMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testLazyMessageFieldNames; + if (hasSubMessage) { + output.WriteMessage(1, field_names[0], SubMessage); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasSubMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(1, SubMessage); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestLazyMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestLazyMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestLazyMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestLazyMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestLazyMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestLazyMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestLazyMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestLazyMessage result; + + private TestLazyMessage PrepareBuilder() { + if (resultIsReadOnly) { + TestLazyMessage original = result; + result = new TestLazyMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestLazyMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestLazyMessage.Descriptor; } + } + + public override TestLazyMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestLazyMessage.DefaultInstance; } + } + + public override TestLazyMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestLazyMessage) { + return MergeFrom((TestLazyMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestLazyMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestLazyMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasSubMessage) { + MergeSubMessage(other.SubMessage); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testLazyMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testLazyMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasSubMessage) { + subBuilder.MergeFrom(SubMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + SubMessage = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasSubMessage { + get { return result.hasSubMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage { + get { return result.SubMessage; } + set { SetSubMessage(value); } + } + public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasSubMessage = true; + result.subMessage_ = value; + return this; + } + public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasSubMessage = true; + result.subMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasSubMessage && + result.subMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.subMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.subMessage_).MergeFrom(value).BuildPartial(); + } else { + result.subMessage_ = value; + } + result.hasSubMessage = true; + return this; + } + public Builder ClearSubMessage() { + PrepareBuilder(); + result.hasSubMessage = false; + result.subMessage_ = null; + return this; + } + } + static TestLazyMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestNestedMessageHasBits : pb::GeneratedMessage { + private TestNestedMessageHasBits() { } + private static readonly TestNestedMessageHasBits defaultInstance = new TestNestedMessageHasBits().MakeReadOnly(); + private static readonly string[] _testNestedMessageHasBitsFieldNames = new string[] { "optional_nested_message" }; + private static readonly uint[] _testNestedMessageHasBitsFieldTags = new uint[] { 10 }; + public static TestNestedMessageHasBits DefaultInstance { + get { return defaultInstance; } + } + + public override TestNestedMessageHasBits DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestNestedMessageHasBits ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessage { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "nestedmessage_repeated_foreignmessage", "nestedmessage_repeated_int32" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 18, 8 }; + public static NestedMessage DefaultInstance { + get { return defaultInstance; } + } + + public override NestedMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override NestedMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable; } + } + + public const int NestedmessageRepeatedInt32FieldNumber = 1; + private pbc::PopsicleList nestedmessageRepeatedInt32_ = new pbc::PopsicleList(); + public scg::IList NestedmessageRepeatedInt32List { + get { return pbc::Lists.AsReadOnly(nestedmessageRepeatedInt32_); } + } + public int NestedmessageRepeatedInt32Count { + get { return nestedmessageRepeatedInt32_.Count; } + } + public int GetNestedmessageRepeatedInt32(int index) { + return nestedmessageRepeatedInt32_[index]; + } + + public const int NestedmessageRepeatedForeignmessageFieldNumber = 2; + private pbc::PopsicleList nestedmessageRepeatedForeignmessage_ = new pbc::PopsicleList(); + public scg::IList NestedmessageRepeatedForeignmessageList { + get { return nestedmessageRepeatedForeignmessage_; } + } + public int NestedmessageRepeatedForeignmessageCount { + get { return nestedmessageRepeatedForeignmessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetNestedmessageRepeatedForeignmessage(int index) { + return nestedmessageRepeatedForeignmessage_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (nestedmessageRepeatedInt32_.Count > 0) { + output.WriteInt32Array(1, field_names[1], nestedmessageRepeatedInt32_); + } + if (nestedmessageRepeatedForeignmessage_.Count > 0) { + output.WriteMessageArray(2, field_names[0], nestedmessageRepeatedForeignmessage_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + foreach (int element in NestedmessageRepeatedInt32List) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 1 * nestedmessageRepeatedInt32_.Count; + } + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in NestedmessageRepeatedForeignmessageList) { + size += pb::CodedOutputStream.ComputeMessageSize(2, element); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() { + nestedmessageRepeatedInt32_.MakeReadOnly(); + nestedmessageRepeatedForeignmessage_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() { + if (resultIsReadOnly) { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override NestedMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Descriptor; } + } + + public override NestedMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance; } + } + + public override NestedMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is NestedMessage) { + return MergeFrom((NestedMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NestedMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.nestedmessageRepeatedInt32_.Count != 0) { + result.nestedmessageRepeatedInt32_.Add(other.nestedmessageRepeatedInt32_); + } + if (other.nestedmessageRepeatedForeignmessage_.Count != 0) { + result.nestedmessageRepeatedForeignmessage_.Add(other.nestedmessageRepeatedForeignmessage_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + case 8: { + input.ReadInt32Array(tag, field_name, result.nestedmessageRepeatedInt32_); + break; + } + case 18: { + input.ReadMessageArray(tag, field_name, result.nestedmessageRepeatedForeignmessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList NestedmessageRepeatedInt32List { + get { return PrepareBuilder().nestedmessageRepeatedInt32_; } + } + public int NestedmessageRepeatedInt32Count { + get { return result.NestedmessageRepeatedInt32Count; } + } + public int GetNestedmessageRepeatedInt32(int index) { + return result.GetNestedmessageRepeatedInt32(index); + } + public Builder SetNestedmessageRepeatedInt32(int index, int value) { + PrepareBuilder(); + result.nestedmessageRepeatedInt32_[index] = value; + return this; + } + public Builder AddNestedmessageRepeatedInt32(int value) { + PrepareBuilder(); + result.nestedmessageRepeatedInt32_.Add(value); + return this; + } + public Builder AddRangeNestedmessageRepeatedInt32(scg::IEnumerable values) { + PrepareBuilder(); + result.nestedmessageRepeatedInt32_.Add(values); + return this; + } + public Builder ClearNestedmessageRepeatedInt32() { + PrepareBuilder(); + result.nestedmessageRepeatedInt32_.Clear(); + return this; + } + + public pbc::IPopsicleList NestedmessageRepeatedForeignmessageList { + get { return PrepareBuilder().nestedmessageRepeatedForeignmessage_; } + } + public int NestedmessageRepeatedForeignmessageCount { + get { return result.NestedmessageRepeatedForeignmessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetNestedmessageRepeatedForeignmessage(int index) { + return result.GetNestedmessageRepeatedForeignmessage(index); + } + public Builder SetNestedmessageRepeatedForeignmessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_[index] = value; + return this; + } + public Builder SetNestedmessageRepeatedForeignmessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddNestedmessageRepeatedForeignmessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_.Add(value); + return this; + } + public Builder AddNestedmessageRepeatedForeignmessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeNestedmessageRepeatedForeignmessage(scg::IEnumerable values) { + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_.Add(values); + return this; + } + public Builder ClearNestedmessageRepeatedForeignmessage() { + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_.Clear(); + return this; + } + } + static NestedMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int OptionalNestedMessageFieldNumber = 1; + private bool hasOptionalNestedMessage; + private global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage optionalNestedMessage_; + public bool HasOptionalNestedMessage { + get { return hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage OptionalNestedMessage { + get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testNestedMessageHasBitsFieldNames; + if (hasOptionalNestedMessage) { + output.WriteMessage(1, field_names[0], OptionalNestedMessage); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOptionalNestedMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(1, OptionalNestedMessage); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestNestedMessageHasBits ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestNestedMessageHasBits ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestNestedMessageHasBits MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestNestedMessageHasBits prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestNestedMessageHasBits cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestNestedMessageHasBits result; + + private TestNestedMessageHasBits PrepareBuilder() { + if (resultIsReadOnly) { + TestNestedMessageHasBits original = result; + result = new TestNestedMessageHasBits(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestNestedMessageHasBits MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Descriptor; } + } + + public override TestNestedMessageHasBits DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.DefaultInstance; } + } + + public override TestNestedMessageHasBits BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestNestedMessageHasBits) { + return MergeFrom((TestNestedMessageHasBits) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestNestedMessageHasBits other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOptionalNestedMessage) { + MergeOptionalNestedMessage(other.OptionalNestedMessage); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testNestedMessageHasBitsFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testNestedMessageHasBitsFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.CreateBuilder(); + if (result.hasOptionalNestedMessage) { + subBuilder.MergeFrom(OptionalNestedMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalNestedMessage = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasOptionalNestedMessage { + get { return result.hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage OptionalNestedMessage { + get { return result.OptionalNestedMessage; } + set { SetOptionalNestedMessage(value); } + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = value; + return this; + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalNestedMessage && + result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance) { + result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalNestedMessage_ = value; + } + result.hasOptionalNestedMessage = true; + return this; + } + public Builder ClearOptionalNestedMessage() { + PrepareBuilder(); + result.hasOptionalNestedMessage = false; + result.optionalNestedMessage_ = null; + return this; + } + } + static TestNestedMessageHasBits() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestCamelCaseFieldNames : pb::GeneratedMessage { + private TestCamelCaseFieldNames() { } + private static readonly TestCamelCaseFieldNames defaultInstance = new TestCamelCaseFieldNames().MakeReadOnly(); + private static readonly string[] _testCamelCaseFieldNamesFieldNames = new string[] { "CordField", "EnumField", "MessageField", "PrimitiveField", "RepeatedCordField", "RepeatedEnumField", "RepeatedMessageField", "RepeatedPrimitiveField", "RepeatedStringField", "RepeatedStringPieceField", "StringField", "StringPieceField" }; + private static readonly uint[] _testCamelCaseFieldNamesFieldTags = new uint[] { 50, 24, 34, 8, 98, 72, 82, 56, 66, 90, 18, 42 }; + public static TestCamelCaseFieldNames DefaultInstance { + get { return defaultInstance; } + } + + public override TestCamelCaseFieldNames DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestCamelCaseFieldNames ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable; } + } + + public const int PrimitiveFieldFieldNumber = 1; + private bool hasPrimitiveField; + private int primitiveField_; + public bool HasPrimitiveField { + get { return hasPrimitiveField; } + } + public int PrimitiveField { + get { return primitiveField_; } + } + + public const int StringFieldFieldNumber = 2; + private bool hasStringField; + private string stringField_ = ""; + public bool HasStringField { + get { return hasStringField; } + } + public string StringField { + get { return stringField_; } + } + + public const int EnumFieldFieldNumber = 3; + private bool hasEnumField; + private global::Google.ProtocolBuffers.TestProtos.ForeignEnum enumField_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + public bool HasEnumField { + get { return hasEnumField; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumField { + get { return enumField_; } + } + + public const int MessageFieldFieldNumber = 4; + private bool hasMessageField; + private global::Google.ProtocolBuffers.TestProtos.ForeignMessage messageField_; + public bool HasMessageField { + get { return hasMessageField; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageField { + get { return messageField_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } + } + + public const int StringPieceFieldFieldNumber = 5; + private bool hasStringPieceField; + private string stringPieceField_ = ""; + public bool HasStringPieceField { + get { return hasStringPieceField; } + } + public string StringPieceField { + get { return stringPieceField_; } + } + + public const int CordFieldFieldNumber = 6; + private bool hasCordField; + private string cordField_ = ""; + public bool HasCordField { + get { return hasCordField; } + } + public string CordField { + get { return cordField_; } + } + + public const int RepeatedPrimitiveFieldFieldNumber = 7; + private pbc::PopsicleList repeatedPrimitiveField_ = new pbc::PopsicleList(); + public scg::IList RepeatedPrimitiveFieldList { + get { return pbc::Lists.AsReadOnly(repeatedPrimitiveField_); } + } + public int RepeatedPrimitiveFieldCount { + get { return repeatedPrimitiveField_.Count; } + } + public int GetRepeatedPrimitiveField(int index) { + return repeatedPrimitiveField_[index]; + } + + public const int RepeatedStringFieldFieldNumber = 8; + private pbc::PopsicleList repeatedStringField_ = new pbc::PopsicleList(); + public scg::IList RepeatedStringFieldList { + get { return pbc::Lists.AsReadOnly(repeatedStringField_); } + } + public int RepeatedStringFieldCount { + get { return repeatedStringField_.Count; } + } + public string GetRepeatedStringField(int index) { + return repeatedStringField_[index]; + } + + public const int RepeatedEnumFieldFieldNumber = 9; + private pbc::PopsicleList repeatedEnumField_ = new pbc::PopsicleList(); + public scg::IList RepeatedEnumFieldList { + get { return pbc::Lists.AsReadOnly(repeatedEnumField_); } + } + public int RepeatedEnumFieldCount { + get { return repeatedEnumField_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedEnumField(int index) { + return repeatedEnumField_[index]; + } + + public const int RepeatedMessageFieldFieldNumber = 10; + private pbc::PopsicleList repeatedMessageField_ = new pbc::PopsicleList(); + public scg::IList RepeatedMessageFieldList { + get { return repeatedMessageField_; } + } + public int RepeatedMessageFieldCount { + get { return repeatedMessageField_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedMessageField(int index) { + return repeatedMessageField_[index]; + } + + public const int RepeatedStringPieceFieldFieldNumber = 11; + private pbc::PopsicleList repeatedStringPieceField_ = new pbc::PopsicleList(); + public scg::IList RepeatedStringPieceFieldList { + get { return pbc::Lists.AsReadOnly(repeatedStringPieceField_); } + } + public int RepeatedStringPieceFieldCount { + get { return repeatedStringPieceField_.Count; } + } + public string GetRepeatedStringPieceField(int index) { + return repeatedStringPieceField_[index]; + } + + public const int RepeatedCordFieldFieldNumber = 12; + private pbc::PopsicleList repeatedCordField_ = new pbc::PopsicleList(); + public scg::IList RepeatedCordFieldList { + get { return pbc::Lists.AsReadOnly(repeatedCordField_); } + } + public int RepeatedCordFieldCount { + get { return repeatedCordField_.Count; } + } + public string GetRepeatedCordField(int index) { + return repeatedCordField_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testCamelCaseFieldNamesFieldNames; + if (hasPrimitiveField) { + output.WriteInt32(1, field_names[3], PrimitiveField); + } + if (hasStringField) { + output.WriteString(2, field_names[10], StringField); + } + if (hasEnumField) { + output.WriteEnum(3, field_names[1], (int) EnumField, EnumField); + } + if (hasMessageField) { + output.WriteMessage(4, field_names[2], MessageField); + } + if (hasStringPieceField) { + output.WriteString(5, field_names[11], StringPieceField); + } + if (hasCordField) { + output.WriteString(6, field_names[0], CordField); + } + if (repeatedPrimitiveField_.Count > 0) { + output.WriteInt32Array(7, field_names[7], repeatedPrimitiveField_); + } + if (repeatedStringField_.Count > 0) { + output.WriteStringArray(8, field_names[8], repeatedStringField_); + } + if (repeatedEnumField_.Count > 0) { + output.WriteEnumArray(9, field_names[5], repeatedEnumField_); + } + if (repeatedMessageField_.Count > 0) { + output.WriteMessageArray(10, field_names[6], repeatedMessageField_); + } + if (repeatedStringPieceField_.Count > 0) { + output.WriteStringArray(11, field_names[9], repeatedStringPieceField_); + } + if (repeatedCordField_.Count > 0) { + output.WriteStringArray(12, field_names[4], repeatedCordField_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasPrimitiveField) { + size += pb::CodedOutputStream.ComputeInt32Size(1, PrimitiveField); + } + if (hasStringField) { + size += pb::CodedOutputStream.ComputeStringSize(2, StringField); + } + if (hasEnumField) { + size += pb::CodedOutputStream.ComputeEnumSize(3, (int) EnumField); + } + if (hasMessageField) { + size += pb::CodedOutputStream.ComputeMessageSize(4, MessageField); + } + if (hasStringPieceField) { + size += pb::CodedOutputStream.ComputeStringSize(5, StringPieceField); + } + if (hasCordField) { + size += pb::CodedOutputStream.ComputeStringSize(6, CordField); + } + { + int dataSize = 0; + foreach (int element in RepeatedPrimitiveFieldList) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 1 * repeatedPrimitiveField_.Count; + } + { + int dataSize = 0; + foreach (string element in RepeatedStringFieldList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 1 * repeatedStringField_.Count; + } + { + int dataSize = 0; + if (repeatedEnumField_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedEnumField_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 1 * repeatedEnumField_.Count; + } + } + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedMessageFieldList) { + size += pb::CodedOutputStream.ComputeMessageSize(10, element); + } + { + int dataSize = 0; + foreach (string element in RepeatedStringPieceFieldList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 1 * repeatedStringPieceField_.Count; + } + { + int dataSize = 0; + foreach (string element in RepeatedCordFieldList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 1 * repeatedCordField_.Count; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestCamelCaseFieldNames ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestCamelCaseFieldNames MakeReadOnly() { + repeatedPrimitiveField_.MakeReadOnly(); + repeatedStringField_.MakeReadOnly(); + repeatedEnumField_.MakeReadOnly(); + repeatedMessageField_.MakeReadOnly(); + repeatedStringPieceField_.MakeReadOnly(); + repeatedCordField_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestCamelCaseFieldNames prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestCamelCaseFieldNames cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestCamelCaseFieldNames result; + + private TestCamelCaseFieldNames PrepareBuilder() { + if (resultIsReadOnly) { + TestCamelCaseFieldNames original = result; + result = new TestCamelCaseFieldNames(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestCamelCaseFieldNames MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.Descriptor; } + } + + public override TestCamelCaseFieldNames DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.DefaultInstance; } + } + + public override TestCamelCaseFieldNames BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestCamelCaseFieldNames) { + return MergeFrom((TestCamelCaseFieldNames) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestCamelCaseFieldNames other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasPrimitiveField) { + PrimitiveField = other.PrimitiveField; + } + if (other.HasStringField) { + StringField = other.StringField; + } + if (other.HasEnumField) { + EnumField = other.EnumField; + } + if (other.HasMessageField) { + MergeMessageField(other.MessageField); + } + if (other.HasStringPieceField) { + StringPieceField = other.StringPieceField; + } + if (other.HasCordField) { + CordField = other.CordField; + } + if (other.repeatedPrimitiveField_.Count != 0) { + result.repeatedPrimitiveField_.Add(other.repeatedPrimitiveField_); + } + if (other.repeatedStringField_.Count != 0) { + result.repeatedStringField_.Add(other.repeatedStringField_); + } + if (other.repeatedEnumField_.Count != 0) { + result.repeatedEnumField_.Add(other.repeatedEnumField_); + } + if (other.repeatedMessageField_.Count != 0) { + result.repeatedMessageField_.Add(other.repeatedMessageField_); + } + if (other.repeatedStringPieceField_.Count != 0) { + result.repeatedStringPieceField_.Add(other.repeatedStringPieceField_); + } + if (other.repeatedCordField_.Count != 0) { + result.repeatedCordField_.Add(other.repeatedCordField_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testCamelCaseFieldNamesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testCamelCaseFieldNamesFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasPrimitiveField = input.ReadInt32(ref result.primitiveField_); + break; + } + case 18: { + result.hasStringField = input.ReadString(ref result.stringField_); + break; + } + case 24: { + object unknown; + if(input.ReadEnum(ref result.enumField_, out unknown)) { + result.hasEnumField = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(3, (ulong)(int)unknown); + } + break; + } + case 34: { + global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); + if (result.hasMessageField) { + subBuilder.MergeFrom(MessageField); + } + input.ReadMessage(subBuilder, extensionRegistry); + MessageField = subBuilder.BuildPartial(); + break; + } + case 42: { + result.hasStringPieceField = input.ReadString(ref result.stringPieceField_); + break; + } + case 50: { + result.hasCordField = input.ReadString(ref result.cordField_); + break; + } + case 58: + case 56: { + input.ReadInt32Array(tag, field_name, result.repeatedPrimitiveField_); + break; + } + case 66: { + input.ReadStringArray(tag, field_name, result.repeatedStringField_); + break; + } + case 74: + case 72: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedEnumField_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(9, (ulong)(int)rawValue); + } + break; + } + case 82: { + input.ReadMessageArray(tag, field_name, result.repeatedMessageField_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); + break; + } + case 90: { + input.ReadStringArray(tag, field_name, result.repeatedStringPieceField_); + break; + } + case 98: { + input.ReadStringArray(tag, field_name, result.repeatedCordField_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasPrimitiveField { + get { return result.hasPrimitiveField; } + } + public int PrimitiveField { + get { return result.PrimitiveField; } + set { SetPrimitiveField(value); } + } + public Builder SetPrimitiveField(int value) { + PrepareBuilder(); + result.hasPrimitiveField = true; + result.primitiveField_ = value; + return this; + } + public Builder ClearPrimitiveField() { + PrepareBuilder(); + result.hasPrimitiveField = false; + result.primitiveField_ = 0; + return this; + } + + public bool HasStringField { + get { return result.hasStringField; } + } + public string StringField { + get { return result.StringField; } + set { SetStringField(value); } + } + public Builder SetStringField(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasStringField = true; + result.stringField_ = value; + return this; + } + public Builder ClearStringField() { + PrepareBuilder(); + result.hasStringField = false; + result.stringField_ = ""; + return this; + } + + public bool HasEnumField { + get { return result.hasEnumField; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumField { + get { return result.EnumField; } + set { SetEnumField(value); } + } + public Builder SetEnumField(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.hasEnumField = true; + result.enumField_ = value; + return this; + } + public Builder ClearEnumField() { + PrepareBuilder(); + result.hasEnumField = false; + result.enumField_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + return this; + } + + public bool HasMessageField { + get { return result.hasMessageField; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageField { + get { return result.MessageField; } + set { SetMessageField(value); } + } + public Builder SetMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasMessageField = true; + result.messageField_ = value; + return this; + } + public Builder SetMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasMessageField = true; + result.messageField_ = builderForValue.Build(); + return this; + } + public Builder MergeMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasMessageField && + result.messageField_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) { + result.messageField_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.messageField_).MergeFrom(value).BuildPartial(); + } else { + result.messageField_ = value; + } + result.hasMessageField = true; + return this; + } + public Builder ClearMessageField() { + PrepareBuilder(); + result.hasMessageField = false; + result.messageField_ = null; + return this; + } + + public bool HasStringPieceField { + get { return result.hasStringPieceField; } + } + public string StringPieceField { + get { return result.StringPieceField; } + set { SetStringPieceField(value); } + } + public Builder SetStringPieceField(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasStringPieceField = true; + result.stringPieceField_ = value; + return this; + } + public Builder ClearStringPieceField() { + PrepareBuilder(); + result.hasStringPieceField = false; + result.stringPieceField_ = ""; + return this; + } + + public bool HasCordField { + get { return result.hasCordField; } + } + public string CordField { + get { return result.CordField; } + set { SetCordField(value); } + } + public Builder SetCordField(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasCordField = true; + result.cordField_ = value; + return this; + } + public Builder ClearCordField() { + PrepareBuilder(); + result.hasCordField = false; + result.cordField_ = ""; + return this; + } + + public pbc::IPopsicleList RepeatedPrimitiveFieldList { + get { return PrepareBuilder().repeatedPrimitiveField_; } + } + public int RepeatedPrimitiveFieldCount { + get { return result.RepeatedPrimitiveFieldCount; } + } + public int GetRepeatedPrimitiveField(int index) { + return result.GetRepeatedPrimitiveField(index); + } + public Builder SetRepeatedPrimitiveField(int index, int value) { + PrepareBuilder(); + result.repeatedPrimitiveField_[index] = value; + return this; + } + public Builder AddRepeatedPrimitiveField(int value) { + PrepareBuilder(); + result.repeatedPrimitiveField_.Add(value); + return this; + } + public Builder AddRangeRepeatedPrimitiveField(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedPrimitiveField_.Add(values); + return this; + } + public Builder ClearRepeatedPrimitiveField() { + PrepareBuilder(); + result.repeatedPrimitiveField_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedStringFieldList { + get { return PrepareBuilder().repeatedStringField_; } + } + public int RepeatedStringFieldCount { + get { return result.RepeatedStringFieldCount; } + } + public string GetRepeatedStringField(int index) { + return result.GetRepeatedStringField(index); + } + public Builder SetRepeatedStringField(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringField_[index] = value; + return this; + } + public Builder AddRepeatedStringField(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringField_.Add(value); + return this; + } + public Builder AddRangeRepeatedStringField(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedStringField_.Add(values); + return this; + } + public Builder ClearRepeatedStringField() { + PrepareBuilder(); + result.repeatedStringField_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedEnumFieldList { + get { return PrepareBuilder().repeatedEnumField_; } + } + public int RepeatedEnumFieldCount { + get { return result.RepeatedEnumFieldCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedEnumField(int index) { + return result.GetRepeatedEnumField(index); + } + public Builder SetRepeatedEnumField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.repeatedEnumField_[index] = value; + return this; + } + public Builder AddRepeatedEnumField(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.repeatedEnumField_.Add(value); + return this; + } + public Builder AddRangeRepeatedEnumField(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedEnumField_.Add(values); + return this; + } + public Builder ClearRepeatedEnumField() { + PrepareBuilder(); + result.repeatedEnumField_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedMessageFieldList { + get { return PrepareBuilder().repeatedMessageField_; } + } + public int RepeatedMessageFieldCount { + get { return result.RepeatedMessageFieldCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedMessageField(int index) { + return result.GetRepeatedMessageField(index); + } + public Builder SetRepeatedMessageField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedMessageField_[index] = value; + return this; + } + public Builder SetRepeatedMessageField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedMessageField_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedMessageField_.Add(value); + return this; + } + public Builder AddRepeatedMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedMessageField_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedMessageField(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedMessageField_.Add(values); + return this; + } + public Builder ClearRepeatedMessageField() { + PrepareBuilder(); + result.repeatedMessageField_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedStringPieceFieldList { + get { return PrepareBuilder().repeatedStringPieceField_; } + } + public int RepeatedStringPieceFieldCount { + get { return result.RepeatedStringPieceFieldCount; } + } + public string GetRepeatedStringPieceField(int index) { + return result.GetRepeatedStringPieceField(index); + } + public Builder SetRepeatedStringPieceField(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringPieceField_[index] = value; + return this; + } + public Builder AddRepeatedStringPieceField(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringPieceField_.Add(value); + return this; + } + public Builder AddRangeRepeatedStringPieceField(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedStringPieceField_.Add(values); + return this; + } + public Builder ClearRepeatedStringPieceField() { + PrepareBuilder(); + result.repeatedStringPieceField_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedCordFieldList { + get { return PrepareBuilder().repeatedCordField_; } + } + public int RepeatedCordFieldCount { + get { return result.RepeatedCordFieldCount; } + } + public string GetRepeatedCordField(int index) { + return result.GetRepeatedCordField(index); + } + public Builder SetRepeatedCordField(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedCordField_[index] = value; + return this; + } + public Builder AddRepeatedCordField(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedCordField_.Add(value); + return this; + } + public Builder AddRangeRepeatedCordField(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedCordField_.Add(values); + return this; + } + public Builder ClearRepeatedCordField() { + PrepareBuilder(); + result.repeatedCordField_.Clear(); + return this; + } + } + static TestCamelCaseFieldNames() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestFieldOrderings : pb::ExtendableMessage { + private TestFieldOrderings() { } + private static readonly TestFieldOrderings defaultInstance = new TestFieldOrderings().MakeReadOnly(); + private static readonly string[] _testFieldOrderingsFieldNames = new string[] { "my_float", "my_int", "my_string", "optional_nested_message" }; + private static readonly uint[] _testFieldOrderingsFieldTags = new uint[] { 813, 8, 90, 1602 }; + public static TestFieldOrderings DefaultInstance { + get { return defaultInstance; } + } + + public override TestFieldOrderings DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestFieldOrderings ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessage { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "bb", "oo" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8, 16 }; + public static NestedMessage DefaultInstance { + get { return defaultInstance; } + } + + public override NestedMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override NestedMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__FieldAccessorTable; } + } + + public const int OoFieldNumber = 2; + private bool hasOo; + private long oo_; + public bool HasOo { + get { return hasOo; } + } + public long Oo { + get { return oo_; } + } + + public const int BbFieldNumber = 1; + private bool hasBb; + private int bb_; + public bool HasBb { + get { return hasBb; } + } + public int Bb { + get { return bb_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (hasBb) { + output.WriteInt32(1, field_names[0], Bb); + } + if (hasOo) { + output.WriteInt64(2, field_names[1], Oo); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOo) { + size += pb::CodedOutputStream.ComputeInt64Size(2, Oo); + } + if (hasBb) { + size += pb::CodedOutputStream.ComputeInt32Size(1, Bb); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() { + if (resultIsReadOnly) { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override NestedMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.Descriptor; } + } + + public override NestedMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance; } + } + + public override NestedMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is NestedMessage) { + return MergeFrom((NestedMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NestedMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOo) { + Oo = other.Oo; + } + if (other.HasBb) { + Bb = other.Bb; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasBb = input.ReadInt32(ref result.bb_); + break; + } + case 16: { + result.hasOo = input.ReadInt64(ref result.oo_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasOo { + get { return result.hasOo; } + } + public long Oo { + get { return result.Oo; } + set { SetOo(value); } + } + public Builder SetOo(long value) { + PrepareBuilder(); + result.hasOo = true; + result.oo_ = value; + return this; + } + public Builder ClearOo() { + PrepareBuilder(); + result.hasOo = false; + result.oo_ = 0L; + return this; + } + + public bool HasBb { + get { return result.hasBb; } + } + public int Bb { + get { return result.Bb; } + set { SetBb(value); } + } + public Builder SetBb(int value) { + PrepareBuilder(); + result.hasBb = true; + result.bb_ = value; + return this; + } + public Builder ClearBb() { + PrepareBuilder(); + result.hasBb = false; + result.bb_ = 0; + return this; + } + } + static NestedMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int MyStringFieldNumber = 11; + private bool hasMyString; + private string myString_ = ""; + public bool HasMyString { + get { return hasMyString; } + } + public string MyString { + get { return myString_; } + } + + public const int MyIntFieldNumber = 1; + private bool hasMyInt; + private long myInt_; + public bool HasMyInt { + get { return hasMyInt; } + } + public long MyInt { + get { return myInt_; } + } + + public const int MyFloatFieldNumber = 101; + private bool hasMyFloat; + private float myFloat_; + public bool HasMyFloat { + get { return hasMyFloat; } + } + public float MyFloat { + get { return myFloat_; } + } + + public const int OptionalNestedMessageFieldNumber = 200; + private bool hasOptionalNestedMessage; + private global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage optionalNestedMessage_; + public bool HasOptionalNestedMessage { + get { return hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage OptionalNestedMessage { + get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance; } + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testFieldOrderingsFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + if (hasMyInt) { + output.WriteInt64(1, field_names[1], MyInt); + } + extensionWriter.WriteUntil(11, output); + if (hasMyString) { + output.WriteString(11, field_names[2], MyString); + } + extensionWriter.WriteUntil(101, output); + if (hasMyFloat) { + output.WriteFloat(101, field_names[0], MyFloat); + } + if (hasOptionalNestedMessage) { + output.WriteMessage(200, field_names[3], OptionalNestedMessage); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasMyString) { + size += pb::CodedOutputStream.ComputeStringSize(11, MyString); + } + if (hasMyInt) { + size += pb::CodedOutputStream.ComputeInt64Size(1, MyInt); + } + if (hasMyFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(101, MyFloat); + } + if (hasOptionalNestedMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(200, OptionalNestedMessage); + } + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestFieldOrderings ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestFieldOrderings ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestFieldOrderings ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestFieldOrderings MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestFieldOrderings prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestFieldOrderings cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestFieldOrderings result; + + private TestFieldOrderings PrepareBuilder() { + if (resultIsReadOnly) { + TestFieldOrderings original = result; + result = new TestFieldOrderings(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestFieldOrderings MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Descriptor; } + } + + public override TestFieldOrderings DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.DefaultInstance; } + } + + public override TestFieldOrderings BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestFieldOrderings) { + return MergeFrom((TestFieldOrderings) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestFieldOrderings other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasMyString) { + MyString = other.MyString; + } + if (other.HasMyInt) { + MyInt = other.MyInt; + } + if (other.HasMyFloat) { + MyFloat = other.MyFloat; + } + if (other.HasOptionalNestedMessage) { + MergeOptionalNestedMessage(other.OptionalNestedMessage); + } + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testFieldOrderingsFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testFieldOrderingsFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasMyInt = input.ReadInt64(ref result.myInt_); + break; + } + case 90: { + result.hasMyString = input.ReadString(ref result.myString_); + break; + } + case 813: { + result.hasMyFloat = input.ReadFloat(ref result.myFloat_); + break; + } + case 1602: { + global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.CreateBuilder(); + if (result.hasOptionalNestedMessage) { + subBuilder.MergeFrom(OptionalNestedMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalNestedMessage = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasMyString { + get { return result.hasMyString; } + } + public string MyString { + get { return result.MyString; } + set { SetMyString(value); } + } + public Builder SetMyString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasMyString = true; + result.myString_ = value; + return this; + } + public Builder ClearMyString() { + PrepareBuilder(); + result.hasMyString = false; + result.myString_ = ""; + return this; + } + + public bool HasMyInt { + get { return result.hasMyInt; } + } + public long MyInt { + get { return result.MyInt; } + set { SetMyInt(value); } + } + public Builder SetMyInt(long value) { + PrepareBuilder(); + result.hasMyInt = true; + result.myInt_ = value; + return this; + } + public Builder ClearMyInt() { + PrepareBuilder(); + result.hasMyInt = false; + result.myInt_ = 0L; + return this; + } + + public bool HasMyFloat { + get { return result.hasMyFloat; } + } + public float MyFloat { + get { return result.MyFloat; } + set { SetMyFloat(value); } + } + public Builder SetMyFloat(float value) { + PrepareBuilder(); + result.hasMyFloat = true; + result.myFloat_ = value; + return this; + } + public Builder ClearMyFloat() { + PrepareBuilder(); + result.hasMyFloat = false; + result.myFloat_ = 0F; + return this; + } + + public bool HasOptionalNestedMessage { + get { return result.hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage OptionalNestedMessage { + get { return result.OptionalNestedMessage; } + set { SetOptionalNestedMessage(value); } + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = value; + return this; + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalNestedMessage && + result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance) { + result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalNestedMessage_ = value; + } + result.hasOptionalNestedMessage = true; + return this; + } + public Builder ClearOptionalNestedMessage() { + PrepareBuilder(); + result.hasOptionalNestedMessage = false; + result.optionalNestedMessage_ = null; + return this; + } + } + static TestFieldOrderings() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestExtremeDefaultValues : pb::GeneratedMessage { + private TestExtremeDefaultValues() { } + private static readonly TestExtremeDefaultValues defaultInstance = new TestExtremeDefaultValues().MakeReadOnly(); + private static readonly string[] _testExtremeDefaultValuesFieldNames = new string[] { "bytes_with_zero", "cord_with_zero", "cpp_trigraph", "escaped_bytes", "inf_double", "inf_float", "large_float", "large_uint32", "large_uint64", "nan_double", "nan_float", "neg_inf_double", "neg_inf_float", "negative_float", "negative_one_float", "one_float", "really_small_int32", "really_small_int64", "replacement_string", "small_float", "small_int32", "small_int64", "small_negative_float", "string_piece_with_zero", "string_with_zero", "utf8_string", "zero_float" }; + private static readonly uint[] _testExtremeDefaultValuesFieldTags = new uint[] { 194, 210, 162, 10, 113, 141, 101, 16, 24, 129, 157, 121, 149, 93, 85, 69, 168, 176, 218, 77, 32, 40, 109, 202, 186, 50, 61 }; + public static TestExtremeDefaultValues DefaultInstance { + get { return defaultInstance; } + } + + public override TestExtremeDefaultValues DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestExtremeDefaultValues ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable; } + } + + public const int EscapedBytesFieldNumber = 1; + private bool hasEscapedBytes; + private pb::ByteString escapedBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[0].DefaultValue; + public bool HasEscapedBytes { + get { return hasEscapedBytes; } + } + public pb::ByteString EscapedBytes { + get { return escapedBytes_; } + } + + public const int LargeUint32FieldNumber = 2; + private bool hasLargeUint32; + private uint largeUint32_ = 4294967295; + public bool HasLargeUint32 { + get { return hasLargeUint32; } + } + [global::System.CLSCompliant(false)] + public uint LargeUint32 { + get { return largeUint32_; } + } + + public const int LargeUint64FieldNumber = 3; + private bool hasLargeUint64; + private ulong largeUint64_ = 18446744073709551615UL; + public bool HasLargeUint64 { + get { return hasLargeUint64; } + } + [global::System.CLSCompliant(false)] + public ulong LargeUint64 { + get { return largeUint64_; } + } + + public const int SmallInt32FieldNumber = 4; + private bool hasSmallInt32; + private int smallInt32_ = -2147483647; + public bool HasSmallInt32 { + get { return hasSmallInt32; } + } + public int SmallInt32 { + get { return smallInt32_; } + } + + public const int SmallInt64FieldNumber = 5; + private bool hasSmallInt64; + private long smallInt64_ = -9223372036854775807L; + public bool HasSmallInt64 { + get { return hasSmallInt64; } + } + public long SmallInt64 { + get { return smallInt64_; } + } + + public const int ReallySmallInt32FieldNumber = 21; + private bool hasReallySmallInt32; + private int reallySmallInt32_ = -2147483648; + public bool HasReallySmallInt32 { + get { return hasReallySmallInt32; } + } + public int ReallySmallInt32 { + get { return reallySmallInt32_; } + } + + public const int ReallySmallInt64FieldNumber = 22; + private bool hasReallySmallInt64; + private long reallySmallInt64_ = -9223372036854775808L; + public bool HasReallySmallInt64 { + get { return hasReallySmallInt64; } + } + public long ReallySmallInt64 { + get { return reallySmallInt64_; } + } + + public const int Utf8StringFieldNumber = 6; + private bool hasUtf8String; + private string utf8String_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[7].DefaultValue; + public bool HasUtf8String { + get { return hasUtf8String; } + } + public string Utf8String { + get { return utf8String_; } + } + + public const int ZeroFloatFieldNumber = 7; + private bool hasZeroFloat; + private float zeroFloat_; + public bool HasZeroFloat { + get { return hasZeroFloat; } + } + public float ZeroFloat { + get { return zeroFloat_; } + } + + public const int OneFloatFieldNumber = 8; + private bool hasOneFloat; + private float oneFloat_ = 1F; + public bool HasOneFloat { + get { return hasOneFloat; } + } + public float OneFloat { + get { return oneFloat_; } + } + + public const int SmallFloatFieldNumber = 9; + private bool hasSmallFloat; + private float smallFloat_ = 1.5F; + public bool HasSmallFloat { + get { return hasSmallFloat; } + } + public float SmallFloat { + get { return smallFloat_; } + } + + public const int NegativeOneFloatFieldNumber = 10; + private bool hasNegativeOneFloat; + private float negativeOneFloat_ = -1F; + public bool HasNegativeOneFloat { + get { return hasNegativeOneFloat; } + } + public float NegativeOneFloat { + get { return negativeOneFloat_; } + } + + public const int NegativeFloatFieldNumber = 11; + private bool hasNegativeFloat; + private float negativeFloat_ = -1.5F; + public bool HasNegativeFloat { + get { return hasNegativeFloat; } + } + public float NegativeFloat { + get { return negativeFloat_; } + } + + public const int LargeFloatFieldNumber = 12; + private bool hasLargeFloat; + private float largeFloat_ = 2e+08F; + public bool HasLargeFloat { + get { return hasLargeFloat; } + } + public float LargeFloat { + get { return largeFloat_; } + } + + public const int SmallNegativeFloatFieldNumber = 13; + private bool hasSmallNegativeFloat; + private float smallNegativeFloat_ = -8e-28F; + public bool HasSmallNegativeFloat { + get { return hasSmallNegativeFloat; } + } + public float SmallNegativeFloat { + get { return smallNegativeFloat_; } + } + + public const int InfDoubleFieldNumber = 14; + private bool hasInfDouble; + private double infDouble_ = double.PositiveInfinity; + public bool HasInfDouble { + get { return hasInfDouble; } + } + public double InfDouble { + get { return infDouble_; } + } + + public const int NegInfDoubleFieldNumber = 15; + private bool hasNegInfDouble; + private double negInfDouble_ = double.NegativeInfinity; + public bool HasNegInfDouble { + get { return hasNegInfDouble; } + } + public double NegInfDouble { + get { return negInfDouble_; } + } + + public const int NanDoubleFieldNumber = 16; + private bool hasNanDouble; + private double nanDouble_ = double.NaN; + public bool HasNanDouble { + get { return hasNanDouble; } + } + public double NanDouble { + get { return nanDouble_; } + } + + public const int InfFloatFieldNumber = 17; + private bool hasInfFloat; + private float infFloat_ = float.PositiveInfinity; + public bool HasInfFloat { + get { return hasInfFloat; } + } + public float InfFloat { + get { return infFloat_; } + } + + public const int NegInfFloatFieldNumber = 18; + private bool hasNegInfFloat; + private float negInfFloat_ = float.NegativeInfinity; + public bool HasNegInfFloat { + get { return hasNegInfFloat; } + } + public float NegInfFloat { + get { return negInfFloat_; } + } + + public const int NanFloatFieldNumber = 19; + private bool hasNanFloat; + private float nanFloat_ = float.NaN; + public bool HasNanFloat { + get { return hasNanFloat; } + } + public float NanFloat { + get { return nanFloat_; } + } + + public const int CppTrigraphFieldNumber = 20; + private bool hasCppTrigraph; + private string cppTrigraph_ = "? ? ?? ?? ??? ??/ ??-"; + public bool HasCppTrigraph { + get { return hasCppTrigraph; } + } + public string CppTrigraph { + get { return cppTrigraph_; } + } + + public const int StringWithZeroFieldNumber = 23; + private bool hasStringWithZero; + private string stringWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[22].DefaultValue; + public bool HasStringWithZero { + get { return hasStringWithZero; } + } + public string StringWithZero { + get { return stringWithZero_; } + } + + public const int BytesWithZeroFieldNumber = 24; + private bool hasBytesWithZero; + private pb::ByteString bytesWithZero_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[23].DefaultValue; + public bool HasBytesWithZero { + get { return hasBytesWithZero; } + } + public pb::ByteString BytesWithZero { + get { return bytesWithZero_; } + } + + public const int StringPieceWithZeroFieldNumber = 25; + private bool hasStringPieceWithZero; + private string stringPieceWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[24].DefaultValue; + public bool HasStringPieceWithZero { + get { return hasStringPieceWithZero; } + } + public string StringPieceWithZero { + get { return stringPieceWithZero_; } + } + + public const int CordWithZeroFieldNumber = 26; + private bool hasCordWithZero; + private string cordWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[25].DefaultValue; + public bool HasCordWithZero { + get { return hasCordWithZero; } + } + public string CordWithZero { + get { return cordWithZero_; } + } + + public const int ReplacementStringFieldNumber = 27; + private bool hasReplacementString; + private string replacementString_ = "${unknown}"; + public bool HasReplacementString { + get { return hasReplacementString; } + } + public string ReplacementString { + get { return replacementString_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testExtremeDefaultValuesFieldNames; + if (hasEscapedBytes) { + output.WriteBytes(1, field_names[3], EscapedBytes); + } + if (hasLargeUint32) { + output.WriteUInt32(2, field_names[7], LargeUint32); + } + if (hasLargeUint64) { + output.WriteUInt64(3, field_names[8], LargeUint64); + } + if (hasSmallInt32) { + output.WriteInt32(4, field_names[20], SmallInt32); + } + if (hasSmallInt64) { + output.WriteInt64(5, field_names[21], SmallInt64); + } + if (hasUtf8String) { + output.WriteString(6, field_names[25], Utf8String); + } + if (hasZeroFloat) { + output.WriteFloat(7, field_names[26], ZeroFloat); + } + if (hasOneFloat) { + output.WriteFloat(8, field_names[15], OneFloat); + } + if (hasSmallFloat) { + output.WriteFloat(9, field_names[19], SmallFloat); + } + if (hasNegativeOneFloat) { + output.WriteFloat(10, field_names[14], NegativeOneFloat); + } + if (hasNegativeFloat) { + output.WriteFloat(11, field_names[13], NegativeFloat); + } + if (hasLargeFloat) { + output.WriteFloat(12, field_names[6], LargeFloat); + } + if (hasSmallNegativeFloat) { + output.WriteFloat(13, field_names[22], SmallNegativeFloat); + } + if (hasInfDouble) { + output.WriteDouble(14, field_names[4], InfDouble); + } + if (hasNegInfDouble) { + output.WriteDouble(15, field_names[11], NegInfDouble); + } + if (hasNanDouble) { + output.WriteDouble(16, field_names[9], NanDouble); + } + if (hasInfFloat) { + output.WriteFloat(17, field_names[5], InfFloat); + } + if (hasNegInfFloat) { + output.WriteFloat(18, field_names[12], NegInfFloat); + } + if (hasNanFloat) { + output.WriteFloat(19, field_names[10], NanFloat); + } + if (hasCppTrigraph) { + output.WriteString(20, field_names[2], CppTrigraph); + } + if (hasReallySmallInt32) { + output.WriteInt32(21, field_names[16], ReallySmallInt32); + } + if (hasReallySmallInt64) { + output.WriteInt64(22, field_names[17], ReallySmallInt64); + } + if (hasStringWithZero) { + output.WriteString(23, field_names[24], StringWithZero); + } + if (hasBytesWithZero) { + output.WriteBytes(24, field_names[0], BytesWithZero); + } + if (hasStringPieceWithZero) { + output.WriteString(25, field_names[23], StringPieceWithZero); + } + if (hasCordWithZero) { + output.WriteString(26, field_names[1], CordWithZero); + } + if (hasReplacementString) { + output.WriteString(27, field_names[18], ReplacementString); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasEscapedBytes) { + size += pb::CodedOutputStream.ComputeBytesSize(1, EscapedBytes); + } + if (hasLargeUint32) { + size += pb::CodedOutputStream.ComputeUInt32Size(2, LargeUint32); + } + if (hasLargeUint64) { + size += pb::CodedOutputStream.ComputeUInt64Size(3, LargeUint64); + } + if (hasSmallInt32) { + size += pb::CodedOutputStream.ComputeInt32Size(4, SmallInt32); + } + if (hasSmallInt64) { + size += pb::CodedOutputStream.ComputeInt64Size(5, SmallInt64); + } + if (hasReallySmallInt32) { + size += pb::CodedOutputStream.ComputeInt32Size(21, ReallySmallInt32); + } + if (hasReallySmallInt64) { + size += pb::CodedOutputStream.ComputeInt64Size(22, ReallySmallInt64); + } + if (hasUtf8String) { + size += pb::CodedOutputStream.ComputeStringSize(6, Utf8String); + } + if (hasZeroFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(7, ZeroFloat); + } + if (hasOneFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(8, OneFloat); + } + if (hasSmallFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(9, SmallFloat); + } + if (hasNegativeOneFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(10, NegativeOneFloat); + } + if (hasNegativeFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(11, NegativeFloat); + } + if (hasLargeFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(12, LargeFloat); + } + if (hasSmallNegativeFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(13, SmallNegativeFloat); + } + if (hasInfDouble) { + size += pb::CodedOutputStream.ComputeDoubleSize(14, InfDouble); + } + if (hasNegInfDouble) { + size += pb::CodedOutputStream.ComputeDoubleSize(15, NegInfDouble); + } + if (hasNanDouble) { + size += pb::CodedOutputStream.ComputeDoubleSize(16, NanDouble); + } + if (hasInfFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(17, InfFloat); + } + if (hasNegInfFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(18, NegInfFloat); + } + if (hasNanFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(19, NanFloat); + } + if (hasCppTrigraph) { + size += pb::CodedOutputStream.ComputeStringSize(20, CppTrigraph); + } + if (hasStringWithZero) { + size += pb::CodedOutputStream.ComputeStringSize(23, StringWithZero); + } + if (hasBytesWithZero) { + size += pb::CodedOutputStream.ComputeBytesSize(24, BytesWithZero); + } + if (hasStringPieceWithZero) { + size += pb::CodedOutputStream.ComputeStringSize(25, StringPieceWithZero); + } + if (hasCordWithZero) { + size += pb::CodedOutputStream.ComputeStringSize(26, CordWithZero); + } + if (hasReplacementString) { + size += pb::CodedOutputStream.ComputeStringSize(27, ReplacementString); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestExtremeDefaultValues ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestExtremeDefaultValues ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestExtremeDefaultValues MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestExtremeDefaultValues prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestExtremeDefaultValues cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestExtremeDefaultValues result; + + private TestExtremeDefaultValues PrepareBuilder() { + if (resultIsReadOnly) { + TestExtremeDefaultValues original = result; + result = new TestExtremeDefaultValues(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestExtremeDefaultValues MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor; } + } + + public override TestExtremeDefaultValues DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.DefaultInstance; } + } + + public override TestExtremeDefaultValues BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestExtremeDefaultValues) { + return MergeFrom((TestExtremeDefaultValues) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestExtremeDefaultValues other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasEscapedBytes) { + EscapedBytes = other.EscapedBytes; + } + if (other.HasLargeUint32) { + LargeUint32 = other.LargeUint32; + } + if (other.HasLargeUint64) { + LargeUint64 = other.LargeUint64; + } + if (other.HasSmallInt32) { + SmallInt32 = other.SmallInt32; + } + if (other.HasSmallInt64) { + SmallInt64 = other.SmallInt64; + } + if (other.HasReallySmallInt32) { + ReallySmallInt32 = other.ReallySmallInt32; + } + if (other.HasReallySmallInt64) { + ReallySmallInt64 = other.ReallySmallInt64; + } + if (other.HasUtf8String) { + Utf8String = other.Utf8String; + } + if (other.HasZeroFloat) { + ZeroFloat = other.ZeroFloat; + } + if (other.HasOneFloat) { + OneFloat = other.OneFloat; + } + if (other.HasSmallFloat) { + SmallFloat = other.SmallFloat; + } + if (other.HasNegativeOneFloat) { + NegativeOneFloat = other.NegativeOneFloat; + } + if (other.HasNegativeFloat) { + NegativeFloat = other.NegativeFloat; + } + if (other.HasLargeFloat) { + LargeFloat = other.LargeFloat; + } + if (other.HasSmallNegativeFloat) { + SmallNegativeFloat = other.SmallNegativeFloat; + } + if (other.HasInfDouble) { + InfDouble = other.InfDouble; + } + if (other.HasNegInfDouble) { + NegInfDouble = other.NegInfDouble; + } + if (other.HasNanDouble) { + NanDouble = other.NanDouble; + } + if (other.HasInfFloat) { + InfFloat = other.InfFloat; + } + if (other.HasNegInfFloat) { + NegInfFloat = other.NegInfFloat; + } + if (other.HasNanFloat) { + NanFloat = other.NanFloat; + } + if (other.HasCppTrigraph) { + CppTrigraph = other.CppTrigraph; + } + if (other.HasStringWithZero) { + StringWithZero = other.StringWithZero; + } + if (other.HasBytesWithZero) { + BytesWithZero = other.BytesWithZero; + } + if (other.HasStringPieceWithZero) { + StringPieceWithZero = other.StringPieceWithZero; + } + if (other.HasCordWithZero) { + CordWithZero = other.CordWithZero; + } + if (other.HasReplacementString) { + ReplacementString = other.ReplacementString; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testExtremeDefaultValuesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testExtremeDefaultValuesFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + result.hasEscapedBytes = input.ReadBytes(ref result.escapedBytes_); + break; + } + case 16: { + result.hasLargeUint32 = input.ReadUInt32(ref result.largeUint32_); + break; + } + case 24: { + result.hasLargeUint64 = input.ReadUInt64(ref result.largeUint64_); + break; + } + case 32: { + result.hasSmallInt32 = input.ReadInt32(ref result.smallInt32_); + break; + } + case 40: { + result.hasSmallInt64 = input.ReadInt64(ref result.smallInt64_); + break; + } + case 50: { + result.hasUtf8String = input.ReadString(ref result.utf8String_); + break; + } + case 61: { + result.hasZeroFloat = input.ReadFloat(ref result.zeroFloat_); + break; + } + case 69: { + result.hasOneFloat = input.ReadFloat(ref result.oneFloat_); + break; + } + case 77: { + result.hasSmallFloat = input.ReadFloat(ref result.smallFloat_); + break; + } + case 85: { + result.hasNegativeOneFloat = input.ReadFloat(ref result.negativeOneFloat_); + break; + } + case 93: { + result.hasNegativeFloat = input.ReadFloat(ref result.negativeFloat_); + break; + } + case 101: { + result.hasLargeFloat = input.ReadFloat(ref result.largeFloat_); + break; + } + case 109: { + result.hasSmallNegativeFloat = input.ReadFloat(ref result.smallNegativeFloat_); + break; + } + case 113: { + result.hasInfDouble = input.ReadDouble(ref result.infDouble_); + break; + } + case 121: { + result.hasNegInfDouble = input.ReadDouble(ref result.negInfDouble_); + break; + } + case 129: { + result.hasNanDouble = input.ReadDouble(ref result.nanDouble_); + break; + } + case 141: { + result.hasInfFloat = input.ReadFloat(ref result.infFloat_); + break; + } + case 149: { + result.hasNegInfFloat = input.ReadFloat(ref result.negInfFloat_); + break; + } + case 157: { + result.hasNanFloat = input.ReadFloat(ref result.nanFloat_); + break; + } + case 162: { + result.hasCppTrigraph = input.ReadString(ref result.cppTrigraph_); + break; + } + case 168: { + result.hasReallySmallInt32 = input.ReadInt32(ref result.reallySmallInt32_); + break; + } + case 176: { + result.hasReallySmallInt64 = input.ReadInt64(ref result.reallySmallInt64_); + break; + } + case 186: { + result.hasStringWithZero = input.ReadString(ref result.stringWithZero_); + break; + } + case 194: { + result.hasBytesWithZero = input.ReadBytes(ref result.bytesWithZero_); + break; + } + case 202: { + result.hasStringPieceWithZero = input.ReadString(ref result.stringPieceWithZero_); + break; + } + case 210: { + result.hasCordWithZero = input.ReadString(ref result.cordWithZero_); + break; + } + case 218: { + result.hasReplacementString = input.ReadString(ref result.replacementString_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasEscapedBytes { + get { return result.hasEscapedBytes; } + } + public pb::ByteString EscapedBytes { + get { return result.EscapedBytes; } + set { SetEscapedBytes(value); } + } + public Builder SetEscapedBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasEscapedBytes = true; + result.escapedBytes_ = value; + return this; + } + public Builder ClearEscapedBytes() { + PrepareBuilder(); + result.hasEscapedBytes = false; + result.escapedBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[0].DefaultValue; + return this; + } + + public bool HasLargeUint32 { + get { return result.hasLargeUint32; } + } + [global::System.CLSCompliant(false)] + public uint LargeUint32 { + get { return result.LargeUint32; } + set { SetLargeUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetLargeUint32(uint value) { + PrepareBuilder(); + result.hasLargeUint32 = true; + result.largeUint32_ = value; + return this; + } + public Builder ClearLargeUint32() { + PrepareBuilder(); + result.hasLargeUint32 = false; + result.largeUint32_ = 4294967295; + return this; + } + + public bool HasLargeUint64 { + get { return result.hasLargeUint64; } + } + [global::System.CLSCompliant(false)] + public ulong LargeUint64 { + get { return result.LargeUint64; } + set { SetLargeUint64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetLargeUint64(ulong value) { + PrepareBuilder(); + result.hasLargeUint64 = true; + result.largeUint64_ = value; + return this; + } + public Builder ClearLargeUint64() { + PrepareBuilder(); + result.hasLargeUint64 = false; + result.largeUint64_ = 18446744073709551615UL; + return this; + } + + public bool HasSmallInt32 { + get { return result.hasSmallInt32; } + } + public int SmallInt32 { + get { return result.SmallInt32; } + set { SetSmallInt32(value); } + } + public Builder SetSmallInt32(int value) { + PrepareBuilder(); + result.hasSmallInt32 = true; + result.smallInt32_ = value; + return this; + } + public Builder ClearSmallInt32() { + PrepareBuilder(); + result.hasSmallInt32 = false; + result.smallInt32_ = -2147483647; + return this; + } + + public bool HasSmallInt64 { + get { return result.hasSmallInt64; } + } + public long SmallInt64 { + get { return result.SmallInt64; } + set { SetSmallInt64(value); } + } + public Builder SetSmallInt64(long value) { + PrepareBuilder(); + result.hasSmallInt64 = true; + result.smallInt64_ = value; + return this; + } + public Builder ClearSmallInt64() { + PrepareBuilder(); + result.hasSmallInt64 = false; + result.smallInt64_ = -9223372036854775807L; + return this; + } + + public bool HasReallySmallInt32 { + get { return result.hasReallySmallInt32; } + } + public int ReallySmallInt32 { + get { return result.ReallySmallInt32; } + set { SetReallySmallInt32(value); } + } + public Builder SetReallySmallInt32(int value) { + PrepareBuilder(); + result.hasReallySmallInt32 = true; + result.reallySmallInt32_ = value; + return this; + } + public Builder ClearReallySmallInt32() { + PrepareBuilder(); + result.hasReallySmallInt32 = false; + result.reallySmallInt32_ = -2147483648; + return this; + } + + public bool HasReallySmallInt64 { + get { return result.hasReallySmallInt64; } + } + public long ReallySmallInt64 { + get { return result.ReallySmallInt64; } + set { SetReallySmallInt64(value); } + } + public Builder SetReallySmallInt64(long value) { + PrepareBuilder(); + result.hasReallySmallInt64 = true; + result.reallySmallInt64_ = value; + return this; + } + public Builder ClearReallySmallInt64() { + PrepareBuilder(); + result.hasReallySmallInt64 = false; + result.reallySmallInt64_ = -9223372036854775808L; + return this; + } + + public bool HasUtf8String { + get { return result.hasUtf8String; } + } + public string Utf8String { + get { return result.Utf8String; } + set { SetUtf8String(value); } + } + public Builder SetUtf8String(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasUtf8String = true; + result.utf8String_ = value; + return this; + } + public Builder ClearUtf8String() { + PrepareBuilder(); + result.hasUtf8String = false; + result.utf8String_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[7].DefaultValue; + return this; + } + + public bool HasZeroFloat { + get { return result.hasZeroFloat; } + } + public float ZeroFloat { + get { return result.ZeroFloat; } + set { SetZeroFloat(value); } + } + public Builder SetZeroFloat(float value) { + PrepareBuilder(); + result.hasZeroFloat = true; + result.zeroFloat_ = value; + return this; + } + public Builder ClearZeroFloat() { + PrepareBuilder(); + result.hasZeroFloat = false; + result.zeroFloat_ = 0F; + return this; + } + + public bool HasOneFloat { + get { return result.hasOneFloat; } + } + public float OneFloat { + get { return result.OneFloat; } + set { SetOneFloat(value); } + } + public Builder SetOneFloat(float value) { + PrepareBuilder(); + result.hasOneFloat = true; + result.oneFloat_ = value; + return this; + } + public Builder ClearOneFloat() { + PrepareBuilder(); + result.hasOneFloat = false; + result.oneFloat_ = 1F; + return this; + } + + public bool HasSmallFloat { + get { return result.hasSmallFloat; } + } + public float SmallFloat { + get { return result.SmallFloat; } + set { SetSmallFloat(value); } + } + public Builder SetSmallFloat(float value) { + PrepareBuilder(); + result.hasSmallFloat = true; + result.smallFloat_ = value; + return this; + } + public Builder ClearSmallFloat() { + PrepareBuilder(); + result.hasSmallFloat = false; + result.smallFloat_ = 1.5F; + return this; + } + + public bool HasNegativeOneFloat { + get { return result.hasNegativeOneFloat; } + } + public float NegativeOneFloat { + get { return result.NegativeOneFloat; } + set { SetNegativeOneFloat(value); } + } + public Builder SetNegativeOneFloat(float value) { + PrepareBuilder(); + result.hasNegativeOneFloat = true; + result.negativeOneFloat_ = value; + return this; + } + public Builder ClearNegativeOneFloat() { + PrepareBuilder(); + result.hasNegativeOneFloat = false; + result.negativeOneFloat_ = -1F; + return this; + } + + public bool HasNegativeFloat { + get { return result.hasNegativeFloat; } + } + public float NegativeFloat { + get { return result.NegativeFloat; } + set { SetNegativeFloat(value); } + } + public Builder SetNegativeFloat(float value) { + PrepareBuilder(); + result.hasNegativeFloat = true; + result.negativeFloat_ = value; + return this; + } + public Builder ClearNegativeFloat() { + PrepareBuilder(); + result.hasNegativeFloat = false; + result.negativeFloat_ = -1.5F; + return this; + } + + public bool HasLargeFloat { + get { return result.hasLargeFloat; } + } + public float LargeFloat { + get { return result.LargeFloat; } + set { SetLargeFloat(value); } + } + public Builder SetLargeFloat(float value) { + PrepareBuilder(); + result.hasLargeFloat = true; + result.largeFloat_ = value; + return this; + } + public Builder ClearLargeFloat() { + PrepareBuilder(); + result.hasLargeFloat = false; + result.largeFloat_ = 2e+08F; + return this; + } + + public bool HasSmallNegativeFloat { + get { return result.hasSmallNegativeFloat; } + } + public float SmallNegativeFloat { + get { return result.SmallNegativeFloat; } + set { SetSmallNegativeFloat(value); } + } + public Builder SetSmallNegativeFloat(float value) { + PrepareBuilder(); + result.hasSmallNegativeFloat = true; + result.smallNegativeFloat_ = value; + return this; + } + public Builder ClearSmallNegativeFloat() { + PrepareBuilder(); + result.hasSmallNegativeFloat = false; + result.smallNegativeFloat_ = -8e-28F; + return this; + } + + public bool HasInfDouble { + get { return result.hasInfDouble; } + } + public double InfDouble { + get { return result.InfDouble; } + set { SetInfDouble(value); } + } + public Builder SetInfDouble(double value) { + PrepareBuilder(); + result.hasInfDouble = true; + result.infDouble_ = value; + return this; + } + public Builder ClearInfDouble() { + PrepareBuilder(); + result.hasInfDouble = false; + result.infDouble_ = double.PositiveInfinity; + return this; + } + + public bool HasNegInfDouble { + get { return result.hasNegInfDouble; } + } + public double NegInfDouble { + get { return result.NegInfDouble; } + set { SetNegInfDouble(value); } + } + public Builder SetNegInfDouble(double value) { + PrepareBuilder(); + result.hasNegInfDouble = true; + result.negInfDouble_ = value; + return this; + } + public Builder ClearNegInfDouble() { + PrepareBuilder(); + result.hasNegInfDouble = false; + result.negInfDouble_ = double.NegativeInfinity; + return this; + } + + public bool HasNanDouble { + get { return result.hasNanDouble; } + } + public double NanDouble { + get { return result.NanDouble; } + set { SetNanDouble(value); } + } + public Builder SetNanDouble(double value) { + PrepareBuilder(); + result.hasNanDouble = true; + result.nanDouble_ = value; + return this; + } + public Builder ClearNanDouble() { + PrepareBuilder(); + result.hasNanDouble = false; + result.nanDouble_ = double.NaN; + return this; + } + + public bool HasInfFloat { + get { return result.hasInfFloat; } + } + public float InfFloat { + get { return result.InfFloat; } + set { SetInfFloat(value); } + } + public Builder SetInfFloat(float value) { + PrepareBuilder(); + result.hasInfFloat = true; + result.infFloat_ = value; + return this; + } + public Builder ClearInfFloat() { + PrepareBuilder(); + result.hasInfFloat = false; + result.infFloat_ = float.PositiveInfinity; + return this; + } + + public bool HasNegInfFloat { + get { return result.hasNegInfFloat; } + } + public float NegInfFloat { + get { return result.NegInfFloat; } + set { SetNegInfFloat(value); } + } + public Builder SetNegInfFloat(float value) { + PrepareBuilder(); + result.hasNegInfFloat = true; + result.negInfFloat_ = value; + return this; + } + public Builder ClearNegInfFloat() { + PrepareBuilder(); + result.hasNegInfFloat = false; + result.negInfFloat_ = float.NegativeInfinity; + return this; + } + + public bool HasNanFloat { + get { return result.hasNanFloat; } + } + public float NanFloat { + get { return result.NanFloat; } + set { SetNanFloat(value); } + } + public Builder SetNanFloat(float value) { + PrepareBuilder(); + result.hasNanFloat = true; + result.nanFloat_ = value; + return this; + } + public Builder ClearNanFloat() { + PrepareBuilder(); + result.hasNanFloat = false; + result.nanFloat_ = float.NaN; + return this; + } + + public bool HasCppTrigraph { + get { return result.hasCppTrigraph; } + } + public string CppTrigraph { + get { return result.CppTrigraph; } + set { SetCppTrigraph(value); } + } + public Builder SetCppTrigraph(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasCppTrigraph = true; + result.cppTrigraph_ = value; + return this; + } + public Builder ClearCppTrigraph() { + PrepareBuilder(); + result.hasCppTrigraph = false; + result.cppTrigraph_ = "? ? ?? ?? ??? ??/ ??-"; + return this; + } + + public bool HasStringWithZero { + get { return result.hasStringWithZero; } + } + public string StringWithZero { + get { return result.StringWithZero; } + set { SetStringWithZero(value); } + } + public Builder SetStringWithZero(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasStringWithZero = true; + result.stringWithZero_ = value; + return this; + } + public Builder ClearStringWithZero() { + PrepareBuilder(); + result.hasStringWithZero = false; + result.stringWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[22].DefaultValue; + return this; + } + + public bool HasBytesWithZero { + get { return result.hasBytesWithZero; } + } + public pb::ByteString BytesWithZero { + get { return result.BytesWithZero; } + set { SetBytesWithZero(value); } + } + public Builder SetBytesWithZero(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBytesWithZero = true; + result.bytesWithZero_ = value; + return this; + } + public Builder ClearBytesWithZero() { + PrepareBuilder(); + result.hasBytesWithZero = false; + result.bytesWithZero_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[23].DefaultValue; + return this; + } + + public bool HasStringPieceWithZero { + get { return result.hasStringPieceWithZero; } + } + public string StringPieceWithZero { + get { return result.StringPieceWithZero; } + set { SetStringPieceWithZero(value); } + } + public Builder SetStringPieceWithZero(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasStringPieceWithZero = true; + result.stringPieceWithZero_ = value; + return this; + } + public Builder ClearStringPieceWithZero() { + PrepareBuilder(); + result.hasStringPieceWithZero = false; + result.stringPieceWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[24].DefaultValue; + return this; + } + + public bool HasCordWithZero { + get { return result.hasCordWithZero; } + } + public string CordWithZero { + get { return result.CordWithZero; } + set { SetCordWithZero(value); } + } + public Builder SetCordWithZero(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasCordWithZero = true; + result.cordWithZero_ = value; + return this; + } + public Builder ClearCordWithZero() { + PrepareBuilder(); + result.hasCordWithZero = false; + result.cordWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[25].DefaultValue; + return this; + } + + public bool HasReplacementString { + get { return result.hasReplacementString; } + } + public string ReplacementString { + get { return result.ReplacementString; } + set { SetReplacementString(value); } + } + public Builder SetReplacementString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasReplacementString = true; + result.replacementString_ = value; + return this; + } + public Builder ClearReplacementString() { + PrepareBuilder(); + result.hasReplacementString = false; + result.replacementString_ = "${unknown}"; + return this; + } + } + static TestExtremeDefaultValues() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class SparseEnumMessage : pb::GeneratedMessage { + private SparseEnumMessage() { } + private static readonly SparseEnumMessage defaultInstance = new SparseEnumMessage().MakeReadOnly(); + private static readonly string[] _sparseEnumMessageFieldNames = new string[] { "sparse_enum" }; + private static readonly uint[] _sparseEnumMessageFieldTags = new uint[] { 8 }; + public static SparseEnumMessage DefaultInstance { + get { return defaultInstance; } + } + + public override SparseEnumMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override SparseEnumMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_SparseEnumMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable; } + } + + public const int SparseEnumFieldNumber = 1; + private bool hasSparseEnum; + private global::Google.ProtocolBuffers.TestProtos.TestSparseEnum sparseEnum_ = global::Google.ProtocolBuffers.TestProtos.TestSparseEnum.SPARSE_A; + public bool HasSparseEnum { + get { return hasSparseEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestSparseEnum SparseEnum { + get { return sparseEnum_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _sparseEnumMessageFieldNames; + if (hasSparseEnum) { + output.WriteEnum(1, field_names[0], (int) SparseEnum, SparseEnum); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasSparseEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(1, (int) SparseEnum); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static SparseEnumMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static SparseEnumMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static SparseEnumMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private SparseEnumMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(SparseEnumMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(SparseEnumMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private SparseEnumMessage result; + + private SparseEnumMessage PrepareBuilder() { + if (resultIsReadOnly) { + SparseEnumMessage original = result; + result = new SparseEnumMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override SparseEnumMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.Descriptor; } + } + + public override SparseEnumMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.DefaultInstance; } + } + + public override SparseEnumMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is SparseEnumMessage) { + return MergeFrom((SparseEnumMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(SparseEnumMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasSparseEnum) { + SparseEnum = other.SparseEnum; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_sparseEnumMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _sparseEnumMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + object unknown; + if(input.ReadEnum(ref result.sparseEnum_, out unknown)) { + result.hasSparseEnum = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(1, (ulong)(int)unknown); + } + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasSparseEnum { + get { return result.hasSparseEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestSparseEnum SparseEnum { + get { return result.SparseEnum; } + set { SetSparseEnum(value); } + } + public Builder SetSparseEnum(global::Google.ProtocolBuffers.TestProtos.TestSparseEnum value) { + PrepareBuilder(); + result.hasSparseEnum = true; + result.sparseEnum_ = value; + return this; + } + public Builder ClearSparseEnum() { + PrepareBuilder(); + result.hasSparseEnum = false; + result.sparseEnum_ = global::Google.ProtocolBuffers.TestProtos.TestSparseEnum.SPARSE_A; + return this; + } + } + static SparseEnumMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OneString : pb::GeneratedMessage { + private OneString() { } + private static readonly OneString defaultInstance = new OneString().MakeReadOnly(); + private static readonly string[] _oneStringFieldNames = new string[] { "data" }; + private static readonly uint[] _oneStringFieldTags = new uint[] { 10 }; + public static OneString DefaultInstance { + get { return defaultInstance; } + } + + public override OneString DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override OneString ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneString__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneString__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private string data_ = ""; + public bool HasData { + get { return hasData; } + } + public string Data { + get { return data_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _oneStringFieldNames; + if (hasData) { + output.WriteString(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) { + size += pb::CodedOutputStream.ComputeStringSize(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static OneString ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OneString ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OneString ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OneString ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OneString ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OneString ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OneString ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OneString ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OneString ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OneString ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OneString MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OneString prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OneString cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OneString result; + + private OneString PrepareBuilder() { + if (resultIsReadOnly) { + OneString original = result; + result = new OneString(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override OneString MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.OneString.Descriptor; } + } + + public override OneString DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.OneString.DefaultInstance; } + } + + public override OneString BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is OneString) { + return MergeFrom((OneString) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OneString other) { + if (other == global::Google.ProtocolBuffers.TestProtos.OneString.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_oneStringFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _oneStringFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + result.hasData = input.ReadString(ref result.data_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData { + get { return result.hasData; } + } + public string Data { + get { return result.Data; } + set { SetData(value); } + } + public Builder SetData(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() { + PrepareBuilder(); + result.hasData = false; + result.data_ = ""; + return this; + } + } + static OneString() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class MoreString : pb::GeneratedMessage { + private MoreString() { } + private static readonly MoreString defaultInstance = new MoreString().MakeReadOnly(); + private static readonly string[] _moreStringFieldNames = new string[] { "data" }; + private static readonly uint[] _moreStringFieldTags = new uint[] { 10 }; + public static MoreString DefaultInstance { + get { return defaultInstance; } + } + + public override MoreString DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override MoreString ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreString__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreString__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private pbc::PopsicleList data_ = new pbc::PopsicleList(); + public scg::IList DataList { + get { return pbc::Lists.AsReadOnly(data_); } + } + public int DataCount { + get { return data_.Count; } + } + public string GetData(int index) { + return data_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _moreStringFieldNames; + if (data_.Count > 0) { + output.WriteStringArray(1, field_names[0], data_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + foreach (string element in DataList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 1 * data_.Count; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static MoreString ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MoreString ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MoreString ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MoreString ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MoreString ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MoreString ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static MoreString ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static MoreString ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static MoreString ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MoreString ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private MoreString MakeReadOnly() { + data_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(MoreString prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(MoreString cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private MoreString result; + + private MoreString PrepareBuilder() { + if (resultIsReadOnly) { + MoreString original = result; + result = new MoreString(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override MoreString MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.MoreString.Descriptor; } + } + + public override MoreString DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.MoreString.DefaultInstance; } + } + + public override MoreString BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is MoreString) { + return MergeFrom((MoreString) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(MoreString other) { + if (other == global::Google.ProtocolBuffers.TestProtos.MoreString.DefaultInstance) return this; + PrepareBuilder(); + if (other.data_.Count != 0) { + result.data_.Add(other.data_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_moreStringFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _moreStringFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + input.ReadStringArray(tag, field_name, result.data_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList DataList { + get { return PrepareBuilder().data_; } + } + public int DataCount { + get { return result.DataCount; } + } + public string GetData(int index) { + return result.GetData(index); + } + public Builder SetData(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.data_[index] = value; + return this; + } + public Builder AddData(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.data_.Add(value); + return this; + } + public Builder AddRangeData(scg::IEnumerable values) { + PrepareBuilder(); + result.data_.Add(values); + return this; + } + public Builder ClearData() { + PrepareBuilder(); + result.data_.Clear(); + return this; + } + } + static MoreString() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OneBytes : pb::GeneratedMessage { + private OneBytes() { } + private static readonly OneBytes defaultInstance = new OneBytes().MakeReadOnly(); + private static readonly string[] _oneBytesFieldNames = new string[] { "data" }; + private static readonly uint[] _oneBytesFieldTags = new uint[] { 10 }; + public static OneBytes DefaultInstance { + get { return defaultInstance; } + } + + public override OneBytes DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override OneBytes ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneBytes__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneBytes__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private pb::ByteString data_ = pb::ByteString.Empty; + public bool HasData { + get { return hasData; } + } + public pb::ByteString Data { + get { return data_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _oneBytesFieldNames; + if (hasData) { + output.WriteBytes(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) { + size += pb::CodedOutputStream.ComputeBytesSize(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static OneBytes ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OneBytes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OneBytes ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OneBytes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OneBytes ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OneBytes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OneBytes ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OneBytes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OneBytes ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OneBytes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OneBytes MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OneBytes prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OneBytes cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OneBytes result; + + private OneBytes PrepareBuilder() { + if (resultIsReadOnly) { + OneBytes original = result; + result = new OneBytes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override OneBytes MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.OneBytes.Descriptor; } + } + + public override OneBytes DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.OneBytes.DefaultInstance; } + } + + public override OneBytes BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is OneBytes) { + return MergeFrom((OneBytes) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OneBytes other) { + if (other == global::Google.ProtocolBuffers.TestProtos.OneBytes.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_oneBytesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _oneBytesFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + result.hasData = input.ReadBytes(ref result.data_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData { + get { return result.hasData; } + } + public pb::ByteString Data { + get { return result.Data; } + set { SetData(value); } + } + public Builder SetData(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() { + PrepareBuilder(); + result.hasData = false; + result.data_ = pb::ByteString.Empty; + return this; + } + } + static OneBytes() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class MoreBytes : pb::GeneratedMessage { + private MoreBytes() { } + private static readonly MoreBytes defaultInstance = new MoreBytes().MakeReadOnly(); + private static readonly string[] _moreBytesFieldNames = new string[] { "data" }; + private static readonly uint[] _moreBytesFieldTags = new uint[] { 10 }; + public static MoreBytes DefaultInstance { + get { return defaultInstance; } + } + + public override MoreBytes DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override MoreBytes ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreBytes__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreBytes__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private pbc::PopsicleList data_ = new pbc::PopsicleList(); + public scg::IList DataList { + get { return pbc::Lists.AsReadOnly(data_); } + } + public int DataCount { + get { return data_.Count; } + } + public pb::ByteString GetData(int index) { + return data_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _moreBytesFieldNames; + if (data_.Count > 0) { + output.WriteBytesArray(1, field_names[0], data_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + foreach (pb::ByteString element in DataList) { + dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element); + } + size += dataSize; + size += 1 * data_.Count; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static MoreBytes ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MoreBytes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MoreBytes ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MoreBytes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MoreBytes ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MoreBytes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static MoreBytes ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static MoreBytes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static MoreBytes ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MoreBytes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private MoreBytes MakeReadOnly() { + data_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(MoreBytes prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(MoreBytes cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private MoreBytes result; + + private MoreBytes PrepareBuilder() { + if (resultIsReadOnly) { + MoreBytes original = result; + result = new MoreBytes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override MoreBytes MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.MoreBytes.Descriptor; } + } + + public override MoreBytes DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.MoreBytes.DefaultInstance; } + } + + public override MoreBytes BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is MoreBytes) { + return MergeFrom((MoreBytes) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(MoreBytes other) { + if (other == global::Google.ProtocolBuffers.TestProtos.MoreBytes.DefaultInstance) return this; + PrepareBuilder(); + if (other.data_.Count != 0) { + result.data_.Add(other.data_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_moreBytesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _moreBytesFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + input.ReadBytesArray(tag, field_name, result.data_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList DataList { + get { return PrepareBuilder().data_; } + } + public int DataCount { + get { return result.DataCount; } + } + public pb::ByteString GetData(int index) { + return result.GetData(index); + } + public Builder SetData(int index, pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.data_[index] = value; + return this; + } + public Builder AddData(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.data_.Add(value); + return this; + } + public Builder AddRangeData(scg::IEnumerable values) { + PrepareBuilder(); + result.data_.Add(values); + return this; + } + public Builder ClearData() { + PrepareBuilder(); + result.data_.Clear(); + return this; + } + } + static MoreBytes() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Int32Message : pb::GeneratedMessage { + private Int32Message() { } + private static readonly Int32Message defaultInstance = new Int32Message().MakeReadOnly(); + private static readonly string[] _int32MessageFieldNames = new string[] { "data" }; + private static readonly uint[] _int32MessageFieldTags = new uint[] { 8 }; + public static Int32Message DefaultInstance { + get { return defaultInstance; } + } + + public override Int32Message DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Int32Message ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int32Message__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int32Message__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private int data_; + public bool HasData { + get { return hasData; } + } + public int Data { + get { return data_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _int32MessageFieldNames; + if (hasData) { + output.WriteInt32(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) { + size += pb::CodedOutputStream.ComputeInt32Size(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Int32Message ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Int32Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Int32Message ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Int32Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Int32Message ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Int32Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Int32Message ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Int32Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Int32Message ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Int32Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Int32Message MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Int32Message prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Int32Message cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Int32Message result; + + private Int32Message PrepareBuilder() { + if (resultIsReadOnly) { + Int32Message original = result; + result = new Int32Message(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Int32Message MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.Int32Message.Descriptor; } + } + + public override Int32Message DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.Int32Message.DefaultInstance; } + } + + public override Int32Message BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is Int32Message) { + return MergeFrom((Int32Message) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Int32Message other) { + if (other == global::Google.ProtocolBuffers.TestProtos.Int32Message.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_int32MessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _int32MessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasData = input.ReadInt32(ref result.data_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData { + get { return result.hasData; } + } + public int Data { + get { return result.Data; } + set { SetData(value); } + } + public Builder SetData(int value) { + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() { + PrepareBuilder(); + result.hasData = false; + result.data_ = 0; + return this; + } + } + static Int32Message() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Uint32Message : pb::GeneratedMessage { + private Uint32Message() { } + private static readonly Uint32Message defaultInstance = new Uint32Message().MakeReadOnly(); + private static readonly string[] _uint32MessageFieldNames = new string[] { "data" }; + private static readonly uint[] _uint32MessageFieldTags = new uint[] { 8 }; + public static Uint32Message DefaultInstance { + get { return defaultInstance; } + } + + public override Uint32Message DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Uint32Message ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint32Message__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint32Message__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private uint data_; + public bool HasData { + get { return hasData; } + } + [global::System.CLSCompliant(false)] + public uint Data { + get { return data_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _uint32MessageFieldNames; + if (hasData) { + output.WriteUInt32(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) { + size += pb::CodedOutputStream.ComputeUInt32Size(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Uint32Message ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Uint32Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Uint32Message ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Uint32Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Uint32Message ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Uint32Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Uint32Message ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Uint32Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Uint32Message ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Uint32Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Uint32Message MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Uint32Message prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Uint32Message cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Uint32Message result; + + private Uint32Message PrepareBuilder() { + if (resultIsReadOnly) { + Uint32Message original = result; + result = new Uint32Message(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Uint32Message MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.Uint32Message.Descriptor; } + } + + public override Uint32Message DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.Uint32Message.DefaultInstance; } + } + + public override Uint32Message BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is Uint32Message) { + return MergeFrom((Uint32Message) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Uint32Message other) { + if (other == global::Google.ProtocolBuffers.TestProtos.Uint32Message.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_uint32MessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _uint32MessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasData = input.ReadUInt32(ref result.data_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData { + get { return result.hasData; } + } + [global::System.CLSCompliant(false)] + public uint Data { + get { return result.Data; } + set { SetData(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetData(uint value) { + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() { + PrepareBuilder(); + result.hasData = false; + result.data_ = 0; + return this; + } + } + static Uint32Message() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Int64Message : pb::GeneratedMessage { + private Int64Message() { } + private static readonly Int64Message defaultInstance = new Int64Message().MakeReadOnly(); + private static readonly string[] _int64MessageFieldNames = new string[] { "data" }; + private static readonly uint[] _int64MessageFieldTags = new uint[] { 8 }; + public static Int64Message DefaultInstance { + get { return defaultInstance; } + } + + public override Int64Message DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Int64Message ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int64Message__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int64Message__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private long data_; + public bool HasData { + get { return hasData; } + } + public long Data { + get { return data_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _int64MessageFieldNames; + if (hasData) { + output.WriteInt64(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) { + size += pb::CodedOutputStream.ComputeInt64Size(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Int64Message ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Int64Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Int64Message ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Int64Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Int64Message ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Int64Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Int64Message ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Int64Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Int64Message ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Int64Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Int64Message MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Int64Message prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Int64Message cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Int64Message result; + + private Int64Message PrepareBuilder() { + if (resultIsReadOnly) { + Int64Message original = result; + result = new Int64Message(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Int64Message MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.Int64Message.Descriptor; } + } + + public override Int64Message DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.Int64Message.DefaultInstance; } + } + + public override Int64Message BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is Int64Message) { + return MergeFrom((Int64Message) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Int64Message other) { + if (other == global::Google.ProtocolBuffers.TestProtos.Int64Message.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_int64MessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _int64MessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasData = input.ReadInt64(ref result.data_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData { + get { return result.hasData; } + } + public long Data { + get { return result.Data; } + set { SetData(value); } + } + public Builder SetData(long value) { + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() { + PrepareBuilder(); + result.hasData = false; + result.data_ = 0L; + return this; + } + } + static Int64Message() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Uint64Message : pb::GeneratedMessage { + private Uint64Message() { } + private static readonly Uint64Message defaultInstance = new Uint64Message().MakeReadOnly(); + private static readonly string[] _uint64MessageFieldNames = new string[] { "data" }; + private static readonly uint[] _uint64MessageFieldTags = new uint[] { 8 }; + public static Uint64Message DefaultInstance { + get { return defaultInstance; } + } + + public override Uint64Message DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Uint64Message ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint64Message__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint64Message__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private ulong data_; + public bool HasData { + get { return hasData; } + } + [global::System.CLSCompliant(false)] + public ulong Data { + get { return data_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _uint64MessageFieldNames; + if (hasData) { + output.WriteUInt64(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) { + size += pb::CodedOutputStream.ComputeUInt64Size(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Uint64Message ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Uint64Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Uint64Message ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Uint64Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Uint64Message ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Uint64Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Uint64Message ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Uint64Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Uint64Message ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Uint64Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Uint64Message MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Uint64Message prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Uint64Message cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Uint64Message result; + + private Uint64Message PrepareBuilder() { + if (resultIsReadOnly) { + Uint64Message original = result; + result = new Uint64Message(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Uint64Message MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.Uint64Message.Descriptor; } + } + + public override Uint64Message DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.Uint64Message.DefaultInstance; } + } + + public override Uint64Message BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is Uint64Message) { + return MergeFrom((Uint64Message) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Uint64Message other) { + if (other == global::Google.ProtocolBuffers.TestProtos.Uint64Message.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_uint64MessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _uint64MessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasData = input.ReadUInt64(ref result.data_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData { + get { return result.hasData; } + } + [global::System.CLSCompliant(false)] + public ulong Data { + get { return result.Data; } + set { SetData(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetData(ulong value) { + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() { + PrepareBuilder(); + result.hasData = false; + result.data_ = 0UL; + return this; + } + } + static Uint64Message() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class BoolMessage : pb::GeneratedMessage { + private BoolMessage() { } + private static readonly BoolMessage defaultInstance = new BoolMessage().MakeReadOnly(); + private static readonly string[] _boolMessageFieldNames = new string[] { "data" }; + private static readonly uint[] _boolMessageFieldTags = new uint[] { 8 }; + public static BoolMessage DefaultInstance { + get { return defaultInstance; } + } + + public override BoolMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override BoolMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BoolMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BoolMessage__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private bool data_; + public bool HasData { + get { return hasData; } + } + public bool Data { + get { return data_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _boolMessageFieldNames; + if (hasData) { + output.WriteBool(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) { + size += pb::CodedOutputStream.ComputeBoolSize(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static BoolMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BoolMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BoolMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BoolMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BoolMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BoolMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static BoolMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static BoolMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static BoolMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BoolMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private BoolMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(BoolMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(BoolMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private BoolMessage result; + + private BoolMessage PrepareBuilder() { + if (resultIsReadOnly) { + BoolMessage original = result; + result = new BoolMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override BoolMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.BoolMessage.Descriptor; } + } + + public override BoolMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.BoolMessage.DefaultInstance; } + } + + public override BoolMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is BoolMessage) { + return MergeFrom((BoolMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(BoolMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.BoolMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_boolMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _boolMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasData = input.ReadBool(ref result.data_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData { + get { return result.hasData; } + } + public bool Data { + get { return result.Data; } + set { SetData(value); } + } + public Builder SetData(bool value) { + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() { + PrepareBuilder(); + result.hasData = false; + result.data_ = false; + return this; + } + } + static BoolMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestOneof : pb::GeneratedMessage { + private TestOneof() { } + private static readonly TestOneof defaultInstance = new TestOneof().MakeReadOnly(); + private static readonly string[] _testOneofFieldNames = new string[] { "foo_int", "foo_message", "foo_string", "foogroup" }; + private static readonly uint[] _testOneofFieldTags = new uint[] { 8, 26, 18, 35 }; + public static TestOneof DefaultInstance { + get { return defaultInstance; } + } + + public override TestOneof DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestOneof ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooGroup : pb::GeneratedMessage { + private FooGroup() { } + private static readonly FooGroup defaultInstance = new FooGroup().MakeReadOnly(); + private static readonly string[] _fooGroupFieldNames = new string[] { "a", "b" }; + private static readonly uint[] _fooGroupFieldTags = new uint[] { 40, 50 }; + public static FooGroup DefaultInstance { + get { return defaultInstance; } + } + + public override FooGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override FooGroup ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof_FooGroup__FieldAccessorTable; } + } + + public const int AFieldNumber = 5; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public const int BFieldNumber = 6; + private bool hasB; + private string b_ = ""; + public bool HasB { + get { return hasB; } + } + public string B { + get { return b_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _fooGroupFieldNames; + if (hasA) { + output.WriteInt32(5, field_names[0], A); + } + if (hasB) { + output.WriteString(6, field_names[1], B); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(5, A); + } + if (hasB) { + size += pb::CodedOutputStream.ComputeStringSize(6, B); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private FooGroup result; + + private FooGroup PrepareBuilder() { + if (resultIsReadOnly) { + FooGroup original = result; + result = new FooGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override FooGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.Descriptor; } + } + + public override FooGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance; } + } + + public override FooGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is FooGroup) { + return MergeFrom((FooGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(FooGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + if (other.HasB) { + B = other.B; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_fooGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _fooGroupFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 40: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 50: { + result.hasB = input.ReadString(ref result.b_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + + public bool HasB { + get { return result.hasB; } + } + public string B { + get { return result.B; } + set { SetB(value); } + } + public Builder SetB(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasB = true; + result.b_ = value; + return this; + } + public Builder ClearB() { + PrepareBuilder(); + result.hasB = false; + result.b_ = ""; + return this; + } + } + static FooGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int FooIntFieldNumber = 1; + private bool hasFooInt; + private int fooInt_; + public bool HasFooInt { + get { return hasFooInt; } + } + public int FooInt { + get { return fooInt_; } + } + + public const int FooStringFieldNumber = 2; + private bool hasFooString; + private string fooString_ = ""; + public bool HasFooString { + get { return hasFooString; } + } + public string FooString { + get { return fooString_; } + } + + public const int FooMessageFieldNumber = 3; + private bool hasFooMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes fooMessage_; + public bool HasFooMessage { + get { return hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage { + get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public const int FooGroupFieldNumber = 4; + private bool hasFooGroup; + private global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup fooGroup_; + public bool HasFooGroup { + get { return hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup FooGroup { + get { return fooGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testOneofFieldNames; + if (hasFooInt) { + output.WriteInt32(1, field_names[0], FooInt); + } + if (hasFooString) { + output.WriteString(2, field_names[2], FooString); + } + if (hasFooMessage) { + output.WriteMessage(3, field_names[1], FooMessage); + } + if (hasFooGroup) { + output.WriteGroup(4, field_names[3], FooGroup); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasFooInt) { + size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); + } + if (hasFooString) { + size += pb::CodedOutputStream.ComputeStringSize(2, FooString); + } + if (hasFooMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(3, FooMessage); + } + if (hasFooGroup) { + size += pb::CodedOutputStream.ComputeGroupSize(4, FooGroup); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestOneof ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneof ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneof ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneof ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneof ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneof ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestOneof ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestOneof ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestOneof ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneof ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestOneof MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestOneof prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestOneof cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestOneof result; + + private TestOneof PrepareBuilder() { + if (resultIsReadOnly) { + TestOneof original = result; + result = new TestOneof(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestOneof MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.Descriptor; } + } + + public override TestOneof DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.DefaultInstance; } + } + + public override TestOneof BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestOneof) { + return MergeFrom((TestOneof) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestOneof other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasFooInt) { + FooInt = other.FooInt; + } + if (other.HasFooString) { + FooString = other.FooString; + } + if (other.HasFooMessage) { + MergeFooMessage(other.FooMessage); + } + if (other.HasFooGroup) { + MergeFooGroup(other.FooGroup); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testOneofFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testOneofFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasFooInt = input.ReadInt32(ref result.fooInt_); + break; + } + case 18: { + result.hasFooString = input.ReadString(ref result.fooString_); + break; + } + case 26: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasFooMessage) { + subBuilder.MergeFrom(FooMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + FooMessage = subBuilder.BuildPartial(); + break; + } + case 35: { + global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.CreateBuilder(); + if (result.hasFooGroup) { + subBuilder.MergeFrom(FooGroup); + } + input.ReadGroup(4, subBuilder, extensionRegistry); + FooGroup = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasFooInt { + get { return result.hasFooInt; } + } + public int FooInt { + get { return result.FooInt; } + set { SetFooInt(value); } + } + public Builder SetFooInt(int value) { + PrepareBuilder(); + result.hasFooInt = true; + result.fooInt_ = value; + return this; + } + public Builder ClearFooInt() { + PrepareBuilder(); + result.hasFooInt = false; + result.fooInt_ = 0; + return this; + } + + public bool HasFooString { + get { return result.hasFooString; } + } + public string FooString { + get { return result.FooString; } + set { SetFooString(value); } + } + public Builder SetFooString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooString = true; + result.fooString_ = value; + return this; + } + public Builder ClearFooString() { + PrepareBuilder(); + result.hasFooString = false; + result.fooString_ = ""; + return this; + } + + public bool HasFooMessage { + get { return result.hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage { + get { return result.FooMessage; } + set { SetFooMessage(value); } + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = value; + return this; + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooMessage && + result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); + } else { + result.fooMessage_ = value; + } + result.hasFooMessage = true; + return this; + } + public Builder ClearFooMessage() { + PrepareBuilder(); + result.hasFooMessage = false; + result.fooMessage_ = null; + return this; + } + + public bool HasFooGroup { + get { return result.hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup FooGroup { + get { return result.FooGroup; } + set { SetFooGroup(value); } + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = value; + return this; + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooGroup && + result.fooGroup_ != global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance) { + result.fooGroup_ = global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.CreateBuilder(result.fooGroup_).MergeFrom(value).BuildPartial(); + } else { + result.fooGroup_ = value; + } + result.hasFooGroup = true; + return this; + } + public Builder ClearFooGroup() { + PrepareBuilder(); + result.hasFooGroup = false; + result.fooGroup_ = null; + return this; + } + } + static TestOneof() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestOneofBackwardsCompatible : pb::GeneratedMessage { + private TestOneofBackwardsCompatible() { } + private static readonly TestOneofBackwardsCompatible defaultInstance = new TestOneofBackwardsCompatible().MakeReadOnly(); + private static readonly string[] _testOneofBackwardsCompatibleFieldNames = new string[] { "foo_int", "foo_message", "foo_string", "foogroup" }; + private static readonly uint[] _testOneofBackwardsCompatibleFieldTags = new uint[] { 8, 26, 18, 35 }; + public static TestOneofBackwardsCompatible DefaultInstance { + get { return defaultInstance; } + } + + public override TestOneofBackwardsCompatible DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestOneofBackwardsCompatible ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooGroup : pb::GeneratedMessage { + private FooGroup() { } + private static readonly FooGroup defaultInstance = new FooGroup().MakeReadOnly(); + private static readonly string[] _fooGroupFieldNames = new string[] { "a", "b" }; + private static readonly uint[] _fooGroupFieldTags = new uint[] { 40, 50 }; + public static FooGroup DefaultInstance { + get { return defaultInstance; } + } + + public override FooGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override FooGroup ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__FieldAccessorTable; } + } + + public const int AFieldNumber = 5; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public const int BFieldNumber = 6; + private bool hasB; + private string b_ = ""; + public bool HasB { + get { return hasB; } + } + public string B { + get { return b_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _fooGroupFieldNames; + if (hasA) { + output.WriteInt32(5, field_names[0], A); + } + if (hasB) { + output.WriteString(6, field_names[1], B); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(5, A); + } + if (hasB) { + size += pb::CodedOutputStream.ComputeStringSize(6, B); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private FooGroup result; + + private FooGroup PrepareBuilder() { + if (resultIsReadOnly) { + FooGroup original = result; + result = new FooGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override FooGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.Descriptor; } + } + + public override FooGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance; } + } + + public override FooGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is FooGroup) { + return MergeFrom((FooGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(FooGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + if (other.HasB) { + B = other.B; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_fooGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _fooGroupFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 40: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 50: { + result.hasB = input.ReadString(ref result.b_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + + public bool HasB { + get { return result.hasB; } + } + public string B { + get { return result.B; } + set { SetB(value); } + } + public Builder SetB(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasB = true; + result.b_ = value; + return this; + } + public Builder ClearB() { + PrepareBuilder(); + result.hasB = false; + result.b_ = ""; + return this; + } + } + static FooGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int FooIntFieldNumber = 1; + private bool hasFooInt; + private int fooInt_; + public bool HasFooInt { + get { return hasFooInt; } + } + public int FooInt { + get { return fooInt_; } + } + + public const int FooStringFieldNumber = 2; + private bool hasFooString; + private string fooString_ = ""; + public bool HasFooString { + get { return hasFooString; } + } + public string FooString { + get { return fooString_; } + } + + public const int FooMessageFieldNumber = 3; + private bool hasFooMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes fooMessage_; + public bool HasFooMessage { + get { return hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage { + get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public const int FooGroupFieldNumber = 4; + private bool hasFooGroup; + private global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup fooGroup_; + public bool HasFooGroup { + get { return hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup FooGroup { + get { return fooGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testOneofBackwardsCompatibleFieldNames; + if (hasFooInt) { + output.WriteInt32(1, field_names[0], FooInt); + } + if (hasFooString) { + output.WriteString(2, field_names[2], FooString); + } + if (hasFooMessage) { + output.WriteMessage(3, field_names[1], FooMessage); + } + if (hasFooGroup) { + output.WriteGroup(4, field_names[3], FooGroup); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasFooInt) { + size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); + } + if (hasFooString) { + size += pb::CodedOutputStream.ComputeStringSize(2, FooString); + } + if (hasFooMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(3, FooMessage); + } + if (hasFooGroup) { + size += pb::CodedOutputStream.ComputeGroupSize(4, FooGroup); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestOneofBackwardsCompatible ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestOneofBackwardsCompatible MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestOneofBackwardsCompatible prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestOneofBackwardsCompatible cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestOneofBackwardsCompatible result; + + private TestOneofBackwardsCompatible PrepareBuilder() { + if (resultIsReadOnly) { + TestOneofBackwardsCompatible original = result; + result = new TestOneofBackwardsCompatible(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestOneofBackwardsCompatible MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Descriptor; } + } + + public override TestOneofBackwardsCompatible DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.DefaultInstance; } + } + + public override TestOneofBackwardsCompatible BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestOneofBackwardsCompatible) { + return MergeFrom((TestOneofBackwardsCompatible) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestOneofBackwardsCompatible other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasFooInt) { + FooInt = other.FooInt; + } + if (other.HasFooString) { + FooString = other.FooString; + } + if (other.HasFooMessage) { + MergeFooMessage(other.FooMessage); + } + if (other.HasFooGroup) { + MergeFooGroup(other.FooGroup); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testOneofBackwardsCompatibleFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testOneofBackwardsCompatibleFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasFooInt = input.ReadInt32(ref result.fooInt_); + break; + } + case 18: { + result.hasFooString = input.ReadString(ref result.fooString_); + break; + } + case 26: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasFooMessage) { + subBuilder.MergeFrom(FooMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + FooMessage = subBuilder.BuildPartial(); + break; + } + case 35: { + global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.CreateBuilder(); + if (result.hasFooGroup) { + subBuilder.MergeFrom(FooGroup); + } + input.ReadGroup(4, subBuilder, extensionRegistry); + FooGroup = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasFooInt { + get { return result.hasFooInt; } + } + public int FooInt { + get { return result.FooInt; } + set { SetFooInt(value); } + } + public Builder SetFooInt(int value) { + PrepareBuilder(); + result.hasFooInt = true; + result.fooInt_ = value; + return this; + } + public Builder ClearFooInt() { + PrepareBuilder(); + result.hasFooInt = false; + result.fooInt_ = 0; + return this; + } + + public bool HasFooString { + get { return result.hasFooString; } + } + public string FooString { + get { return result.FooString; } + set { SetFooString(value); } + } + public Builder SetFooString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooString = true; + result.fooString_ = value; + return this; + } + public Builder ClearFooString() { + PrepareBuilder(); + result.hasFooString = false; + result.fooString_ = ""; + return this; + } + + public bool HasFooMessage { + get { return result.hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage { + get { return result.FooMessage; } + set { SetFooMessage(value); } + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = value; + return this; + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooMessage && + result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); + } else { + result.fooMessage_ = value; + } + result.hasFooMessage = true; + return this; + } + public Builder ClearFooMessage() { + PrepareBuilder(); + result.hasFooMessage = false; + result.fooMessage_ = null; + return this; + } + + public bool HasFooGroup { + get { return result.hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup FooGroup { + get { return result.FooGroup; } + set { SetFooGroup(value); } + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = value; + return this; + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooGroup && + result.fooGroup_ != global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance) { + result.fooGroup_ = global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.CreateBuilder(result.fooGroup_).MergeFrom(value).BuildPartial(); + } else { + result.fooGroup_ = value; + } + result.hasFooGroup = true; + return this; + } + public Builder ClearFooGroup() { + PrepareBuilder(); + result.hasFooGroup = false; + result.fooGroup_ = null; + return this; + } + } + static TestOneofBackwardsCompatible() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestOneof2 : pb::GeneratedMessage { + private TestOneof2() { } + private static readonly TestOneof2 defaultInstance = new TestOneof2().MakeReadOnly(); + private static readonly string[] _testOneof2FieldNames = new string[] { "bar_bytes", "bar_cord", "bar_enum", "bar_int", "bar_string", "bar_string_piece", "baz_int", "baz_string", "foo_bytes", "foo_cord", "foo_enum", "foo_int", "foo_lazy_message", "foo_message", "foo_string", "foo_string_piece", "foogroup" }; + private static readonly uint[] _testOneof2FieldTags = new uint[] { 130, 114, 136, 96, 106, 122, 144, 154, 42, 26, 48, 8, 90, 58, 18, 34, 67 }; + public static TestOneof2 DefaultInstance { + get { return defaultInstance; } + } + + public override TestOneof2 DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestOneof2 ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + public enum NestedEnum { + FOO = 1, + BAR = 2, + BAZ = 3, + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooGroup : pb::GeneratedMessage { + private FooGroup() { } + private static readonly FooGroup defaultInstance = new FooGroup().MakeReadOnly(); + private static readonly string[] _fooGroupFieldNames = new string[] { "a", "b" }; + private static readonly uint[] _fooGroupFieldTags = new uint[] { 72, 82 }; + public static FooGroup DefaultInstance { + get { return defaultInstance; } + } + + public override FooGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override FooGroup ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_FooGroup__FieldAccessorTable; } + } + + public const int AFieldNumber = 9; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public const int BFieldNumber = 10; + private bool hasB; + private string b_ = ""; + public bool HasB { + get { return hasB; } + } + public string B { + get { return b_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _fooGroupFieldNames; + if (hasA) { + output.WriteInt32(9, field_names[0], A); + } + if (hasB) { + output.WriteString(10, field_names[1], B); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(9, A); + } + if (hasB) { + size += pb::CodedOutputStream.ComputeStringSize(10, B); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private FooGroup result; + + private FooGroup PrepareBuilder() { + if (resultIsReadOnly) { + FooGroup original = result; + result = new FooGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override FooGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.Descriptor; } + } + + public override FooGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance; } + } + + public override FooGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is FooGroup) { + return MergeFrom((FooGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(FooGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + if (other.HasB) { + B = other.B; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_fooGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _fooGroupFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 72: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 82: { + result.hasB = input.ReadString(ref result.b_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + + public bool HasB { + get { return result.hasB; } + } + public string B { + get { return result.B; } + set { SetB(value); } + } + public Builder SetB(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasB = true; + result.b_ = value; + return this; + } + public Builder ClearB() { + PrepareBuilder(); + result.hasB = false; + result.b_ = ""; + return this; + } + } + static FooGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessage { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "corge_int", "qux_int" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 16, 8 }; + public static NestedMessage DefaultInstance { + get { return defaultInstance; } + } + + public override NestedMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override NestedMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_NestedMessage__FieldAccessorTable; } + } + + public const int QuxIntFieldNumber = 1; + private bool hasQuxInt; + private long quxInt_; + public bool HasQuxInt { + get { return hasQuxInt; } + } + public long QuxInt { + get { return quxInt_; } + } + + public const int CorgeIntFieldNumber = 2; + private pbc::PopsicleList corgeInt_ = new pbc::PopsicleList(); + public scg::IList CorgeIntList { + get { return pbc::Lists.AsReadOnly(corgeInt_); } + } + public int CorgeIntCount { + get { return corgeInt_.Count; } + } + public int GetCorgeInt(int index) { + return corgeInt_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (hasQuxInt) { + output.WriteInt64(1, field_names[1], QuxInt); + } + if (corgeInt_.Count > 0) { + output.WriteInt32Array(2, field_names[0], corgeInt_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasQuxInt) { + size += pb::CodedOutputStream.ComputeInt64Size(1, QuxInt); + } + { + int dataSize = 0; + foreach (int element in CorgeIntList) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 1 * corgeInt_.Count; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() { + corgeInt_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() { + if (resultIsReadOnly) { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override NestedMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Descriptor; } + } + + public override NestedMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance; } + } + + public override NestedMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is NestedMessage) { + return MergeFrom((NestedMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NestedMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasQuxInt) { + QuxInt = other.QuxInt; + } + if (other.corgeInt_.Count != 0) { + result.corgeInt_.Add(other.corgeInt_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasQuxInt = input.ReadInt64(ref result.quxInt_); + break; + } + case 18: + case 16: { + input.ReadInt32Array(tag, field_name, result.corgeInt_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasQuxInt { + get { return result.hasQuxInt; } + } + public long QuxInt { + get { return result.QuxInt; } + set { SetQuxInt(value); } + } + public Builder SetQuxInt(long value) { + PrepareBuilder(); + result.hasQuxInt = true; + result.quxInt_ = value; + return this; + } + public Builder ClearQuxInt() { + PrepareBuilder(); + result.hasQuxInt = false; + result.quxInt_ = 0L; + return this; + } + + public pbc::IPopsicleList CorgeIntList { + get { return PrepareBuilder().corgeInt_; } + } + public int CorgeIntCount { + get { return result.CorgeIntCount; } + } + public int GetCorgeInt(int index) { + return result.GetCorgeInt(index); + } + public Builder SetCorgeInt(int index, int value) { + PrepareBuilder(); + result.corgeInt_[index] = value; + return this; + } + public Builder AddCorgeInt(int value) { + PrepareBuilder(); + result.corgeInt_.Add(value); + return this; + } + public Builder AddRangeCorgeInt(scg::IEnumerable values) { + PrepareBuilder(); + result.corgeInt_.Add(values); + return this; + } + public Builder ClearCorgeInt() { + PrepareBuilder(); + result.corgeInt_.Clear(); + return this; + } + } + static NestedMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int FooIntFieldNumber = 1; + private bool hasFooInt; + private int fooInt_; + public bool HasFooInt { + get { return hasFooInt; } + } + public int FooInt { + get { return fooInt_; } + } + + public const int FooStringFieldNumber = 2; + private bool hasFooString; + private string fooString_ = ""; + public bool HasFooString { + get { return hasFooString; } + } + public string FooString { + get { return fooString_; } + } + + public const int FooCordFieldNumber = 3; + private bool hasFooCord; + private string fooCord_ = ""; + public bool HasFooCord { + get { return hasFooCord; } + } + public string FooCord { + get { return fooCord_; } + } + + public const int FooStringPieceFieldNumber = 4; + private bool hasFooStringPiece; + private string fooStringPiece_ = ""; + public bool HasFooStringPiece { + get { return hasFooStringPiece; } + } + public string FooStringPiece { + get { return fooStringPiece_; } + } + + public const int FooBytesFieldNumber = 5; + private bool hasFooBytes; + private pb::ByteString fooBytes_ = pb::ByteString.Empty; + public bool HasFooBytes { + get { return hasFooBytes; } + } + public pb::ByteString FooBytes { + get { return fooBytes_; } + } + + public const int FooEnumFieldNumber = 6; + private bool hasFooEnum; + private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum fooEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.FOO; + public bool HasFooEnum { + get { return hasFooEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum FooEnum { + get { return fooEnum_; } + } + + public const int FooMessageFieldNumber = 7; + private bool hasFooMessage; + private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage fooMessage_; + public bool HasFooMessage { + get { return hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooMessage { + get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance; } + } + + public const int FooGroupFieldNumber = 8; + private bool hasFooGroup; + private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup fooGroup_; + public bool HasFooGroup { + get { return hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup FooGroup { + get { return fooGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance; } + } + + public const int FooLazyMessageFieldNumber = 11; + private bool hasFooLazyMessage; + private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage fooLazyMessage_; + public bool HasFooLazyMessage { + get { return hasFooLazyMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooLazyMessage { + get { return fooLazyMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance; } + } + + public const int BarIntFieldNumber = 12; + private bool hasBarInt; + private int barInt_ = 5; + public bool HasBarInt { + get { return hasBarInt; } + } + public int BarInt { + get { return barInt_; } + } + + public const int BarStringFieldNumber = 13; + private bool hasBarString; + private string barString_ = "STRING"; + public bool HasBarString { + get { return hasBarString; } + } + public string BarString { + get { return barString_; } + } + + public const int BarCordFieldNumber = 14; + private bool hasBarCord; + private string barCord_ = "CORD"; + public bool HasBarCord { + get { return hasBarCord; } + } + public string BarCord { + get { return barCord_; } + } + + public const int BarStringPieceFieldNumber = 15; + private bool hasBarStringPiece; + private string barStringPiece_ = "SPIECE"; + public bool HasBarStringPiece { + get { return hasBarStringPiece; } + } + public string BarStringPiece { + get { return barStringPiece_; } + } + + public const int BarBytesFieldNumber = 16; + private bool hasBarBytes; + private pb::ByteString barBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestOneof2.Descriptor.Fields[13].DefaultValue; + public bool HasBarBytes { + get { return hasBarBytes; } + } + public pb::ByteString BarBytes { + get { return barBytes_; } + } + + public const int BarEnumFieldNumber = 17; + private bool hasBarEnum; + private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum barEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.BAR; + public bool HasBarEnum { + get { return hasBarEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum BarEnum { + get { return barEnum_; } + } + + public const int BazIntFieldNumber = 18; + private bool hasBazInt; + private int bazInt_; + public bool HasBazInt { + get { return hasBazInt; } + } + public int BazInt { + get { return bazInt_; } + } + + public const int BazStringFieldNumber = 19; + private bool hasBazString; + private string bazString_ = "BAZ"; + public bool HasBazString { + get { return hasBazString; } + } + public string BazString { + get { return bazString_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testOneof2FieldNames; + if (hasFooInt) { + output.WriteInt32(1, field_names[11], FooInt); + } + if (hasFooString) { + output.WriteString(2, field_names[14], FooString); + } + if (hasFooCord) { + output.WriteString(3, field_names[9], FooCord); + } + if (hasFooStringPiece) { + output.WriteString(4, field_names[15], FooStringPiece); + } + if (hasFooBytes) { + output.WriteBytes(5, field_names[8], FooBytes); + } + if (hasFooEnum) { + output.WriteEnum(6, field_names[10], (int) FooEnum, FooEnum); + } + if (hasFooMessage) { + output.WriteMessage(7, field_names[13], FooMessage); + } + if (hasFooGroup) { + output.WriteGroup(8, field_names[16], FooGroup); + } + if (hasFooLazyMessage) { + output.WriteMessage(11, field_names[12], FooLazyMessage); + } + if (hasBarInt) { + output.WriteInt32(12, field_names[3], BarInt); + } + if (hasBarString) { + output.WriteString(13, field_names[4], BarString); + } + if (hasBarCord) { + output.WriteString(14, field_names[1], BarCord); + } + if (hasBarStringPiece) { + output.WriteString(15, field_names[5], BarStringPiece); + } + if (hasBarBytes) { + output.WriteBytes(16, field_names[0], BarBytes); + } + if (hasBarEnum) { + output.WriteEnum(17, field_names[2], (int) BarEnum, BarEnum); + } + if (hasBazInt) { + output.WriteInt32(18, field_names[6], BazInt); + } + if (hasBazString) { + output.WriteString(19, field_names[7], BazString); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasFooInt) { + size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); + } + if (hasFooString) { + size += pb::CodedOutputStream.ComputeStringSize(2, FooString); + } + if (hasFooCord) { + size += pb::CodedOutputStream.ComputeStringSize(3, FooCord); + } + if (hasFooStringPiece) { + size += pb::CodedOutputStream.ComputeStringSize(4, FooStringPiece); + } + if (hasFooBytes) { + size += pb::CodedOutputStream.ComputeBytesSize(5, FooBytes); + } + if (hasFooEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(6, (int) FooEnum); + } + if (hasFooMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(7, FooMessage); + } + if (hasFooGroup) { + size += pb::CodedOutputStream.ComputeGroupSize(8, FooGroup); + } + if (hasFooLazyMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(11, FooLazyMessage); + } + if (hasBarInt) { + size += pb::CodedOutputStream.ComputeInt32Size(12, BarInt); + } + if (hasBarString) { + size += pb::CodedOutputStream.ComputeStringSize(13, BarString); + } + if (hasBarCord) { + size += pb::CodedOutputStream.ComputeStringSize(14, BarCord); + } + if (hasBarStringPiece) { + size += pb::CodedOutputStream.ComputeStringSize(15, BarStringPiece); + } + if (hasBarBytes) { + size += pb::CodedOutputStream.ComputeBytesSize(16, BarBytes); + } + if (hasBarEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(17, (int) BarEnum); + } + if (hasBazInt) { + size += pb::CodedOutputStream.ComputeInt32Size(18, BazInt); + } + if (hasBazString) { + size += pb::CodedOutputStream.ComputeStringSize(19, BazString); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestOneof2 ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneof2 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneof2 ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneof2 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneof2 ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneof2 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestOneof2 ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestOneof2 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestOneof2 ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneof2 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestOneof2 MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestOneof2 prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestOneof2 cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestOneof2 result; + + private TestOneof2 PrepareBuilder() { + if (resultIsReadOnly) { + TestOneof2 original = result; + result = new TestOneof2(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestOneof2 MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Descriptor; } + } + + public override TestOneof2 DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.DefaultInstance; } + } + + public override TestOneof2 BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestOneof2) { + return MergeFrom((TestOneof2) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestOneof2 other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof2.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasFooInt) { + FooInt = other.FooInt; + } + if (other.HasFooString) { + FooString = other.FooString; + } + if (other.HasFooCord) { + FooCord = other.FooCord; + } + if (other.HasFooStringPiece) { + FooStringPiece = other.FooStringPiece; + } + if (other.HasFooBytes) { + FooBytes = other.FooBytes; + } + if (other.HasFooEnum) { + FooEnum = other.FooEnum; + } + if (other.HasFooMessage) { + MergeFooMessage(other.FooMessage); + } + if (other.HasFooGroup) { + MergeFooGroup(other.FooGroup); + } + if (other.HasFooLazyMessage) { + MergeFooLazyMessage(other.FooLazyMessage); + } + if (other.HasBarInt) { + BarInt = other.BarInt; + } + if (other.HasBarString) { + BarString = other.BarString; + } + if (other.HasBarCord) { + BarCord = other.BarCord; + } + if (other.HasBarStringPiece) { + BarStringPiece = other.BarStringPiece; + } + if (other.HasBarBytes) { + BarBytes = other.BarBytes; + } + if (other.HasBarEnum) { + BarEnum = other.BarEnum; + } + if (other.HasBazInt) { + BazInt = other.BazInt; + } + if (other.HasBazString) { + BazString = other.BazString; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testOneof2FieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testOneof2FieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasFooInt = input.ReadInt32(ref result.fooInt_); + break; + } + case 18: { + result.hasFooString = input.ReadString(ref result.fooString_); + break; + } + case 26: { + result.hasFooCord = input.ReadString(ref result.fooCord_); + break; + } + case 34: { + result.hasFooStringPiece = input.ReadString(ref result.fooStringPiece_); + break; + } + case 42: { + result.hasFooBytes = input.ReadBytes(ref result.fooBytes_); + break; + } + case 48: { + object unknown; + if(input.ReadEnum(ref result.fooEnum_, out unknown)) { + result.hasFooEnum = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(6, (ulong)(int)unknown); + } + break; + } + case 58: { + global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(); + if (result.hasFooMessage) { + subBuilder.MergeFrom(FooMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + FooMessage = subBuilder.BuildPartial(); + break; + } + case 67: { + global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.CreateBuilder(); + if (result.hasFooGroup) { + subBuilder.MergeFrom(FooGroup); + } + input.ReadGroup(8, subBuilder, extensionRegistry); + FooGroup = subBuilder.BuildPartial(); + break; + } + case 90: { + global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(); + if (result.hasFooLazyMessage) { + subBuilder.MergeFrom(FooLazyMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + FooLazyMessage = subBuilder.BuildPartial(); + break; + } + case 96: { + result.hasBarInt = input.ReadInt32(ref result.barInt_); + break; + } + case 106: { + result.hasBarString = input.ReadString(ref result.barString_); + break; + } + case 114: { + result.hasBarCord = input.ReadString(ref result.barCord_); + break; + } + case 122: { + result.hasBarStringPiece = input.ReadString(ref result.barStringPiece_); + break; + } + case 130: { + result.hasBarBytes = input.ReadBytes(ref result.barBytes_); + break; + } + case 136: { + object unknown; + if(input.ReadEnum(ref result.barEnum_, out unknown)) { + result.hasBarEnum = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(17, (ulong)(int)unknown); + } + break; + } + case 144: { + result.hasBazInt = input.ReadInt32(ref result.bazInt_); + break; + } + case 154: { + result.hasBazString = input.ReadString(ref result.bazString_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasFooInt { + get { return result.hasFooInt; } + } + public int FooInt { + get { return result.FooInt; } + set { SetFooInt(value); } + } + public Builder SetFooInt(int value) { + PrepareBuilder(); + result.hasFooInt = true; + result.fooInt_ = value; + return this; + } + public Builder ClearFooInt() { + PrepareBuilder(); + result.hasFooInt = false; + result.fooInt_ = 0; + return this; + } + + public bool HasFooString { + get { return result.hasFooString; } + } + public string FooString { + get { return result.FooString; } + set { SetFooString(value); } + } + public Builder SetFooString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooString = true; + result.fooString_ = value; + return this; + } + public Builder ClearFooString() { + PrepareBuilder(); + result.hasFooString = false; + result.fooString_ = ""; + return this; + } + + public bool HasFooCord { + get { return result.hasFooCord; } + } + public string FooCord { + get { return result.FooCord; } + set { SetFooCord(value); } + } + public Builder SetFooCord(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooCord = true; + result.fooCord_ = value; + return this; + } + public Builder ClearFooCord() { + PrepareBuilder(); + result.hasFooCord = false; + result.fooCord_ = ""; + return this; + } + + public bool HasFooStringPiece { + get { return result.hasFooStringPiece; } + } + public string FooStringPiece { + get { return result.FooStringPiece; } + set { SetFooStringPiece(value); } + } + public Builder SetFooStringPiece(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooStringPiece = true; + result.fooStringPiece_ = value; + return this; + } + public Builder ClearFooStringPiece() { + PrepareBuilder(); + result.hasFooStringPiece = false; + result.fooStringPiece_ = ""; + return this; + } + + public bool HasFooBytes { + get { return result.hasFooBytes; } + } + public pb::ByteString FooBytes { + get { return result.FooBytes; } + set { SetFooBytes(value); } + } + public Builder SetFooBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooBytes = true; + result.fooBytes_ = value; + return this; + } + public Builder ClearFooBytes() { + PrepareBuilder(); + result.hasFooBytes = false; + result.fooBytes_ = pb::ByteString.Empty; + return this; + } + + public bool HasFooEnum { + get { return result.hasFooEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum FooEnum { + get { return result.FooEnum; } + set { SetFooEnum(value); } + } + public Builder SetFooEnum(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum value) { + PrepareBuilder(); + result.hasFooEnum = true; + result.fooEnum_ = value; + return this; + } + public Builder ClearFooEnum() { + PrepareBuilder(); + result.hasFooEnum = false; + result.fooEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.FOO; + return this; + } + + public bool HasFooMessage { + get { return result.hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooMessage { + get { return result.FooMessage; } + set { SetFooMessage(value); } + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = value; + return this; + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooMessage && + result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance) { + result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); + } else { + result.fooMessage_ = value; + } + result.hasFooMessage = true; + return this; + } + public Builder ClearFooMessage() { + PrepareBuilder(); + result.hasFooMessage = false; + result.fooMessage_ = null; + return this; + } + + public bool HasFooGroup { + get { return result.hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup FooGroup { + get { return result.FooGroup; } + set { SetFooGroup(value); } + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = value; + return this; + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooGroup && + result.fooGroup_ != global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance) { + result.fooGroup_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.CreateBuilder(result.fooGroup_).MergeFrom(value).BuildPartial(); + } else { + result.fooGroup_ = value; + } + result.hasFooGroup = true; + return this; + } + public Builder ClearFooGroup() { + PrepareBuilder(); + result.hasFooGroup = false; + result.fooGroup_ = null; + return this; + } + + public bool HasFooLazyMessage { + get { return result.hasFooLazyMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooLazyMessage { + get { return result.FooLazyMessage; } + set { SetFooLazyMessage(value); } + } + public Builder SetFooLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooLazyMessage = true; + result.fooLazyMessage_ = value; + return this; + } + public Builder SetFooLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooLazyMessage = true; + result.fooLazyMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeFooLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooLazyMessage && + result.fooLazyMessage_ != global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance) { + result.fooLazyMessage_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(result.fooLazyMessage_).MergeFrom(value).BuildPartial(); + } else { + result.fooLazyMessage_ = value; + } + result.hasFooLazyMessage = true; + return this; + } + public Builder ClearFooLazyMessage() { + PrepareBuilder(); + result.hasFooLazyMessage = false; + result.fooLazyMessage_ = null; + return this; + } + + public bool HasBarInt { + get { return result.hasBarInt; } + } + public int BarInt { + get { return result.BarInt; } + set { SetBarInt(value); } + } + public Builder SetBarInt(int value) { + PrepareBuilder(); + result.hasBarInt = true; + result.barInt_ = value; + return this; + } + public Builder ClearBarInt() { + PrepareBuilder(); + result.hasBarInt = false; + result.barInt_ = 5; + return this; + } + + public bool HasBarString { + get { return result.hasBarString; } + } + public string BarString { + get { return result.BarString; } + set { SetBarString(value); } + } + public Builder SetBarString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBarString = true; + result.barString_ = value; + return this; + } + public Builder ClearBarString() { + PrepareBuilder(); + result.hasBarString = false; + result.barString_ = "STRING"; + return this; + } + + public bool HasBarCord { + get { return result.hasBarCord; } + } + public string BarCord { + get { return result.BarCord; } + set { SetBarCord(value); } + } + public Builder SetBarCord(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBarCord = true; + result.barCord_ = value; + return this; + } + public Builder ClearBarCord() { + PrepareBuilder(); + result.hasBarCord = false; + result.barCord_ = "CORD"; + return this; + } + + public bool HasBarStringPiece { + get { return result.hasBarStringPiece; } + } + public string BarStringPiece { + get { return result.BarStringPiece; } + set { SetBarStringPiece(value); } + } + public Builder SetBarStringPiece(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBarStringPiece = true; + result.barStringPiece_ = value; + return this; + } + public Builder ClearBarStringPiece() { + PrepareBuilder(); + result.hasBarStringPiece = false; + result.barStringPiece_ = "SPIECE"; + return this; + } + + public bool HasBarBytes { + get { return result.hasBarBytes; } + } + public pb::ByteString BarBytes { + get { return result.BarBytes; } + set { SetBarBytes(value); } + } + public Builder SetBarBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBarBytes = true; + result.barBytes_ = value; + return this; + } + public Builder ClearBarBytes() { + PrepareBuilder(); + result.hasBarBytes = false; + result.barBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestOneof2.Descriptor.Fields[13].DefaultValue; + return this; + } + + public bool HasBarEnum { + get { return result.hasBarEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum BarEnum { + get { return result.BarEnum; } + set { SetBarEnum(value); } + } + public Builder SetBarEnum(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum value) { + PrepareBuilder(); + result.hasBarEnum = true; + result.barEnum_ = value; + return this; + } + public Builder ClearBarEnum() { + PrepareBuilder(); + result.hasBarEnum = false; + result.barEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.BAR; + return this; + } + + public bool HasBazInt { + get { return result.hasBazInt; } + } + public int BazInt { + get { return result.BazInt; } + set { SetBazInt(value); } + } + public Builder SetBazInt(int value) { + PrepareBuilder(); + result.hasBazInt = true; + result.bazInt_ = value; + return this; + } + public Builder ClearBazInt() { + PrepareBuilder(); + result.hasBazInt = false; + result.bazInt_ = 0; + return this; + } + + public bool HasBazString { + get { return result.hasBazString; } + } + public string BazString { + get { return result.BazString; } + set { SetBazString(value); } + } + public Builder SetBazString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBazString = true; + result.bazString_ = value; + return this; + } + public Builder ClearBazString() { + PrepareBuilder(); + result.hasBazString = false; + result.bazString_ = "BAZ"; + return this; + } + } + static TestOneof2() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestRequiredOneof : pb::GeneratedMessage { + private TestRequiredOneof() { } + private static readonly TestRequiredOneof defaultInstance = new TestRequiredOneof().MakeReadOnly(); + private static readonly string[] _testRequiredOneofFieldNames = new string[] { "foo_int", "foo_message", "foo_string" }; + private static readonly uint[] _testRequiredOneofFieldTags = new uint[] { 8, 26, 18 }; + public static TestRequiredOneof DefaultInstance { + get { return defaultInstance; } + } + + public override TestRequiredOneof DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestRequiredOneof ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessage { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "required_double" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 9 }; + public static NestedMessage DefaultInstance { + get { return defaultInstance; } + } + + public override NestedMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override NestedMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__FieldAccessorTable; } + } + + public const int RequiredDoubleFieldNumber = 1; + private bool hasRequiredDouble; + private double requiredDouble_; + public bool HasRequiredDouble { + get { return hasRequiredDouble; } + } + public double RequiredDouble { + get { return requiredDouble_; } + } + + public override bool IsInitialized { + get { + if (!hasRequiredDouble) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (hasRequiredDouble) { + output.WriteDouble(1, field_names[0], RequiredDouble); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasRequiredDouble) { + size += pb::CodedOutputStream.ComputeDoubleSize(1, RequiredDouble); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() { + if (resultIsReadOnly) { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override NestedMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.Descriptor; } + } + + public override NestedMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance; } + } + + public override NestedMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is NestedMessage) { + return MergeFrom((NestedMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NestedMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasRequiredDouble) { + RequiredDouble = other.RequiredDouble; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 9: { + result.hasRequiredDouble = input.ReadDouble(ref result.requiredDouble_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasRequiredDouble { + get { return result.hasRequiredDouble; } + } + public double RequiredDouble { + get { return result.RequiredDouble; } + set { SetRequiredDouble(value); } + } + public Builder SetRequiredDouble(double value) { + PrepareBuilder(); + result.hasRequiredDouble = true; + result.requiredDouble_ = value; + return this; + } + public Builder ClearRequiredDouble() { + PrepareBuilder(); + result.hasRequiredDouble = false; + result.requiredDouble_ = 0D; + return this; + } + } + static NestedMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int FooIntFieldNumber = 1; + private bool hasFooInt; + private int fooInt_; + public bool HasFooInt { + get { return hasFooInt; } + } + public int FooInt { + get { return fooInt_; } + } + + public const int FooStringFieldNumber = 2; + private bool hasFooString; + private string fooString_ = ""; + public bool HasFooString { + get { return hasFooString; } + } + public string FooString { + get { return fooString_; } + } + + public const int FooMessageFieldNumber = 3; + private bool hasFooMessage; + private global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage fooMessage_; + public bool HasFooMessage { + get { return hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage FooMessage { + get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance; } + } + + public override bool IsInitialized { + get { + if (HasFooMessage) { + if (!FooMessage.IsInitialized) return false; + } + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testRequiredOneofFieldNames; + if (hasFooInt) { + output.WriteInt32(1, field_names[0], FooInt); + } + if (hasFooString) { + output.WriteString(2, field_names[2], FooString); + } + if (hasFooMessage) { + output.WriteMessage(3, field_names[1], FooMessage); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasFooInt) { + size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); + } + if (hasFooString) { + size += pb::CodedOutputStream.ComputeStringSize(2, FooString); + } + if (hasFooMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(3, FooMessage); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestRequiredOneof ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequiredOneof ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequiredOneof ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequiredOneof ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequiredOneof ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequiredOneof ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestRequiredOneof ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestRequiredOneof ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestRequiredOneof ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequiredOneof ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestRequiredOneof MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestRequiredOneof prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRequiredOneof cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestRequiredOneof result; + + private TestRequiredOneof PrepareBuilder() { + if (resultIsReadOnly) { + TestRequiredOneof original = result; + result = new TestRequiredOneof(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestRequiredOneof MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Descriptor; } + } + + public override TestRequiredOneof DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.DefaultInstance; } + } + + public override TestRequiredOneof BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestRequiredOneof) { + return MergeFrom((TestRequiredOneof) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestRequiredOneof other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasFooInt) { + FooInt = other.FooInt; + } + if (other.HasFooString) { + FooString = other.FooString; + } + if (other.HasFooMessage) { + MergeFooMessage(other.FooMessage); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testRequiredOneofFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testRequiredOneofFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasFooInt = input.ReadInt32(ref result.fooInt_); + break; + } + case 18: { + result.hasFooString = input.ReadString(ref result.fooString_); + break; + } + case 26: { + global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.CreateBuilder(); + if (result.hasFooMessage) { + subBuilder.MergeFrom(FooMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + FooMessage = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasFooInt { + get { return result.hasFooInt; } + } + public int FooInt { + get { return result.FooInt; } + set { SetFooInt(value); } + } + public Builder SetFooInt(int value) { + PrepareBuilder(); + result.hasFooInt = true; + result.fooInt_ = value; + return this; + } + public Builder ClearFooInt() { + PrepareBuilder(); + result.hasFooInt = false; + result.fooInt_ = 0; + return this; + } + + public bool HasFooString { + get { return result.hasFooString; } + } + public string FooString { + get { return result.FooString; } + set { SetFooString(value); } + } + public Builder SetFooString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooString = true; + result.fooString_ = value; + return this; + } + public Builder ClearFooString() { + PrepareBuilder(); + result.hasFooString = false; + result.fooString_ = ""; + return this; + } + + public bool HasFooMessage { + get { return result.hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage FooMessage { + get { return result.FooMessage; } + set { SetFooMessage(value); } + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = value; + return this; + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooMessage && + result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance) { + result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); + } else { + result.fooMessage_ = value; + } + result.hasFooMessage = true; + return this; + } + public Builder ClearFooMessage() { + PrepareBuilder(); + result.hasFooMessage = false; + result.fooMessage_ = null; + return this; + } + } + static TestRequiredOneof() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestPackedTypes : pb::GeneratedMessage { + private TestPackedTypes() { } + private static readonly TestPackedTypes defaultInstance = new TestPackedTypes().MakeReadOnly(); + private static readonly string[] _testPackedTypesFieldNames = new string[] { "packed_bool", "packed_double", "packed_enum", "packed_fixed32", "packed_fixed64", "packed_float", "packed_int32", "packed_int64", "packed_sfixed32", "packed_sfixed64", "packed_sint32", "packed_sint64", "packed_uint32", "packed_uint64" }; + private static readonly uint[] _testPackedTypesFieldTags = new uint[] { 818, 810, 826, 770, 778, 802, 722, 730, 786, 794, 754, 762, 738, 746 }; + public static TestPackedTypes DefaultInstance { + get { return defaultInstance; } + } + + public override TestPackedTypes DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestPackedTypes ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedTypes__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable; } + } + + public const int PackedInt32FieldNumber = 90; + private int packedInt32MemoizedSerializedSize; + private pbc::PopsicleList packedInt32_ = new pbc::PopsicleList(); + public scg::IList PackedInt32List { + get { return pbc::Lists.AsReadOnly(packedInt32_); } + } + public int PackedInt32Count { + get { return packedInt32_.Count; } + } + public int GetPackedInt32(int index) { + return packedInt32_[index]; + } + + public const int PackedInt64FieldNumber = 91; + private int packedInt64MemoizedSerializedSize; + private pbc::PopsicleList packedInt64_ = new pbc::PopsicleList(); + public scg::IList PackedInt64List { + get { return pbc::Lists.AsReadOnly(packedInt64_); } + } + public int PackedInt64Count { + get { return packedInt64_.Count; } + } + public long GetPackedInt64(int index) { + return packedInt64_[index]; + } + + public const int PackedUint32FieldNumber = 92; + private int packedUint32MemoizedSerializedSize; + private pbc::PopsicleList packedUint32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedUint32List { + get { return pbc::Lists.AsReadOnly(packedUint32_); } + } + public int PackedUint32Count { + get { return packedUint32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedUint32(int index) { + return packedUint32_[index]; + } + + public const int PackedUint64FieldNumber = 93; + private int packedUint64MemoizedSerializedSize; + private pbc::PopsicleList packedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedUint64List { + get { return pbc::Lists.AsReadOnly(packedUint64_); } + } + public int PackedUint64Count { + get { return packedUint64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedUint64(int index) { + return packedUint64_[index]; + } + + public const int PackedSint32FieldNumber = 94; + private int packedSint32MemoizedSerializedSize; + private pbc::PopsicleList packedSint32_ = new pbc::PopsicleList(); + public scg::IList PackedSint32List { + get { return pbc::Lists.AsReadOnly(packedSint32_); } + } + public int PackedSint32Count { + get { return packedSint32_.Count; } + } + public int GetPackedSint32(int index) { + return packedSint32_[index]; + } + + public const int PackedSint64FieldNumber = 95; + private int packedSint64MemoizedSerializedSize; + private pbc::PopsicleList packedSint64_ = new pbc::PopsicleList(); + public scg::IList PackedSint64List { + get { return pbc::Lists.AsReadOnly(packedSint64_); } + } + public int PackedSint64Count { + get { return packedSint64_.Count; } + } + public long GetPackedSint64(int index) { + return packedSint64_[index]; + } + + public const int PackedFixed32FieldNumber = 96; + private int packedFixed32MemoizedSerializedSize; + private pbc::PopsicleList packedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedFixed32List { + get { return pbc::Lists.AsReadOnly(packedFixed32_); } + } + public int PackedFixed32Count { + get { return packedFixed32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedFixed32(int index) { + return packedFixed32_[index]; + } + + public const int PackedFixed64FieldNumber = 97; + private int packedFixed64MemoizedSerializedSize; + private pbc::PopsicleList packedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedFixed64List { + get { return pbc::Lists.AsReadOnly(packedFixed64_); } + } + public int PackedFixed64Count { + get { return packedFixed64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedFixed64(int index) { + return packedFixed64_[index]; + } + + public const int PackedSfixed32FieldNumber = 98; + private int packedSfixed32MemoizedSerializedSize; + private pbc::PopsicleList packedSfixed32_ = new pbc::PopsicleList(); + public scg::IList PackedSfixed32List { + get { return pbc::Lists.AsReadOnly(packedSfixed32_); } + } + public int PackedSfixed32Count { + get { return packedSfixed32_.Count; } + } + public int GetPackedSfixed32(int index) { + return packedSfixed32_[index]; + } + + public const int PackedSfixed64FieldNumber = 99; + private int packedSfixed64MemoizedSerializedSize; + private pbc::PopsicleList packedSfixed64_ = new pbc::PopsicleList(); + public scg::IList PackedSfixed64List { + get { return pbc::Lists.AsReadOnly(packedSfixed64_); } + } + public int PackedSfixed64Count { + get { return packedSfixed64_.Count; } + } + public long GetPackedSfixed64(int index) { + return packedSfixed64_[index]; + } + + public const int PackedFloatFieldNumber = 100; + private int packedFloatMemoizedSerializedSize; + private pbc::PopsicleList packedFloat_ = new pbc::PopsicleList(); + public scg::IList PackedFloatList { + get { return pbc::Lists.AsReadOnly(packedFloat_); } + } + public int PackedFloatCount { + get { return packedFloat_.Count; } + } + public float GetPackedFloat(int index) { + return packedFloat_[index]; + } + + public const int PackedDoubleFieldNumber = 101; + private int packedDoubleMemoizedSerializedSize; + private pbc::PopsicleList packedDouble_ = new pbc::PopsicleList(); + public scg::IList PackedDoubleList { + get { return pbc::Lists.AsReadOnly(packedDouble_); } + } + public int PackedDoubleCount { + get { return packedDouble_.Count; } + } + public double GetPackedDouble(int index) { + return packedDouble_[index]; + } + + public const int PackedBoolFieldNumber = 102; + private int packedBoolMemoizedSerializedSize; + private pbc::PopsicleList packedBool_ = new pbc::PopsicleList(); + public scg::IList PackedBoolList { + get { return pbc::Lists.AsReadOnly(packedBool_); } + } + public int PackedBoolCount { + get { return packedBool_.Count; } + } + public bool GetPackedBool(int index) { + return packedBool_[index]; + } + + public const int PackedEnumFieldNumber = 103; + private int packedEnumMemoizedSerializedSize; + private pbc::PopsicleList packedEnum_ = new pbc::PopsicleList(); + public scg::IList PackedEnumList { + get { return pbc::Lists.AsReadOnly(packedEnum_); } + } + public int PackedEnumCount { + get { return packedEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetPackedEnum(int index) { + return packedEnum_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testPackedTypesFieldNames; + if (packedInt32_.Count > 0) { + output.WritePackedInt32Array(90, field_names[6], packedInt32MemoizedSerializedSize, packedInt32_); + } + if (packedInt64_.Count > 0) { + output.WritePackedInt64Array(91, field_names[7], packedInt64MemoizedSerializedSize, packedInt64_); + } + if (packedUint32_.Count > 0) { + output.WritePackedUInt32Array(92, field_names[12], packedUint32MemoizedSerializedSize, packedUint32_); + } + if (packedUint64_.Count > 0) { + output.WritePackedUInt64Array(93, field_names[13], packedUint64MemoizedSerializedSize, packedUint64_); + } + if (packedSint32_.Count > 0) { + output.WritePackedSInt32Array(94, field_names[10], packedSint32MemoizedSerializedSize, packedSint32_); + } + if (packedSint64_.Count > 0) { + output.WritePackedSInt64Array(95, field_names[11], packedSint64MemoizedSerializedSize, packedSint64_); + } + if (packedFixed32_.Count > 0) { + output.WritePackedFixed32Array(96, field_names[3], packedFixed32MemoizedSerializedSize, packedFixed32_); + } + if (packedFixed64_.Count > 0) { + output.WritePackedFixed64Array(97, field_names[4], packedFixed64MemoizedSerializedSize, packedFixed64_); + } + if (packedSfixed32_.Count > 0) { + output.WritePackedSFixed32Array(98, field_names[8], packedSfixed32MemoizedSerializedSize, packedSfixed32_); + } + if (packedSfixed64_.Count > 0) { + output.WritePackedSFixed64Array(99, field_names[9], packedSfixed64MemoizedSerializedSize, packedSfixed64_); + } + if (packedFloat_.Count > 0) { + output.WritePackedFloatArray(100, field_names[5], packedFloatMemoizedSerializedSize, packedFloat_); + } + if (packedDouble_.Count > 0) { + output.WritePackedDoubleArray(101, field_names[1], packedDoubleMemoizedSerializedSize, packedDouble_); + } + if (packedBool_.Count > 0) { + output.WritePackedBoolArray(102, field_names[0], packedBoolMemoizedSerializedSize, packedBool_); + } + if (packedEnum_.Count > 0) { + output.WritePackedEnumArray(103, field_names[2], packedEnumMemoizedSerializedSize, packedEnum_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + foreach (int element in PackedInt32List) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + if (packedInt32_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedInt32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + foreach (long element in PackedInt64List) { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + if (packedInt64_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedInt64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + foreach (uint element in PackedUint32List) { + dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); + } + size += dataSize; + if (packedUint32_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedUint32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + foreach (ulong element in PackedUint64List) { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); + } + size += dataSize; + if (packedUint64_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedUint64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + foreach (int element in PackedSint32List) { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + if (packedSint32_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSint32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + foreach (long element in PackedSint64List) { + dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); + } + size += dataSize; + if (packedSint64_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSint64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 4 * packedFixed32_.Count; + size += dataSize; + if (packedFixed32_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedFixed32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 8 * packedFixed64_.Count; + size += dataSize; + if (packedFixed64_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedFixed64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 4 * packedSfixed32_.Count; + size += dataSize; + if (packedSfixed32_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSfixed32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 8 * packedSfixed64_.Count; + size += dataSize; + if (packedSfixed64_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSfixed64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 4 * packedFloat_.Count; + size += dataSize; + if (packedFloat_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedFloatMemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 8 * packedDouble_.Count; + size += dataSize; + if (packedDouble_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedDoubleMemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 1 * packedBool_.Count; + size += dataSize; + if (packedBool_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedBoolMemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + if (packedEnum_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in packedEnum_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 2; + size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); + } + packedEnumMemoizedSerializedSize = dataSize; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestPackedTypes ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestPackedTypes ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestPackedTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestPackedTypes ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestPackedTypes MakeReadOnly() { + packedInt32_.MakeReadOnly(); + packedInt64_.MakeReadOnly(); + packedUint32_.MakeReadOnly(); + packedUint64_.MakeReadOnly(); + packedSint32_.MakeReadOnly(); + packedSint64_.MakeReadOnly(); + packedFixed32_.MakeReadOnly(); + packedFixed64_.MakeReadOnly(); + packedSfixed32_.MakeReadOnly(); + packedSfixed64_.MakeReadOnly(); + packedFloat_.MakeReadOnly(); + packedDouble_.MakeReadOnly(); + packedBool_.MakeReadOnly(); + packedEnum_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestPackedTypes prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestPackedTypes cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestPackedTypes result; + + private TestPackedTypes PrepareBuilder() { + if (resultIsReadOnly) { + TestPackedTypes original = result; + result = new TestPackedTypes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestPackedTypes MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.Descriptor; } + } + + public override TestPackedTypes DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.DefaultInstance; } + } + + public override TestPackedTypes BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestPackedTypes) { + return MergeFrom((TestPackedTypes) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestPackedTypes other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.DefaultInstance) return this; + PrepareBuilder(); + if (other.packedInt32_.Count != 0) { + result.packedInt32_.Add(other.packedInt32_); + } + if (other.packedInt64_.Count != 0) { + result.packedInt64_.Add(other.packedInt64_); + } + if (other.packedUint32_.Count != 0) { + result.packedUint32_.Add(other.packedUint32_); + } + if (other.packedUint64_.Count != 0) { + result.packedUint64_.Add(other.packedUint64_); + } + if (other.packedSint32_.Count != 0) { + result.packedSint32_.Add(other.packedSint32_); + } + if (other.packedSint64_.Count != 0) { + result.packedSint64_.Add(other.packedSint64_); + } + if (other.packedFixed32_.Count != 0) { + result.packedFixed32_.Add(other.packedFixed32_); + } + if (other.packedFixed64_.Count != 0) { + result.packedFixed64_.Add(other.packedFixed64_); + } + if (other.packedSfixed32_.Count != 0) { + result.packedSfixed32_.Add(other.packedSfixed32_); + } + if (other.packedSfixed64_.Count != 0) { + result.packedSfixed64_.Add(other.packedSfixed64_); + } + if (other.packedFloat_.Count != 0) { + result.packedFloat_.Add(other.packedFloat_); + } + if (other.packedDouble_.Count != 0) { + result.packedDouble_.Add(other.packedDouble_); + } + if (other.packedBool_.Count != 0) { + result.packedBool_.Add(other.packedBool_); + } + if (other.packedEnum_.Count != 0) { + result.packedEnum_.Add(other.packedEnum_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testPackedTypesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testPackedTypesFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 722: + case 720: { + input.ReadInt32Array(tag, field_name, result.packedInt32_); + break; + } + case 730: + case 728: { + input.ReadInt64Array(tag, field_name, result.packedInt64_); + break; + } + case 738: + case 736: { + input.ReadUInt32Array(tag, field_name, result.packedUint32_); + break; + } + case 746: + case 744: { + input.ReadUInt64Array(tag, field_name, result.packedUint64_); + break; + } + case 754: + case 752: { + input.ReadSInt32Array(tag, field_name, result.packedSint32_); + break; + } + case 762: + case 760: { + input.ReadSInt64Array(tag, field_name, result.packedSint64_); + break; + } + case 770: + case 773: { + input.ReadFixed32Array(tag, field_name, result.packedFixed32_); + break; + } + case 778: + case 777: { + input.ReadFixed64Array(tag, field_name, result.packedFixed64_); + break; + } + case 786: + case 789: { + input.ReadSFixed32Array(tag, field_name, result.packedSfixed32_); + break; + } + case 794: + case 793: { + input.ReadSFixed64Array(tag, field_name, result.packedSfixed64_); + break; + } + case 802: + case 805: { + input.ReadFloatArray(tag, field_name, result.packedFloat_); + break; + } + case 810: + case 809: { + input.ReadDoubleArray(tag, field_name, result.packedDouble_); + break; + } + case 818: + case 816: { + input.ReadBoolArray(tag, field_name, result.packedBool_); + break; + } + case 826: + case 824: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.packedEnum_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(103, (ulong)(int)rawValue); + } + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList PackedInt32List { + get { return PrepareBuilder().packedInt32_; } + } + public int PackedInt32Count { + get { return result.PackedInt32Count; } + } + public int GetPackedInt32(int index) { + return result.GetPackedInt32(index); + } + public Builder SetPackedInt32(int index, int value) { + PrepareBuilder(); + result.packedInt32_[index] = value; + return this; + } + public Builder AddPackedInt32(int value) { + PrepareBuilder(); + result.packedInt32_.Add(value); + return this; + } + public Builder AddRangePackedInt32(scg::IEnumerable values) { + PrepareBuilder(); + result.packedInt32_.Add(values); + return this; + } + public Builder ClearPackedInt32() { + PrepareBuilder(); + result.packedInt32_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedInt64List { + get { return PrepareBuilder().packedInt64_; } + } + public int PackedInt64Count { + get { return result.PackedInt64Count; } + } + public long GetPackedInt64(int index) { + return result.GetPackedInt64(index); + } + public Builder SetPackedInt64(int index, long value) { + PrepareBuilder(); + result.packedInt64_[index] = value; + return this; + } + public Builder AddPackedInt64(long value) { + PrepareBuilder(); + result.packedInt64_.Add(value); + return this; + } + public Builder AddRangePackedInt64(scg::IEnumerable values) { + PrepareBuilder(); + result.packedInt64_.Add(values); + return this; + } + public Builder ClearPackedInt64() { + PrepareBuilder(); + result.packedInt64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedUint32List { + get { return PrepareBuilder().packedUint32_; } + } + public int PackedUint32Count { + get { return result.PackedUint32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedUint32(int index) { + return result.GetPackedUint32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedUint32(int index, uint value) { + PrepareBuilder(); + result.packedUint32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedUint32(uint value) { + PrepareBuilder(); + result.packedUint32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedUint32(scg::IEnumerable values) { + PrepareBuilder(); + result.packedUint32_.Add(values); + return this; + } + public Builder ClearPackedUint32() { + PrepareBuilder(); + result.packedUint32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedUint64List { + get { return PrepareBuilder().packedUint64_; } + } + public int PackedUint64Count { + get { return result.PackedUint64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedUint64(int index) { + return result.GetPackedUint64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedUint64(int index, ulong value) { + PrepareBuilder(); + result.packedUint64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedUint64(ulong value) { + PrepareBuilder(); + result.packedUint64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedUint64(scg::IEnumerable values) { + PrepareBuilder(); + result.packedUint64_.Add(values); + return this; + } + public Builder ClearPackedUint64() { + PrepareBuilder(); + result.packedUint64_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedSint32List { + get { return PrepareBuilder().packedSint32_; } + } + public int PackedSint32Count { + get { return result.PackedSint32Count; } + } + public int GetPackedSint32(int index) { + return result.GetPackedSint32(index); + } + public Builder SetPackedSint32(int index, int value) { + PrepareBuilder(); + result.packedSint32_[index] = value; + return this; + } + public Builder AddPackedSint32(int value) { + PrepareBuilder(); + result.packedSint32_.Add(value); + return this; + } + public Builder AddRangePackedSint32(scg::IEnumerable values) { + PrepareBuilder(); + result.packedSint32_.Add(values); + return this; + } + public Builder ClearPackedSint32() { + PrepareBuilder(); + result.packedSint32_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedSint64List { + get { return PrepareBuilder().packedSint64_; } + } + public int PackedSint64Count { + get { return result.PackedSint64Count; } + } + public long GetPackedSint64(int index) { + return result.GetPackedSint64(index); + } + public Builder SetPackedSint64(int index, long value) { + PrepareBuilder(); + result.packedSint64_[index] = value; + return this; + } + public Builder AddPackedSint64(long value) { + PrepareBuilder(); + result.packedSint64_.Add(value); + return this; + } + public Builder AddRangePackedSint64(scg::IEnumerable values) { + PrepareBuilder(); + result.packedSint64_.Add(values); + return this; + } + public Builder ClearPackedSint64() { + PrepareBuilder(); + result.packedSint64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedFixed32List { + get { return PrepareBuilder().packedFixed32_; } + } + public int PackedFixed32Count { + get { return result.PackedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedFixed32(int index) { + return result.GetPackedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedFixed32(int index, uint value) { + PrepareBuilder(); + result.packedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedFixed32(uint value) { + PrepareBuilder(); + result.packedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedFixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.packedFixed32_.Add(values); + return this; + } + public Builder ClearPackedFixed32() { + PrepareBuilder(); + result.packedFixed32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedFixed64List { + get { return PrepareBuilder().packedFixed64_; } + } + public int PackedFixed64Count { + get { return result.PackedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedFixed64(int index) { + return result.GetPackedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedFixed64(int index, ulong value) { + PrepareBuilder(); + result.packedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedFixed64(ulong value) { + PrepareBuilder(); + result.packedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedFixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.packedFixed64_.Add(values); + return this; + } + public Builder ClearPackedFixed64() { + PrepareBuilder(); + result.packedFixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedSfixed32List { + get { return PrepareBuilder().packedSfixed32_; } + } + public int PackedSfixed32Count { + get { return result.PackedSfixed32Count; } + } + public int GetPackedSfixed32(int index) { + return result.GetPackedSfixed32(index); + } + public Builder SetPackedSfixed32(int index, int value) { + PrepareBuilder(); + result.packedSfixed32_[index] = value; + return this; + } + public Builder AddPackedSfixed32(int value) { + PrepareBuilder(); + result.packedSfixed32_.Add(value); + return this; + } + public Builder AddRangePackedSfixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.packedSfixed32_.Add(values); + return this; + } + public Builder ClearPackedSfixed32() { + PrepareBuilder(); + result.packedSfixed32_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedSfixed64List { + get { return PrepareBuilder().packedSfixed64_; } + } + public int PackedSfixed64Count { + get { return result.PackedSfixed64Count; } + } + public long GetPackedSfixed64(int index) { + return result.GetPackedSfixed64(index); + } + public Builder SetPackedSfixed64(int index, long value) { + PrepareBuilder(); + result.packedSfixed64_[index] = value; + return this; + } + public Builder AddPackedSfixed64(long value) { + PrepareBuilder(); + result.packedSfixed64_.Add(value); + return this; + } + public Builder AddRangePackedSfixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.packedSfixed64_.Add(values); + return this; + } + public Builder ClearPackedSfixed64() { + PrepareBuilder(); + result.packedSfixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedFloatList { + get { return PrepareBuilder().packedFloat_; } + } + public int PackedFloatCount { + get { return result.PackedFloatCount; } + } + public float GetPackedFloat(int index) { + return result.GetPackedFloat(index); + } + public Builder SetPackedFloat(int index, float value) { + PrepareBuilder(); + result.packedFloat_[index] = value; + return this; + } + public Builder AddPackedFloat(float value) { + PrepareBuilder(); + result.packedFloat_.Add(value); + return this; + } + public Builder AddRangePackedFloat(scg::IEnumerable values) { + PrepareBuilder(); + result.packedFloat_.Add(values); + return this; + } + public Builder ClearPackedFloat() { + PrepareBuilder(); + result.packedFloat_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedDoubleList { + get { return PrepareBuilder().packedDouble_; } + } + public int PackedDoubleCount { + get { return result.PackedDoubleCount; } + } + public double GetPackedDouble(int index) { + return result.GetPackedDouble(index); + } + public Builder SetPackedDouble(int index, double value) { + PrepareBuilder(); + result.packedDouble_[index] = value; + return this; + } + public Builder AddPackedDouble(double value) { + PrepareBuilder(); + result.packedDouble_.Add(value); + return this; + } + public Builder AddRangePackedDouble(scg::IEnumerable values) { + PrepareBuilder(); + result.packedDouble_.Add(values); + return this; + } + public Builder ClearPackedDouble() { + PrepareBuilder(); + result.packedDouble_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedBoolList { + get { return PrepareBuilder().packedBool_; } + } + public int PackedBoolCount { + get { return result.PackedBoolCount; } + } + public bool GetPackedBool(int index) { + return result.GetPackedBool(index); + } + public Builder SetPackedBool(int index, bool value) { + PrepareBuilder(); + result.packedBool_[index] = value; + return this; + } + public Builder AddPackedBool(bool value) { + PrepareBuilder(); + result.packedBool_.Add(value); + return this; + } + public Builder AddRangePackedBool(scg::IEnumerable values) { + PrepareBuilder(); + result.packedBool_.Add(values); + return this; + } + public Builder ClearPackedBool() { + PrepareBuilder(); + result.packedBool_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedEnumList { + get { return PrepareBuilder().packedEnum_; } + } + public int PackedEnumCount { + get { return result.PackedEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetPackedEnum(int index) { + return result.GetPackedEnum(index); + } + public Builder SetPackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.packedEnum_[index] = value; + return this; + } + public Builder AddPackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.packedEnum_.Add(value); + return this; + } + public Builder AddRangePackedEnum(scg::IEnumerable values) { + PrepareBuilder(); + result.packedEnum_.Add(values); + return this; + } + public Builder ClearPackedEnum() { + PrepareBuilder(); + result.packedEnum_.Clear(); + return this; + } + } + static TestPackedTypes() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestUnpackedTypes : pb::GeneratedMessage { + private TestUnpackedTypes() { } + private static readonly TestUnpackedTypes defaultInstance = new TestUnpackedTypes().MakeReadOnly(); + private static readonly string[] _testUnpackedTypesFieldNames = new string[] { "unpacked_bool", "unpacked_double", "unpacked_enum", "unpacked_fixed32", "unpacked_fixed64", "unpacked_float", "unpacked_int32", "unpacked_int64", "unpacked_sfixed32", "unpacked_sfixed64", "unpacked_sint32", "unpacked_sint64", "unpacked_uint32", "unpacked_uint64" }; + private static readonly uint[] _testUnpackedTypesFieldTags = new uint[] { 816, 809, 824, 773, 777, 805, 720, 728, 789, 793, 752, 760, 736, 744 }; + public static TestUnpackedTypes DefaultInstance { + get { return defaultInstance; } + } + + public override TestUnpackedTypes DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestUnpackedTypes ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable; } + } + + public const int UnpackedInt32FieldNumber = 90; + private pbc::PopsicleList unpackedInt32_ = new pbc::PopsicleList(); + public scg::IList UnpackedInt32List { + get { return pbc::Lists.AsReadOnly(unpackedInt32_); } + } + public int UnpackedInt32Count { + get { return unpackedInt32_.Count; } + } + public int GetUnpackedInt32(int index) { + return unpackedInt32_[index]; + } + + public const int UnpackedInt64FieldNumber = 91; + private pbc::PopsicleList unpackedInt64_ = new pbc::PopsicleList(); + public scg::IList UnpackedInt64List { + get { return pbc::Lists.AsReadOnly(unpackedInt64_); } + } + public int UnpackedInt64Count { + get { return unpackedInt64_.Count; } + } + public long GetUnpackedInt64(int index) { + return unpackedInt64_[index]; + } + + public const int UnpackedUint32FieldNumber = 92; + private pbc::PopsicleList unpackedUint32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedUint32List { + get { return pbc::Lists.AsReadOnly(unpackedUint32_); } + } + public int UnpackedUint32Count { + get { return unpackedUint32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedUint32(int index) { + return unpackedUint32_[index]; + } + + public const int UnpackedUint64FieldNumber = 93; + private pbc::PopsicleList unpackedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedUint64List { + get { return pbc::Lists.AsReadOnly(unpackedUint64_); } + } + public int UnpackedUint64Count { + get { return unpackedUint64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedUint64(int index) { + return unpackedUint64_[index]; + } + + public const int UnpackedSint32FieldNumber = 94; + private pbc::PopsicleList unpackedSint32_ = new pbc::PopsicleList(); + public scg::IList UnpackedSint32List { + get { return pbc::Lists.AsReadOnly(unpackedSint32_); } + } + public int UnpackedSint32Count { + get { return unpackedSint32_.Count; } + } + public int GetUnpackedSint32(int index) { + return unpackedSint32_[index]; + } + + public const int UnpackedSint64FieldNumber = 95; + private pbc::PopsicleList unpackedSint64_ = new pbc::PopsicleList(); + public scg::IList UnpackedSint64List { + get { return pbc::Lists.AsReadOnly(unpackedSint64_); } + } + public int UnpackedSint64Count { + get { return unpackedSint64_.Count; } + } + public long GetUnpackedSint64(int index) { + return unpackedSint64_[index]; + } + + public const int UnpackedFixed32FieldNumber = 96; + private pbc::PopsicleList unpackedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedFixed32List { + get { return pbc::Lists.AsReadOnly(unpackedFixed32_); } + } + public int UnpackedFixed32Count { + get { return unpackedFixed32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedFixed32(int index) { + return unpackedFixed32_[index]; + } + + public const int UnpackedFixed64FieldNumber = 97; + private pbc::PopsicleList unpackedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedFixed64List { + get { return pbc::Lists.AsReadOnly(unpackedFixed64_); } + } + public int UnpackedFixed64Count { + get { return unpackedFixed64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedFixed64(int index) { + return unpackedFixed64_[index]; + } + + public const int UnpackedSfixed32FieldNumber = 98; + private pbc::PopsicleList unpackedSfixed32_ = new pbc::PopsicleList(); + public scg::IList UnpackedSfixed32List { + get { return pbc::Lists.AsReadOnly(unpackedSfixed32_); } + } + public int UnpackedSfixed32Count { + get { return unpackedSfixed32_.Count; } + } + public int GetUnpackedSfixed32(int index) { + return unpackedSfixed32_[index]; + } + + public const int UnpackedSfixed64FieldNumber = 99; + private pbc::PopsicleList unpackedSfixed64_ = new pbc::PopsicleList(); + public scg::IList UnpackedSfixed64List { + get { return pbc::Lists.AsReadOnly(unpackedSfixed64_); } + } + public int UnpackedSfixed64Count { + get { return unpackedSfixed64_.Count; } + } + public long GetUnpackedSfixed64(int index) { + return unpackedSfixed64_[index]; + } + + public const int UnpackedFloatFieldNumber = 100; + private pbc::PopsicleList unpackedFloat_ = new pbc::PopsicleList(); + public scg::IList UnpackedFloatList { + get { return pbc::Lists.AsReadOnly(unpackedFloat_); } + } + public int UnpackedFloatCount { + get { return unpackedFloat_.Count; } + } + public float GetUnpackedFloat(int index) { + return unpackedFloat_[index]; + } + + public const int UnpackedDoubleFieldNumber = 101; + private pbc::PopsicleList unpackedDouble_ = new pbc::PopsicleList(); + public scg::IList UnpackedDoubleList { + get { return pbc::Lists.AsReadOnly(unpackedDouble_); } + } + public int UnpackedDoubleCount { + get { return unpackedDouble_.Count; } + } + public double GetUnpackedDouble(int index) { + return unpackedDouble_[index]; + } + + public const int UnpackedBoolFieldNumber = 102; + private pbc::PopsicleList unpackedBool_ = new pbc::PopsicleList(); + public scg::IList UnpackedBoolList { + get { return pbc::Lists.AsReadOnly(unpackedBool_); } + } + public int UnpackedBoolCount { + get { return unpackedBool_.Count; } + } + public bool GetUnpackedBool(int index) { + return unpackedBool_[index]; + } + + public const int UnpackedEnumFieldNumber = 103; + private pbc::PopsicleList unpackedEnum_ = new pbc::PopsicleList(); + public scg::IList UnpackedEnumList { + get { return pbc::Lists.AsReadOnly(unpackedEnum_); } + } + public int UnpackedEnumCount { + get { return unpackedEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetUnpackedEnum(int index) { + return unpackedEnum_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testUnpackedTypesFieldNames; + if (unpackedInt32_.Count > 0) { + output.WriteInt32Array(90, field_names[6], unpackedInt32_); + } + if (unpackedInt64_.Count > 0) { + output.WriteInt64Array(91, field_names[7], unpackedInt64_); + } + if (unpackedUint32_.Count > 0) { + output.WriteUInt32Array(92, field_names[12], unpackedUint32_); + } + if (unpackedUint64_.Count > 0) { + output.WriteUInt64Array(93, field_names[13], unpackedUint64_); + } + if (unpackedSint32_.Count > 0) { + output.WriteSInt32Array(94, field_names[10], unpackedSint32_); + } + if (unpackedSint64_.Count > 0) { + output.WriteSInt64Array(95, field_names[11], unpackedSint64_); + } + if (unpackedFixed32_.Count > 0) { + output.WriteFixed32Array(96, field_names[3], unpackedFixed32_); + } + if (unpackedFixed64_.Count > 0) { + output.WriteFixed64Array(97, field_names[4], unpackedFixed64_); + } + if (unpackedSfixed32_.Count > 0) { + output.WriteSFixed32Array(98, field_names[8], unpackedSfixed32_); + } + if (unpackedSfixed64_.Count > 0) { + output.WriteSFixed64Array(99, field_names[9], unpackedSfixed64_); + } + if (unpackedFloat_.Count > 0) { + output.WriteFloatArray(100, field_names[5], unpackedFloat_); + } + if (unpackedDouble_.Count > 0) { + output.WriteDoubleArray(101, field_names[1], unpackedDouble_); + } + if (unpackedBool_.Count > 0) { + output.WriteBoolArray(102, field_names[0], unpackedBool_); + } + if (unpackedEnum_.Count > 0) { + output.WriteEnumArray(103, field_names[2], unpackedEnum_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + foreach (int element in UnpackedInt32List) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedInt32_.Count; + } + { + int dataSize = 0; + foreach (long element in UnpackedInt64List) { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedInt64_.Count; + } + { + int dataSize = 0; + foreach (uint element in UnpackedUint32List) { + dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedUint32_.Count; + } + { + int dataSize = 0; + foreach (ulong element in UnpackedUint64List) { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedUint64_.Count; + } + { + int dataSize = 0; + foreach (int element in UnpackedSint32List) { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedSint32_.Count; + } + { + int dataSize = 0; + foreach (long element in UnpackedSint64List) { + dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedSint64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * unpackedFixed32_.Count; + size += dataSize; + size += 2 * unpackedFixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * unpackedFixed64_.Count; + size += dataSize; + size += 2 * unpackedFixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * unpackedSfixed32_.Count; + size += dataSize; + size += 2 * unpackedSfixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * unpackedSfixed64_.Count; + size += dataSize; + size += 2 * unpackedSfixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * unpackedFloat_.Count; + size += dataSize; + size += 2 * unpackedFloat_.Count; + } + { + int dataSize = 0; + dataSize = 8 * unpackedDouble_.Count; + size += dataSize; + size += 2 * unpackedDouble_.Count; + } + { + int dataSize = 0; + dataSize = 1 * unpackedBool_.Count; + size += dataSize; + size += 2 * unpackedBool_.Count; + } + { + int dataSize = 0; + if (unpackedEnum_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in unpackedEnum_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 2 * unpackedEnum_.Count; + } + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestUnpackedTypes ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedTypes ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestUnpackedTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestUnpackedTypes MakeReadOnly() { + unpackedInt32_.MakeReadOnly(); + unpackedInt64_.MakeReadOnly(); + unpackedUint32_.MakeReadOnly(); + unpackedUint64_.MakeReadOnly(); + unpackedSint32_.MakeReadOnly(); + unpackedSint64_.MakeReadOnly(); + unpackedFixed32_.MakeReadOnly(); + unpackedFixed64_.MakeReadOnly(); + unpackedSfixed32_.MakeReadOnly(); + unpackedSfixed64_.MakeReadOnly(); + unpackedFloat_.MakeReadOnly(); + unpackedDouble_.MakeReadOnly(); + unpackedBool_.MakeReadOnly(); + unpackedEnum_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestUnpackedTypes prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestUnpackedTypes cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestUnpackedTypes result; + + private TestUnpackedTypes PrepareBuilder() { + if (resultIsReadOnly) { + TestUnpackedTypes original = result; + result = new TestUnpackedTypes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestUnpackedTypes MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.Descriptor; } + } + + public override TestUnpackedTypes DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.DefaultInstance; } + } + + public override TestUnpackedTypes BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestUnpackedTypes) { + return MergeFrom((TestUnpackedTypes) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestUnpackedTypes other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.DefaultInstance) return this; + PrepareBuilder(); + if (other.unpackedInt32_.Count != 0) { + result.unpackedInt32_.Add(other.unpackedInt32_); + } + if (other.unpackedInt64_.Count != 0) { + result.unpackedInt64_.Add(other.unpackedInt64_); + } + if (other.unpackedUint32_.Count != 0) { + result.unpackedUint32_.Add(other.unpackedUint32_); + } + if (other.unpackedUint64_.Count != 0) { + result.unpackedUint64_.Add(other.unpackedUint64_); + } + if (other.unpackedSint32_.Count != 0) { + result.unpackedSint32_.Add(other.unpackedSint32_); + } + if (other.unpackedSint64_.Count != 0) { + result.unpackedSint64_.Add(other.unpackedSint64_); + } + if (other.unpackedFixed32_.Count != 0) { + result.unpackedFixed32_.Add(other.unpackedFixed32_); + } + if (other.unpackedFixed64_.Count != 0) { + result.unpackedFixed64_.Add(other.unpackedFixed64_); + } + if (other.unpackedSfixed32_.Count != 0) { + result.unpackedSfixed32_.Add(other.unpackedSfixed32_); + } + if (other.unpackedSfixed64_.Count != 0) { + result.unpackedSfixed64_.Add(other.unpackedSfixed64_); + } + if (other.unpackedFloat_.Count != 0) { + result.unpackedFloat_.Add(other.unpackedFloat_); + } + if (other.unpackedDouble_.Count != 0) { + result.unpackedDouble_.Add(other.unpackedDouble_); + } + if (other.unpackedBool_.Count != 0) { + result.unpackedBool_.Add(other.unpackedBool_); + } + if (other.unpackedEnum_.Count != 0) { + result.unpackedEnum_.Add(other.unpackedEnum_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testUnpackedTypesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testUnpackedTypesFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 722: + case 720: { + input.ReadInt32Array(tag, field_name, result.unpackedInt32_); + break; + } + case 730: + case 728: { + input.ReadInt64Array(tag, field_name, result.unpackedInt64_); + break; + } + case 738: + case 736: { + input.ReadUInt32Array(tag, field_name, result.unpackedUint32_); + break; + } + case 746: + case 744: { + input.ReadUInt64Array(tag, field_name, result.unpackedUint64_); + break; + } + case 754: + case 752: { + input.ReadSInt32Array(tag, field_name, result.unpackedSint32_); + break; + } + case 762: + case 760: { + input.ReadSInt64Array(tag, field_name, result.unpackedSint64_); + break; + } + case 770: + case 773: { + input.ReadFixed32Array(tag, field_name, result.unpackedFixed32_); + break; + } + case 778: + case 777: { + input.ReadFixed64Array(tag, field_name, result.unpackedFixed64_); + break; + } + case 786: + case 789: { + input.ReadSFixed32Array(tag, field_name, result.unpackedSfixed32_); + break; + } + case 794: + case 793: { + input.ReadSFixed64Array(tag, field_name, result.unpackedSfixed64_); + break; + } + case 802: + case 805: { + input.ReadFloatArray(tag, field_name, result.unpackedFloat_); + break; + } + case 810: + case 809: { + input.ReadDoubleArray(tag, field_name, result.unpackedDouble_); + break; + } + case 818: + case 816: { + input.ReadBoolArray(tag, field_name, result.unpackedBool_); + break; + } + case 826: + case 824: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.unpackedEnum_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(103, (ulong)(int)rawValue); + } + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList UnpackedInt32List { + get { return PrepareBuilder().unpackedInt32_; } + } + public int UnpackedInt32Count { + get { return result.UnpackedInt32Count; } + } + public int GetUnpackedInt32(int index) { + return result.GetUnpackedInt32(index); + } + public Builder SetUnpackedInt32(int index, int value) { + PrepareBuilder(); + result.unpackedInt32_[index] = value; + return this; + } + public Builder AddUnpackedInt32(int value) { + PrepareBuilder(); + result.unpackedInt32_.Add(value); + return this; + } + public Builder AddRangeUnpackedInt32(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedInt32_.Add(values); + return this; + } + public Builder ClearUnpackedInt32() { + PrepareBuilder(); + result.unpackedInt32_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedInt64List { + get { return PrepareBuilder().unpackedInt64_; } + } + public int UnpackedInt64Count { + get { return result.UnpackedInt64Count; } + } + public long GetUnpackedInt64(int index) { + return result.GetUnpackedInt64(index); + } + public Builder SetUnpackedInt64(int index, long value) { + PrepareBuilder(); + result.unpackedInt64_[index] = value; + return this; + } + public Builder AddUnpackedInt64(long value) { + PrepareBuilder(); + result.unpackedInt64_.Add(value); + return this; + } + public Builder AddRangeUnpackedInt64(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedInt64_.Add(values); + return this; + } + public Builder ClearUnpackedInt64() { + PrepareBuilder(); + result.unpackedInt64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedUint32List { + get { return PrepareBuilder().unpackedUint32_; } + } + public int UnpackedUint32Count { + get { return result.UnpackedUint32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedUint32(int index) { + return result.GetUnpackedUint32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedUint32(int index, uint value) { + PrepareBuilder(); + result.unpackedUint32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedUint32(uint value) { + PrepareBuilder(); + result.unpackedUint32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedUint32(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedUint32_.Add(values); + return this; + } + public Builder ClearUnpackedUint32() { + PrepareBuilder(); + result.unpackedUint32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedUint64List { + get { return PrepareBuilder().unpackedUint64_; } + } + public int UnpackedUint64Count { + get { return result.UnpackedUint64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedUint64(int index) { + return result.GetUnpackedUint64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedUint64(int index, ulong value) { + PrepareBuilder(); + result.unpackedUint64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedUint64(ulong value) { + PrepareBuilder(); + result.unpackedUint64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedUint64(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedUint64_.Add(values); + return this; + } + public Builder ClearUnpackedUint64() { + PrepareBuilder(); + result.unpackedUint64_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedSint32List { + get { return PrepareBuilder().unpackedSint32_; } + } + public int UnpackedSint32Count { + get { return result.UnpackedSint32Count; } + } + public int GetUnpackedSint32(int index) { + return result.GetUnpackedSint32(index); + } + public Builder SetUnpackedSint32(int index, int value) { + PrepareBuilder(); + result.unpackedSint32_[index] = value; + return this; + } + public Builder AddUnpackedSint32(int value) { + PrepareBuilder(); + result.unpackedSint32_.Add(value); + return this; + } + public Builder AddRangeUnpackedSint32(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedSint32_.Add(values); + return this; + } + public Builder ClearUnpackedSint32() { + PrepareBuilder(); + result.unpackedSint32_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedSint64List { + get { return PrepareBuilder().unpackedSint64_; } + } + public int UnpackedSint64Count { + get { return result.UnpackedSint64Count; } + } + public long GetUnpackedSint64(int index) { + return result.GetUnpackedSint64(index); + } + public Builder SetUnpackedSint64(int index, long value) { + PrepareBuilder(); + result.unpackedSint64_[index] = value; + return this; + } + public Builder AddUnpackedSint64(long value) { + PrepareBuilder(); + result.unpackedSint64_.Add(value); + return this; + } + public Builder AddRangeUnpackedSint64(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedSint64_.Add(values); + return this; + } + public Builder ClearUnpackedSint64() { + PrepareBuilder(); + result.unpackedSint64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedFixed32List { + get { return PrepareBuilder().unpackedFixed32_; } + } + public int UnpackedFixed32Count { + get { return result.UnpackedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedFixed32(int index) { + return result.GetUnpackedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedFixed32(int index, uint value) { + PrepareBuilder(); + result.unpackedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedFixed32(uint value) { + PrepareBuilder(); + result.unpackedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedFixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedFixed32_.Add(values); + return this; + } + public Builder ClearUnpackedFixed32() { + PrepareBuilder(); + result.unpackedFixed32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedFixed64List { + get { return PrepareBuilder().unpackedFixed64_; } + } + public int UnpackedFixed64Count { + get { return result.UnpackedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedFixed64(int index) { + return result.GetUnpackedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedFixed64(int index, ulong value) { + PrepareBuilder(); + result.unpackedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedFixed64(ulong value) { + PrepareBuilder(); + result.unpackedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedFixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedFixed64_.Add(values); + return this; + } + public Builder ClearUnpackedFixed64() { + PrepareBuilder(); + result.unpackedFixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedSfixed32List { + get { return PrepareBuilder().unpackedSfixed32_; } + } + public int UnpackedSfixed32Count { + get { return result.UnpackedSfixed32Count; } + } + public int GetUnpackedSfixed32(int index) { + return result.GetUnpackedSfixed32(index); + } + public Builder SetUnpackedSfixed32(int index, int value) { + PrepareBuilder(); + result.unpackedSfixed32_[index] = value; + return this; + } + public Builder AddUnpackedSfixed32(int value) { + PrepareBuilder(); + result.unpackedSfixed32_.Add(value); + return this; + } + public Builder AddRangeUnpackedSfixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedSfixed32_.Add(values); + return this; + } + public Builder ClearUnpackedSfixed32() { + PrepareBuilder(); + result.unpackedSfixed32_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedSfixed64List { + get { return PrepareBuilder().unpackedSfixed64_; } + } + public int UnpackedSfixed64Count { + get { return result.UnpackedSfixed64Count; } + } + public long GetUnpackedSfixed64(int index) { + return result.GetUnpackedSfixed64(index); + } + public Builder SetUnpackedSfixed64(int index, long value) { + PrepareBuilder(); + result.unpackedSfixed64_[index] = value; + return this; + } + public Builder AddUnpackedSfixed64(long value) { + PrepareBuilder(); + result.unpackedSfixed64_.Add(value); + return this; + } + public Builder AddRangeUnpackedSfixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedSfixed64_.Add(values); + return this; + } + public Builder ClearUnpackedSfixed64() { + PrepareBuilder(); + result.unpackedSfixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedFloatList { + get { return PrepareBuilder().unpackedFloat_; } + } + public int UnpackedFloatCount { + get { return result.UnpackedFloatCount; } + } + public float GetUnpackedFloat(int index) { + return result.GetUnpackedFloat(index); + } + public Builder SetUnpackedFloat(int index, float value) { + PrepareBuilder(); + result.unpackedFloat_[index] = value; + return this; + } + public Builder AddUnpackedFloat(float value) { + PrepareBuilder(); + result.unpackedFloat_.Add(value); + return this; + } + public Builder AddRangeUnpackedFloat(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedFloat_.Add(values); + return this; + } + public Builder ClearUnpackedFloat() { + PrepareBuilder(); + result.unpackedFloat_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedDoubleList { + get { return PrepareBuilder().unpackedDouble_; } + } + public int UnpackedDoubleCount { + get { return result.UnpackedDoubleCount; } + } + public double GetUnpackedDouble(int index) { + return result.GetUnpackedDouble(index); + } + public Builder SetUnpackedDouble(int index, double value) { + PrepareBuilder(); + result.unpackedDouble_[index] = value; + return this; + } + public Builder AddUnpackedDouble(double value) { + PrepareBuilder(); + result.unpackedDouble_.Add(value); + return this; + } + public Builder AddRangeUnpackedDouble(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedDouble_.Add(values); + return this; + } + public Builder ClearUnpackedDouble() { + PrepareBuilder(); + result.unpackedDouble_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedBoolList { + get { return PrepareBuilder().unpackedBool_; } + } + public int UnpackedBoolCount { + get { return result.UnpackedBoolCount; } + } + public bool GetUnpackedBool(int index) { + return result.GetUnpackedBool(index); + } + public Builder SetUnpackedBool(int index, bool value) { + PrepareBuilder(); + result.unpackedBool_[index] = value; + return this; + } + public Builder AddUnpackedBool(bool value) { + PrepareBuilder(); + result.unpackedBool_.Add(value); + return this; + } + public Builder AddRangeUnpackedBool(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedBool_.Add(values); + return this; + } + public Builder ClearUnpackedBool() { + PrepareBuilder(); + result.unpackedBool_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedEnumList { + get { return PrepareBuilder().unpackedEnum_; } + } + public int UnpackedEnumCount { + get { return result.UnpackedEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetUnpackedEnum(int index) { + return result.GetUnpackedEnum(index); + } + public Builder SetUnpackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.unpackedEnum_[index] = value; + return this; + } + public Builder AddUnpackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.unpackedEnum_.Add(value); + return this; + } + public Builder AddRangeUnpackedEnum(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedEnum_.Add(values); + return this; + } + public Builder ClearUnpackedEnum() { + PrepareBuilder(); + result.unpackedEnum_.Clear(); + return this; + } + } + static TestUnpackedTypes() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestPackedExtensions : pb::ExtendableMessage { + private TestPackedExtensions() { } + private static readonly TestPackedExtensions defaultInstance = new TestPackedExtensions().MakeReadOnly(); + private static readonly string[] _testPackedExtensionsFieldNames = new string[] { }; + private static readonly uint[] _testPackedExtensionsFieldTags = new uint[] { }; + public static TestPackedExtensions DefaultInstance { + get { return defaultInstance; } + } + + public override TestPackedExtensions DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestPackedExtensions ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedExtensions__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testPackedExtensionsFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestPackedExtensions ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestPackedExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestPackedExtensions ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestPackedExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestPackedExtensions ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestPackedExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestPackedExtensions ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestPackedExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestPackedExtensions ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestPackedExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestPackedExtensions MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestPackedExtensions prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestPackedExtensions cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestPackedExtensions result; + + private TestPackedExtensions PrepareBuilder() { + if (resultIsReadOnly) { + TestPackedExtensions original = result; + result = new TestPackedExtensions(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestPackedExtensions MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.Descriptor; } + } + + public override TestPackedExtensions DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.DefaultInstance; } + } + + public override TestPackedExtensions BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestPackedExtensions) { + return MergeFrom((TestPackedExtensions) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestPackedExtensions other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testPackedExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testPackedExtensionsFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestPackedExtensions() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestUnpackedExtensions : pb::ExtendableMessage { + private TestUnpackedExtensions() { } + private static readonly TestUnpackedExtensions defaultInstance = new TestUnpackedExtensions().MakeReadOnly(); + private static readonly string[] _testUnpackedExtensionsFieldNames = new string[] { }; + private static readonly uint[] _testUnpackedExtensionsFieldTags = new uint[] { }; + public static TestUnpackedExtensions DefaultInstance { + get { return defaultInstance; } + } + + public override TestUnpackedExtensions DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestUnpackedExtensions ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testUnpackedExtensionsFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestUnpackedExtensions ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedExtensions ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestUnpackedExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestUnpackedExtensions MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestUnpackedExtensions prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestUnpackedExtensions cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestUnpackedExtensions result; + + private TestUnpackedExtensions PrepareBuilder() { + if (resultIsReadOnly) { + TestUnpackedExtensions original = result; + result = new TestUnpackedExtensions(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestUnpackedExtensions MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.Descriptor; } + } + + public override TestUnpackedExtensions DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.DefaultInstance; } + } + + public override TestUnpackedExtensions BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestUnpackedExtensions) { + return MergeFrom((TestUnpackedExtensions) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestUnpackedExtensions other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testUnpackedExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testUnpackedExtensionsFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestUnpackedExtensions() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestDynamicExtensions : pb::GeneratedMessage { + private TestDynamicExtensions() { } + private static readonly TestDynamicExtensions defaultInstance = new TestDynamicExtensions().MakeReadOnly(); + private static readonly string[] _testDynamicExtensionsFieldNames = new string[] { "dynamic_enum_extension", "dynamic_message_extension", "enum_extension", "message_extension", "packed_extension", "repeated_extension", "scalar_extension" }; + private static readonly uint[] _testDynamicExtensionsFieldTags = new uint[] { 16016, 16034, 16008, 16026, 16050, 16042, 16005 }; + public static TestDynamicExtensions DefaultInstance { + get { return defaultInstance; } + } + + public override TestDynamicExtensions DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestDynamicExtensions ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + public enum DynamicEnumType { + DYNAMIC_FOO = 2200, + DYNAMIC_BAR = 2201, + DYNAMIC_BAZ = 2202, + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class DynamicMessageType : pb::GeneratedMessage { + private DynamicMessageType() { } + private static readonly DynamicMessageType defaultInstance = new DynamicMessageType().MakeReadOnly(); + private static readonly string[] _dynamicMessageTypeFieldNames = new string[] { "dynamic_field" }; + private static readonly uint[] _dynamicMessageTypeFieldTags = new uint[] { 16800 }; + public static DynamicMessageType DefaultInstance { + get { return defaultInstance; } + } + + public override DynamicMessageType DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override DynamicMessageType ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable; } + } + + public const int DynamicFieldFieldNumber = 2100; + private bool hasDynamicField; + private int dynamicField_; + public bool HasDynamicField { + get { return hasDynamicField; } + } + public int DynamicField { + get { return dynamicField_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _dynamicMessageTypeFieldNames; + if (hasDynamicField) { + output.WriteInt32(2100, field_names[0], DynamicField); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasDynamicField) { + size += pb::CodedOutputStream.ComputeInt32Size(2100, DynamicField); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static DynamicMessageType ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static DynamicMessageType ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static DynamicMessageType ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static DynamicMessageType ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private DynamicMessageType MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(DynamicMessageType prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(DynamicMessageType cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private DynamicMessageType result; + + private DynamicMessageType PrepareBuilder() { + if (resultIsReadOnly) { + DynamicMessageType original = result; + result = new DynamicMessageType(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override DynamicMessageType MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Descriptor; } + } + + public override DynamicMessageType DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance; } + } + + public override DynamicMessageType BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is DynamicMessageType) { + return MergeFrom((DynamicMessageType) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(DynamicMessageType other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasDynamicField) { + DynamicField = other.DynamicField; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_dynamicMessageTypeFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _dynamicMessageTypeFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 16800: { + result.hasDynamicField = input.ReadInt32(ref result.dynamicField_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasDynamicField { + get { return result.hasDynamicField; } + } + public int DynamicField { + get { return result.DynamicField; } + set { SetDynamicField(value); } + } + public Builder SetDynamicField(int value) { + PrepareBuilder(); + result.hasDynamicField = true; + result.dynamicField_ = value; + return this; + } + public Builder ClearDynamicField() { + PrepareBuilder(); + result.hasDynamicField = false; + result.dynamicField_ = 0; + return this; + } + } + static DynamicMessageType() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int ScalarExtensionFieldNumber = 2000; + private bool hasScalarExtension; + private uint scalarExtension_; + public bool HasScalarExtension { + get { return hasScalarExtension; } + } + [global::System.CLSCompliant(false)] + public uint ScalarExtension { + get { return scalarExtension_; } + } + + public const int EnumExtensionFieldNumber = 2001; + private bool hasEnumExtension; + private global::Google.ProtocolBuffers.TestProtos.ForeignEnum enumExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + public bool HasEnumExtension { + get { return hasEnumExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumExtension { + get { return enumExtension_; } + } + + public const int DynamicEnumExtensionFieldNumber = 2002; + private bool hasDynamicEnumExtension; + private global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType dynamicEnumExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType.DYNAMIC_FOO; + public bool HasDynamicEnumExtension { + get { return hasDynamicEnumExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType DynamicEnumExtension { + get { return dynamicEnumExtension_; } + } + + public const int MessageExtensionFieldNumber = 2003; + private bool hasMessageExtension; + private global::Google.ProtocolBuffers.TestProtos.ForeignMessage messageExtension_; + public bool HasMessageExtension { + get { return hasMessageExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageExtension { + get { return messageExtension_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } + } + + public const int DynamicMessageExtensionFieldNumber = 2004; + private bool hasDynamicMessageExtension; + private global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType dynamicMessageExtension_; + public bool HasDynamicMessageExtension { + get { return hasDynamicMessageExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType DynamicMessageExtension { + get { return dynamicMessageExtension_ ?? global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance; } + } + + public const int RepeatedExtensionFieldNumber = 2005; + private pbc::PopsicleList repeatedExtension_ = new pbc::PopsicleList(); + public scg::IList RepeatedExtensionList { + get { return pbc::Lists.AsReadOnly(repeatedExtension_); } + } + public int RepeatedExtensionCount { + get { return repeatedExtension_.Count; } + } + public string GetRepeatedExtension(int index) { + return repeatedExtension_[index]; + } + + public const int PackedExtensionFieldNumber = 2006; + private int packedExtensionMemoizedSerializedSize; + private pbc::PopsicleList packedExtension_ = new pbc::PopsicleList(); + public scg::IList PackedExtensionList { + get { return pbc::Lists.AsReadOnly(packedExtension_); } + } + public int PackedExtensionCount { + get { return packedExtension_.Count; } + } + public int GetPackedExtension(int index) { + return packedExtension_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testDynamicExtensionsFieldNames; + if (hasScalarExtension) { + output.WriteFixed32(2000, field_names[6], ScalarExtension); + } + if (hasEnumExtension) { + output.WriteEnum(2001, field_names[2], (int) EnumExtension, EnumExtension); + } + if (hasDynamicEnumExtension) { + output.WriteEnum(2002, field_names[0], (int) DynamicEnumExtension, DynamicEnumExtension); + } + if (hasMessageExtension) { + output.WriteMessage(2003, field_names[3], MessageExtension); + } + if (hasDynamicMessageExtension) { + output.WriteMessage(2004, field_names[1], DynamicMessageExtension); + } + if (repeatedExtension_.Count > 0) { + output.WriteStringArray(2005, field_names[5], repeatedExtension_); + } + if (packedExtension_.Count > 0) { + output.WritePackedSInt32Array(2006, field_names[4], packedExtensionMemoizedSerializedSize, packedExtension_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasScalarExtension) { + size += pb::CodedOutputStream.ComputeFixed32Size(2000, ScalarExtension); + } + if (hasEnumExtension) { + size += pb::CodedOutputStream.ComputeEnumSize(2001, (int) EnumExtension); + } + if (hasDynamicEnumExtension) { + size += pb::CodedOutputStream.ComputeEnumSize(2002, (int) DynamicEnumExtension); + } + if (hasMessageExtension) { + size += pb::CodedOutputStream.ComputeMessageSize(2003, MessageExtension); + } + if (hasDynamicMessageExtension) { + size += pb::CodedOutputStream.ComputeMessageSize(2004, DynamicMessageExtension); + } + { + int dataSize = 0; + foreach (string element in RepeatedExtensionList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedExtension_.Count; + } + { + int dataSize = 0; + foreach (int element in PackedExtensionList) { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + if (packedExtension_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedExtensionMemoizedSerializedSize = dataSize; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestDynamicExtensions ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDynamicExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDynamicExtensions ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDynamicExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDynamicExtensions ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDynamicExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestDynamicExtensions ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestDynamicExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestDynamicExtensions ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDynamicExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestDynamicExtensions MakeReadOnly() { + repeatedExtension_.MakeReadOnly(); + packedExtension_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestDynamicExtensions prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestDynamicExtensions cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestDynamicExtensions result; + + private TestDynamicExtensions PrepareBuilder() { + if (resultIsReadOnly) { + TestDynamicExtensions original = result; + result = new TestDynamicExtensions(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestDynamicExtensions MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Descriptor; } + } + + public override TestDynamicExtensions DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.DefaultInstance; } + } + + public override TestDynamicExtensions BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestDynamicExtensions) { + return MergeFrom((TestDynamicExtensions) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestDynamicExtensions other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasScalarExtension) { + ScalarExtension = other.ScalarExtension; + } + if (other.HasEnumExtension) { + EnumExtension = other.EnumExtension; + } + if (other.HasDynamicEnumExtension) { + DynamicEnumExtension = other.DynamicEnumExtension; + } + if (other.HasMessageExtension) { + MergeMessageExtension(other.MessageExtension); + } + if (other.HasDynamicMessageExtension) { + MergeDynamicMessageExtension(other.DynamicMessageExtension); + } + if (other.repeatedExtension_.Count != 0) { + result.repeatedExtension_.Add(other.repeatedExtension_); + } + if (other.packedExtension_.Count != 0) { + result.packedExtension_.Add(other.packedExtension_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testDynamicExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testDynamicExtensionsFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 16005: { + result.hasScalarExtension = input.ReadFixed32(ref result.scalarExtension_); + break; + } + case 16008: { + object unknown; + if(input.ReadEnum(ref result.enumExtension_, out unknown)) { + result.hasEnumExtension = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(2001, (ulong)(int)unknown); + } + break; + } + case 16016: { + object unknown; + if(input.ReadEnum(ref result.dynamicEnumExtension_, out unknown)) { + result.hasDynamicEnumExtension = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(2002, (ulong)(int)unknown); + } + break; + } + case 16026: { + global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); + if (result.hasMessageExtension) { + subBuilder.MergeFrom(MessageExtension); + } + input.ReadMessage(subBuilder, extensionRegistry); + MessageExtension = subBuilder.BuildPartial(); + break; + } + case 16034: { + global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.CreateBuilder(); + if (result.hasDynamicMessageExtension) { + subBuilder.MergeFrom(DynamicMessageExtension); + } + input.ReadMessage(subBuilder, extensionRegistry); + DynamicMessageExtension = subBuilder.BuildPartial(); + break; + } + case 16042: { + input.ReadStringArray(tag, field_name, result.repeatedExtension_); + break; + } + case 16050: + case 16048: { + input.ReadSInt32Array(tag, field_name, result.packedExtension_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasScalarExtension { + get { return result.hasScalarExtension; } + } + [global::System.CLSCompliant(false)] + public uint ScalarExtension { + get { return result.ScalarExtension; } + set { SetScalarExtension(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetScalarExtension(uint value) { + PrepareBuilder(); + result.hasScalarExtension = true; + result.scalarExtension_ = value; + return this; + } + public Builder ClearScalarExtension() { + PrepareBuilder(); + result.hasScalarExtension = false; + result.scalarExtension_ = 0; + return this; + } + + public bool HasEnumExtension { + get { return result.hasEnumExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumExtension { + get { return result.EnumExtension; } + set { SetEnumExtension(value); } + } + public Builder SetEnumExtension(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { + PrepareBuilder(); + result.hasEnumExtension = true; + result.enumExtension_ = value; + return this; + } + public Builder ClearEnumExtension() { + PrepareBuilder(); + result.hasEnumExtension = false; + result.enumExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + return this; + } + + public bool HasDynamicEnumExtension { + get { return result.hasDynamicEnumExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType DynamicEnumExtension { + get { return result.DynamicEnumExtension; } + set { SetDynamicEnumExtension(value); } + } + public Builder SetDynamicEnumExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType value) { + PrepareBuilder(); + result.hasDynamicEnumExtension = true; + result.dynamicEnumExtension_ = value; + return this; + } + public Builder ClearDynamicEnumExtension() { + PrepareBuilder(); + result.hasDynamicEnumExtension = false; + result.dynamicEnumExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType.DYNAMIC_FOO; + return this; + } + + public bool HasMessageExtension { + get { return result.hasMessageExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageExtension { + get { return result.MessageExtension; } + set { SetMessageExtension(value); } + } + public Builder SetMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasMessageExtension = true; + result.messageExtension_ = value; + return this; + } + public Builder SetMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasMessageExtension = true; + result.messageExtension_ = builderForValue.Build(); + return this; + } + public Builder MergeMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasMessageExtension && + result.messageExtension_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) { + result.messageExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.messageExtension_).MergeFrom(value).BuildPartial(); + } else { + result.messageExtension_ = value; + } + result.hasMessageExtension = true; + return this; + } + public Builder ClearMessageExtension() { + PrepareBuilder(); + result.hasMessageExtension = false; + result.messageExtension_ = null; + return this; + } + + public bool HasDynamicMessageExtension { + get { return result.hasDynamicMessageExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType DynamicMessageExtension { + get { return result.DynamicMessageExtension; } + set { SetDynamicMessageExtension(value); } + } + public Builder SetDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDynamicMessageExtension = true; + result.dynamicMessageExtension_ = value; + return this; + } + public Builder SetDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasDynamicMessageExtension = true; + result.dynamicMessageExtension_ = builderForValue.Build(); + return this; + } + public Builder MergeDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasDynamicMessageExtension && + result.dynamicMessageExtension_ != global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance) { + result.dynamicMessageExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.CreateBuilder(result.dynamicMessageExtension_).MergeFrom(value).BuildPartial(); + } else { + result.dynamicMessageExtension_ = value; + } + result.hasDynamicMessageExtension = true; + return this; + } + public Builder ClearDynamicMessageExtension() { + PrepareBuilder(); + result.hasDynamicMessageExtension = false; + result.dynamicMessageExtension_ = null; + return this; + } + + public pbc::IPopsicleList RepeatedExtensionList { + get { return PrepareBuilder().repeatedExtension_; } + } + public int RepeatedExtensionCount { + get { return result.RepeatedExtensionCount; } + } + public string GetRepeatedExtension(int index) { + return result.GetRepeatedExtension(index); + } + public Builder SetRepeatedExtension(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedExtension_[index] = value; + return this; + } + public Builder AddRepeatedExtension(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedExtension_.Add(value); + return this; + } + public Builder AddRangeRepeatedExtension(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedExtension_.Add(values); + return this; + } + public Builder ClearRepeatedExtension() { + PrepareBuilder(); + result.repeatedExtension_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedExtensionList { + get { return PrepareBuilder().packedExtension_; } + } + public int PackedExtensionCount { + get { return result.PackedExtensionCount; } + } + public int GetPackedExtension(int index) { + return result.GetPackedExtension(index); + } + public Builder SetPackedExtension(int index, int value) { + PrepareBuilder(); + result.packedExtension_[index] = value; + return this; + } + public Builder AddPackedExtension(int value) { + PrepareBuilder(); + result.packedExtension_.Add(value); + return this; + } + public Builder AddRangePackedExtension(scg::IEnumerable values) { + PrepareBuilder(); + result.packedExtension_.Add(values); + return this; + } + public Builder ClearPackedExtension() { + PrepareBuilder(); + result.packedExtension_.Clear(); + return this; + } + } + static TestDynamicExtensions() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestRepeatedScalarDifferentTagSizes : pb::GeneratedMessage { + private TestRepeatedScalarDifferentTagSizes() { } + private static readonly TestRepeatedScalarDifferentTagSizes defaultInstance = new TestRepeatedScalarDifferentTagSizes().MakeReadOnly(); + private static readonly string[] _testRepeatedScalarDifferentTagSizesFieldNames = new string[] { "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_int32", "repeated_int64", "repeated_uint64" }; + private static readonly uint[] _testRepeatedScalarDifferentTagSizesFieldTags = new uint[] { 101, 16369, 2097141, 104, 16376, 2097144 }; + public static TestRepeatedScalarDifferentTagSizes DefaultInstance { + get { return defaultInstance; } + } + + public override TestRepeatedScalarDifferentTagSizes DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestRepeatedScalarDifferentTagSizes ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable; } + } + + public const int RepeatedFixed32FieldNumber = 12; + private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedFixed32List { + get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } + } + public int RepeatedFixed32Count { + get { return repeatedFixed32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedFixed32(int index) { + return repeatedFixed32_[index]; + } + + public const int RepeatedInt32FieldNumber = 13; + private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); + public scg::IList RepeatedInt32List { + get { return pbc::Lists.AsReadOnly(repeatedInt32_); } + } + public int RepeatedInt32Count { + get { return repeatedInt32_.Count; } + } + public int GetRepeatedInt32(int index) { + return repeatedInt32_[index]; + } + + public const int RepeatedFixed64FieldNumber = 2046; + private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedFixed64List { + get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } + } + public int RepeatedFixed64Count { + get { return repeatedFixed64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedFixed64(int index) { + return repeatedFixed64_[index]; + } + + public const int RepeatedInt64FieldNumber = 2047; + private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); + public scg::IList RepeatedInt64List { + get { return pbc::Lists.AsReadOnly(repeatedInt64_); } + } + public int RepeatedInt64Count { + get { return repeatedInt64_.Count; } + } + public long GetRepeatedInt64(int index) { + return repeatedInt64_[index]; + } + + public const int RepeatedFloatFieldNumber = 262142; + private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); + public scg::IList RepeatedFloatList { + get { return pbc::Lists.AsReadOnly(repeatedFloat_); } + } + public int RepeatedFloatCount { + get { return repeatedFloat_.Count; } + } + public float GetRepeatedFloat(int index) { + return repeatedFloat_[index]; + } + + public const int RepeatedUint64FieldNumber = 262143; + private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedUint64List { + get { return pbc::Lists.AsReadOnly(repeatedUint64_); } + } + public int RepeatedUint64Count { + get { return repeatedUint64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedUint64(int index) { + return repeatedUint64_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testRepeatedScalarDifferentTagSizesFieldNames; + if (repeatedFixed32_.Count > 0) { + output.WriteFixed32Array(12, field_names[0], repeatedFixed32_); + } + if (repeatedInt32_.Count > 0) { + output.WriteInt32Array(13, field_names[3], repeatedInt32_); + } + if (repeatedFixed64_.Count > 0) { + output.WriteFixed64Array(2046, field_names[1], repeatedFixed64_); + } + if (repeatedInt64_.Count > 0) { + output.WriteInt64Array(2047, field_names[4], repeatedInt64_); + } + if (repeatedFloat_.Count > 0) { + output.WriteFloatArray(262142, field_names[2], repeatedFloat_); + } + if (repeatedUint64_.Count > 0) { + output.WriteUInt64Array(262143, field_names[5], repeatedUint64_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + dataSize = 4 * repeatedFixed32_.Count; + size += dataSize; + size += 1 * repeatedFixed32_.Count; + } + { + int dataSize = 0; + foreach (int element in RepeatedInt32List) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 1 * repeatedInt32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedFixed64_.Count; + size += dataSize; + size += 2 * repeatedFixed64_.Count; + } + { + int dataSize = 0; + foreach (long element in RepeatedInt64List) { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedInt64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedFloat_.Count; + size += dataSize; + size += 3 * repeatedFloat_.Count; + } + { + int dataSize = 0; + foreach (ulong element in RepeatedUint64List) { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); + } + size += dataSize; + size += 3 * repeatedUint64_.Count; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestRepeatedScalarDifferentTagSizes MakeReadOnly() { + repeatedFixed32_.MakeReadOnly(); + repeatedInt32_.MakeReadOnly(); + repeatedFixed64_.MakeReadOnly(); + repeatedInt64_.MakeReadOnly(); + repeatedFloat_.MakeReadOnly(); + repeatedUint64_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestRepeatedScalarDifferentTagSizes prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRepeatedScalarDifferentTagSizes cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestRepeatedScalarDifferentTagSizes result; + + private TestRepeatedScalarDifferentTagSizes PrepareBuilder() { + if (resultIsReadOnly) { + TestRepeatedScalarDifferentTagSizes original = result; + result = new TestRepeatedScalarDifferentTagSizes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestRepeatedScalarDifferentTagSizes MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.Descriptor; } + } + + public override TestRepeatedScalarDifferentTagSizes DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.DefaultInstance; } + } + + public override TestRepeatedScalarDifferentTagSizes BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestRepeatedScalarDifferentTagSizes) { + return MergeFrom((TestRepeatedScalarDifferentTagSizes) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestRepeatedScalarDifferentTagSizes other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.DefaultInstance) return this; + PrepareBuilder(); + if (other.repeatedFixed32_.Count != 0) { + result.repeatedFixed32_.Add(other.repeatedFixed32_); + } + if (other.repeatedInt32_.Count != 0) { + result.repeatedInt32_.Add(other.repeatedInt32_); + } + if (other.repeatedFixed64_.Count != 0) { + result.repeatedFixed64_.Add(other.repeatedFixed64_); + } + if (other.repeatedInt64_.Count != 0) { + result.repeatedInt64_.Add(other.repeatedInt64_); + } + if (other.repeatedFloat_.Count != 0) { + result.repeatedFloat_.Add(other.repeatedFloat_); + } + if (other.repeatedUint64_.Count != 0) { + result.repeatedUint64_.Add(other.repeatedUint64_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testRepeatedScalarDifferentTagSizesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testRepeatedScalarDifferentTagSizesFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 98: + case 101: { + input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); + break; + } + case 106: + case 104: { + input.ReadInt32Array(tag, field_name, result.repeatedInt32_); + break; + } + case 16370: + case 16369: { + input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); + break; + } + case 16378: + case 16376: { + input.ReadInt64Array(tag, field_name, result.repeatedInt64_); + break; + } + case 2097138: + case 2097141: { + input.ReadFloatArray(tag, field_name, result.repeatedFloat_); + break; + } + case 2097146: + case 2097144: { + input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedFixed32List { + get { return PrepareBuilder().repeatedFixed32_; } + } + public int RepeatedFixed32Count { + get { return result.RepeatedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedFixed32(int index) { + return result.GetRepeatedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedFixed32(int index, uint value) { + PrepareBuilder(); + result.repeatedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedFixed32(uint value) { + PrepareBuilder(); + result.repeatedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedFixed32_.Add(values); + return this; + } + public Builder ClearRepeatedFixed32() { + PrepareBuilder(); + result.repeatedFixed32_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedInt32List { + get { return PrepareBuilder().repeatedInt32_; } + } + public int RepeatedInt32Count { + get { return result.RepeatedInt32Count; } + } + public int GetRepeatedInt32(int index) { + return result.GetRepeatedInt32(index); + } + public Builder SetRepeatedInt32(int index, int value) { + PrepareBuilder(); + result.repeatedInt32_[index] = value; + return this; + } + public Builder AddRepeatedInt32(int value) { + PrepareBuilder(); + result.repeatedInt32_.Add(value); + return this; + } + public Builder AddRangeRepeatedInt32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedInt32_.Add(values); + return this; + } + public Builder ClearRepeatedInt32() { + PrepareBuilder(); + result.repeatedInt32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedFixed64List { + get { return PrepareBuilder().repeatedFixed64_; } + } + public int RepeatedFixed64Count { + get { return result.RepeatedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedFixed64(int index) { + return result.GetRepeatedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedFixed64(int index, ulong value) { + PrepareBuilder(); + result.repeatedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedFixed64(ulong value) { + PrepareBuilder(); + result.repeatedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedFixed64_.Add(values); + return this; + } + public Builder ClearRepeatedFixed64() { + PrepareBuilder(); + result.repeatedFixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedInt64List { + get { return PrepareBuilder().repeatedInt64_; } + } + public int RepeatedInt64Count { + get { return result.RepeatedInt64Count; } + } + public long GetRepeatedInt64(int index) { + return result.GetRepeatedInt64(index); + } + public Builder SetRepeatedInt64(int index, long value) { + PrepareBuilder(); + result.repeatedInt64_[index] = value; + return this; + } + public Builder AddRepeatedInt64(long value) { + PrepareBuilder(); + result.repeatedInt64_.Add(value); + return this; + } + public Builder AddRangeRepeatedInt64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedInt64_.Add(values); + return this; + } + public Builder ClearRepeatedInt64() { + PrepareBuilder(); + result.repeatedInt64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedFloatList { + get { return PrepareBuilder().repeatedFloat_; } + } + public int RepeatedFloatCount { + get { return result.RepeatedFloatCount; } + } + public float GetRepeatedFloat(int index) { + return result.GetRepeatedFloat(index); + } + public Builder SetRepeatedFloat(int index, float value) { + PrepareBuilder(); + result.repeatedFloat_[index] = value; + return this; + } + public Builder AddRepeatedFloat(float value) { + PrepareBuilder(); + result.repeatedFloat_.Add(value); + return this; + } + public Builder AddRangeRepeatedFloat(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedFloat_.Add(values); + return this; + } + public Builder ClearRepeatedFloat() { + PrepareBuilder(); + result.repeatedFloat_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedUint64List { + get { return PrepareBuilder().repeatedUint64_; } + } + public int RepeatedUint64Count { + get { return result.RepeatedUint64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedUint64(int index) { + return result.GetRepeatedUint64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedUint64(int index, ulong value) { + PrepareBuilder(); + result.repeatedUint64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedUint64(ulong value) { + PrepareBuilder(); + result.repeatedUint64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedUint64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedUint64_.Add(values); + return this; + } + public Builder ClearRepeatedUint64() { + PrepareBuilder(); + result.repeatedUint64_.Clear(); + return this; + } + } + static TestRepeatedScalarDifferentTagSizes() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestParsingMerge : pb::ExtendableMessage { + private TestParsingMerge() { } + private static readonly TestParsingMerge defaultInstance = new TestParsingMerge().MakeReadOnly(); + private static readonly string[] _testParsingMergeFieldNames = new string[] { "optional_all_types", "optionalgroup", "repeated_all_types", "repeatedgroup", "required_all_types" }; + private static readonly uint[] _testParsingMergeFieldTags = new uint[] { 18, 83, 26, 163, 10 }; + public static TestParsingMerge DefaultInstance { + get { return defaultInstance; } + } + + public override TestParsingMerge DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestParsingMerge ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge__FieldAccessorTable; } + } + + public const int OptionalExtFieldNumber = 1000; + public static pb::GeneratedExtensionBase OptionalExt; + public const int RepeatedExtFieldNumber = 1001; + public static pb::GeneratedExtensionBase> RepeatedExt; + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedFieldsGenerator : pb::GeneratedMessage { + private RepeatedFieldsGenerator() { } + private static readonly RepeatedFieldsGenerator defaultInstance = new RepeatedFieldsGenerator().MakeReadOnly(); + private static readonly string[] _repeatedFieldsGeneratorFieldNames = new string[] { "ext1", "ext2", "field1", "field2", "field3", "group1", "group2" }; + private static readonly uint[] _repeatedFieldsGeneratorFieldTags = new uint[] { 8002, 8010, 10, 18, 26, 83, 163 }; + public static RepeatedFieldsGenerator DefaultInstance { + get { return defaultInstance; } + } + + public override RepeatedFieldsGenerator DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override RepeatedFieldsGenerator ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Group1 : pb::GeneratedMessage { + private Group1() { } + private static readonly Group1 defaultInstance = new Group1().MakeReadOnly(); + private static readonly string[] _group1FieldNames = new string[] { "field1" }; + private static readonly uint[] _group1FieldTags = new uint[] { 90 }; + public static Group1 DefaultInstance { + get { return defaultInstance; } + } + + public override Group1 DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Group1 ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__FieldAccessorTable; } + } + + public const int Field1FieldNumber = 11; + private bool hasField1; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes field1_; + public bool HasField1 { + get { return hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 { + get { return field1_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _group1FieldNames; + if (hasField1) { + output.WriteMessage(11, field_names[0], Field1); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasField1) { + size += pb::CodedOutputStream.ComputeMessageSize(11, Field1); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Group1 ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group1 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group1 ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group1 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group1 ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group1 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Group1 ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Group1 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Group1 ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group1 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Group1 MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Group1 prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Group1 cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Group1 result; + + private Group1 PrepareBuilder() { + if (resultIsReadOnly) { + Group1 original = result; + result = new Group1(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Group1 MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.Descriptor; } + } + + public override Group1 DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance; } + } + + public override Group1 BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is Group1) { + return MergeFrom((Group1) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Group1 other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasField1) { + MergeField1(other.Field1); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_group1FieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _group1FieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 90: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasField1) { + subBuilder.MergeFrom(Field1); + } + input.ReadMessage(subBuilder, extensionRegistry); + Field1 = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasField1 { + get { return result.hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 { + get { return result.Field1; } + set { SetField1(value); } + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = value; + return this; + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = builderForValue.Build(); + return this; + } + public Builder MergeField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasField1 && + result.field1_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.field1_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.field1_).MergeFrom(value).BuildPartial(); + } else { + result.field1_ = value; + } + result.hasField1 = true; + return this; + } + public Builder ClearField1() { + PrepareBuilder(); + result.hasField1 = false; + result.field1_ = null; + return this; + } + } + static Group1() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Group2 : pb::GeneratedMessage { + private Group2() { } + private static readonly Group2 defaultInstance = new Group2().MakeReadOnly(); + private static readonly string[] _group2FieldNames = new string[] { "field1" }; + private static readonly uint[] _group2FieldTags = new uint[] { 170 }; + public static Group2 DefaultInstance { + get { return defaultInstance; } + } + + public override Group2 DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Group2 ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__FieldAccessorTable; } + } + + public const int Field1FieldNumber = 21; + private bool hasField1; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes field1_; + public bool HasField1 { + get { return hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 { + get { return field1_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _group2FieldNames; + if (hasField1) { + output.WriteMessage(21, field_names[0], Field1); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasField1) { + size += pb::CodedOutputStream.ComputeMessageSize(21, Field1); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Group2 ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group2 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group2 ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group2 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group2 ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group2 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Group2 ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Group2 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Group2 ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group2 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Group2 MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Group2 prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Group2 cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Group2 result; + + private Group2 PrepareBuilder() { + if (resultIsReadOnly) { + Group2 original = result; + result = new Group2(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Group2 MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.Descriptor; } + } + + public override Group2 DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance; } + } + + public override Group2 BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is Group2) { + return MergeFrom((Group2) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Group2 other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasField1) { + MergeField1(other.Field1); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_group2FieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _group2FieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 170: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasField1) { + subBuilder.MergeFrom(Field1); + } + input.ReadMessage(subBuilder, extensionRegistry); + Field1 = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasField1 { + get { return result.hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 { + get { return result.Field1; } + set { SetField1(value); } + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = value; + return this; + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = builderForValue.Build(); + return this; + } + public Builder MergeField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasField1 && + result.field1_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.field1_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.field1_).MergeFrom(value).BuildPartial(); + } else { + result.field1_ = value; + } + result.hasField1 = true; + return this; + } + public Builder ClearField1() { + PrepareBuilder(); + result.hasField1 = false; + result.field1_ = null; + return this; + } + } + static Group2() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int Field1FieldNumber = 1; + private pbc::PopsicleList field1_ = new pbc::PopsicleList(); + public scg::IList Field1List { + get { return field1_; } + } + public int Field1Count { + get { return field1_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField1(int index) { + return field1_[index]; + } + + public const int Field2FieldNumber = 2; + private pbc::PopsicleList field2_ = new pbc::PopsicleList(); + public scg::IList Field2List { + get { return field2_; } + } + public int Field2Count { + get { return field2_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField2(int index) { + return field2_[index]; + } + + public const int Field3FieldNumber = 3; + private pbc::PopsicleList field3_ = new pbc::PopsicleList(); + public scg::IList Field3List { + get { return field3_; } + } + public int Field3Count { + get { return field3_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField3(int index) { + return field3_[index]; + } + + public const int Group1FieldNumber = 10; + private pbc::PopsicleList group1_ = new pbc::PopsicleList(); + public scg::IList Group1List { + get { return group1_; } + } + public int Group1Count { + get { return group1_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 GetGroup1(int index) { + return group1_[index]; + } + + public const int Group2FieldNumber = 20; + private pbc::PopsicleList group2_ = new pbc::PopsicleList(); + public scg::IList Group2List { + get { return group2_; } + } + public int Group2Count { + get { return group2_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 GetGroup2(int index) { + return group2_[index]; + } + + public const int Ext1FieldNumber = 1000; + private pbc::PopsicleList ext1_ = new pbc::PopsicleList(); + public scg::IList Ext1List { + get { return ext1_; } + } + public int Ext1Count { + get { return ext1_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt1(int index) { + return ext1_[index]; + } + + public const int Ext2FieldNumber = 1001; + private pbc::PopsicleList ext2_ = new pbc::PopsicleList(); + public scg::IList Ext2List { + get { return ext2_; } + } + public int Ext2Count { + get { return ext2_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt2(int index) { + return ext2_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _repeatedFieldsGeneratorFieldNames; + if (field1_.Count > 0) { + output.WriteMessageArray(1, field_names[2], field1_); + } + if (field2_.Count > 0) { + output.WriteMessageArray(2, field_names[3], field2_); + } + if (field3_.Count > 0) { + output.WriteMessageArray(3, field_names[4], field3_); + } + if (group1_.Count > 0) { + output.WriteGroupArray(10, field_names[5], group1_); + } + if (group2_.Count > 0) { + output.WriteGroupArray(20, field_names[6], group2_); + } + if (ext1_.Count > 0) { + output.WriteMessageArray(1000, field_names[0], ext1_); + } + if (ext2_.Count > 0) { + output.WriteMessageArray(1001, field_names[1], ext2_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Field1List) { + size += pb::CodedOutputStream.ComputeMessageSize(1, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Field2List) { + size += pb::CodedOutputStream.ComputeMessageSize(2, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Field3List) { + size += pb::CodedOutputStream.ComputeMessageSize(3, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 element in Group1List) { + size += pb::CodedOutputStream.ComputeGroupSize(10, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 element in Group2List) { + size += pb::CodedOutputStream.ComputeGroupSize(20, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Ext1List) { + size += pb::CodedOutputStream.ComputeMessageSize(1000, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Ext2List) { + size += pb::CodedOutputStream.ComputeMessageSize(1001, element); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static RepeatedFieldsGenerator ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedFieldsGenerator MakeReadOnly() { + field1_.MakeReadOnly(); + field2_.MakeReadOnly(); + field3_.MakeReadOnly(); + group1_.MakeReadOnly(); + group2_.MakeReadOnly(); + ext1_.MakeReadOnly(); + ext2_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedFieldsGenerator prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedFieldsGenerator cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private RepeatedFieldsGenerator result; + + private RepeatedFieldsGenerator PrepareBuilder() { + if (resultIsReadOnly) { + RepeatedFieldsGenerator original = result; + result = new RepeatedFieldsGenerator(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override RepeatedFieldsGenerator MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Descriptor; } + } + + public override RepeatedFieldsGenerator DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.DefaultInstance; } + } + + public override RepeatedFieldsGenerator BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is RepeatedFieldsGenerator) { + return MergeFrom((RepeatedFieldsGenerator) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(RepeatedFieldsGenerator other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.DefaultInstance) return this; + PrepareBuilder(); + if (other.field1_.Count != 0) { + result.field1_.Add(other.field1_); + } + if (other.field2_.Count != 0) { + result.field2_.Add(other.field2_); + } + if (other.field3_.Count != 0) { + result.field3_.Add(other.field3_); + } + if (other.group1_.Count != 0) { + result.group1_.Add(other.group1_); + } + if (other.group2_.Count != 0) { + result.group2_.Add(other.group2_); + } + if (other.ext1_.Count != 0) { + result.ext1_.Add(other.ext1_); + } + if (other.ext2_.Count != 0) { + result.ext2_.Add(other.ext2_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_repeatedFieldsGeneratorFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _repeatedFieldsGeneratorFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + input.ReadMessageArray(tag, field_name, result.field1_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + case 18: { + input.ReadMessageArray(tag, field_name, result.field2_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + case 26: { + input.ReadMessageArray(tag, field_name, result.field3_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + case 83: { + input.ReadGroupArray(tag, field_name, result.group1_, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance, extensionRegistry); + break; + } + case 163: { + input.ReadGroupArray(tag, field_name, result.group2_, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance, extensionRegistry); + break; + } + case 8002: { + input.ReadMessageArray(tag, field_name, result.ext1_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + case 8010: { + input.ReadMessageArray(tag, field_name, result.ext2_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList Field1List { + get { return PrepareBuilder().field1_; } + } + public int Field1Count { + get { return result.Field1Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField1(int index) { + return result.GetField1(index); + } + public Builder SetField1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field1_[index] = value; + return this; + } + public Builder SetField1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field1_[index] = builderForValue.Build(); + return this; + } + public Builder AddField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field1_.Add(value); + return this; + } + public Builder AddField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field1_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeField1(scg::IEnumerable values) { + PrepareBuilder(); + result.field1_.Add(values); + return this; + } + public Builder ClearField1() { + PrepareBuilder(); + result.field1_.Clear(); + return this; + } + + public pbc::IPopsicleList Field2List { + get { return PrepareBuilder().field2_; } + } + public int Field2Count { + get { return result.Field2Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField2(int index) { + return result.GetField2(index); + } + public Builder SetField2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field2_[index] = value; + return this; + } + public Builder SetField2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field2_[index] = builderForValue.Build(); + return this; + } + public Builder AddField2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field2_.Add(value); + return this; + } + public Builder AddField2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field2_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeField2(scg::IEnumerable values) { + PrepareBuilder(); + result.field2_.Add(values); + return this; + } + public Builder ClearField2() { + PrepareBuilder(); + result.field2_.Clear(); + return this; + } + + public pbc::IPopsicleList Field3List { + get { return PrepareBuilder().field3_; } + } + public int Field3Count { + get { return result.Field3Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField3(int index) { + return result.GetField3(index); + } + public Builder SetField3(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field3_[index] = value; + return this; + } + public Builder SetField3(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field3_[index] = builderForValue.Build(); + return this; + } + public Builder AddField3(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field3_.Add(value); + return this; + } + public Builder AddField3(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field3_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeField3(scg::IEnumerable values) { + PrepareBuilder(); + result.field3_.Add(values); + return this; + } + public Builder ClearField3() { + PrepareBuilder(); + result.field3_.Clear(); + return this; + } + + public pbc::IPopsicleList Group1List { + get { return PrepareBuilder().group1_; } + } + public int Group1Count { + get { return result.Group1Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 GetGroup1(int index) { + return result.GetGroup1(index); + } + public Builder SetGroup1(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group1_[index] = value; + return this; + } + public Builder SetGroup1(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group1_[index] = builderForValue.Build(); + return this; + } + public Builder AddGroup1(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group1_.Add(value); + return this; + } + public Builder AddGroup1(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group1_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeGroup1(scg::IEnumerable values) { + PrepareBuilder(); + result.group1_.Add(values); + return this; + } + public Builder ClearGroup1() { + PrepareBuilder(); + result.group1_.Clear(); + return this; + } + + public pbc::IPopsicleList Group2List { + get { return PrepareBuilder().group2_; } + } + public int Group2Count { + get { return result.Group2Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 GetGroup2(int index) { + return result.GetGroup2(index); + } + public Builder SetGroup2(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group2_[index] = value; + return this; + } + public Builder SetGroup2(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group2_[index] = builderForValue.Build(); + return this; + } + public Builder AddGroup2(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group2_.Add(value); + return this; + } + public Builder AddGroup2(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group2_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeGroup2(scg::IEnumerable values) { + PrepareBuilder(); + result.group2_.Add(values); + return this; + } + public Builder ClearGroup2() { + PrepareBuilder(); + result.group2_.Clear(); + return this; + } + + public pbc::IPopsicleList Ext1List { + get { return PrepareBuilder().ext1_; } + } + public int Ext1Count { + get { return result.Ext1Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt1(int index) { + return result.GetExt1(index); + } + public Builder SetExt1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext1_[index] = value; + return this; + } + public Builder SetExt1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext1_[index] = builderForValue.Build(); + return this; + } + public Builder AddExt1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext1_.Add(value); + return this; + } + public Builder AddExt1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext1_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeExt1(scg::IEnumerable values) { + PrepareBuilder(); + result.ext1_.Add(values); + return this; + } + public Builder ClearExt1() { + PrepareBuilder(); + result.ext1_.Clear(); + return this; + } + + public pbc::IPopsicleList Ext2List { + get { return PrepareBuilder().ext2_; } + } + public int Ext2Count { + get { return result.Ext2Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt2(int index) { + return result.GetExt2(index); + } + public Builder SetExt2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext2_[index] = value; + return this; + } + public Builder SetExt2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext2_[index] = builderForValue.Build(); + return this; + } + public Builder AddExt2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext2_.Add(value); + return this; + } + public Builder AddExt2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext2_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeExt2(scg::IEnumerable values) { + PrepareBuilder(); + result.ext2_.Add(values); + return this; + } + public Builder ClearExt2() { + PrepareBuilder(); + result.ext2_.Clear(); + return this; + } + } + static RepeatedFieldsGenerator() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OptionalGroup : pb::GeneratedMessage { + private OptionalGroup() { } + private static readonly OptionalGroup defaultInstance = new OptionalGroup().MakeReadOnly(); + private static readonly string[] _optionalGroupFieldNames = new string[] { "optional_group_all_types" }; + private static readonly uint[] _optionalGroupFieldTags = new uint[] { 90 }; + public static OptionalGroup DefaultInstance { + get { return defaultInstance; } + } + + public override OptionalGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override OptionalGroup ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__FieldAccessorTable; } + } + + public const int OptionalGroupAllTypesFieldNumber = 11; + private bool hasOptionalGroupAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes optionalGroupAllTypes_; + public bool HasOptionalGroupAllTypes { + get { return hasOptionalGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalGroupAllTypes { + get { return optionalGroupAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _optionalGroupFieldNames; + if (hasOptionalGroupAllTypes) { + output.WriteMessage(11, field_names[0], OptionalGroupAllTypes); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOptionalGroupAllTypes) { + size += pb::CodedOutputStream.ComputeMessageSize(11, OptionalGroupAllTypes); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static OptionalGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OptionalGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OptionalGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OptionalGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OptionalGroup result; + + private OptionalGroup PrepareBuilder() { + if (resultIsReadOnly) { + OptionalGroup original = result; + result = new OptionalGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override OptionalGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.Descriptor; } + } + + public override OptionalGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance; } + } + + public override OptionalGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is OptionalGroup) { + return MergeFrom((OptionalGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OptionalGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOptionalGroupAllTypes) { + MergeOptionalGroupAllTypes(other.OptionalGroupAllTypes); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _optionalGroupFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 90: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasOptionalGroupAllTypes) { + subBuilder.MergeFrom(OptionalGroupAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalGroupAllTypes = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasOptionalGroupAllTypes { + get { return result.hasOptionalGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalGroupAllTypes { + get { return result.OptionalGroupAllTypes; } + set { SetOptionalGroupAllTypes(value); } + } + public Builder SetOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalGroupAllTypes = true; + result.optionalGroupAllTypes_ = value; + return this; + } + public Builder SetOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalGroupAllTypes = true; + result.optionalGroupAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalGroupAllTypes && + result.optionalGroupAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.optionalGroupAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.optionalGroupAllTypes_).MergeFrom(value).BuildPartial(); + } else { + result.optionalGroupAllTypes_ = value; + } + result.hasOptionalGroupAllTypes = true; + return this; + } + public Builder ClearOptionalGroupAllTypes() { + PrepareBuilder(); + result.hasOptionalGroupAllTypes = false; + result.optionalGroupAllTypes_ = null; + return this; + } + } + static OptionalGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedGroup : pb::GeneratedMessage { + private RepeatedGroup() { } + private static readonly RepeatedGroup defaultInstance = new RepeatedGroup().MakeReadOnly(); + private static readonly string[] _repeatedGroupFieldNames = new string[] { "repeated_group_all_types" }; + private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 170 }; + public static RepeatedGroup DefaultInstance { + get { return defaultInstance; } + } + + public override RepeatedGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override RepeatedGroup ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__FieldAccessorTable; } + } + + public const int RepeatedGroupAllTypesFieldNumber = 21; + private bool hasRepeatedGroupAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes repeatedGroupAllTypes_; + public bool HasRepeatedGroupAllTypes { + get { return hasRepeatedGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RepeatedGroupAllTypes { + get { return repeatedGroupAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _repeatedGroupFieldNames; + if (hasRepeatedGroupAllTypes) { + output.WriteMessage(21, field_names[0], RepeatedGroupAllTypes); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasRepeatedGroupAllTypes) { + size += pb::CodedOutputStream.ComputeMessageSize(21, RepeatedGroupAllTypes); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static RepeatedGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private RepeatedGroup result; + + private RepeatedGroup PrepareBuilder() { + if (resultIsReadOnly) { + RepeatedGroup original = result; + result = new RepeatedGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override RepeatedGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.Descriptor; } + } + + public override RepeatedGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.DefaultInstance; } + } + + public override RepeatedGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is RepeatedGroup) { + return MergeFrom((RepeatedGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(RepeatedGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasRepeatedGroupAllTypes) { + MergeRepeatedGroupAllTypes(other.RepeatedGroupAllTypes); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _repeatedGroupFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 170: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasRepeatedGroupAllTypes) { + subBuilder.MergeFrom(RepeatedGroupAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + RepeatedGroupAllTypes = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasRepeatedGroupAllTypes { + get { return result.hasRepeatedGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RepeatedGroupAllTypes { + get { return result.RepeatedGroupAllTypes; } + set { SetRepeatedGroupAllTypes(value); } + } + public Builder SetRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasRepeatedGroupAllTypes = true; + result.repeatedGroupAllTypes_ = value; + return this; + } + public Builder SetRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasRepeatedGroupAllTypes = true; + result.repeatedGroupAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasRepeatedGroupAllTypes && + result.repeatedGroupAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.repeatedGroupAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.repeatedGroupAllTypes_).MergeFrom(value).BuildPartial(); + } else { + result.repeatedGroupAllTypes_ = value; + } + result.hasRepeatedGroupAllTypes = true; + return this; + } + public Builder ClearRepeatedGroupAllTypes() { + PrepareBuilder(); + result.hasRepeatedGroupAllTypes = false; + result.repeatedGroupAllTypes_ = null; + return this; + } + } + static RepeatedGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int RequiredAllTypesFieldNumber = 1; + private bool hasRequiredAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes requiredAllTypes_; + public bool HasRequiredAllTypes { + get { return hasRequiredAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RequiredAllTypes { + get { return requiredAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public const int OptionalAllTypesFieldNumber = 2; + private bool hasOptionalAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes optionalAllTypes_; + public bool HasOptionalAllTypes { + get { return hasOptionalAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalAllTypes { + get { return optionalAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public const int RepeatedAllTypesFieldNumber = 3; + private pbc::PopsicleList repeatedAllTypes_ = new pbc::PopsicleList(); + public scg::IList RepeatedAllTypesList { + get { return repeatedAllTypes_; } + } + public int RepeatedAllTypesCount { + get { return repeatedAllTypes_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetRepeatedAllTypes(int index) { + return repeatedAllTypes_[index]; + } + + public const int OptionalGroupFieldNumber = 10; + private bool hasOptionalGroup; + private global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup optionalGroup_; + public bool HasOptionalGroup { + get { return hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup OptionalGroup { + get { return optionalGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance; } + } + + public const int RepeatedGroupFieldNumber = 20; + private pbc::PopsicleList repeatedGroup_ = new pbc::PopsicleList(); + public scg::IList RepeatedGroupList { + get { return repeatedGroup_; } + } + public int RepeatedGroupCount { + get { return repeatedGroup_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup GetRepeatedGroup(int index) { + return repeatedGroup_[index]; + } + + public override bool IsInitialized { + get { + if (!hasRequiredAllTypes) return false; + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testParsingMergeFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + if (hasRequiredAllTypes) { + output.WriteMessage(1, field_names[4], RequiredAllTypes); + } + if (hasOptionalAllTypes) { + output.WriteMessage(2, field_names[0], OptionalAllTypes); + } + if (repeatedAllTypes_.Count > 0) { + output.WriteMessageArray(3, field_names[2], repeatedAllTypes_); + } + if (hasOptionalGroup) { + output.WriteGroup(10, field_names[1], OptionalGroup); + } + if (repeatedGroup_.Count > 0) { + output.WriteGroupArray(20, field_names[3], repeatedGroup_); + } + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasRequiredAllTypes) { + size += pb::CodedOutputStream.ComputeMessageSize(1, RequiredAllTypes); + } + if (hasOptionalAllTypes) { + size += pb::CodedOutputStream.ComputeMessageSize(2, OptionalAllTypes); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in RepeatedAllTypesList) { + size += pb::CodedOutputStream.ComputeMessageSize(3, element); + } + if (hasOptionalGroup) { + size += pb::CodedOutputStream.ComputeGroupSize(10, OptionalGroup); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup element in RepeatedGroupList) { + size += pb::CodedOutputStream.ComputeGroupSize(20, element); + } + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestParsingMerge ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestParsingMerge ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestParsingMerge ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestParsingMerge ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestParsingMerge ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestParsingMerge ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestParsingMerge ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestParsingMerge ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestParsingMerge ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestParsingMerge ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestParsingMerge MakeReadOnly() { + repeatedAllTypes_.MakeReadOnly(); + repeatedGroup_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestParsingMerge prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestParsingMerge cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestParsingMerge result; + + private TestParsingMerge PrepareBuilder() { + if (resultIsReadOnly) { + TestParsingMerge original = result; + result = new TestParsingMerge(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestParsingMerge MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Descriptor; } + } + + public override TestParsingMerge DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.DefaultInstance; } + } + + public override TestParsingMerge BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestParsingMerge) { + return MergeFrom((TestParsingMerge) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestParsingMerge other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasRequiredAllTypes) { + MergeRequiredAllTypes(other.RequiredAllTypes); + } + if (other.HasOptionalAllTypes) { + MergeOptionalAllTypes(other.OptionalAllTypes); + } + if (other.repeatedAllTypes_.Count != 0) { + result.repeatedAllTypes_.Add(other.repeatedAllTypes_); + } + if (other.HasOptionalGroup) { + MergeOptionalGroup(other.OptionalGroup); + } + if (other.repeatedGroup_.Count != 0) { + result.repeatedGroup_.Add(other.repeatedGroup_); + } + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testParsingMergeFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testParsingMergeFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasRequiredAllTypes) { + subBuilder.MergeFrom(RequiredAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + RequiredAllTypes = subBuilder.BuildPartial(); + break; + } + case 18: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasOptionalAllTypes) { + subBuilder.MergeFrom(OptionalAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalAllTypes = subBuilder.BuildPartial(); + break; + } + case 26: { + input.ReadMessageArray(tag, field_name, result.repeatedAllTypes_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + case 83: { + global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.CreateBuilder(); + if (result.hasOptionalGroup) { + subBuilder.MergeFrom(OptionalGroup); + } + input.ReadGroup(10, subBuilder, extensionRegistry); + OptionalGroup = subBuilder.BuildPartial(); + break; + } + case 163: { + input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.DefaultInstance, extensionRegistry); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasRequiredAllTypes { + get { return result.hasRequiredAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RequiredAllTypes { + get { return result.RequiredAllTypes; } + set { SetRequiredAllTypes(value); } + } + public Builder SetRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasRequiredAllTypes = true; + result.requiredAllTypes_ = value; + return this; + } + public Builder SetRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasRequiredAllTypes = true; + result.requiredAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasRequiredAllTypes && + result.requiredAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.requiredAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.requiredAllTypes_).MergeFrom(value).BuildPartial(); + } else { + result.requiredAllTypes_ = value; + } + result.hasRequiredAllTypes = true; + return this; + } + public Builder ClearRequiredAllTypes() { + PrepareBuilder(); + result.hasRequiredAllTypes = false; + result.requiredAllTypes_ = null; + return this; + } + + public bool HasOptionalAllTypes { + get { return result.hasOptionalAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalAllTypes { + get { return result.OptionalAllTypes; } + set { SetOptionalAllTypes(value); } + } + public Builder SetOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalAllTypes = true; + result.optionalAllTypes_ = value; + return this; + } + public Builder SetOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalAllTypes = true; + result.optionalAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalAllTypes && + result.optionalAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.optionalAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.optionalAllTypes_).MergeFrom(value).BuildPartial(); + } else { + result.optionalAllTypes_ = value; + } + result.hasOptionalAllTypes = true; + return this; + } + public Builder ClearOptionalAllTypes() { + PrepareBuilder(); + result.hasOptionalAllTypes = false; + result.optionalAllTypes_ = null; + return this; + } + + public pbc::IPopsicleList RepeatedAllTypesList { + get { return PrepareBuilder().repeatedAllTypes_; } + } + public int RepeatedAllTypesCount { + get { return result.RepeatedAllTypesCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetRepeatedAllTypes(int index) { + return result.GetRepeatedAllTypes(index); + } + public Builder SetRepeatedAllTypes(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedAllTypes_[index] = value; + return this; + } + public Builder SetRepeatedAllTypes(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedAllTypes_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedAllTypes_.Add(value); + return this; + } + public Builder AddRepeatedAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedAllTypes_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedAllTypes(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedAllTypes_.Add(values); + return this; + } + public Builder ClearRepeatedAllTypes() { + PrepareBuilder(); + result.repeatedAllTypes_.Clear(); + return this; + } + + public bool HasOptionalGroup { + get { return result.hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup OptionalGroup { + get { return result.OptionalGroup; } + set { SetOptionalGroup(value); } + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = value; + return this; + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalGroup && + result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance) { + result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial(); + } else { + result.optionalGroup_ = value; + } + result.hasOptionalGroup = true; + return this; + } + public Builder ClearOptionalGroup() { + PrepareBuilder(); + result.hasOptionalGroup = false; + result.optionalGroup_ = null; + return this; + } + + public pbc::IPopsicleList RepeatedGroupList { + get { return PrepareBuilder().repeatedGroup_; } + } + public int RepeatedGroupCount { + get { return result.RepeatedGroupCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup GetRepeatedGroup(int index) { + return result.GetRepeatedGroup(index); + } + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_[index] = value; + return this; + } + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_.Add(value); + return this; + } + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedGroup(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedGroup_.Add(values); + return this; + } + public Builder ClearRepeatedGroup() { + PrepareBuilder(); + result.repeatedGroup_.Clear(); + return this; + } + } + static TestParsingMerge() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestCommentInjectionMessage : pb::GeneratedMessage { + private TestCommentInjectionMessage() { } + private static readonly TestCommentInjectionMessage defaultInstance = new TestCommentInjectionMessage().MakeReadOnly(); + private static readonly string[] _testCommentInjectionMessageFieldNames = new string[] { "a" }; + private static readonly uint[] _testCommentInjectionMessageFieldTags = new uint[] { 10 }; + public static TestCommentInjectionMessage DefaultInstance { + get { return defaultInstance; } + } + + public override TestCommentInjectionMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestCommentInjectionMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCommentInjectionMessage__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private string a_ = "*/ <- Neither should this."; + public bool HasA { + get { return hasA; } + } + public string A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testCommentInjectionMessageFieldNames; + if (hasA) { + output.WriteString(1, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeStringSize(1, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestCommentInjectionMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestCommentInjectionMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestCommentInjectionMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestCommentInjectionMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestCommentInjectionMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestCommentInjectionMessage result; + + private TestCommentInjectionMessage PrepareBuilder() { + if (resultIsReadOnly) { + TestCommentInjectionMessage original = result; + result = new TestCommentInjectionMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestCommentInjectionMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestCommentInjectionMessage.Descriptor; } + } + + public override TestCommentInjectionMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestCommentInjectionMessage.DefaultInstance; } + } + + public override TestCommentInjectionMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestCommentInjectionMessage) { + return MergeFrom((TestCommentInjectionMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestCommentInjectionMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestCommentInjectionMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testCommentInjectionMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testCommentInjectionMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + result.hasA = input.ReadString(ref result.a_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public string A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = "*/ <- Neither should this."; + return this; + } + } + static TestCommentInjectionMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooRequest : pb::GeneratedMessage { + private FooRequest() { } + private static readonly FooRequest defaultInstance = new FooRequest().MakeReadOnly(); + private static readonly string[] _fooRequestFieldNames = new string[] { }; + private static readonly uint[] _fooRequestFieldTags = new uint[] { }; + public static FooRequest DefaultInstance { + get { return defaultInstance; } + } + + public override FooRequest DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override FooRequest ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooRequest__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooRequest__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _fooRequestFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooRequest ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooRequest ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooRequest ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooRequest ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooRequest ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooRequest MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooRequest prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooRequest cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private FooRequest result; + + private FooRequest PrepareBuilder() { + if (resultIsReadOnly) { + FooRequest original = result; + result = new FooRequest(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override FooRequest MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.FooRequest.Descriptor; } + } + + public override FooRequest DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.FooRequest.DefaultInstance; } + } + + public override FooRequest BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is FooRequest) { + return MergeFrom((FooRequest) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(FooRequest other) { + if (other == global::Google.ProtocolBuffers.TestProtos.FooRequest.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_fooRequestFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _fooRequestFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static FooRequest() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooResponse : pb::GeneratedMessage { + private FooResponse() { } + private static readonly FooResponse defaultInstance = new FooResponse().MakeReadOnly(); + private static readonly string[] _fooResponseFieldNames = new string[] { }; + private static readonly uint[] _fooResponseFieldTags = new uint[] { }; + public static FooResponse DefaultInstance { + get { return defaultInstance; } + } + + public override FooResponse DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override FooResponse ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooResponse__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooResponse__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _fooResponseFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooResponse ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooResponse ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooResponse ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooResponse ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooResponse ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooResponse MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooResponse prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooResponse cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private FooResponse result; + + private FooResponse PrepareBuilder() { + if (resultIsReadOnly) { + FooResponse original = result; + result = new FooResponse(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override FooResponse MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.FooResponse.Descriptor; } + } + + public override FooResponse DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.FooResponse.DefaultInstance; } + } + + public override FooResponse BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is FooResponse) { + return MergeFrom((FooResponse) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(FooResponse other) { + if (other == global::Google.ProtocolBuffers.TestProtos.FooResponse.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_fooResponseFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _fooResponseFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static FooResponse() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooClientMessage : pb::GeneratedMessage { + private FooClientMessage() { } + private static readonly FooClientMessage defaultInstance = new FooClientMessage().MakeReadOnly(); + private static readonly string[] _fooClientMessageFieldNames = new string[] { }; + private static readonly uint[] _fooClientMessageFieldTags = new uint[] { }; + public static FooClientMessage DefaultInstance { + get { return defaultInstance; } + } + + public override FooClientMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override FooClientMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooClientMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooClientMessage__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _fooClientMessageFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooClientMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooClientMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooClientMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooClientMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooClientMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooClientMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooClientMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooClientMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooClientMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooClientMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooClientMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooClientMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooClientMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private FooClientMessage result; + + private FooClientMessage PrepareBuilder() { + if (resultIsReadOnly) { + FooClientMessage original = result; + result = new FooClientMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override FooClientMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.FooClientMessage.Descriptor; } + } + + public override FooClientMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.FooClientMessage.DefaultInstance; } + } + + public override FooClientMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is FooClientMessage) { + return MergeFrom((FooClientMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(FooClientMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.FooClientMessage.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_fooClientMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _fooClientMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static FooClientMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooServerMessage : pb::GeneratedMessage { + private FooServerMessage() { } + private static readonly FooServerMessage defaultInstance = new FooServerMessage().MakeReadOnly(); + private static readonly string[] _fooServerMessageFieldNames = new string[] { }; + private static readonly uint[] _fooServerMessageFieldTags = new uint[] { }; + public static FooServerMessage DefaultInstance { + get { return defaultInstance; } + } + + public override FooServerMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override FooServerMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooServerMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooServerMessage__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _fooServerMessageFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooServerMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooServerMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooServerMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooServerMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooServerMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooServerMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooServerMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooServerMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooServerMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooServerMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooServerMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooServerMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooServerMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private FooServerMessage result; + + private FooServerMessage PrepareBuilder() { + if (resultIsReadOnly) { + FooServerMessage original = result; + result = new FooServerMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override FooServerMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.FooServerMessage.Descriptor; } + } + + public override FooServerMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.FooServerMessage.DefaultInstance; } + } + + public override FooServerMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is FooServerMessage) { + return MergeFrom((FooServerMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(FooServerMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.FooServerMessage.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_fooServerMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _fooServerMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static FooServerMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class BarRequest : pb::GeneratedMessage { + private BarRequest() { } + private static readonly BarRequest defaultInstance = new BarRequest().MakeReadOnly(); + private static readonly string[] _barRequestFieldNames = new string[] { }; + private static readonly uint[] _barRequestFieldTags = new uint[] { }; + public static BarRequest DefaultInstance { + get { return defaultInstance; } + } + + public override BarRequest DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override BarRequest ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarRequest__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarRequest__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _barRequestFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static BarRequest ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BarRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BarRequest ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BarRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BarRequest ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BarRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static BarRequest ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static BarRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static BarRequest ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BarRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private BarRequest MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(BarRequest prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(BarRequest cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private BarRequest result; + + private BarRequest PrepareBuilder() { + if (resultIsReadOnly) { + BarRequest original = result; + result = new BarRequest(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override BarRequest MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.BarRequest.Descriptor; } + } + + public override BarRequest DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.BarRequest.DefaultInstance; } + } + + public override BarRequest BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is BarRequest) { + return MergeFrom((BarRequest) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(BarRequest other) { + if (other == global::Google.ProtocolBuffers.TestProtos.BarRequest.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_barRequestFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _barRequestFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static BarRequest() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class BarResponse : pb::GeneratedMessage { + private BarResponse() { } + private static readonly BarResponse defaultInstance = new BarResponse().MakeReadOnly(); + private static readonly string[] _barResponseFieldNames = new string[] { }; + private static readonly uint[] _barResponseFieldTags = new uint[] { }; + public static BarResponse DefaultInstance { + get { return defaultInstance; } + } + + public override BarResponse DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override BarResponse ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarResponse__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarResponse__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _barResponseFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static BarResponse ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BarResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BarResponse ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BarResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BarResponse ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BarResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static BarResponse ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static BarResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static BarResponse ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BarResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private BarResponse MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(BarResponse prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(BarResponse cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private BarResponse result; + + private BarResponse PrepareBuilder() { + if (resultIsReadOnly) { + BarResponse original = result; + result = new BarResponse(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override BarResponse MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.BarResponse.Descriptor; } + } + + public override BarResponse DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.BarResponse.DefaultInstance; } + } + + public override BarResponse BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is BarResponse) { + return MergeFrom((BarResponse) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(BarResponse other) { + if (other == global::Google.ProtocolBuffers.TestProtos.BarResponse.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_barResponseFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _barResponseFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static BarResponse() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasFull.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasFull.cs new file mode 100644 index 00000000..3eed99f1 --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasFull.cs @@ -0,0 +1,2141 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: unittest_extras_full.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace Google.ProtocolBuffers.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class UnittestExtrasFull { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.EmployeeId); + } + #endregion + #region Extensions + public const int EmployeeIdFieldNumber = 126; + public static pb::GeneratedExtensionBase EmployeeId; + #endregion + + #region Static variables + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestInteropPerson__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestInteropEmployeeId__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestInteropEmployeeId__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestMissingFieldsA__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestMissingFieldsA__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestMissingFieldsB__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestMissingFieldsB__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__FieldAccessorTable; + #endregion + #region Descriptor + public static pbd::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbd::FileDescriptor descriptor; + + static UnittestExtrasFull() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Chp1bml0dGVzdF9leHRyYXNfZnVsbC5wcm90bxIXcHJvdG9idWZfdW5pdHRl", + "c3RfZXh0cmEi1gMKEVRlc3RJbnRlcm9wUGVyc29uEgwKBG5hbWUYASACKAkS", + "CgoCaWQYAiACKAUSDQoFZW1haWwYAyABKAkSEQoFY29kZXMYCiADKAVCAhAB", + "EkUKBXBob25lGAQgAygLMjYucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEuVGVz", + "dEludGVyb3BQZXJzb24uUGhvbmVOdW1iZXISRwoJYWRkcmVzc2VzGAUgAygK", + "MjQucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEuVGVzdEludGVyb3BQZXJzb24u", + "QWRkcmVzc2VzGmcKC1Bob25lTnVtYmVyEg4KBm51bWJlchgBIAIoCRJICgR0", + "eXBlGAIgASgOMjQucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEuVGVzdEludGVy", + "b3BQZXJzb24uUGhvbmVUeXBlOgRIT01FGlgKCUFkZHJlc3NlcxIPCgdhZGRy", + "ZXNzGAEgAigJEhAKCGFkZHJlc3MyGAIgASgJEgwKBGNpdHkYAyACKAkSDQoF", + "c3RhdGUYBCACKAkSCwoDemlwGAUgAigHIisKCVBob25lVHlwZRIKCgZNT0JJ", + "TEUQABIICgRIT01FEAESCAoEV09SSxACKgUIZBDIASInChVUZXN0SW50ZXJv", + "cEVtcGxveWVlSWQSDgoGbnVtYmVyGAEgAigJIqUBChJUZXN0TWlzc2luZ0Zp", + "ZWxkc0ESDAoEbmFtZRgBIAIoCRIKCgJpZBgCIAIoBRINCgVlbWFpbBgDIAEo", + "CRI/CgV0ZXN0QRgLIAEoCzIwLnByb3RvYnVmX3VuaXR0ZXN0X2V4dHJhLlRl", + "c3RNaXNzaW5nRmllbGRzQS5TdWJBGiUKBFN1YkESDQoFY291bnQYBSACKAUS", + "DgoGdmFsdWVzGAYgAygJIpgBChJUZXN0TWlzc2luZ0ZpZWxkc0ISDAoEbmFt", + "ZRgBIAIoCRIKCgJpZBgCIAIoBRIPCgd3ZWJzaXRlGAQgASgJEj8KBXRlc3RC", + "GAwgASgLMjAucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEuVGVzdE1pc3NpbmdG", + "aWVsZHNCLlN1YkIaFgoEU3ViQhIOCgZ2YWx1ZXMYByADKAk6bwoLZW1wbG95", + "ZWVfaWQSKi5wcm90b2J1Zl91bml0dGVzdF9leHRyYS5UZXN0SW50ZXJvcFBl", + "cnNvbhh+IAEoCzIuLnByb3RvYnVmX3VuaXR0ZXN0X2V4dHJhLlRlc3RJbnRl", + "cm9wRW1wbG95ZWVJZEI7ChNjb20uZ29vZ2xlLnByb3RvYnVmSAKqAiFHb29n", + "bGUuUHJvdG9jb2xCdWZmZXJzLlRlc3RQcm90b3M=")); + pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { + descriptor = root; + internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor = Descriptor.MessageTypes[0]; + internal__static_protobuf_unittest_extra_TestInteropPerson__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor, + new string[] { "Name", "Id", "Email", "Codes", "Phone", "Addresses", }); + internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__Descriptor = internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__Descriptor, + new string[] { "Number", "Type", }); + internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__Descriptor = internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__Descriptor, + new string[] { "Address", "Address2", "City", "State", "Zip", }); + internal__static_protobuf_unittest_extra_TestInteropEmployeeId__Descriptor = Descriptor.MessageTypes[1]; + internal__static_protobuf_unittest_extra_TestInteropEmployeeId__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestInteropEmployeeId__Descriptor, + new string[] { "Number", }); + internal__static_protobuf_unittest_extra_TestMissingFieldsA__Descriptor = Descriptor.MessageTypes[2]; + internal__static_protobuf_unittest_extra_TestMissingFieldsA__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestMissingFieldsA__Descriptor, + new string[] { "Name", "Id", "Email", "TestA", }); + internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__Descriptor = internal__static_protobuf_unittest_extra_TestMissingFieldsA__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__Descriptor, + new string[] { "Count", "Values", }); + internal__static_protobuf_unittest_extra_TestMissingFieldsB__Descriptor = Descriptor.MessageTypes[3]; + internal__static_protobuf_unittest_extra_TestMissingFieldsB__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestMissingFieldsB__Descriptor, + new string[] { "Name", "Id", "Website", "TestB", }); + internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__Descriptor = internal__static_protobuf_unittest_extra_TestMissingFieldsB__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__Descriptor, + new string[] { "Values", }); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.EmployeeId = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.Descriptor.Extensions[0]); + pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); + RegisterAllExtensions(registry); + return registry; + }; + pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, + new pbd::FileDescriptor[] { + }, assigner); + } + #endregion + + } + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestInteropPerson : pb::ExtendableMessage { + private TestInteropPerson() { } + private static readonly TestInteropPerson defaultInstance = new TestInteropPerson().MakeReadOnly(); + public static TestInteropPerson DefaultInstance { + get { return defaultInstance; } + } + + public override TestInteropPerson DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestInteropPerson ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestInteropPerson__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestInteropPerson__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + public enum PhoneType { + MOBILE = 0, + HOME = 1, + WORK = 2, + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class PhoneNumber : pb::GeneratedMessage { + private PhoneNumber() { } + private static readonly PhoneNumber defaultInstance = new PhoneNumber().MakeReadOnly(); + public static PhoneNumber DefaultInstance { + get { return defaultInstance; } + } + + public override PhoneNumber DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override PhoneNumber ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestInteropPerson_PhoneNumber__FieldAccessorTable; } + } + + public const int NumberFieldNumber = 1; + private bool hasNumber; + private string number_ = ""; + public bool HasNumber { + get { return hasNumber; } + } + public string Number { + get { return number_; } + } + + public const int TypeFieldNumber = 2; + private bool hasType; + private global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType type_ = global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType.HOME; + public bool HasType { + get { return hasType; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType Type { + get { return type_; } + } + + public static PhoneNumber ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static PhoneNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static PhoneNumber ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static PhoneNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static PhoneNumber ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static PhoneNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static PhoneNumber ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static PhoneNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static PhoneNumber ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static PhoneNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private PhoneNumber MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(PhoneNumber prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(PhoneNumber cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private PhoneNumber result; + + private PhoneNumber PrepareBuilder() { + if (resultIsReadOnly) { + PhoneNumber original = result; + result = new PhoneNumber(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override PhoneNumber MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber.Descriptor; } + } + + public override PhoneNumber DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber.DefaultInstance; } + } + + public override PhoneNumber BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + + public bool HasNumber { + get { return result.hasNumber; } + } + public string Number { + get { return result.Number; } + set { SetNumber(value); } + } + public Builder SetNumber(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasNumber = true; + result.number_ = value; + return this; + } + public Builder ClearNumber() { + PrepareBuilder(); + result.hasNumber = false; + result.number_ = ""; + return this; + } + + public bool HasType { + get { return result.hasType; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType Type { + get { return result.Type; } + set { SetType(value); } + } + public Builder SetType(global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType value) { + PrepareBuilder(); + result.hasType = true; + result.type_ = value; + return this; + } + public Builder ClearType() { + PrepareBuilder(); + result.hasType = false; + result.type_ = global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneType.HOME; + return this; + } + } + static PhoneNumber() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Addresses : pb::GeneratedMessage { + private Addresses() { } + private static readonly Addresses defaultInstance = new Addresses().MakeReadOnly(); + public static Addresses DefaultInstance { + get { return defaultInstance; } + } + + public override Addresses DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Addresses ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestInteropPerson_Addresses__FieldAccessorTable; } + } + + public const int AddressFieldNumber = 1; + private bool hasAddress; + private string address_ = ""; + public bool HasAddress { + get { return hasAddress; } + } + public string Address { + get { return address_; } + } + + public const int Address2FieldNumber = 2; + private bool hasAddress2; + private string address2_ = ""; + public bool HasAddress2 { + get { return hasAddress2; } + } + public string Address2 { + get { return address2_; } + } + + public const int CityFieldNumber = 3; + private bool hasCity; + private string city_ = ""; + public bool HasCity { + get { return hasCity; } + } + public string City { + get { return city_; } + } + + public const int StateFieldNumber = 4; + private bool hasState; + private string state_ = ""; + public bool HasState { + get { return hasState; } + } + public string State { + get { return state_; } + } + + public const int ZipFieldNumber = 5; + private bool hasZip; + private uint zip_; + public bool HasZip { + get { return hasZip; } + } + [global::System.CLSCompliant(false)] + public uint Zip { + get { return zip_; } + } + + public static Addresses ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Addresses ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Addresses ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Addresses ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Addresses ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Addresses ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Addresses ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Addresses ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Addresses ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Addresses ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Addresses MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Addresses prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Addresses cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Addresses result; + + private Addresses PrepareBuilder() { + if (resultIsReadOnly) { + Addresses original = result; + result = new Addresses(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Addresses MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses.Descriptor; } + } + + public override Addresses DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses.DefaultInstance; } + } + + public override Addresses BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + + public bool HasAddress { + get { return result.hasAddress; } + } + public string Address { + get { return result.Address; } + set { SetAddress(value); } + } + public Builder SetAddress(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasAddress = true; + result.address_ = value; + return this; + } + public Builder ClearAddress() { + PrepareBuilder(); + result.hasAddress = false; + result.address_ = ""; + return this; + } + + public bool HasAddress2 { + get { return result.hasAddress2; } + } + public string Address2 { + get { return result.Address2; } + set { SetAddress2(value); } + } + public Builder SetAddress2(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasAddress2 = true; + result.address2_ = value; + return this; + } + public Builder ClearAddress2() { + PrepareBuilder(); + result.hasAddress2 = false; + result.address2_ = ""; + return this; + } + + public bool HasCity { + get { return result.hasCity; } + } + public string City { + get { return result.City; } + set { SetCity(value); } + } + public Builder SetCity(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasCity = true; + result.city_ = value; + return this; + } + public Builder ClearCity() { + PrepareBuilder(); + result.hasCity = false; + result.city_ = ""; + return this; + } + + public bool HasState { + get { return result.hasState; } + } + public string State { + get { return result.State; } + set { SetState(value); } + } + public Builder SetState(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasState = true; + result.state_ = value; + return this; + } + public Builder ClearState() { + PrepareBuilder(); + result.hasState = false; + result.state_ = ""; + return this; + } + + public bool HasZip { + get { return result.hasZip; } + } + [global::System.CLSCompliant(false)] + public uint Zip { + get { return result.Zip; } + set { SetZip(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetZip(uint value) { + PrepareBuilder(); + result.hasZip = true; + result.zip_ = value; + return this; + } + public Builder ClearZip() { + PrepareBuilder(); + result.hasZip = false; + result.zip_ = 0; + return this; + } + } + static Addresses() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.Descriptor, null); + } + } + + } + #endregion + + public const int NameFieldNumber = 1; + private bool hasName; + private string name_ = ""; + public bool HasName { + get { return hasName; } + } + public string Name { + get { return name_; } + } + + public const int IdFieldNumber = 2; + private bool hasId; + private int id_; + public bool HasId { + get { return hasId; } + } + public int Id { + get { return id_; } + } + + public const int EmailFieldNumber = 3; + private bool hasEmail; + private string email_ = ""; + public bool HasEmail { + get { return hasEmail; } + } + public string Email { + get { return email_; } + } + + public const int CodesFieldNumber = 10; + private pbc::PopsicleList codes_ = new pbc::PopsicleList(); + public scg::IList CodesList { + get { return pbc::Lists.AsReadOnly(codes_); } + } + public int CodesCount { + get { return codes_.Count; } + } + public int GetCodes(int index) { + return codes_[index]; + } + + public const int PhoneFieldNumber = 4; + private pbc::PopsicleList phone_ = new pbc::PopsicleList(); + public scg::IList PhoneList { + get { return phone_; } + } + public int PhoneCount { + get { return phone_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber GetPhone(int index) { + return phone_[index]; + } + + public const int AddressesFieldNumber = 5; + private pbc::PopsicleList addresses_ = new pbc::PopsicleList(); + public scg::IList AddressesList { + get { return addresses_; } + } + public int AddressesCount { + get { return addresses_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses GetAddresses(int index) { + return addresses_[index]; + } + + public static TestInteropPerson ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestInteropPerson ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestInteropPerson ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestInteropPerson ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestInteropPerson ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestInteropPerson ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestInteropPerson ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestInteropPerson ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestInteropPerson ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestInteropPerson ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestInteropPerson MakeReadOnly() { + codes_.MakeReadOnly(); + phone_.MakeReadOnly(); + addresses_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestInteropPerson prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestInteropPerson cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestInteropPerson result; + + private TestInteropPerson PrepareBuilder() { + if (resultIsReadOnly) { + TestInteropPerson original = result; + result = new TestInteropPerson(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestInteropPerson MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Descriptor; } + } + + public override TestInteropPerson DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.DefaultInstance; } + } + + public override TestInteropPerson BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + + public bool HasName { + get { return result.hasName; } + } + public string Name { + get { return result.Name; } + set { SetName(value); } + } + public Builder SetName(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasName = true; + result.name_ = value; + return this; + } + public Builder ClearName() { + PrepareBuilder(); + result.hasName = false; + result.name_ = ""; + return this; + } + + public bool HasId { + get { return result.hasId; } + } + public int Id { + get { return result.Id; } + set { SetId(value); } + } + public Builder SetId(int value) { + PrepareBuilder(); + result.hasId = true; + result.id_ = value; + return this; + } + public Builder ClearId() { + PrepareBuilder(); + result.hasId = false; + result.id_ = 0; + return this; + } + + public bool HasEmail { + get { return result.hasEmail; } + } + public string Email { + get { return result.Email; } + set { SetEmail(value); } + } + public Builder SetEmail(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasEmail = true; + result.email_ = value; + return this; + } + public Builder ClearEmail() { + PrepareBuilder(); + result.hasEmail = false; + result.email_ = ""; + return this; + } + + public pbc::IPopsicleList CodesList { + get { return PrepareBuilder().codes_; } + } + public int CodesCount { + get { return result.CodesCount; } + } + public int GetCodes(int index) { + return result.GetCodes(index); + } + public Builder SetCodes(int index, int value) { + PrepareBuilder(); + result.codes_[index] = value; + return this; + } + public Builder AddCodes(int value) { + PrepareBuilder(); + result.codes_.Add(value); + return this; + } + public Builder AddRangeCodes(scg::IEnumerable values) { + PrepareBuilder(); + result.codes_.Add(values); + return this; + } + public Builder ClearCodes() { + PrepareBuilder(); + result.codes_.Clear(); + return this; + } + + public pbc::IPopsicleList PhoneList { + get { return PrepareBuilder().phone_; } + } + public int PhoneCount { + get { return result.PhoneCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber GetPhone(int index) { + return result.GetPhone(index); + } + public Builder SetPhone(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.phone_[index] = value; + return this; + } + public Builder SetPhone(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.phone_[index] = builderForValue.Build(); + return this; + } + public Builder AddPhone(global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.phone_.Add(value); + return this; + } + public Builder AddPhone(global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.PhoneNumber.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.phone_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangePhone(scg::IEnumerable values) { + PrepareBuilder(); + result.phone_.Add(values); + return this; + } + public Builder ClearPhone() { + PrepareBuilder(); + result.phone_.Clear(); + return this; + } + + public pbc::IPopsicleList AddressesList { + get { return PrepareBuilder().addresses_; } + } + public int AddressesCount { + get { return result.AddressesCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses GetAddresses(int index) { + return result.GetAddresses(index); + } + public Builder SetAddresses(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.addresses_[index] = value; + return this; + } + public Builder SetAddresses(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.addresses_[index] = builderForValue.Build(); + return this; + } + public Builder AddAddresses(global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.addresses_.Add(value); + return this; + } + public Builder AddAddresses(global::Google.ProtocolBuffers.TestProtos.TestInteropPerson.Types.Addresses.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.addresses_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeAddresses(scg::IEnumerable values) { + PrepareBuilder(); + result.addresses_.Add(values); + return this; + } + public Builder ClearAddresses() { + PrepareBuilder(); + result.addresses_.Clear(); + return this; + } + } + static TestInteropPerson() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestInteropEmployeeId : pb::GeneratedMessage { + private TestInteropEmployeeId() { } + private static readonly TestInteropEmployeeId defaultInstance = new TestInteropEmployeeId().MakeReadOnly(); + public static TestInteropEmployeeId DefaultInstance { + get { return defaultInstance; } + } + + public override TestInteropEmployeeId DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestInteropEmployeeId ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestInteropEmployeeId__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestInteropEmployeeId__FieldAccessorTable; } + } + + public const int NumberFieldNumber = 1; + private bool hasNumber; + private string number_ = ""; + public bool HasNumber { + get { return hasNumber; } + } + public string Number { + get { return number_; } + } + + public static TestInteropEmployeeId ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestInteropEmployeeId ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestInteropEmployeeId ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestInteropEmployeeId ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestInteropEmployeeId ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestInteropEmployeeId ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestInteropEmployeeId ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestInteropEmployeeId ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestInteropEmployeeId ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestInteropEmployeeId ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestInteropEmployeeId MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestInteropEmployeeId prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestInteropEmployeeId cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestInteropEmployeeId result; + + private TestInteropEmployeeId PrepareBuilder() { + if (resultIsReadOnly) { + TestInteropEmployeeId original = result; + result = new TestInteropEmployeeId(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestInteropEmployeeId MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropEmployeeId.Descriptor; } + } + + public override TestInteropEmployeeId DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropEmployeeId.DefaultInstance; } + } + + public override TestInteropEmployeeId BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + + public bool HasNumber { + get { return result.hasNumber; } + } + public string Number { + get { return result.Number; } + set { SetNumber(value); } + } + public Builder SetNumber(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasNumber = true; + result.number_ = value; + return this; + } + public Builder ClearNumber() { + PrepareBuilder(); + result.hasNumber = false; + result.number_ = ""; + return this; + } + } + static TestInteropEmployeeId() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestMissingFieldsA : pb::GeneratedMessage { + private TestMissingFieldsA() { } + private static readonly TestMissingFieldsA defaultInstance = new TestMissingFieldsA().MakeReadOnly(); + public static TestMissingFieldsA DefaultInstance { + get { return defaultInstance; } + } + + public override TestMissingFieldsA DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestMissingFieldsA ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestMissingFieldsA__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestMissingFieldsA__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class SubA : pb::GeneratedMessage { + private SubA() { } + private static readonly SubA defaultInstance = new SubA().MakeReadOnly(); + public static SubA DefaultInstance { + get { return defaultInstance; } + } + + public override SubA DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override SubA ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestMissingFieldsA_SubA__FieldAccessorTable; } + } + + public const int CountFieldNumber = 5; + private bool hasCount; + private int count_; + public bool HasCount { + get { return hasCount; } + } + public int Count { + get { return count_; } + } + + public const int ValuesFieldNumber = 6; + private pbc::PopsicleList values_ = new pbc::PopsicleList(); + public scg::IList ValuesList { + get { return pbc::Lists.AsReadOnly(values_); } + } + public int ValuesCount { + get { return values_.Count; } + } + public string GetValues(int index) { + return values_[index]; + } + + public static SubA ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static SubA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static SubA ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static SubA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static SubA ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static SubA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static SubA ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static SubA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static SubA ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static SubA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private SubA MakeReadOnly() { + values_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(SubA prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(SubA cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private SubA result; + + private SubA PrepareBuilder() { + if (resultIsReadOnly) { + SubA original = result; + result = new SubA(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override SubA MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.Descriptor; } + } + + public override SubA DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.DefaultInstance; } + } + + public override SubA BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + + public bool HasCount { + get { return result.hasCount; } + } + public int Count { + get { return result.Count; } + set { SetCount(value); } + } + public Builder SetCount(int value) { + PrepareBuilder(); + result.hasCount = true; + result.count_ = value; + return this; + } + public Builder ClearCount() { + PrepareBuilder(); + result.hasCount = false; + result.count_ = 0; + return this; + } + + public pbc::IPopsicleList ValuesList { + get { return PrepareBuilder().values_; } + } + public int ValuesCount { + get { return result.ValuesCount; } + } + public string GetValues(int index) { + return result.GetValues(index); + } + public Builder SetValues(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.values_[index] = value; + return this; + } + public Builder AddValues(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.values_.Add(value); + return this; + } + public Builder AddRangeValues(scg::IEnumerable values) { + PrepareBuilder(); + result.values_.Add(values); + return this; + } + public Builder ClearValues() { + PrepareBuilder(); + result.values_.Clear(); + return this; + } + } + static SubA() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.Descriptor, null); + } + } + + } + #endregion + + public const int NameFieldNumber = 1; + private bool hasName; + private string name_ = ""; + public bool HasName { + get { return hasName; } + } + public string Name { + get { return name_; } + } + + public const int IdFieldNumber = 2; + private bool hasId; + private int id_; + public bool HasId { + get { return hasId; } + } + public int Id { + get { return id_; } + } + + public const int EmailFieldNumber = 3; + private bool hasEmail; + private string email_ = ""; + public bool HasEmail { + get { return hasEmail; } + } + public string Email { + get { return email_; } + } + + public const int TestAFieldNumber = 11; + private bool hasTestA; + private global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA testA_; + public bool HasTestA { + get { return hasTestA; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA TestA { + get { return testA_ ?? global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.DefaultInstance; } + } + + public static TestMissingFieldsA ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMissingFieldsA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMissingFieldsA ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMissingFieldsA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMissingFieldsA ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMissingFieldsA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestMissingFieldsA ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestMissingFieldsA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestMissingFieldsA ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMissingFieldsA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestMissingFieldsA MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestMissingFieldsA prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestMissingFieldsA cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestMissingFieldsA result; + + private TestMissingFieldsA PrepareBuilder() { + if (resultIsReadOnly) { + TestMissingFieldsA original = result; + result = new TestMissingFieldsA(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestMissingFieldsA MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Descriptor; } + } + + public override TestMissingFieldsA DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.DefaultInstance; } + } + + public override TestMissingFieldsA BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + + public bool HasName { + get { return result.hasName; } + } + public string Name { + get { return result.Name; } + set { SetName(value); } + } + public Builder SetName(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasName = true; + result.name_ = value; + return this; + } + public Builder ClearName() { + PrepareBuilder(); + result.hasName = false; + result.name_ = ""; + return this; + } + + public bool HasId { + get { return result.hasId; } + } + public int Id { + get { return result.Id; } + set { SetId(value); } + } + public Builder SetId(int value) { + PrepareBuilder(); + result.hasId = true; + result.id_ = value; + return this; + } + public Builder ClearId() { + PrepareBuilder(); + result.hasId = false; + result.id_ = 0; + return this; + } + + public bool HasEmail { + get { return result.hasEmail; } + } + public string Email { + get { return result.Email; } + set { SetEmail(value); } + } + public Builder SetEmail(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasEmail = true; + result.email_ = value; + return this; + } + public Builder ClearEmail() { + PrepareBuilder(); + result.hasEmail = false; + result.email_ = ""; + return this; + } + + public bool HasTestA { + get { return result.hasTestA; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA TestA { + get { return result.TestA; } + set { SetTestA(value); } + } + public Builder SetTestA(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasTestA = true; + result.testA_ = value; + return this; + } + public Builder SetTestA(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasTestA = true; + result.testA_ = builderForValue.Build(); + return this; + } + public Builder MergeTestA(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasTestA && + result.testA_ != global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.DefaultInstance) { + result.testA_ = global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsA.Types.SubA.CreateBuilder(result.testA_).MergeFrom(value).BuildPartial(); + } else { + result.testA_ = value; + } + result.hasTestA = true; + return this; + } + public Builder ClearTestA() { + PrepareBuilder(); + result.hasTestA = false; + result.testA_ = null; + return this; + } + } + static TestMissingFieldsA() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestMissingFieldsB : pb::GeneratedMessage { + private TestMissingFieldsB() { } + private static readonly TestMissingFieldsB defaultInstance = new TestMissingFieldsB().MakeReadOnly(); + public static TestMissingFieldsB DefaultInstance { + get { return defaultInstance; } + } + + public override TestMissingFieldsB DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestMissingFieldsB ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestMissingFieldsB__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestMissingFieldsB__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class SubB : pb::GeneratedMessage { + private SubB() { } + private static readonly SubB defaultInstance = new SubB().MakeReadOnly(); + public static SubB DefaultInstance { + get { return defaultInstance; } + } + + public override SubB DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override SubB ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.internal__static_protobuf_unittest_extra_TestMissingFieldsB_SubB__FieldAccessorTable; } + } + + public const int ValuesFieldNumber = 7; + private pbc::PopsicleList values_ = new pbc::PopsicleList(); + public scg::IList ValuesList { + get { return pbc::Lists.AsReadOnly(values_); } + } + public int ValuesCount { + get { return values_.Count; } + } + public string GetValues(int index) { + return values_[index]; + } + + public static SubB ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static SubB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static SubB ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static SubB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static SubB ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static SubB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static SubB ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static SubB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static SubB ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static SubB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private SubB MakeReadOnly() { + values_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(SubB prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(SubB cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private SubB result; + + private SubB PrepareBuilder() { + if (resultIsReadOnly) { + SubB original = result; + result = new SubB(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override SubB MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.Descriptor; } + } + + public override SubB DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.DefaultInstance; } + } + + public override SubB BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + + public pbc::IPopsicleList ValuesList { + get { return PrepareBuilder().values_; } + } + public int ValuesCount { + get { return result.ValuesCount; } + } + public string GetValues(int index) { + return result.GetValues(index); + } + public Builder SetValues(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.values_[index] = value; + return this; + } + public Builder AddValues(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.values_.Add(value); + return this; + } + public Builder AddRangeValues(scg::IEnumerable values) { + PrepareBuilder(); + result.values_.Add(values); + return this; + } + public Builder ClearValues() { + PrepareBuilder(); + result.values_.Clear(); + return this; + } + } + static SubB() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.Descriptor, null); + } + } + + } + #endregion + + public const int NameFieldNumber = 1; + private bool hasName; + private string name_ = ""; + public bool HasName { + get { return hasName; } + } + public string Name { + get { return name_; } + } + + public const int IdFieldNumber = 2; + private bool hasId; + private int id_; + public bool HasId { + get { return hasId; } + } + public int Id { + get { return id_; } + } + + public const int WebsiteFieldNumber = 4; + private bool hasWebsite; + private string website_ = ""; + public bool HasWebsite { + get { return hasWebsite; } + } + public string Website { + get { return website_; } + } + + public const int TestBFieldNumber = 12; + private bool hasTestB; + private global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB testB_; + public bool HasTestB { + get { return hasTestB; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB TestB { + get { return testB_ ?? global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.DefaultInstance; } + } + + public static TestMissingFieldsB ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMissingFieldsB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMissingFieldsB ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMissingFieldsB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMissingFieldsB ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMissingFieldsB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestMissingFieldsB ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestMissingFieldsB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestMissingFieldsB ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMissingFieldsB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestMissingFieldsB MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestMissingFieldsB prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestMissingFieldsB cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestMissingFieldsB result; + + private TestMissingFieldsB PrepareBuilder() { + if (resultIsReadOnly) { + TestMissingFieldsB original = result; + result = new TestMissingFieldsB(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestMissingFieldsB MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Descriptor; } + } + + public override TestMissingFieldsB DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.DefaultInstance; } + } + + public override TestMissingFieldsB BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + + public bool HasName { + get { return result.hasName; } + } + public string Name { + get { return result.Name; } + set { SetName(value); } + } + public Builder SetName(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasName = true; + result.name_ = value; + return this; + } + public Builder ClearName() { + PrepareBuilder(); + result.hasName = false; + result.name_ = ""; + return this; + } + + public bool HasId { + get { return result.hasId; } + } + public int Id { + get { return result.Id; } + set { SetId(value); } + } + public Builder SetId(int value) { + PrepareBuilder(); + result.hasId = true; + result.id_ = value; + return this; + } + public Builder ClearId() { + PrepareBuilder(); + result.hasId = false; + result.id_ = 0; + return this; + } + + public bool HasWebsite { + get { return result.hasWebsite; } + } + public string Website { + get { return result.Website; } + set { SetWebsite(value); } + } + public Builder SetWebsite(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasWebsite = true; + result.website_ = value; + return this; + } + public Builder ClearWebsite() { + PrepareBuilder(); + result.hasWebsite = false; + result.website_ = ""; + return this; + } + + public bool HasTestB { + get { return result.hasTestB; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB TestB { + get { return result.TestB; } + set { SetTestB(value); } + } + public Builder SetTestB(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasTestB = true; + result.testB_ = value; + return this; + } + public Builder SetTestB(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasTestB = true; + result.testB_ = builderForValue.Build(); + return this; + } + public Builder MergeTestB(global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasTestB && + result.testB_ != global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.DefaultInstance) { + result.testB_ = global::Google.ProtocolBuffers.TestProtos.TestMissingFieldsB.Types.SubB.CreateBuilder(result.testB_).MergeFrom(value).BuildPartial(); + } else { + result.testB_ = value; + } + result.hasTestB = true; + return this; + } + public Builder ClearTestB() { + PrepareBuilder(); + result.hasTestB = false; + result.testB_ = null; + return this; + } + } + static TestMissingFieldsB() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasFull.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasLite.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasLite.cs new file mode 100644 index 00000000..2cb0459b --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasLite.cs @@ -0,0 +1,4209 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: unittest_extras_lite.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace Google.ProtocolBuffers.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class UnittestExtrasLite { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.EmployeeIdLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedInt32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedInt64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedUint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedUint64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSint64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedFixed32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedFixed64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSfixed32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSfixed64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedFloatExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedDoubleExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedBoolExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedEnumExtensionLite); + } + #endregion + #region Extensions + public const int EmployeeIdLiteFieldNumber = 126; + public static pb::GeneratedExtensionLite EmployeeIdLite; + public const int UnpackedInt32ExtensionLiteFieldNumber = 90; + public static pb::GeneratedRepeatExtensionLite UnpackedInt32ExtensionLite; + public const int UnpackedInt64ExtensionLiteFieldNumber = 91; + public static pb::GeneratedRepeatExtensionLite UnpackedInt64ExtensionLite; + public const int UnpackedUint32ExtensionLiteFieldNumber = 92; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite UnpackedUint32ExtensionLite; + public const int UnpackedUint64ExtensionLiteFieldNumber = 93; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite UnpackedUint64ExtensionLite; + public const int UnpackedSint32ExtensionLiteFieldNumber = 94; + public static pb::GeneratedRepeatExtensionLite UnpackedSint32ExtensionLite; + public const int UnpackedSint64ExtensionLiteFieldNumber = 95; + public static pb::GeneratedRepeatExtensionLite UnpackedSint64ExtensionLite; + public const int UnpackedFixed32ExtensionLiteFieldNumber = 96; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite UnpackedFixed32ExtensionLite; + public const int UnpackedFixed64ExtensionLiteFieldNumber = 97; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite UnpackedFixed64ExtensionLite; + public const int UnpackedSfixed32ExtensionLiteFieldNumber = 98; + public static pb::GeneratedRepeatExtensionLite UnpackedSfixed32ExtensionLite; + public const int UnpackedSfixed64ExtensionLiteFieldNumber = 99; + public static pb::GeneratedRepeatExtensionLite UnpackedSfixed64ExtensionLite; + public const int UnpackedFloatExtensionLiteFieldNumber = 100; + public static pb::GeneratedRepeatExtensionLite UnpackedFloatExtensionLite; + public const int UnpackedDoubleExtensionLiteFieldNumber = 101; + public static pb::GeneratedRepeatExtensionLite UnpackedDoubleExtensionLite; + public const int UnpackedBoolExtensionLiteFieldNumber = 102; + public static pb::GeneratedRepeatExtensionLite UnpackedBoolExtensionLite; + public const int UnpackedEnumExtensionLiteFieldNumber = 103; + public static pb::GeneratedRepeatExtensionLite UnpackedEnumExtensionLite; + #endregion + + #region Static variables + #endregion + #region Extensions + internal static readonly object Descriptor; + static UnittestExtrasLite() { + Descriptor = null; + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.EmployeeIdLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest_extra.employee_id_lite", + global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.TestInteropEmployeeIdLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.EmployeeIdLiteFieldNumber, + pbd::FieldType.Message); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedInt32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_int32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedInt32ExtensionLiteFieldNumber, + pbd::FieldType.Int32, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedInt64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_int64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedInt64ExtensionLiteFieldNumber, + pbd::FieldType.Int64, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedUint32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_uint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedUint32ExtensionLiteFieldNumber, + pbd::FieldType.UInt32, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedUint64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_uint64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedUint64ExtensionLiteFieldNumber, + pbd::FieldType.UInt64, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSint32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_sint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSint32ExtensionLiteFieldNumber, + pbd::FieldType.SInt32, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSint64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_sint64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSint64ExtensionLiteFieldNumber, + pbd::FieldType.SInt64, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedFixed32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_fixed32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedFixed32ExtensionLiteFieldNumber, + pbd::FieldType.Fixed32, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedFixed64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_fixed64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedFixed64ExtensionLiteFieldNumber, + pbd::FieldType.Fixed64, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSfixed32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_sfixed32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSfixed32ExtensionLiteFieldNumber, + pbd::FieldType.SFixed32, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSfixed64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_sfixed64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedSfixed64ExtensionLiteFieldNumber, + pbd::FieldType.SFixed64, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedFloatExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_float_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedFloatExtensionLiteFieldNumber, + pbd::FieldType.Float, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedDoubleExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_double_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedDoubleExtensionLiteFieldNumber, + pbd::FieldType.Double, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedBoolExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_bool_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedBoolExtensionLiteFieldNumber, + pbd::FieldType.Bool, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedEnumExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest_extra.unpacked_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance, + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.UnpackedEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum, + false); + } + #endregion + + } + #region Enums + public enum ExtraEnum { + DEFAULT = 10, + EXLITE_FOO = 7, + EXLITE_BAR = 8, + EXLITE_BAZ = 9, + } + + public enum UnpackedTypesForeignEnumLite { + FOREIGN_LITE_FOO = 4, + FOREIGN_LITE_BAR = 5, + FOREIGN_LITE_BAZ = 6, + } + + #endregion + + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestRequiredLite : pb::GeneratedMessageLite { + private TestRequiredLite() { } + private static readonly TestRequiredLite defaultInstance = new TestRequiredLite().MakeReadOnly(); + private static readonly string[] _testRequiredLiteFieldNames = new string[] { "d", "en" }; + private static readonly uint[] _testRequiredLiteFieldTags = new uint[] { 8, 16 }; + public static TestRequiredLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestRequiredLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestRequiredLite ThisMessage { + get { return this; } + } + + public const int DFieldNumber = 1; + private bool hasD; + private int d_; + public bool HasD { + get { return hasD; } + } + public int D { + get { return d_; } + } + + public const int EnFieldNumber = 2; + private bool hasEn; + private global::Google.ProtocolBuffers.TestProtos.ExtraEnum en_ = global::Google.ProtocolBuffers.TestProtos.ExtraEnum.DEFAULT; + public bool HasEn { + get { return hasEn; } + } + public global::Google.ProtocolBuffers.TestProtos.ExtraEnum En { + get { return en_; } + } + + public override bool IsInitialized { + get { + if (!hasD) return false; + if (!hasEn) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testRequiredLiteFieldNames; + if (hasD) { + output.WriteInt32(1, field_names[0], D); + } + if (hasEn) { + output.WriteEnum(2, field_names[1], (int) En, En); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasD) { + size += pb::CodedOutputStream.ComputeInt32Size(1, D); + } + if (hasEn) { + size += pb::CodedOutputStream.ComputeEnumSize(2, (int) En); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasD) hash ^= d_.GetHashCode(); + if (hasEn) hash ^= en_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestRequiredLite other = obj as TestRequiredLite; + if (other == null) return false; + if (hasD != other.hasD || (hasD && !d_.Equals(other.d_))) return false; + if (hasEn != other.hasEn || (hasEn && !en_.Equals(other.en_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("d", hasD, d_, writer); + PrintField("en", hasEn, en_, writer); + } + #endregion + + public static TestRequiredLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequiredLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequiredLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequiredLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequiredLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequiredLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestRequiredLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestRequiredLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestRequiredLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequiredLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestRequiredLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestRequiredLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRequiredLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestRequiredLite result; + + private TestRequiredLite PrepareBuilder() { + if (resultIsReadOnly) { + TestRequiredLite original = result; + result = new TestRequiredLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestRequiredLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestRequiredLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredLite.DefaultInstance; } + } + + public override TestRequiredLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestRequiredLite) { + return MergeFrom((TestRequiredLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestRequiredLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasD) { + D = other.D; + } + if (other.HasEn) { + En = other.En; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testRequiredLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testRequiredLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasD = input.ReadInt32(ref result.d_); + break; + } + case 16: { + object unknown; + if(input.ReadEnum(ref result.en_, out unknown)) { + result.hasEn = true; + } else if(unknown is int) { + } + break; + } + } + } + + return this; + } + + + public bool HasD { + get { return result.hasD; } + } + public int D { + get { return result.D; } + set { SetD(value); } + } + public Builder SetD(int value) { + PrepareBuilder(); + result.hasD = true; + result.d_ = value; + return this; + } + public Builder ClearD() { + PrepareBuilder(); + result.hasD = false; + result.d_ = 0; + return this; + } + + public bool HasEn { + get { return result.hasEn; } + } + public global::Google.ProtocolBuffers.TestProtos.ExtraEnum En { + get { return result.En; } + set { SetEn(value); } + } + public Builder SetEn(global::Google.ProtocolBuffers.TestProtos.ExtraEnum value) { + PrepareBuilder(); + result.hasEn = true; + result.en_ = value; + return this; + } + public Builder ClearEn() { + PrepareBuilder(); + result.hasEn = false; + result.en_ = global::Google.ProtocolBuffers.TestProtos.ExtraEnum.DEFAULT; + return this; + } + } + static TestRequiredLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestInteropPersonLite : pb::ExtendableMessageLite { + private TestInteropPersonLite() { } + private static readonly TestInteropPersonLite defaultInstance = new TestInteropPersonLite().MakeReadOnly(); + private static readonly string[] _testInteropPersonLiteFieldNames = new string[] { "addresses", "codes", "email", "id", "name", "phone" }; + private static readonly uint[] _testInteropPersonLiteFieldTags = new uint[] { 43, 82, 26, 16, 10, 34 }; + public static TestInteropPersonLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestInteropPersonLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestInteropPersonLite ThisMessage { + get { return this; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + public enum PhoneType { + MOBILE = 0, + HOME = 1, + WORK = 2, + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class PhoneNumber : pb::GeneratedMessageLite { + private PhoneNumber() { } + private static readonly PhoneNumber defaultInstance = new PhoneNumber().MakeReadOnly(); + private static readonly string[] _phoneNumberFieldNames = new string[] { "number", "type" }; + private static readonly uint[] _phoneNumberFieldTags = new uint[] { 10, 16 }; + public static PhoneNumber DefaultInstance { + get { return defaultInstance; } + } + + public override PhoneNumber DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override PhoneNumber ThisMessage { + get { return this; } + } + + public const int NumberFieldNumber = 1; + private bool hasNumber; + private string number_ = ""; + public bool HasNumber { + get { return hasNumber; } + } + public string Number { + get { return number_; } + } + + public const int TypeFieldNumber = 2; + private bool hasType; + private global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType type_ = global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType.HOME; + public bool HasType { + get { return hasType; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType Type { + get { return type_; } + } + + public override bool IsInitialized { + get { + if (!hasNumber) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _phoneNumberFieldNames; + if (hasNumber) { + output.WriteString(1, field_names[0], Number); + } + if (hasType) { + output.WriteEnum(2, field_names[1], (int) Type, Type); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasNumber) { + size += pb::CodedOutputStream.ComputeStringSize(1, Number); + } + if (hasType) { + size += pb::CodedOutputStream.ComputeEnumSize(2, (int) Type); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasNumber) hash ^= number_.GetHashCode(); + if (hasType) hash ^= type_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + PhoneNumber other = obj as PhoneNumber; + if (other == null) return false; + if (hasNumber != other.hasNumber || (hasNumber && !number_.Equals(other.number_))) return false; + if (hasType != other.hasType || (hasType && !type_.Equals(other.type_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("number", hasNumber, number_, writer); + PrintField("type", hasType, type_, writer); + } + #endregion + + public static PhoneNumber ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static PhoneNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static PhoneNumber ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static PhoneNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static PhoneNumber ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static PhoneNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static PhoneNumber ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static PhoneNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static PhoneNumber ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static PhoneNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private PhoneNumber MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(PhoneNumber prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(PhoneNumber cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private PhoneNumber result; + + private PhoneNumber PrepareBuilder() { + if (resultIsReadOnly) { + PhoneNumber original = result; + result = new PhoneNumber(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override PhoneNumber MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override PhoneNumber DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber.DefaultInstance; } + } + + public override PhoneNumber BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is PhoneNumber) { + return MergeFrom((PhoneNumber) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(PhoneNumber other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasNumber) { + Number = other.Number; + } + if (other.HasType) { + Type = other.Type; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_phoneNumberFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _phoneNumberFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 10: { + result.hasNumber = input.ReadString(ref result.number_); + break; + } + case 16: { + object unknown; + if(input.ReadEnum(ref result.type_, out unknown)) { + result.hasType = true; + } else if(unknown is int) { + } + break; + } + } + } + + return this; + } + + + public bool HasNumber { + get { return result.hasNumber; } + } + public string Number { + get { return result.Number; } + set { SetNumber(value); } + } + public Builder SetNumber(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasNumber = true; + result.number_ = value; + return this; + } + public Builder ClearNumber() { + PrepareBuilder(); + result.hasNumber = false; + result.number_ = ""; + return this; + } + + public bool HasType { + get { return result.hasType; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType Type { + get { return result.Type; } + set { SetType(value); } + } + public Builder SetType(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType value) { + PrepareBuilder(); + result.hasType = true; + result.type_ = value; + return this; + } + public Builder ClearType() { + PrepareBuilder(); + result.hasType = false; + result.type_ = global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneType.HOME; + return this; + } + } + static PhoneNumber() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Addresses : pb::GeneratedMessageLite { + private Addresses() { } + private static readonly Addresses defaultInstance = new Addresses().MakeReadOnly(); + private static readonly string[] _addressesFieldNames = new string[] { "address", "address2", "city", "state", "zip" }; + private static readonly uint[] _addressesFieldTags = new uint[] { 10, 18, 26, 34, 45 }; + public static Addresses DefaultInstance { + get { return defaultInstance; } + } + + public override Addresses DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Addresses ThisMessage { + get { return this; } + } + + public const int AddressFieldNumber = 1; + private bool hasAddress; + private string address_ = ""; + public bool HasAddress { + get { return hasAddress; } + } + public string Address { + get { return address_; } + } + + public const int Address2FieldNumber = 2; + private bool hasAddress2; + private string address2_ = ""; + public bool HasAddress2 { + get { return hasAddress2; } + } + public string Address2 { + get { return address2_; } + } + + public const int CityFieldNumber = 3; + private bool hasCity; + private string city_ = ""; + public bool HasCity { + get { return hasCity; } + } + public string City { + get { return city_; } + } + + public const int StateFieldNumber = 4; + private bool hasState; + private string state_ = ""; + public bool HasState { + get { return hasState; } + } + public string State { + get { return state_; } + } + + public const int ZipFieldNumber = 5; + private bool hasZip; + private uint zip_; + public bool HasZip { + get { return hasZip; } + } + [global::System.CLSCompliant(false)] + public uint Zip { + get { return zip_; } + } + + public override bool IsInitialized { + get { + if (!hasAddress) return false; + if (!hasCity) return false; + if (!hasState) return false; + if (!hasZip) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _addressesFieldNames; + if (hasAddress) { + output.WriteString(1, field_names[0], Address); + } + if (hasAddress2) { + output.WriteString(2, field_names[1], Address2); + } + if (hasCity) { + output.WriteString(3, field_names[2], City); + } + if (hasState) { + output.WriteString(4, field_names[3], State); + } + if (hasZip) { + output.WriteFixed32(5, field_names[4], Zip); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasAddress) { + size += pb::CodedOutputStream.ComputeStringSize(1, Address); + } + if (hasAddress2) { + size += pb::CodedOutputStream.ComputeStringSize(2, Address2); + } + if (hasCity) { + size += pb::CodedOutputStream.ComputeStringSize(3, City); + } + if (hasState) { + size += pb::CodedOutputStream.ComputeStringSize(4, State); + } + if (hasZip) { + size += pb::CodedOutputStream.ComputeFixed32Size(5, Zip); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasAddress) hash ^= address_.GetHashCode(); + if (hasAddress2) hash ^= address2_.GetHashCode(); + if (hasCity) hash ^= city_.GetHashCode(); + if (hasState) hash ^= state_.GetHashCode(); + if (hasZip) hash ^= zip_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + Addresses other = obj as Addresses; + if (other == null) return false; + if (hasAddress != other.hasAddress || (hasAddress && !address_.Equals(other.address_))) return false; + if (hasAddress2 != other.hasAddress2 || (hasAddress2 && !address2_.Equals(other.address2_))) return false; + if (hasCity != other.hasCity || (hasCity && !city_.Equals(other.city_))) return false; + if (hasState != other.hasState || (hasState && !state_.Equals(other.state_))) return false; + if (hasZip != other.hasZip || (hasZip && !zip_.Equals(other.zip_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("address", hasAddress, address_, writer); + PrintField("address2", hasAddress2, address2_, writer); + PrintField("city", hasCity, city_, writer); + PrintField("state", hasState, state_, writer); + PrintField("zip", hasZip, zip_, writer); + } + #endregion + + public static Addresses ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Addresses ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Addresses ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Addresses ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Addresses ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Addresses ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Addresses ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Addresses ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Addresses ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Addresses ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Addresses MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Addresses prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Addresses cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Addresses result; + + private Addresses PrepareBuilder() { + if (resultIsReadOnly) { + Addresses original = result; + result = new Addresses(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Addresses MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override Addresses DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses.DefaultInstance; } + } + + public override Addresses BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is Addresses) { + return MergeFrom((Addresses) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Addresses other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasAddress) { + Address = other.Address; + } + if (other.HasAddress2) { + Address2 = other.Address2; + } + if (other.HasCity) { + City = other.City; + } + if (other.HasState) { + State = other.State; + } + if (other.HasZip) { + Zip = other.Zip; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_addressesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _addressesFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 10: { + result.hasAddress = input.ReadString(ref result.address_); + break; + } + case 18: { + result.hasAddress2 = input.ReadString(ref result.address2_); + break; + } + case 26: { + result.hasCity = input.ReadString(ref result.city_); + break; + } + case 34: { + result.hasState = input.ReadString(ref result.state_); + break; + } + case 45: { + result.hasZip = input.ReadFixed32(ref result.zip_); + break; + } + } + } + + return this; + } + + + public bool HasAddress { + get { return result.hasAddress; } + } + public string Address { + get { return result.Address; } + set { SetAddress(value); } + } + public Builder SetAddress(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasAddress = true; + result.address_ = value; + return this; + } + public Builder ClearAddress() { + PrepareBuilder(); + result.hasAddress = false; + result.address_ = ""; + return this; + } + + public bool HasAddress2 { + get { return result.hasAddress2; } + } + public string Address2 { + get { return result.Address2; } + set { SetAddress2(value); } + } + public Builder SetAddress2(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasAddress2 = true; + result.address2_ = value; + return this; + } + public Builder ClearAddress2() { + PrepareBuilder(); + result.hasAddress2 = false; + result.address2_ = ""; + return this; + } + + public bool HasCity { + get { return result.hasCity; } + } + public string City { + get { return result.City; } + set { SetCity(value); } + } + public Builder SetCity(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasCity = true; + result.city_ = value; + return this; + } + public Builder ClearCity() { + PrepareBuilder(); + result.hasCity = false; + result.city_ = ""; + return this; + } + + public bool HasState { + get { return result.hasState; } + } + public string State { + get { return result.State; } + set { SetState(value); } + } + public Builder SetState(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasState = true; + result.state_ = value; + return this; + } + public Builder ClearState() { + PrepareBuilder(); + result.hasState = false; + result.state_ = ""; + return this; + } + + public bool HasZip { + get { return result.hasZip; } + } + [global::System.CLSCompliant(false)] + public uint Zip { + get { return result.Zip; } + set { SetZip(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetZip(uint value) { + PrepareBuilder(); + result.hasZip = true; + result.zip_ = value; + return this; + } + public Builder ClearZip() { + PrepareBuilder(); + result.hasZip = false; + result.zip_ = 0; + return this; + } + } + static Addresses() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.Descriptor, null); + } + } + + } + #endregion + + public const int NameFieldNumber = 1; + private bool hasName; + private string name_ = ""; + public bool HasName { + get { return hasName; } + } + public string Name { + get { return name_; } + } + + public const int IdFieldNumber = 2; + private bool hasId; + private int id_; + public bool HasId { + get { return hasId; } + } + public int Id { + get { return id_; } + } + + public const int EmailFieldNumber = 3; + private bool hasEmail; + private string email_ = ""; + public bool HasEmail { + get { return hasEmail; } + } + public string Email { + get { return email_; } + } + + public const int CodesFieldNumber = 10; + private int codesMemoizedSerializedSize; + private pbc::PopsicleList codes_ = new pbc::PopsicleList(); + public scg::IList CodesList { + get { return pbc::Lists.AsReadOnly(codes_); } + } + public int CodesCount { + get { return codes_.Count; } + } + public int GetCodes(int index) { + return codes_[index]; + } + + public const int PhoneFieldNumber = 4; + private pbc::PopsicleList phone_ = new pbc::PopsicleList(); + public scg::IList PhoneList { + get { return phone_; } + } + public int PhoneCount { + get { return phone_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber GetPhone(int index) { + return phone_[index]; + } + + public const int AddressesFieldNumber = 5; + private pbc::PopsicleList addresses_ = new pbc::PopsicleList(); + public scg::IList AddressesList { + get { return addresses_; } + } + public int AddressesCount { + get { return addresses_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses GetAddresses(int index) { + return addresses_[index]; + } + + public override bool IsInitialized { + get { + if (!hasName) return false; + if (!hasId) return false; + foreach (global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber element in PhoneList) { + if (!element.IsInitialized) return false; + } + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testInteropPersonLiteFieldNames; + pb::ExtendableMessageLite.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + if (hasName) { + output.WriteString(1, field_names[4], Name); + } + if (hasId) { + output.WriteInt32(2, field_names[3], Id); + } + if (hasEmail) { + output.WriteString(3, field_names[2], Email); + } + if (phone_.Count > 0) { + output.WriteMessageArray(4, field_names[5], phone_); + } + if (addresses_.Count > 0) { + output.WriteGroupArray(5, field_names[0], addresses_); + } + if (codes_.Count > 0) { + output.WritePackedInt32Array(10, field_names[1], codesMemoizedSerializedSize, codes_); + } + extensionWriter.WriteUntil(200, output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasName) { + size += pb::CodedOutputStream.ComputeStringSize(1, Name); + } + if (hasId) { + size += pb::CodedOutputStream.ComputeInt32Size(2, Id); + } + if (hasEmail) { + size += pb::CodedOutputStream.ComputeStringSize(3, Email); + } + { + int dataSize = 0; + foreach (int element in CodesList) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + if (codes_.Count != 0) { + size += 1 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + codesMemoizedSerializedSize = dataSize; + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber element in PhoneList) { + size += pb::CodedOutputStream.ComputeMessageSize(4, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses element in AddressesList) { + size += pb::CodedOutputStream.ComputeGroupSize(5, element); + } + size += ExtensionsSerializedSize; + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasName) hash ^= name_.GetHashCode(); + if (hasId) hash ^= id_.GetHashCode(); + if (hasEmail) hash ^= email_.GetHashCode(); + foreach(int i in codes_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber i in phone_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses i in addresses_) + hash ^= i.GetHashCode(); + hash ^= base.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestInteropPersonLite other = obj as TestInteropPersonLite; + if (other == null) return false; + if (hasName != other.hasName || (hasName && !name_.Equals(other.name_))) return false; + if (hasId != other.hasId || (hasId && !id_.Equals(other.id_))) return false; + if (hasEmail != other.hasEmail || (hasEmail && !email_.Equals(other.email_))) return false; + if(codes_.Count != other.codes_.Count) return false; + for(int ix=0; ix < codes_.Count; ix++) + if(!codes_[ix].Equals(other.codes_[ix])) return false; + if(phone_.Count != other.phone_.Count) return false; + for(int ix=0; ix < phone_.Count; ix++) + if(!phone_[ix].Equals(other.phone_[ix])) return false; + if(addresses_.Count != other.addresses_.Count) return false; + for(int ix=0; ix < addresses_.Count; ix++) + if(!addresses_[ix].Equals(other.addresses_[ix])) return false; + if (!base.Equals(other)) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("name", hasName, name_, writer); + PrintField("id", hasId, id_, writer); + PrintField("email", hasEmail, email_, writer); + PrintField("phone", phone_, writer); + PrintField("Addresses", addresses_, writer); + PrintField("codes", codes_, writer); + base.PrintTo(writer); + } + #endregion + + public static TestInteropPersonLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestInteropPersonLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestInteropPersonLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestInteropPersonLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestInteropPersonLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestInteropPersonLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestInteropPersonLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestInteropPersonLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestInteropPersonLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestInteropPersonLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestInteropPersonLite MakeReadOnly() { + codes_.MakeReadOnly(); + phone_.MakeReadOnly(); + addresses_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestInteropPersonLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestInteropPersonLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestInteropPersonLite result; + + private TestInteropPersonLite PrepareBuilder() { + if (resultIsReadOnly) { + TestInteropPersonLite original = result; + result = new TestInteropPersonLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestInteropPersonLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestInteropPersonLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.DefaultInstance; } + } + + public override TestInteropPersonLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestInteropPersonLite) { + return MergeFrom((TestInteropPersonLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestInteropPersonLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasName) { + Name = other.Name; + } + if (other.HasId) { + Id = other.Id; + } + if (other.HasEmail) { + Email = other.Email; + } + if (other.codes_.Count != 0) { + result.codes_.Add(other.codes_); + } + if (other.phone_.Count != 0) { + result.phone_.Add(other.phone_); + } + if (other.addresses_.Count != 0) { + result.addresses_.Add(other.addresses_); + } + this.MergeExtensionFields(other); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testInteropPersonLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testInteropPersonLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 10: { + result.hasName = input.ReadString(ref result.name_); + break; + } + case 16: { + result.hasId = input.ReadInt32(ref result.id_); + break; + } + case 26: { + result.hasEmail = input.ReadString(ref result.email_); + break; + } + case 34: { + input.ReadMessageArray(tag, field_name, result.phone_, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber.DefaultInstance, extensionRegistry); + break; + } + case 43: { + input.ReadGroupArray(tag, field_name, result.addresses_, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses.DefaultInstance, extensionRegistry); + break; + } + case 82: + case 80: { + input.ReadInt32Array(tag, field_name, result.codes_); + break; + } + } + } + + return this; + } + + + public bool HasName { + get { return result.hasName; } + } + public string Name { + get { return result.Name; } + set { SetName(value); } + } + public Builder SetName(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasName = true; + result.name_ = value; + return this; + } + public Builder ClearName() { + PrepareBuilder(); + result.hasName = false; + result.name_ = ""; + return this; + } + + public bool HasId { + get { return result.hasId; } + } + public int Id { + get { return result.Id; } + set { SetId(value); } + } + public Builder SetId(int value) { + PrepareBuilder(); + result.hasId = true; + result.id_ = value; + return this; + } + public Builder ClearId() { + PrepareBuilder(); + result.hasId = false; + result.id_ = 0; + return this; + } + + public bool HasEmail { + get { return result.hasEmail; } + } + public string Email { + get { return result.Email; } + set { SetEmail(value); } + } + public Builder SetEmail(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasEmail = true; + result.email_ = value; + return this; + } + public Builder ClearEmail() { + PrepareBuilder(); + result.hasEmail = false; + result.email_ = ""; + return this; + } + + public pbc::IPopsicleList CodesList { + get { return PrepareBuilder().codes_; } + } + public int CodesCount { + get { return result.CodesCount; } + } + public int GetCodes(int index) { + return result.GetCodes(index); + } + public Builder SetCodes(int index, int value) { + PrepareBuilder(); + result.codes_[index] = value; + return this; + } + public Builder AddCodes(int value) { + PrepareBuilder(); + result.codes_.Add(value); + return this; + } + public Builder AddRangeCodes(scg::IEnumerable values) { + PrepareBuilder(); + result.codes_.Add(values); + return this; + } + public Builder ClearCodes() { + PrepareBuilder(); + result.codes_.Clear(); + return this; + } + + public pbc::IPopsicleList PhoneList { + get { return PrepareBuilder().phone_; } + } + public int PhoneCount { + get { return result.PhoneCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber GetPhone(int index) { + return result.GetPhone(index); + } + public Builder SetPhone(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.phone_[index] = value; + return this; + } + public Builder SetPhone(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.phone_[index] = builderForValue.Build(); + return this; + } + public Builder AddPhone(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.phone_.Add(value); + return this; + } + public Builder AddPhone(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.phone_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangePhone(scg::IEnumerable values) { + PrepareBuilder(); + result.phone_.Add(values); + return this; + } + public Builder ClearPhone() { + PrepareBuilder(); + result.phone_.Clear(); + return this; + } + + public pbc::IPopsicleList AddressesList { + get { return PrepareBuilder().addresses_; } + } + public int AddressesCount { + get { return result.AddressesCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses GetAddresses(int index) { + return result.GetAddresses(index); + } + public Builder SetAddresses(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.addresses_[index] = value; + return this; + } + public Builder SetAddresses(int index, global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.addresses_[index] = builderForValue.Build(); + return this; + } + public Builder AddAddresses(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.addresses_.Add(value); + return this; + } + public Builder AddAddresses(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.Addresses.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.addresses_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeAddresses(scg::IEnumerable values) { + PrepareBuilder(); + result.addresses_.Add(values); + return this; + } + public Builder ClearAddresses() { + PrepareBuilder(); + result.addresses_.Clear(); + return this; + } + } + static TestInteropPersonLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestInteropEmployeeIdLite : pb::GeneratedMessageLite { + private TestInteropEmployeeIdLite() { } + private static readonly TestInteropEmployeeIdLite defaultInstance = new TestInteropEmployeeIdLite().MakeReadOnly(); + private static readonly string[] _testInteropEmployeeIdLiteFieldNames = new string[] { "number" }; + private static readonly uint[] _testInteropEmployeeIdLiteFieldTags = new uint[] { 10 }; + public static TestInteropEmployeeIdLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestInteropEmployeeIdLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestInteropEmployeeIdLite ThisMessage { + get { return this; } + } + + public const int NumberFieldNumber = 1; + private bool hasNumber; + private string number_ = ""; + public bool HasNumber { + get { return hasNumber; } + } + public string Number { + get { return number_; } + } + + public override bool IsInitialized { + get { + if (!hasNumber) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testInteropEmployeeIdLiteFieldNames; + if (hasNumber) { + output.WriteString(1, field_names[0], Number); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasNumber) { + size += pb::CodedOutputStream.ComputeStringSize(1, Number); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasNumber) hash ^= number_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestInteropEmployeeIdLite other = obj as TestInteropEmployeeIdLite; + if (other == null) return false; + if (hasNumber != other.hasNumber || (hasNumber && !number_.Equals(other.number_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("number", hasNumber, number_, writer); + } + #endregion + + public static TestInteropEmployeeIdLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestInteropEmployeeIdLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestInteropEmployeeIdLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestInteropEmployeeIdLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestInteropEmployeeIdLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestInteropEmployeeIdLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestInteropEmployeeIdLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestInteropEmployeeIdLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestInteropEmployeeIdLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestInteropEmployeeIdLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestInteropEmployeeIdLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestInteropEmployeeIdLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestInteropEmployeeIdLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestInteropEmployeeIdLite result; + + private TestInteropEmployeeIdLite PrepareBuilder() { + if (resultIsReadOnly) { + TestInteropEmployeeIdLite original = result; + result = new TestInteropEmployeeIdLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestInteropEmployeeIdLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestInteropEmployeeIdLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestInteropEmployeeIdLite.DefaultInstance; } + } + + public override TestInteropEmployeeIdLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestInteropEmployeeIdLite) { + return MergeFrom((TestInteropEmployeeIdLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestInteropEmployeeIdLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestInteropEmployeeIdLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasNumber) { + Number = other.Number; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testInteropEmployeeIdLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testInteropEmployeeIdLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 10: { + result.hasNumber = input.ReadString(ref result.number_); + break; + } + } + } + + return this; + } + + + public bool HasNumber { + get { return result.hasNumber; } + } + public string Number { + get { return result.Number; } + set { SetNumber(value); } + } + public Builder SetNumber(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasNumber = true; + result.number_ = value; + return this; + } + public Builder ClearNumber() { + PrepareBuilder(); + result.hasNumber = false; + result.number_ = ""; + return this; + } + } + static TestInteropEmployeeIdLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestUnpackedExtensionsLite : pb::ExtendableMessageLite { + private TestUnpackedExtensionsLite() { } + private static readonly TestUnpackedExtensionsLite defaultInstance = new TestUnpackedExtensionsLite().MakeReadOnly(); + private static readonly string[] _testUnpackedExtensionsLiteFieldNames = new string[] { }; + private static readonly uint[] _testUnpackedExtensionsLiteFieldTags = new uint[] { }; + public static TestUnpackedExtensionsLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestUnpackedExtensionsLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestUnpackedExtensionsLite ThisMessage { + get { return this; } + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testUnpackedExtensionsLiteFieldNames; + pb::ExtendableMessageLite.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + hash ^= base.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestUnpackedExtensionsLite other = obj as TestUnpackedExtensionsLite; + if (other == null) return false; + if (!base.Equals(other)) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + base.PrintTo(writer); + } + #endregion + + public static TestUnpackedExtensionsLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedExtensionsLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedExtensionsLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedExtensionsLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedExtensionsLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedExtensionsLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestUnpackedExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestUnpackedExtensionsLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedExtensionsLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestUnpackedExtensionsLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestUnpackedExtensionsLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestUnpackedExtensionsLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestUnpackedExtensionsLite result; + + private TestUnpackedExtensionsLite PrepareBuilder() { + if (resultIsReadOnly) { + TestUnpackedExtensionsLite original = result; + result = new TestUnpackedExtensionsLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestUnpackedExtensionsLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestUnpackedExtensionsLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance; } + } + + public override TestUnpackedExtensionsLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestUnpackedExtensionsLite) { + return MergeFrom((TestUnpackedExtensionsLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestUnpackedExtensionsLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensionsLite.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testUnpackedExtensionsLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testUnpackedExtensionsLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + } + } + + return this; + } + + } + static TestUnpackedExtensionsLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestUnpackedTypesLite : pb::GeneratedMessageLite { + private TestUnpackedTypesLite() { } + private static readonly TestUnpackedTypesLite defaultInstance = new TestUnpackedTypesLite().MakeReadOnly(); + private static readonly string[] _testUnpackedTypesLiteFieldNames = new string[] { "unpacked_bool", "unpacked_double", "unpacked_enum", "unpacked_fixed32", "unpacked_fixed64", "unpacked_float", "unpacked_int32", "unpacked_int64", "unpacked_sfixed32", "unpacked_sfixed64", "unpacked_sint32", "unpacked_sint64", "unpacked_uint32", "unpacked_uint64" }; + private static readonly uint[] _testUnpackedTypesLiteFieldTags = new uint[] { 816, 809, 824, 773, 777, 805, 720, 728, 789, 793, 752, 760, 736, 744 }; + public static TestUnpackedTypesLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestUnpackedTypesLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestUnpackedTypesLite ThisMessage { + get { return this; } + } + + public const int UnpackedInt32FieldNumber = 90; + private pbc::PopsicleList unpackedInt32_ = new pbc::PopsicleList(); + public scg::IList UnpackedInt32List { + get { return pbc::Lists.AsReadOnly(unpackedInt32_); } + } + public int UnpackedInt32Count { + get { return unpackedInt32_.Count; } + } + public int GetUnpackedInt32(int index) { + return unpackedInt32_[index]; + } + + public const int UnpackedInt64FieldNumber = 91; + private pbc::PopsicleList unpackedInt64_ = new pbc::PopsicleList(); + public scg::IList UnpackedInt64List { + get { return pbc::Lists.AsReadOnly(unpackedInt64_); } + } + public int UnpackedInt64Count { + get { return unpackedInt64_.Count; } + } + public long GetUnpackedInt64(int index) { + return unpackedInt64_[index]; + } + + public const int UnpackedUint32FieldNumber = 92; + private pbc::PopsicleList unpackedUint32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedUint32List { + get { return pbc::Lists.AsReadOnly(unpackedUint32_); } + } + public int UnpackedUint32Count { + get { return unpackedUint32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedUint32(int index) { + return unpackedUint32_[index]; + } + + public const int UnpackedUint64FieldNumber = 93; + private pbc::PopsicleList unpackedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedUint64List { + get { return pbc::Lists.AsReadOnly(unpackedUint64_); } + } + public int UnpackedUint64Count { + get { return unpackedUint64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedUint64(int index) { + return unpackedUint64_[index]; + } + + public const int UnpackedSint32FieldNumber = 94; + private pbc::PopsicleList unpackedSint32_ = new pbc::PopsicleList(); + public scg::IList UnpackedSint32List { + get { return pbc::Lists.AsReadOnly(unpackedSint32_); } + } + public int UnpackedSint32Count { + get { return unpackedSint32_.Count; } + } + public int GetUnpackedSint32(int index) { + return unpackedSint32_[index]; + } + + public const int UnpackedSint64FieldNumber = 95; + private pbc::PopsicleList unpackedSint64_ = new pbc::PopsicleList(); + public scg::IList UnpackedSint64List { + get { return pbc::Lists.AsReadOnly(unpackedSint64_); } + } + public int UnpackedSint64Count { + get { return unpackedSint64_.Count; } + } + public long GetUnpackedSint64(int index) { + return unpackedSint64_[index]; + } + + public const int UnpackedFixed32FieldNumber = 96; + private pbc::PopsicleList unpackedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedFixed32List { + get { return pbc::Lists.AsReadOnly(unpackedFixed32_); } + } + public int UnpackedFixed32Count { + get { return unpackedFixed32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedFixed32(int index) { + return unpackedFixed32_[index]; + } + + public const int UnpackedFixed64FieldNumber = 97; + private pbc::PopsicleList unpackedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedFixed64List { + get { return pbc::Lists.AsReadOnly(unpackedFixed64_); } + } + public int UnpackedFixed64Count { + get { return unpackedFixed64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedFixed64(int index) { + return unpackedFixed64_[index]; + } + + public const int UnpackedSfixed32FieldNumber = 98; + private pbc::PopsicleList unpackedSfixed32_ = new pbc::PopsicleList(); + public scg::IList UnpackedSfixed32List { + get { return pbc::Lists.AsReadOnly(unpackedSfixed32_); } + } + public int UnpackedSfixed32Count { + get { return unpackedSfixed32_.Count; } + } + public int GetUnpackedSfixed32(int index) { + return unpackedSfixed32_[index]; + } + + public const int UnpackedSfixed64FieldNumber = 99; + private pbc::PopsicleList unpackedSfixed64_ = new pbc::PopsicleList(); + public scg::IList UnpackedSfixed64List { + get { return pbc::Lists.AsReadOnly(unpackedSfixed64_); } + } + public int UnpackedSfixed64Count { + get { return unpackedSfixed64_.Count; } + } + public long GetUnpackedSfixed64(int index) { + return unpackedSfixed64_[index]; + } + + public const int UnpackedFloatFieldNumber = 100; + private pbc::PopsicleList unpackedFloat_ = new pbc::PopsicleList(); + public scg::IList UnpackedFloatList { + get { return pbc::Lists.AsReadOnly(unpackedFloat_); } + } + public int UnpackedFloatCount { + get { return unpackedFloat_.Count; } + } + public float GetUnpackedFloat(int index) { + return unpackedFloat_[index]; + } + + public const int UnpackedDoubleFieldNumber = 101; + private pbc::PopsicleList unpackedDouble_ = new pbc::PopsicleList(); + public scg::IList UnpackedDoubleList { + get { return pbc::Lists.AsReadOnly(unpackedDouble_); } + } + public int UnpackedDoubleCount { + get { return unpackedDouble_.Count; } + } + public double GetUnpackedDouble(int index) { + return unpackedDouble_[index]; + } + + public const int UnpackedBoolFieldNumber = 102; + private pbc::PopsicleList unpackedBool_ = new pbc::PopsicleList(); + public scg::IList UnpackedBoolList { + get { return pbc::Lists.AsReadOnly(unpackedBool_); } + } + public int UnpackedBoolCount { + get { return unpackedBool_.Count; } + } + public bool GetUnpackedBool(int index) { + return unpackedBool_[index]; + } + + public const int UnpackedEnumFieldNumber = 103; + private pbc::PopsicleList unpackedEnum_ = new pbc::PopsicleList(); + public scg::IList UnpackedEnumList { + get { return pbc::Lists.AsReadOnly(unpackedEnum_); } + } + public int UnpackedEnumCount { + get { return unpackedEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite GetUnpackedEnum(int index) { + return unpackedEnum_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testUnpackedTypesLiteFieldNames; + if (unpackedInt32_.Count > 0) { + output.WriteInt32Array(90, field_names[6], unpackedInt32_); + } + if (unpackedInt64_.Count > 0) { + output.WriteInt64Array(91, field_names[7], unpackedInt64_); + } + if (unpackedUint32_.Count > 0) { + output.WriteUInt32Array(92, field_names[12], unpackedUint32_); + } + if (unpackedUint64_.Count > 0) { + output.WriteUInt64Array(93, field_names[13], unpackedUint64_); + } + if (unpackedSint32_.Count > 0) { + output.WriteSInt32Array(94, field_names[10], unpackedSint32_); + } + if (unpackedSint64_.Count > 0) { + output.WriteSInt64Array(95, field_names[11], unpackedSint64_); + } + if (unpackedFixed32_.Count > 0) { + output.WriteFixed32Array(96, field_names[3], unpackedFixed32_); + } + if (unpackedFixed64_.Count > 0) { + output.WriteFixed64Array(97, field_names[4], unpackedFixed64_); + } + if (unpackedSfixed32_.Count > 0) { + output.WriteSFixed32Array(98, field_names[8], unpackedSfixed32_); + } + if (unpackedSfixed64_.Count > 0) { + output.WriteSFixed64Array(99, field_names[9], unpackedSfixed64_); + } + if (unpackedFloat_.Count > 0) { + output.WriteFloatArray(100, field_names[5], unpackedFloat_); + } + if (unpackedDouble_.Count > 0) { + output.WriteDoubleArray(101, field_names[1], unpackedDouble_); + } + if (unpackedBool_.Count > 0) { + output.WriteBoolArray(102, field_names[0], unpackedBool_); + } + if (unpackedEnum_.Count > 0) { + output.WriteEnumArray(103, field_names[2], unpackedEnum_); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + foreach (int element in UnpackedInt32List) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedInt32_.Count; + } + { + int dataSize = 0; + foreach (long element in UnpackedInt64List) { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedInt64_.Count; + } + { + int dataSize = 0; + foreach (uint element in UnpackedUint32List) { + dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedUint32_.Count; + } + { + int dataSize = 0; + foreach (ulong element in UnpackedUint64List) { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedUint64_.Count; + } + { + int dataSize = 0; + foreach (int element in UnpackedSint32List) { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedSint32_.Count; + } + { + int dataSize = 0; + foreach (long element in UnpackedSint64List) { + dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedSint64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * unpackedFixed32_.Count; + size += dataSize; + size += 2 * unpackedFixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * unpackedFixed64_.Count; + size += dataSize; + size += 2 * unpackedFixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * unpackedSfixed32_.Count; + size += dataSize; + size += 2 * unpackedSfixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * unpackedSfixed64_.Count; + size += dataSize; + size += 2 * unpackedSfixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * unpackedFloat_.Count; + size += dataSize; + size += 2 * unpackedFloat_.Count; + } + { + int dataSize = 0; + dataSize = 8 * unpackedDouble_.Count; + size += dataSize; + size += 2 * unpackedDouble_.Count; + } + { + int dataSize = 0; + dataSize = 1 * unpackedBool_.Count; + size += dataSize; + size += 2 * unpackedBool_.Count; + } + { + int dataSize = 0; + if (unpackedEnum_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite element in unpackedEnum_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 2 * unpackedEnum_.Count; + } + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + foreach(int i in unpackedInt32_) + hash ^= i.GetHashCode(); + foreach(long i in unpackedInt64_) + hash ^= i.GetHashCode(); + foreach(uint i in unpackedUint32_) + hash ^= i.GetHashCode(); + foreach(ulong i in unpackedUint64_) + hash ^= i.GetHashCode(); + foreach(int i in unpackedSint32_) + hash ^= i.GetHashCode(); + foreach(long i in unpackedSint64_) + hash ^= i.GetHashCode(); + foreach(uint i in unpackedFixed32_) + hash ^= i.GetHashCode(); + foreach(ulong i in unpackedFixed64_) + hash ^= i.GetHashCode(); + foreach(int i in unpackedSfixed32_) + hash ^= i.GetHashCode(); + foreach(long i in unpackedSfixed64_) + hash ^= i.GetHashCode(); + foreach(float i in unpackedFloat_) + hash ^= i.GetHashCode(); + foreach(double i in unpackedDouble_) + hash ^= i.GetHashCode(); + foreach(bool i in unpackedBool_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite i in unpackedEnum_) + hash ^= i.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestUnpackedTypesLite other = obj as TestUnpackedTypesLite; + if (other == null) return false; + if(unpackedInt32_.Count != other.unpackedInt32_.Count) return false; + for(int ix=0; ix < unpackedInt32_.Count; ix++) + if(!unpackedInt32_[ix].Equals(other.unpackedInt32_[ix])) return false; + if(unpackedInt64_.Count != other.unpackedInt64_.Count) return false; + for(int ix=0; ix < unpackedInt64_.Count; ix++) + if(!unpackedInt64_[ix].Equals(other.unpackedInt64_[ix])) return false; + if(unpackedUint32_.Count != other.unpackedUint32_.Count) return false; + for(int ix=0; ix < unpackedUint32_.Count; ix++) + if(!unpackedUint32_[ix].Equals(other.unpackedUint32_[ix])) return false; + if(unpackedUint64_.Count != other.unpackedUint64_.Count) return false; + for(int ix=0; ix < unpackedUint64_.Count; ix++) + if(!unpackedUint64_[ix].Equals(other.unpackedUint64_[ix])) return false; + if(unpackedSint32_.Count != other.unpackedSint32_.Count) return false; + for(int ix=0; ix < unpackedSint32_.Count; ix++) + if(!unpackedSint32_[ix].Equals(other.unpackedSint32_[ix])) return false; + if(unpackedSint64_.Count != other.unpackedSint64_.Count) return false; + for(int ix=0; ix < unpackedSint64_.Count; ix++) + if(!unpackedSint64_[ix].Equals(other.unpackedSint64_[ix])) return false; + if(unpackedFixed32_.Count != other.unpackedFixed32_.Count) return false; + for(int ix=0; ix < unpackedFixed32_.Count; ix++) + if(!unpackedFixed32_[ix].Equals(other.unpackedFixed32_[ix])) return false; + if(unpackedFixed64_.Count != other.unpackedFixed64_.Count) return false; + for(int ix=0; ix < unpackedFixed64_.Count; ix++) + if(!unpackedFixed64_[ix].Equals(other.unpackedFixed64_[ix])) return false; + if(unpackedSfixed32_.Count != other.unpackedSfixed32_.Count) return false; + for(int ix=0; ix < unpackedSfixed32_.Count; ix++) + if(!unpackedSfixed32_[ix].Equals(other.unpackedSfixed32_[ix])) return false; + if(unpackedSfixed64_.Count != other.unpackedSfixed64_.Count) return false; + for(int ix=0; ix < unpackedSfixed64_.Count; ix++) + if(!unpackedSfixed64_[ix].Equals(other.unpackedSfixed64_[ix])) return false; + if(unpackedFloat_.Count != other.unpackedFloat_.Count) return false; + for(int ix=0; ix < unpackedFloat_.Count; ix++) + if(!unpackedFloat_[ix].Equals(other.unpackedFloat_[ix])) return false; + if(unpackedDouble_.Count != other.unpackedDouble_.Count) return false; + for(int ix=0; ix < unpackedDouble_.Count; ix++) + if(!unpackedDouble_[ix].Equals(other.unpackedDouble_[ix])) return false; + if(unpackedBool_.Count != other.unpackedBool_.Count) return false; + for(int ix=0; ix < unpackedBool_.Count; ix++) + if(!unpackedBool_[ix].Equals(other.unpackedBool_[ix])) return false; + if(unpackedEnum_.Count != other.unpackedEnum_.Count) return false; + for(int ix=0; ix < unpackedEnum_.Count; ix++) + if(!unpackedEnum_[ix].Equals(other.unpackedEnum_[ix])) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("unpacked_int32", unpackedInt32_, writer); + PrintField("unpacked_int64", unpackedInt64_, writer); + PrintField("unpacked_uint32", unpackedUint32_, writer); + PrintField("unpacked_uint64", unpackedUint64_, writer); + PrintField("unpacked_sint32", unpackedSint32_, writer); + PrintField("unpacked_sint64", unpackedSint64_, writer); + PrintField("unpacked_fixed32", unpackedFixed32_, writer); + PrintField("unpacked_fixed64", unpackedFixed64_, writer); + PrintField("unpacked_sfixed32", unpackedSfixed32_, writer); + PrintField("unpacked_sfixed64", unpackedSfixed64_, writer); + PrintField("unpacked_float", unpackedFloat_, writer); + PrintField("unpacked_double", unpackedDouble_, writer); + PrintField("unpacked_bool", unpackedBool_, writer); + PrintField("unpacked_enum", unpackedEnum_, writer); + } + #endregion + + public static TestUnpackedTypesLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedTypesLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedTypesLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedTypesLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedTypesLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedTypesLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedTypesLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestUnpackedTypesLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestUnpackedTypesLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedTypesLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestUnpackedTypesLite MakeReadOnly() { + unpackedInt32_.MakeReadOnly(); + unpackedInt64_.MakeReadOnly(); + unpackedUint32_.MakeReadOnly(); + unpackedUint64_.MakeReadOnly(); + unpackedSint32_.MakeReadOnly(); + unpackedSint64_.MakeReadOnly(); + unpackedFixed32_.MakeReadOnly(); + unpackedFixed64_.MakeReadOnly(); + unpackedSfixed32_.MakeReadOnly(); + unpackedSfixed64_.MakeReadOnly(); + unpackedFloat_.MakeReadOnly(); + unpackedDouble_.MakeReadOnly(); + unpackedBool_.MakeReadOnly(); + unpackedEnum_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestUnpackedTypesLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestUnpackedTypesLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestUnpackedTypesLite result; + + private TestUnpackedTypesLite PrepareBuilder() { + if (resultIsReadOnly) { + TestUnpackedTypesLite original = result; + result = new TestUnpackedTypesLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestUnpackedTypesLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestUnpackedTypesLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypesLite.DefaultInstance; } + } + + public override TestUnpackedTypesLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestUnpackedTypesLite) { + return MergeFrom((TestUnpackedTypesLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestUnpackedTypesLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypesLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.unpackedInt32_.Count != 0) { + result.unpackedInt32_.Add(other.unpackedInt32_); + } + if (other.unpackedInt64_.Count != 0) { + result.unpackedInt64_.Add(other.unpackedInt64_); + } + if (other.unpackedUint32_.Count != 0) { + result.unpackedUint32_.Add(other.unpackedUint32_); + } + if (other.unpackedUint64_.Count != 0) { + result.unpackedUint64_.Add(other.unpackedUint64_); + } + if (other.unpackedSint32_.Count != 0) { + result.unpackedSint32_.Add(other.unpackedSint32_); + } + if (other.unpackedSint64_.Count != 0) { + result.unpackedSint64_.Add(other.unpackedSint64_); + } + if (other.unpackedFixed32_.Count != 0) { + result.unpackedFixed32_.Add(other.unpackedFixed32_); + } + if (other.unpackedFixed64_.Count != 0) { + result.unpackedFixed64_.Add(other.unpackedFixed64_); + } + if (other.unpackedSfixed32_.Count != 0) { + result.unpackedSfixed32_.Add(other.unpackedSfixed32_); + } + if (other.unpackedSfixed64_.Count != 0) { + result.unpackedSfixed64_.Add(other.unpackedSfixed64_); + } + if (other.unpackedFloat_.Count != 0) { + result.unpackedFloat_.Add(other.unpackedFloat_); + } + if (other.unpackedDouble_.Count != 0) { + result.unpackedDouble_.Add(other.unpackedDouble_); + } + if (other.unpackedBool_.Count != 0) { + result.unpackedBool_.Add(other.unpackedBool_); + } + if (other.unpackedEnum_.Count != 0) { + result.unpackedEnum_.Add(other.unpackedEnum_); + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testUnpackedTypesLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testUnpackedTypesLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 722: + case 720: { + input.ReadInt32Array(tag, field_name, result.unpackedInt32_); + break; + } + case 730: + case 728: { + input.ReadInt64Array(tag, field_name, result.unpackedInt64_); + break; + } + case 738: + case 736: { + input.ReadUInt32Array(tag, field_name, result.unpackedUint32_); + break; + } + case 746: + case 744: { + input.ReadUInt64Array(tag, field_name, result.unpackedUint64_); + break; + } + case 754: + case 752: { + input.ReadSInt32Array(tag, field_name, result.unpackedSint32_); + break; + } + case 762: + case 760: { + input.ReadSInt64Array(tag, field_name, result.unpackedSint64_); + break; + } + case 770: + case 773: { + input.ReadFixed32Array(tag, field_name, result.unpackedFixed32_); + break; + } + case 778: + case 777: { + input.ReadFixed64Array(tag, field_name, result.unpackedFixed64_); + break; + } + case 786: + case 789: { + input.ReadSFixed32Array(tag, field_name, result.unpackedSfixed32_); + break; + } + case 794: + case 793: { + input.ReadSFixed64Array(tag, field_name, result.unpackedSfixed64_); + break; + } + case 802: + case 805: { + input.ReadFloatArray(tag, field_name, result.unpackedFloat_); + break; + } + case 810: + case 809: { + input.ReadDoubleArray(tag, field_name, result.unpackedDouble_); + break; + } + case 818: + case 816: { + input.ReadBoolArray(tag, field_name, result.unpackedBool_); + break; + } + case 826: + case 824: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.unpackedEnum_, out unknownItems); + break; + } + } + } + + return this; + } + + + public pbc::IPopsicleList UnpackedInt32List { + get { return PrepareBuilder().unpackedInt32_; } + } + public int UnpackedInt32Count { + get { return result.UnpackedInt32Count; } + } + public int GetUnpackedInt32(int index) { + return result.GetUnpackedInt32(index); + } + public Builder SetUnpackedInt32(int index, int value) { + PrepareBuilder(); + result.unpackedInt32_[index] = value; + return this; + } + public Builder AddUnpackedInt32(int value) { + PrepareBuilder(); + result.unpackedInt32_.Add(value); + return this; + } + public Builder AddRangeUnpackedInt32(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedInt32_.Add(values); + return this; + } + public Builder ClearUnpackedInt32() { + PrepareBuilder(); + result.unpackedInt32_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedInt64List { + get { return PrepareBuilder().unpackedInt64_; } + } + public int UnpackedInt64Count { + get { return result.UnpackedInt64Count; } + } + public long GetUnpackedInt64(int index) { + return result.GetUnpackedInt64(index); + } + public Builder SetUnpackedInt64(int index, long value) { + PrepareBuilder(); + result.unpackedInt64_[index] = value; + return this; + } + public Builder AddUnpackedInt64(long value) { + PrepareBuilder(); + result.unpackedInt64_.Add(value); + return this; + } + public Builder AddRangeUnpackedInt64(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedInt64_.Add(values); + return this; + } + public Builder ClearUnpackedInt64() { + PrepareBuilder(); + result.unpackedInt64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedUint32List { + get { return PrepareBuilder().unpackedUint32_; } + } + public int UnpackedUint32Count { + get { return result.UnpackedUint32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedUint32(int index) { + return result.GetUnpackedUint32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedUint32(int index, uint value) { + PrepareBuilder(); + result.unpackedUint32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedUint32(uint value) { + PrepareBuilder(); + result.unpackedUint32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedUint32(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedUint32_.Add(values); + return this; + } + public Builder ClearUnpackedUint32() { + PrepareBuilder(); + result.unpackedUint32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedUint64List { + get { return PrepareBuilder().unpackedUint64_; } + } + public int UnpackedUint64Count { + get { return result.UnpackedUint64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedUint64(int index) { + return result.GetUnpackedUint64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedUint64(int index, ulong value) { + PrepareBuilder(); + result.unpackedUint64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedUint64(ulong value) { + PrepareBuilder(); + result.unpackedUint64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedUint64(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedUint64_.Add(values); + return this; + } + public Builder ClearUnpackedUint64() { + PrepareBuilder(); + result.unpackedUint64_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedSint32List { + get { return PrepareBuilder().unpackedSint32_; } + } + public int UnpackedSint32Count { + get { return result.UnpackedSint32Count; } + } + public int GetUnpackedSint32(int index) { + return result.GetUnpackedSint32(index); + } + public Builder SetUnpackedSint32(int index, int value) { + PrepareBuilder(); + result.unpackedSint32_[index] = value; + return this; + } + public Builder AddUnpackedSint32(int value) { + PrepareBuilder(); + result.unpackedSint32_.Add(value); + return this; + } + public Builder AddRangeUnpackedSint32(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedSint32_.Add(values); + return this; + } + public Builder ClearUnpackedSint32() { + PrepareBuilder(); + result.unpackedSint32_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedSint64List { + get { return PrepareBuilder().unpackedSint64_; } + } + public int UnpackedSint64Count { + get { return result.UnpackedSint64Count; } + } + public long GetUnpackedSint64(int index) { + return result.GetUnpackedSint64(index); + } + public Builder SetUnpackedSint64(int index, long value) { + PrepareBuilder(); + result.unpackedSint64_[index] = value; + return this; + } + public Builder AddUnpackedSint64(long value) { + PrepareBuilder(); + result.unpackedSint64_.Add(value); + return this; + } + public Builder AddRangeUnpackedSint64(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedSint64_.Add(values); + return this; + } + public Builder ClearUnpackedSint64() { + PrepareBuilder(); + result.unpackedSint64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedFixed32List { + get { return PrepareBuilder().unpackedFixed32_; } + } + public int UnpackedFixed32Count { + get { return result.UnpackedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedFixed32(int index) { + return result.GetUnpackedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedFixed32(int index, uint value) { + PrepareBuilder(); + result.unpackedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedFixed32(uint value) { + PrepareBuilder(); + result.unpackedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedFixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedFixed32_.Add(values); + return this; + } + public Builder ClearUnpackedFixed32() { + PrepareBuilder(); + result.unpackedFixed32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedFixed64List { + get { return PrepareBuilder().unpackedFixed64_; } + } + public int UnpackedFixed64Count { + get { return result.UnpackedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedFixed64(int index) { + return result.GetUnpackedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedFixed64(int index, ulong value) { + PrepareBuilder(); + result.unpackedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedFixed64(ulong value) { + PrepareBuilder(); + result.unpackedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedFixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedFixed64_.Add(values); + return this; + } + public Builder ClearUnpackedFixed64() { + PrepareBuilder(); + result.unpackedFixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedSfixed32List { + get { return PrepareBuilder().unpackedSfixed32_; } + } + public int UnpackedSfixed32Count { + get { return result.UnpackedSfixed32Count; } + } + public int GetUnpackedSfixed32(int index) { + return result.GetUnpackedSfixed32(index); + } + public Builder SetUnpackedSfixed32(int index, int value) { + PrepareBuilder(); + result.unpackedSfixed32_[index] = value; + return this; + } + public Builder AddUnpackedSfixed32(int value) { + PrepareBuilder(); + result.unpackedSfixed32_.Add(value); + return this; + } + public Builder AddRangeUnpackedSfixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedSfixed32_.Add(values); + return this; + } + public Builder ClearUnpackedSfixed32() { + PrepareBuilder(); + result.unpackedSfixed32_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedSfixed64List { + get { return PrepareBuilder().unpackedSfixed64_; } + } + public int UnpackedSfixed64Count { + get { return result.UnpackedSfixed64Count; } + } + public long GetUnpackedSfixed64(int index) { + return result.GetUnpackedSfixed64(index); + } + public Builder SetUnpackedSfixed64(int index, long value) { + PrepareBuilder(); + result.unpackedSfixed64_[index] = value; + return this; + } + public Builder AddUnpackedSfixed64(long value) { + PrepareBuilder(); + result.unpackedSfixed64_.Add(value); + return this; + } + public Builder AddRangeUnpackedSfixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedSfixed64_.Add(values); + return this; + } + public Builder ClearUnpackedSfixed64() { + PrepareBuilder(); + result.unpackedSfixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedFloatList { + get { return PrepareBuilder().unpackedFloat_; } + } + public int UnpackedFloatCount { + get { return result.UnpackedFloatCount; } + } + public float GetUnpackedFloat(int index) { + return result.GetUnpackedFloat(index); + } + public Builder SetUnpackedFloat(int index, float value) { + PrepareBuilder(); + result.unpackedFloat_[index] = value; + return this; + } + public Builder AddUnpackedFloat(float value) { + PrepareBuilder(); + result.unpackedFloat_.Add(value); + return this; + } + public Builder AddRangeUnpackedFloat(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedFloat_.Add(values); + return this; + } + public Builder ClearUnpackedFloat() { + PrepareBuilder(); + result.unpackedFloat_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedDoubleList { + get { return PrepareBuilder().unpackedDouble_; } + } + public int UnpackedDoubleCount { + get { return result.UnpackedDoubleCount; } + } + public double GetUnpackedDouble(int index) { + return result.GetUnpackedDouble(index); + } + public Builder SetUnpackedDouble(int index, double value) { + PrepareBuilder(); + result.unpackedDouble_[index] = value; + return this; + } + public Builder AddUnpackedDouble(double value) { + PrepareBuilder(); + result.unpackedDouble_.Add(value); + return this; + } + public Builder AddRangeUnpackedDouble(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedDouble_.Add(values); + return this; + } + public Builder ClearUnpackedDouble() { + PrepareBuilder(); + result.unpackedDouble_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedBoolList { + get { return PrepareBuilder().unpackedBool_; } + } + public int UnpackedBoolCount { + get { return result.UnpackedBoolCount; } + } + public bool GetUnpackedBool(int index) { + return result.GetUnpackedBool(index); + } + public Builder SetUnpackedBool(int index, bool value) { + PrepareBuilder(); + result.unpackedBool_[index] = value; + return this; + } + public Builder AddUnpackedBool(bool value) { + PrepareBuilder(); + result.unpackedBool_.Add(value); + return this; + } + public Builder AddRangeUnpackedBool(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedBool_.Add(values); + return this; + } + public Builder ClearUnpackedBool() { + PrepareBuilder(); + result.unpackedBool_.Clear(); + return this; + } + + public pbc::IPopsicleList UnpackedEnumList { + get { return PrepareBuilder().unpackedEnum_; } + } + public int UnpackedEnumCount { + get { return result.UnpackedEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite GetUnpackedEnum(int index) { + return result.GetUnpackedEnum(index); + } + public Builder SetUnpackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite value) { + PrepareBuilder(); + result.unpackedEnum_[index] = value; + return this; + } + public Builder AddUnpackedEnum(global::Google.ProtocolBuffers.TestProtos.UnpackedTypesForeignEnumLite value) { + PrepareBuilder(); + result.unpackedEnum_.Add(value); + return this; + } + public Builder AddRangeUnpackedEnum(scg::IEnumerable values) { + PrepareBuilder(); + result.unpackedEnum_.Add(values); + return this; + } + public Builder ClearUnpackedEnum() { + PrepareBuilder(); + result.unpackedEnum_.Clear(); + return this; + } + } + static TestUnpackedTypesLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class BucketOfBytes : pb::GeneratedMessageLite { + private BucketOfBytes() { } + private static readonly BucketOfBytes defaultInstance = new BucketOfBytes().MakeReadOnly(); + private static readonly string[] _bucketOfBytesFieldNames = new string[] { "value" }; + private static readonly uint[] _bucketOfBytesFieldTags = new uint[] { 10 }; + public static BucketOfBytes DefaultInstance { + get { return defaultInstance; } + } + + public override BucketOfBytes DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override BucketOfBytes ThisMessage { + get { return this; } + } + + public const int ValueFieldNumber = 1; + private bool hasValue; + private pb::ByteString value_ = pb::ByteString.Empty; + public bool HasValue { + get { return hasValue; } + } + public pb::ByteString Value { + get { return value_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _bucketOfBytesFieldNames; + if (hasValue) { + output.WriteBytes(1, field_names[0], Value); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasValue) { + size += pb::CodedOutputStream.ComputeBytesSize(1, Value); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasValue) hash ^= value_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + BucketOfBytes other = obj as BucketOfBytes; + if (other == null) return false; + if (hasValue != other.hasValue || (hasValue && !value_.Equals(other.value_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("value", hasValue, value_, writer); + } + #endregion + + public static BucketOfBytes ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BucketOfBytes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BucketOfBytes ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BucketOfBytes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BucketOfBytes ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BucketOfBytes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static BucketOfBytes ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static BucketOfBytes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static BucketOfBytes ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BucketOfBytes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private BucketOfBytes MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(BucketOfBytes prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(BucketOfBytes cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private BucketOfBytes result; + + private BucketOfBytes PrepareBuilder() { + if (resultIsReadOnly) { + BucketOfBytes original = result; + result = new BucketOfBytes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override BucketOfBytes MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override BucketOfBytes DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.BucketOfBytes.DefaultInstance; } + } + + public override BucketOfBytes BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is BucketOfBytes) { + return MergeFrom((BucketOfBytes) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(BucketOfBytes other) { + if (other == global::Google.ProtocolBuffers.TestProtos.BucketOfBytes.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasValue) { + Value = other.Value; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_bucketOfBytesFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _bucketOfBytesFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 10: { + result.hasValue = input.ReadBytes(ref result.value_); + break; + } + } + } + + return this; + } + + + public bool HasValue { + get { return result.hasValue; } + } + public pb::ByteString Value { + get { return result.Value; } + set { SetValue(value); } + } + public Builder SetValue(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasValue = true; + result.value_ = value; + return this; + } + public Builder ClearValue() { + PrepareBuilder(); + result.hasValue = false; + result.value_ = pb::ByteString.Empty; + return this; + } + } + static BucketOfBytes() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class BucketOfBytesEx : pb::GeneratedMessageLite { + private BucketOfBytesEx() { } + private static readonly BucketOfBytesEx defaultInstance = new BucketOfBytesEx().MakeReadOnly(); + private static readonly string[] _bucketOfBytesExFieldNames = new string[] { "value", "value2" }; + private static readonly uint[] _bucketOfBytesExFieldTags = new uint[] { 10, 2042 }; + public static BucketOfBytesEx DefaultInstance { + get { return defaultInstance; } + } + + public override BucketOfBytesEx DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override BucketOfBytesEx ThisMessage { + get { return this; } + } + + public const int ValueFieldNumber = 1; + private bool hasValue; + private pb::ByteString value_ = pb::ByteString.Empty; + public bool HasValue { + get { return hasValue; } + } + public pb::ByteString Value { + get { return value_; } + } + + public const int Value2FieldNumber = 255; + private bool hasValue2; + private pb::ByteString value2_ = pb::ByteString.Empty; + public bool HasValue2 { + get { return hasValue2; } + } + public pb::ByteString Value2 { + get { return value2_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _bucketOfBytesExFieldNames; + if (hasValue) { + output.WriteBytes(1, field_names[0], Value); + } + if (hasValue2) { + output.WriteBytes(255, field_names[1], Value2); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasValue) { + size += pb::CodedOutputStream.ComputeBytesSize(1, Value); + } + if (hasValue2) { + size += pb::CodedOutputStream.ComputeBytesSize(255, Value2); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasValue) hash ^= value_.GetHashCode(); + if (hasValue2) hash ^= value2_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + BucketOfBytesEx other = obj as BucketOfBytesEx; + if (other == null) return false; + if (hasValue != other.hasValue || (hasValue && !value_.Equals(other.value_))) return false; + if (hasValue2 != other.hasValue2 || (hasValue2 && !value2_.Equals(other.value2_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("value", hasValue, value_, writer); + PrintField("value2", hasValue2, value2_, writer); + } + #endregion + + public static BucketOfBytesEx ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BucketOfBytesEx ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BucketOfBytesEx ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BucketOfBytesEx ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BucketOfBytesEx ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BucketOfBytesEx ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static BucketOfBytesEx ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static BucketOfBytesEx ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static BucketOfBytesEx ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BucketOfBytesEx ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private BucketOfBytesEx MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(BucketOfBytesEx prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(BucketOfBytesEx cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private BucketOfBytesEx result; + + private BucketOfBytesEx PrepareBuilder() { + if (resultIsReadOnly) { + BucketOfBytesEx original = result; + result = new BucketOfBytesEx(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override BucketOfBytesEx MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override BucketOfBytesEx DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.BucketOfBytesEx.DefaultInstance; } + } + + public override BucketOfBytesEx BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is BucketOfBytesEx) { + return MergeFrom((BucketOfBytesEx) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(BucketOfBytesEx other) { + if (other == global::Google.ProtocolBuffers.TestProtos.BucketOfBytesEx.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasValue) { + Value = other.Value; + } + if (other.HasValue2) { + Value2 = other.Value2; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_bucketOfBytesExFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _bucketOfBytesExFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 10: { + result.hasValue = input.ReadBytes(ref result.value_); + break; + } + case 2042: { + result.hasValue2 = input.ReadBytes(ref result.value2_); + break; + } + } + } + + return this; + } + + + public bool HasValue { + get { return result.hasValue; } + } + public pb::ByteString Value { + get { return result.Value; } + set { SetValue(value); } + } + public Builder SetValue(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasValue = true; + result.value_ = value; + return this; + } + public Builder ClearValue() { + PrepareBuilder(); + result.hasValue = false; + result.value_ = pb::ByteString.Empty; + return this; + } + + public bool HasValue2 { + get { return result.hasValue2; } + } + public pb::ByteString Value2 { + get { return result.Value2; } + set { SetValue2(value); } + } + public Builder SetValue2(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasValue2 = true; + result.value2_ = value; + return this; + } + public Builder ClearValue2() { + PrepareBuilder(); + result.hasValue2 = false; + result.value2_ = pb::ByteString.Empty; + return this; + } + } + static BucketOfBytesEx() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasLite.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasXmltest.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasXmltest.cs new file mode 100644 index 00000000..70bdbfa9 --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasXmltest.cs @@ -0,0 +1,2277 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: unittest_extras_xmltest.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace Google.ProtocolBuffers.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class UnittestExtrasXmltest { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionEnum); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionText); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionNumber); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionMessage); + } + #endregion + #region Extensions + public const int ExtensionEnumFieldNumber = 101; + public static pb::GeneratedExtensionBase ExtensionEnum; + public const int ExtensionTextFieldNumber = 102; + public static pb::GeneratedExtensionBase ExtensionText; + public const int ExtensionNumberFieldNumber = 103; + public static pb::GeneratedExtensionBase> ExtensionNumber; + public const int ExtensionMessageFieldNumber = 199; + public static pb::GeneratedExtensionBase ExtensionMessage; + #endregion + + #region Static variables + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlChild__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlChild__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlNoFields__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlNoFields__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlRescursive__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlRescursive__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlMessage_Children__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlMessage_Children__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlExtension__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlExtension__FieldAccessorTable; + #endregion + #region Descriptor + public static pbd::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbd::FileDescriptor descriptor; + + static UnittestExtrasXmltest() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ch11bml0dGVzdF9leHRyYXNfeG1sdGVzdC5wcm90bxIXcHJvdG9idWZfdW5p", + "dHRlc3RfZXh0cmEiVQoMVGVzdFhtbENoaWxkEjUKB29wdGlvbnMYAyADKA4y", + "JC5wcm90b2J1Zl91bml0dGVzdF9leHRyYS5FbnVtT3B0aW9ucxIOCgZiaW5h", + "cnkYBCABKAwiEQoPVGVzdFhtbE5vRmllbGRzIk4KEVRlc3RYbWxSZXNjdXJz", + "aXZlEjkKBWNoaWxkGAEgASgLMioucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEu", + "VGVzdFhtbFJlc2N1cnNpdmUitwIKDlRlc3RYbWxNZXNzYWdlEg4KBm51bWJl", + "chgGIAEoAxIPCgdudW1iZXJzGAIgAygFEgwKBHRleHQYAyABKAkSEgoJdGV4", + "dGxpbmVzGLwFIAMoCRINCgV2YWxpZBgFIAEoCBI0CgVjaGlsZBgBIAEoCzIl", + "LnByb3RvYnVmX3VuaXR0ZXN0X2V4dHJhLlRlc3RYbWxDaGlsZBJDCghjaGls", + "ZHJlbhiRAyADKAoyMC5wcm90b2J1Zl91bml0dGVzdF9leHRyYS5UZXN0WG1s", + "TWVzc2FnZS5DaGlsZHJlbhpRCghDaGlsZHJlbhI1CgdvcHRpb25zGAMgAygO", + "MiQucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEuRW51bU9wdGlvbnMSDgoGYmlu", + "YXJ5GAQgASgMKgUIZBDIASIiChBUZXN0WG1sRXh0ZW5zaW9uEg4KBm51bWJl", + "chgBIAIoBSoqCgtFbnVtT3B0aW9ucxIHCgNPTkUQABIHCgNUV08QARIJCgVU", + "SFJFRRACOmUKDmV4dGVuc2lvbl9lbnVtEicucHJvdG9idWZfdW5pdHRlc3Rf", + "ZXh0cmEuVGVzdFhtbE1lc3NhZ2UYZSABKA4yJC5wcm90b2J1Zl91bml0dGVz", + "dF9leHRyYS5FbnVtT3B0aW9uczo/Cg5leHRlbnNpb25fdGV4dBInLnByb3Rv", + "YnVmX3VuaXR0ZXN0X2V4dHJhLlRlc3RYbWxNZXNzYWdlGGYgASgJOkUKEGV4", + "dGVuc2lvbl9udW1iZXISJy5wcm90b2J1Zl91bml0dGVzdF9leHRyYS5UZXN0", + "WG1sTWVzc2FnZRhnIAMoBUICEAE6bgoRZXh0ZW5zaW9uX21lc3NhZ2USJy5w", + "cm90b2J1Zl91bml0dGVzdF9leHRyYS5UZXN0WG1sTWVzc2FnZRjHASABKAsy", + "KS5wcm90b2J1Zl91bml0dGVzdF9leHRyYS5UZXN0WG1sRXh0ZW5zaW9uQiZI", + "AaoCIUdvb2dsZS5Qcm90b2NvbEJ1ZmZlcnMuVGVzdFByb3Rvcw==")); + pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { + descriptor = root; + internal__static_protobuf_unittest_extra_TestXmlChild__Descriptor = Descriptor.MessageTypes[0]; + internal__static_protobuf_unittest_extra_TestXmlChild__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlChild__Descriptor, + new string[] { "Options", "Binary", }); + internal__static_protobuf_unittest_extra_TestXmlNoFields__Descriptor = Descriptor.MessageTypes[1]; + internal__static_protobuf_unittest_extra_TestXmlNoFields__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlNoFields__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_extra_TestXmlRescursive__Descriptor = Descriptor.MessageTypes[2]; + internal__static_protobuf_unittest_extra_TestXmlRescursive__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlRescursive__Descriptor, + new string[] { "Child", }); + internal__static_protobuf_unittest_extra_TestXmlMessage__Descriptor = Descriptor.MessageTypes[3]; + internal__static_protobuf_unittest_extra_TestXmlMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlMessage__Descriptor, + new string[] { "Number", "Numbers", "Text", "Textlines", "Valid", "Child", "Children", }); + internal__static_protobuf_unittest_extra_TestXmlMessage_Children__Descriptor = internal__static_protobuf_unittest_extra_TestXmlMessage__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_extra_TestXmlMessage_Children__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlMessage_Children__Descriptor, + new string[] { "Options", "Binary", }); + internal__static_protobuf_unittest_extra_TestXmlExtension__Descriptor = Descriptor.MessageTypes[4]; + internal__static_protobuf_unittest_extra_TestXmlExtension__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlExtension__Descriptor, + new string[] { "Number", }); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionEnum = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor.Extensions[0]); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionText = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor.Extensions[1]); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionNumber = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor.Extensions[2]); + global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionMessage = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor.Extensions[3]); + pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); + RegisterAllExtensions(registry); + return registry; + }; + pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, + new pbd::FileDescriptor[] { + }, assigner); + } + #endregion + + } + #region Enums + public enum EnumOptions { + ONE = 0, + TWO = 1, + THREE = 2, + } + + #endregion + + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestXmlChild : pb::GeneratedMessage { + private TestXmlChild() { } + private static readonly TestXmlChild defaultInstance = new TestXmlChild().MakeReadOnly(); + private static readonly string[] _testXmlChildFieldNames = new string[] { "binary", "options" }; + private static readonly uint[] _testXmlChildFieldTags = new uint[] { 34, 24 }; + public static TestXmlChild DefaultInstance { + get { return defaultInstance; } + } + + public override TestXmlChild DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestXmlChild ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlChild__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlChild__FieldAccessorTable; } + } + + public const int OptionsFieldNumber = 3; + private pbc::PopsicleList options_ = new pbc::PopsicleList(); + public scg::IList OptionsList { + get { return pbc::Lists.AsReadOnly(options_); } + } + public int OptionsCount { + get { return options_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.EnumOptions GetOptions(int index) { + return options_[index]; + } + + public const int BinaryFieldNumber = 4; + private bool hasBinary; + private pb::ByteString binary_ = pb::ByteString.Empty; + public bool HasBinary { + get { return hasBinary; } + } + public pb::ByteString Binary { + get { return binary_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testXmlChildFieldNames; + if (options_.Count > 0) { + output.WriteEnumArray(3, field_names[1], options_); + } + if (hasBinary) { + output.WriteBytes(4, field_names[0], Binary); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + if (options_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.EnumOptions element in options_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 1 * options_.Count; + } + } + if (hasBinary) { + size += pb::CodedOutputStream.ComputeBytesSize(4, Binary); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestXmlChild ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestXmlChild ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestXmlChild ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestXmlChild ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestXmlChild ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestXmlChild ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestXmlChild ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestXmlChild ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestXmlChild ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestXmlChild ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestXmlChild MakeReadOnly() { + options_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestXmlChild prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestXmlChild cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestXmlChild result; + + private TestXmlChild PrepareBuilder() { + if (resultIsReadOnly) { + TestXmlChild original = result; + result = new TestXmlChild(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestXmlChild MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlChild.Descriptor; } + } + + public override TestXmlChild DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlChild.DefaultInstance; } + } + + public override TestXmlChild BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestXmlChild) { + return MergeFrom((TestXmlChild) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestXmlChild other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlChild.DefaultInstance) return this; + PrepareBuilder(); + if (other.options_.Count != 0) { + result.options_.Add(other.options_); + } + if (other.HasBinary) { + Binary = other.Binary; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testXmlChildFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testXmlChildFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 26: + case 24: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.options_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(3, (ulong)(int)rawValue); + } + break; + } + case 34: { + result.hasBinary = input.ReadBytes(ref result.binary_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList OptionsList { + get { return PrepareBuilder().options_; } + } + public int OptionsCount { + get { return result.OptionsCount; } + } + public global::Google.ProtocolBuffers.TestProtos.EnumOptions GetOptions(int index) { + return result.GetOptions(index); + } + public Builder SetOptions(int index, global::Google.ProtocolBuffers.TestProtos.EnumOptions value) { + PrepareBuilder(); + result.options_[index] = value; + return this; + } + public Builder AddOptions(global::Google.ProtocolBuffers.TestProtos.EnumOptions value) { + PrepareBuilder(); + result.options_.Add(value); + return this; + } + public Builder AddRangeOptions(scg::IEnumerable values) { + PrepareBuilder(); + result.options_.Add(values); + return this; + } + public Builder ClearOptions() { + PrepareBuilder(); + result.options_.Clear(); + return this; + } + + public bool HasBinary { + get { return result.hasBinary; } + } + public pb::ByteString Binary { + get { return result.Binary; } + set { SetBinary(value); } + } + public Builder SetBinary(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBinary = true; + result.binary_ = value; + return this; + } + public Builder ClearBinary() { + PrepareBuilder(); + result.hasBinary = false; + result.binary_ = pb::ByteString.Empty; + return this; + } + } + static TestXmlChild() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestXmlNoFields : pb::GeneratedMessage { + private TestXmlNoFields() { } + private static readonly TestXmlNoFields defaultInstance = new TestXmlNoFields().MakeReadOnly(); + private static readonly string[] _testXmlNoFieldsFieldNames = new string[] { }; + private static readonly uint[] _testXmlNoFieldsFieldTags = new uint[] { }; + public static TestXmlNoFields DefaultInstance { + get { return defaultInstance; } + } + + public override TestXmlNoFields DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestXmlNoFields ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlNoFields__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlNoFields__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testXmlNoFieldsFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestXmlNoFields ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestXmlNoFields ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestXmlNoFields ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestXmlNoFields ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestXmlNoFields ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestXmlNoFields ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestXmlNoFields ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestXmlNoFields ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestXmlNoFields ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestXmlNoFields ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestXmlNoFields MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestXmlNoFields prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestXmlNoFields cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestXmlNoFields result; + + private TestXmlNoFields PrepareBuilder() { + if (resultIsReadOnly) { + TestXmlNoFields original = result; + result = new TestXmlNoFields(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestXmlNoFields MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlNoFields.Descriptor; } + } + + public override TestXmlNoFields DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlNoFields.DefaultInstance; } + } + + public override TestXmlNoFields BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestXmlNoFields) { + return MergeFrom((TestXmlNoFields) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestXmlNoFields other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlNoFields.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testXmlNoFieldsFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testXmlNoFieldsFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestXmlNoFields() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestXmlRescursive : pb::GeneratedMessage { + private TestXmlRescursive() { } + private static readonly TestXmlRescursive defaultInstance = new TestXmlRescursive().MakeReadOnly(); + private static readonly string[] _testXmlRescursiveFieldNames = new string[] { "child" }; + private static readonly uint[] _testXmlRescursiveFieldTags = new uint[] { 10 }; + public static TestXmlRescursive DefaultInstance { + get { return defaultInstance; } + } + + public override TestXmlRescursive DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestXmlRescursive ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlRescursive__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlRescursive__FieldAccessorTable; } + } + + public const int ChildFieldNumber = 1; + private bool hasChild; + private global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive child_; + public bool HasChild { + get { return hasChild; } + } + public global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive Child { + get { return child_ ?? global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testXmlRescursiveFieldNames; + if (hasChild) { + output.WriteMessage(1, field_names[0], Child); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasChild) { + size += pb::CodedOutputStream.ComputeMessageSize(1, Child); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestXmlRescursive ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestXmlRescursive ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestXmlRescursive ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestXmlRescursive ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestXmlRescursive ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestXmlRescursive ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestXmlRescursive ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestXmlRescursive ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestXmlRescursive ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestXmlRescursive ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestXmlRescursive MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestXmlRescursive prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestXmlRescursive cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestXmlRescursive result; + + private TestXmlRescursive PrepareBuilder() { + if (resultIsReadOnly) { + TestXmlRescursive original = result; + result = new TestXmlRescursive(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestXmlRescursive MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.Descriptor; } + } + + public override TestXmlRescursive DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.DefaultInstance; } + } + + public override TestXmlRescursive BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestXmlRescursive) { + return MergeFrom((TestXmlRescursive) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestXmlRescursive other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasChild) { + MergeChild(other.Child); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testXmlRescursiveFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testXmlRescursiveFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.CreateBuilder(); + if (result.hasChild) { + subBuilder.MergeFrom(Child); + } + input.ReadMessage(subBuilder, extensionRegistry); + Child = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasChild { + get { return result.hasChild; } + } + public global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive Child { + get { return result.Child; } + set { SetChild(value); } + } + public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasChild = true; + result.child_ = value; + return this; + } + public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasChild = true; + result.child_ = builderForValue.Build(); + return this; + } + public Builder MergeChild(global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasChild && + result.child_ != global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.DefaultInstance) { + result.child_ = global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.CreateBuilder(result.child_).MergeFrom(value).BuildPartial(); + } else { + result.child_ = value; + } + result.hasChild = true; + return this; + } + public Builder ClearChild() { + PrepareBuilder(); + result.hasChild = false; + result.child_ = null; + return this; + } + } + static TestXmlRescursive() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestXmlMessage : pb::ExtendableMessage { + private TestXmlMessage() { } + private static readonly TestXmlMessage defaultInstance = new TestXmlMessage().MakeReadOnly(); + private static readonly string[] _testXmlMessageFieldNames = new string[] { "child", "children", "number", "numbers", "text", "textlines", "valid" }; + private static readonly uint[] _testXmlMessageFieldTags = new uint[] { 10, 3211, 48, 16, 26, 5602, 40 }; + public static TestXmlMessage DefaultInstance { + get { return defaultInstance; } + } + + public override TestXmlMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestXmlMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlMessage__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Children : pb::GeneratedMessage { + private Children() { } + private static readonly Children defaultInstance = new Children().MakeReadOnly(); + private static readonly string[] _childrenFieldNames = new string[] { "binary", "options" }; + private static readonly uint[] _childrenFieldTags = new uint[] { 34, 24 }; + public static Children DefaultInstance { + get { return defaultInstance; } + } + + public override Children DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Children ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlMessage_Children__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlMessage_Children__FieldAccessorTable; } + } + + public const int OptionsFieldNumber = 3; + private pbc::PopsicleList options_ = new pbc::PopsicleList(); + public scg::IList OptionsList { + get { return pbc::Lists.AsReadOnly(options_); } + } + public int OptionsCount { + get { return options_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.EnumOptions GetOptions(int index) { + return options_[index]; + } + + public const int BinaryFieldNumber = 4; + private bool hasBinary; + private pb::ByteString binary_ = pb::ByteString.Empty; + public bool HasBinary { + get { return hasBinary; } + } + public pb::ByteString Binary { + get { return binary_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _childrenFieldNames; + if (options_.Count > 0) { + output.WriteEnumArray(3, field_names[1], options_); + } + if (hasBinary) { + output.WriteBytes(4, field_names[0], Binary); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + if (options_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.EnumOptions element in options_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 1 * options_.Count; + } + } + if (hasBinary) { + size += pb::CodedOutputStream.ComputeBytesSize(4, Binary); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Children ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Children ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Children ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Children ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Children ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Children ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Children ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Children ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Children ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Children ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Children MakeReadOnly() { + options_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Children prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Children cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Children result; + + private Children PrepareBuilder() { + if (resultIsReadOnly) { + Children original = result; + result = new Children(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Children MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.Descriptor; } + } + + public override Children DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.DefaultInstance; } + } + + public override Children BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is Children) { + return MergeFrom((Children) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Children other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.DefaultInstance) return this; + PrepareBuilder(); + if (other.options_.Count != 0) { + result.options_.Add(other.options_); + } + if (other.HasBinary) { + Binary = other.Binary; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_childrenFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _childrenFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 26: + case 24: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.options_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(3, (ulong)(int)rawValue); + } + break; + } + case 34: { + result.hasBinary = input.ReadBytes(ref result.binary_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList OptionsList { + get { return PrepareBuilder().options_; } + } + public int OptionsCount { + get { return result.OptionsCount; } + } + public global::Google.ProtocolBuffers.TestProtos.EnumOptions GetOptions(int index) { + return result.GetOptions(index); + } + public Builder SetOptions(int index, global::Google.ProtocolBuffers.TestProtos.EnumOptions value) { + PrepareBuilder(); + result.options_[index] = value; + return this; + } + public Builder AddOptions(global::Google.ProtocolBuffers.TestProtos.EnumOptions value) { + PrepareBuilder(); + result.options_.Add(value); + return this; + } + public Builder AddRangeOptions(scg::IEnumerable values) { + PrepareBuilder(); + result.options_.Add(values); + return this; + } + public Builder ClearOptions() { + PrepareBuilder(); + result.options_.Clear(); + return this; + } + + public bool HasBinary { + get { return result.hasBinary; } + } + public pb::ByteString Binary { + get { return result.Binary; } + set { SetBinary(value); } + } + public Builder SetBinary(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBinary = true; + result.binary_ = value; + return this; + } + public Builder ClearBinary() { + PrepareBuilder(); + result.hasBinary = false; + result.binary_ = pb::ByteString.Empty; + return this; + } + } + static Children() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); + } + } + + } + #endregion + + public const int NumberFieldNumber = 6; + private bool hasNumber; + private long number_; + public bool HasNumber { + get { return hasNumber; } + } + public long Number { + get { return number_; } + } + + public const int NumbersFieldNumber = 2; + private pbc::PopsicleList numbers_ = new pbc::PopsicleList(); + public scg::IList NumbersList { + get { return pbc::Lists.AsReadOnly(numbers_); } + } + public int NumbersCount { + get { return numbers_.Count; } + } + public int GetNumbers(int index) { + return numbers_[index]; + } + + public const int TextFieldNumber = 3; + private bool hasText; + private string text_ = ""; + public bool HasText { + get { return hasText; } + } + public string Text { + get { return text_; } + } + + public const int TextlinesFieldNumber = 700; + private pbc::PopsicleList textlines_ = new pbc::PopsicleList(); + public scg::IList TextlinesList { + get { return pbc::Lists.AsReadOnly(textlines_); } + } + public int TextlinesCount { + get { return textlines_.Count; } + } + public string GetTextlines(int index) { + return textlines_[index]; + } + + public const int ValidFieldNumber = 5; + private bool hasValid; + private bool valid_; + public bool HasValid { + get { return hasValid; } + } + public bool Valid { + get { return valid_; } + } + + public const int ChildFieldNumber = 1; + private bool hasChild; + private global::Google.ProtocolBuffers.TestProtos.TestXmlChild child_; + public bool HasChild { + get { return hasChild; } + } + public global::Google.ProtocolBuffers.TestProtos.TestXmlChild Child { + get { return child_ ?? global::Google.ProtocolBuffers.TestProtos.TestXmlChild.DefaultInstance; } + } + + public const int ChildrenFieldNumber = 401; + private pbc::PopsicleList children_ = new pbc::PopsicleList(); + public scg::IList ChildrenList { + get { return children_; } + } + public int ChildrenCount { + get { return children_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children GetChildren(int index) { + return children_[index]; + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testXmlMessageFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + if (hasChild) { + output.WriteMessage(1, field_names[0], Child); + } + if (numbers_.Count > 0) { + output.WriteInt32Array(2, field_names[3], numbers_); + } + if (hasText) { + output.WriteString(3, field_names[4], Text); + } + if (hasValid) { + output.WriteBool(5, field_names[6], Valid); + } + if (hasNumber) { + output.WriteInt64(6, field_names[2], Number); + } + extensionWriter.WriteUntil(200, output); + if (children_.Count > 0) { + output.WriteGroupArray(401, field_names[1], children_); + } + if (textlines_.Count > 0) { + output.WriteStringArray(700, field_names[5], textlines_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasNumber) { + size += pb::CodedOutputStream.ComputeInt64Size(6, Number); + } + { + int dataSize = 0; + foreach (int element in NumbersList) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 1 * numbers_.Count; + } + if (hasText) { + size += pb::CodedOutputStream.ComputeStringSize(3, Text); + } + { + int dataSize = 0; + foreach (string element in TextlinesList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * textlines_.Count; + } + if (hasValid) { + size += pb::CodedOutputStream.ComputeBoolSize(5, Valid); + } + if (hasChild) { + size += pb::CodedOutputStream.ComputeMessageSize(1, Child); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children element in ChildrenList) { + size += pb::CodedOutputStream.ComputeGroupSize(401, element); + } + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestXmlMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestXmlMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestXmlMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestXmlMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestXmlMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestXmlMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestXmlMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestXmlMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestXmlMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestXmlMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestXmlMessage MakeReadOnly() { + numbers_.MakeReadOnly(); + textlines_.MakeReadOnly(); + children_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestXmlMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestXmlMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestXmlMessage result; + + private TestXmlMessage PrepareBuilder() { + if (resultIsReadOnly) { + TestXmlMessage original = result; + result = new TestXmlMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestXmlMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Descriptor; } + } + + public override TestXmlMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.DefaultInstance; } + } + + public override TestXmlMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestXmlMessage) { + return MergeFrom((TestXmlMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestXmlMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasNumber) { + Number = other.Number; + } + if (other.numbers_.Count != 0) { + result.numbers_.Add(other.numbers_); + } + if (other.HasText) { + Text = other.Text; + } + if (other.textlines_.Count != 0) { + result.textlines_.Add(other.textlines_); + } + if (other.HasValid) { + Valid = other.Valid; + } + if (other.HasChild) { + MergeChild(other.Child); + } + if (other.children_.Count != 0) { + result.children_.Add(other.children_); + } + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testXmlMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testXmlMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestXmlChild.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestXmlChild.CreateBuilder(); + if (result.hasChild) { + subBuilder.MergeFrom(Child); + } + input.ReadMessage(subBuilder, extensionRegistry); + Child = subBuilder.BuildPartial(); + break; + } + case 18: + case 16: { + input.ReadInt32Array(tag, field_name, result.numbers_); + break; + } + case 26: { + result.hasText = input.ReadString(ref result.text_); + break; + } + case 40: { + result.hasValid = input.ReadBool(ref result.valid_); + break; + } + case 48: { + result.hasNumber = input.ReadInt64(ref result.number_); + break; + } + case 3211: { + input.ReadGroupArray(tag, field_name, result.children_, global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.DefaultInstance, extensionRegistry); + break; + } + case 5602: { + input.ReadStringArray(tag, field_name, result.textlines_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasNumber { + get { return result.hasNumber; } + } + public long Number { + get { return result.Number; } + set { SetNumber(value); } + } + public Builder SetNumber(long value) { + PrepareBuilder(); + result.hasNumber = true; + result.number_ = value; + return this; + } + public Builder ClearNumber() { + PrepareBuilder(); + result.hasNumber = false; + result.number_ = 0L; + return this; + } + + public pbc::IPopsicleList NumbersList { + get { return PrepareBuilder().numbers_; } + } + public int NumbersCount { + get { return result.NumbersCount; } + } + public int GetNumbers(int index) { + return result.GetNumbers(index); + } + public Builder SetNumbers(int index, int value) { + PrepareBuilder(); + result.numbers_[index] = value; + return this; + } + public Builder AddNumbers(int value) { + PrepareBuilder(); + result.numbers_.Add(value); + return this; + } + public Builder AddRangeNumbers(scg::IEnumerable values) { + PrepareBuilder(); + result.numbers_.Add(values); + return this; + } + public Builder ClearNumbers() { + PrepareBuilder(); + result.numbers_.Clear(); + return this; + } + + public bool HasText { + get { return result.hasText; } + } + public string Text { + get { return result.Text; } + set { SetText(value); } + } + public Builder SetText(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasText = true; + result.text_ = value; + return this; + } + public Builder ClearText() { + PrepareBuilder(); + result.hasText = false; + result.text_ = ""; + return this; + } + + public pbc::IPopsicleList TextlinesList { + get { return PrepareBuilder().textlines_; } + } + public int TextlinesCount { + get { return result.TextlinesCount; } + } + public string GetTextlines(int index) { + return result.GetTextlines(index); + } + public Builder SetTextlines(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.textlines_[index] = value; + return this; + } + public Builder AddTextlines(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.textlines_.Add(value); + return this; + } + public Builder AddRangeTextlines(scg::IEnumerable values) { + PrepareBuilder(); + result.textlines_.Add(values); + return this; + } + public Builder ClearTextlines() { + PrepareBuilder(); + result.textlines_.Clear(); + return this; + } + + public bool HasValid { + get { return result.hasValid; } + } + public bool Valid { + get { return result.Valid; } + set { SetValid(value); } + } + public Builder SetValid(bool value) { + PrepareBuilder(); + result.hasValid = true; + result.valid_ = value; + return this; + } + public Builder ClearValid() { + PrepareBuilder(); + result.hasValid = false; + result.valid_ = false; + return this; + } + + public bool HasChild { + get { return result.hasChild; } + } + public global::Google.ProtocolBuffers.TestProtos.TestXmlChild Child { + get { return result.Child; } + set { SetChild(value); } + } + public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.TestXmlChild value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasChild = true; + result.child_ = value; + return this; + } + public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.TestXmlChild.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasChild = true; + result.child_ = builderForValue.Build(); + return this; + } + public Builder MergeChild(global::Google.ProtocolBuffers.TestProtos.TestXmlChild value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasChild && + result.child_ != global::Google.ProtocolBuffers.TestProtos.TestXmlChild.DefaultInstance) { + result.child_ = global::Google.ProtocolBuffers.TestProtos.TestXmlChild.CreateBuilder(result.child_).MergeFrom(value).BuildPartial(); + } else { + result.child_ = value; + } + result.hasChild = true; + return this; + } + public Builder ClearChild() { + PrepareBuilder(); + result.hasChild = false; + result.child_ = null; + return this; + } + + public pbc::IPopsicleList ChildrenList { + get { return PrepareBuilder().children_; } + } + public int ChildrenCount { + get { return result.ChildrenCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children GetChildren(int index) { + return result.GetChildren(index); + } + public Builder SetChildren(int index, global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.children_[index] = value; + return this; + } + public Builder SetChildren(int index, global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.children_[index] = builderForValue.Build(); + return this; + } + public Builder AddChildren(global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.children_.Add(value); + return this; + } + public Builder AddChildren(global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.children_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeChildren(scg::IEnumerable values) { + PrepareBuilder(); + result.children_.Add(values); + return this; + } + public Builder ClearChildren() { + PrepareBuilder(); + result.children_.Clear(); + return this; + } + } + static TestXmlMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestXmlExtension : pb::GeneratedMessage { + private TestXmlExtension() { } + private static readonly TestXmlExtension defaultInstance = new TestXmlExtension().MakeReadOnly(); + private static readonly string[] _testXmlExtensionFieldNames = new string[] { "number" }; + private static readonly uint[] _testXmlExtensionFieldTags = new uint[] { 8 }; + public static TestXmlExtension DefaultInstance { + get { return defaultInstance; } + } + + public override TestXmlExtension DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestXmlExtension ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlExtension__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlExtension__FieldAccessorTable; } + } + + public const int NumberFieldNumber = 1; + private bool hasNumber; + private int number_; + public bool HasNumber { + get { return hasNumber; } + } + public int Number { + get { return number_; } + } + + public override bool IsInitialized { + get { + if (!hasNumber) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testXmlExtensionFieldNames; + if (hasNumber) { + output.WriteInt32(1, field_names[0], Number); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasNumber) { + size += pb::CodedOutputStream.ComputeInt32Size(1, Number); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestXmlExtension ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestXmlExtension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestXmlExtension ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestXmlExtension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestXmlExtension ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestXmlExtension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestXmlExtension ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestXmlExtension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestXmlExtension ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestXmlExtension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestXmlExtension MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestXmlExtension prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestXmlExtension cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestXmlExtension result; + + private TestXmlExtension PrepareBuilder() { + if (resultIsReadOnly) { + TestXmlExtension original = result; + result = new TestXmlExtension(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestXmlExtension MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlExtension.Descriptor; } + } + + public override TestXmlExtension DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestXmlExtension.DefaultInstance; } + } + + public override TestXmlExtension BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is TestXmlExtension) { + return MergeFrom((TestXmlExtension) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestXmlExtension other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlExtension.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasNumber) { + Number = other.Number; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testXmlExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testXmlExtensionFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasNumber = input.ReadInt32(ref result.number_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasNumber { + get { return result.hasNumber; } + } + public int Number { + get { return result.Number; } + set { SetNumber(value); } + } + public Builder SetNumber(int value) { + PrepareBuilder(); + result.hasNumber = true; + result.number_ = value; + return this; + } + public Builder ClearNumber() { + PrepareBuilder(); + result.hasNumber = false; + result.number_ = 0; + return this; + } + } + static TestXmlExtension() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImport.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImport.cs new file mode 100644 index 00000000..81f9ee53 --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImport.cs @@ -0,0 +1,347 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/protobuf/unittest_import.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace Google.ProtocolBuffers.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class UnittestImport { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + } + #endregion + #region Static variables + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_import_ImportMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_import_ImportMessage__FieldAccessorTable; + #endregion + #region Descriptor + public static pbd::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbd::FileDescriptor descriptor; + + static UnittestImport() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "CiVnb29nbGUvcHJvdG9idWYvdW5pdHRlc3RfaW1wb3J0LnByb3RvEhhwcm90", + "b2J1Zl91bml0dGVzdF9pbXBvcnQaLGdvb2dsZS9wcm90b2J1Zi91bml0dGVz", + "dF9pbXBvcnRfcHVibGljLnByb3RvIhoKDUltcG9ydE1lc3NhZ2USCQoBZBgB", + "IAEoBSo8CgpJbXBvcnRFbnVtEg4KCklNUE9SVF9GT08QBxIOCgpJTVBPUlRf", + "QkFSEAgSDgoKSU1QT1JUX0JBWhAJQkMKGGNvbS5nb29nbGUucHJvdG9idWYu", + "dGVzdEgB+AEBqgIhR29vZ2xlLlByb3RvY29sQnVmZmVycy5UZXN0UHJvdG9z", + "UAA=")); + pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { + descriptor = root; + internal__static_protobuf_unittest_import_ImportMessage__Descriptor = Descriptor.MessageTypes[0]; + internal__static_protobuf_unittest_import_ImportMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_import_ImportMessage__Descriptor, + new string[] { "D", }); + pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); + RegisterAllExtensions(registry); + global::Google.ProtocolBuffers.TestProtos.UnittestImportPublic.RegisterAllExtensions(registry); + return registry; + }; + pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, + new pbd::FileDescriptor[] { + global::Google.ProtocolBuffers.TestProtos.UnittestImportPublic.Descriptor, + }, assigner); + } + #endregion + + } + #region Enums + public enum ImportEnum { + IMPORT_FOO = 7, + IMPORT_BAR = 8, + IMPORT_BAZ = 9, + } + + #endregion + + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class ImportMessage : pb::GeneratedMessage { + private ImportMessage() { } + private static readonly ImportMessage defaultInstance = new ImportMessage().MakeReadOnly(); + private static readonly string[] _importMessageFieldNames = new string[] { "d" }; + private static readonly uint[] _importMessageFieldTags = new uint[] { 8 }; + public static ImportMessage DefaultInstance { + get { return defaultInstance; } + } + + public override ImportMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override ImportMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestImport.internal__static_protobuf_unittest_import_ImportMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestImport.internal__static_protobuf_unittest_import_ImportMessage__FieldAccessorTable; } + } + + public const int DFieldNumber = 1; + private bool hasD; + private int d_; + public bool HasD { + get { return hasD; } + } + public int D { + get { return d_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _importMessageFieldNames; + if (hasD) { + output.WriteInt32(1, field_names[0], D); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasD) { + size += pb::CodedOutputStream.ComputeInt32Size(1, D); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static ImportMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ImportMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ImportMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ImportMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ImportMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ImportMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static ImportMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static ImportMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static ImportMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ImportMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private ImportMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(ImportMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(ImportMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private ImportMessage result; + + private ImportMessage PrepareBuilder() { + if (resultIsReadOnly) { + ImportMessage original = result; + result = new ImportMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override ImportMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.ImportMessage.Descriptor; } + } + + public override ImportMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance; } + } + + public override ImportMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is ImportMessage) { + return MergeFrom((ImportMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(ImportMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasD) { + D = other.D; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_importMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _importMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasD = input.ReadInt32(ref result.d_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasD { + get { return result.hasD; } + } + public int D { + get { return result.D; } + set { SetD(value); } + } + public Builder SetD(int value) { + PrepareBuilder(); + result.hasD = true; + result.d_ = value; + return this; + } + public Builder ClearD() { + PrepareBuilder(); + result.hasD = false; + result.d_ = 0; + return this; + } + } + static ImportMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestImport.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportLite.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportLite.cs new file mode 100644 index 00000000..b0ad3155 --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportLite.cs @@ -0,0 +1,309 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/protobuf/unittest_import_lite.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace Google.ProtocolBuffers.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class UnittestImportLite { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + } + #endregion + #region Static variables + #endregion + #region Extensions + internal static readonly object Descriptor; + static UnittestImportLite() { + Descriptor = null; + } + #endregion + + } + #region Enums + public enum ImportEnumLite { + IMPORT_LITE_FOO = 7, + IMPORT_LITE_BAR = 8, + IMPORT_LITE_BAZ = 9, + } + + #endregion + + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class ImportMessageLite : pb::GeneratedMessageLite { + private ImportMessageLite() { } + private static readonly ImportMessageLite defaultInstance = new ImportMessageLite().MakeReadOnly(); + private static readonly string[] _importMessageLiteFieldNames = new string[] { "d" }; + private static readonly uint[] _importMessageLiteFieldTags = new uint[] { 8 }; + public static ImportMessageLite DefaultInstance { + get { return defaultInstance; } + } + + public override ImportMessageLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override ImportMessageLite ThisMessage { + get { return this; } + } + + public const int DFieldNumber = 1; + private bool hasD; + private int d_; + public bool HasD { + get { return hasD; } + } + public int D { + get { return d_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _importMessageLiteFieldNames; + if (hasD) { + output.WriteInt32(1, field_names[0], D); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasD) { + size += pb::CodedOutputStream.ComputeInt32Size(1, D); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasD) hash ^= d_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + ImportMessageLite other = obj as ImportMessageLite; + if (other == null) return false; + if (hasD != other.hasD || (hasD && !d_.Equals(other.d_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("d", hasD, d_, writer); + } + #endregion + + public static ImportMessageLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ImportMessageLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ImportMessageLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ImportMessageLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ImportMessageLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ImportMessageLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static ImportMessageLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static ImportMessageLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static ImportMessageLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ImportMessageLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private ImportMessageLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(ImportMessageLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(ImportMessageLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private ImportMessageLite result; + + private ImportMessageLite PrepareBuilder() { + if (resultIsReadOnly) { + ImportMessageLite original = result; + result = new ImportMessageLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override ImportMessageLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override ImportMessageLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance; } + } + + public override ImportMessageLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is ImportMessageLite) { + return MergeFrom((ImportMessageLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(ImportMessageLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasD) { + D = other.D; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_importMessageLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _importMessageLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasD = input.ReadInt32(ref result.d_); + break; + } + } + } + + return this; + } + + + public bool HasD { + get { return result.hasD; } + } + public int D { + get { return result.D; } + set { SetD(value); } + } + public Builder SetD(int value) { + PrepareBuilder(); + result.hasD = true; + result.d_ = value; + return this; + } + public Builder ClearD() { + PrepareBuilder(); + result.hasD = false; + result.d_ = 0; + return this; + } + } + static ImportMessageLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestImportLite.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublic.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublic.cs new file mode 100644 index 00000000..4185cac7 --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublic.cs @@ -0,0 +1,333 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/protobuf/unittest_import_public.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace Google.ProtocolBuffers.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class UnittestImportPublic { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + } + #endregion + #region Static variables + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_import_PublicImportMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_import_PublicImportMessage__FieldAccessorTable; + #endregion + #region Descriptor + public static pbd::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbd::FileDescriptor descriptor; + + static UnittestImportPublic() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Cixnb29nbGUvcHJvdG9idWYvdW5pdHRlc3RfaW1wb3J0X3B1YmxpYy5wcm90", + "bxIYcHJvdG9idWZfdW5pdHRlc3RfaW1wb3J0IiAKE1B1YmxpY0ltcG9ydE1l", + "c3NhZ2USCQoBZRgBIAEoBUI+Chhjb20uZ29vZ2xlLnByb3RvYnVmLnRlc3Sq", + "AiFHb29nbGUuUHJvdG9jb2xCdWZmZXJzLlRlc3RQcm90b3M=")); + pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { + descriptor = root; + internal__static_protobuf_unittest_import_PublicImportMessage__Descriptor = Descriptor.MessageTypes[0]; + internal__static_protobuf_unittest_import_PublicImportMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_import_PublicImportMessage__Descriptor, + new string[] { "E", }); + pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); + RegisterAllExtensions(registry); + return registry; + }; + pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, + new pbd::FileDescriptor[] { + }, assigner); + } + #endregion + + } + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class PublicImportMessage : pb::GeneratedMessage { + private PublicImportMessage() { } + private static readonly PublicImportMessage defaultInstance = new PublicImportMessage().MakeReadOnly(); + private static readonly string[] _publicImportMessageFieldNames = new string[] { "e" }; + private static readonly uint[] _publicImportMessageFieldTags = new uint[] { 8 }; + public static PublicImportMessage DefaultInstance { + get { return defaultInstance; } + } + + public override PublicImportMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override PublicImportMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestImportPublic.internal__static_protobuf_unittest_import_PublicImportMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::Google.ProtocolBuffers.TestProtos.UnittestImportPublic.internal__static_protobuf_unittest_import_PublicImportMessage__FieldAccessorTable; } + } + + public const int EFieldNumber = 1; + private bool hasE; + private int e_; + public bool HasE { + get { return hasE; } + } + public int E { + get { return e_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _publicImportMessageFieldNames; + if (hasE) { + output.WriteInt32(1, field_names[0], E); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasE) { + size += pb::CodedOutputStream.ComputeInt32Size(1, E); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static PublicImportMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static PublicImportMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static PublicImportMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static PublicImportMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static PublicImportMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static PublicImportMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static PublicImportMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static PublicImportMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static PublicImportMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static PublicImportMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private PublicImportMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(PublicImportMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(PublicImportMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private PublicImportMessage result; + + private PublicImportMessage PrepareBuilder() { + if (resultIsReadOnly) { + PublicImportMessage original = result; + result = new PublicImportMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override PublicImportMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.Descriptor; } + } + + public override PublicImportMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.DefaultInstance; } + } + + public override PublicImportMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is PublicImportMessage) { + return MergeFrom((PublicImportMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(PublicImportMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasE) { + E = other.E; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_publicImportMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _publicImportMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasE = input.ReadInt32(ref result.e_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasE { + get { return result.hasE; } + } + public int E { + get { return result.E; } + set { SetE(value); } + } + public Builder SetE(int value) { + PrepareBuilder(); + result.hasE = true; + result.e_ = value; + return this; + } + public Builder ClearE() { + PrepareBuilder(); + result.hasE = false; + result.e_ = 0; + return this; + } + } + static PublicImportMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestImportPublic.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublicLite.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublicLite.cs new file mode 100644 index 00000000..de250899 --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublicLite.cs @@ -0,0 +1,300 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/protobuf/unittest_import_public_lite.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace Google.ProtocolBuffers.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class UnittestImportPublicLite { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + } + #endregion + #region Static variables + #endregion + #region Extensions + internal static readonly object Descriptor; + static UnittestImportPublicLite() { + Descriptor = null; + } + #endregion + + } + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class PublicImportMessageLite : pb::GeneratedMessageLite { + private PublicImportMessageLite() { } + private static readonly PublicImportMessageLite defaultInstance = new PublicImportMessageLite().MakeReadOnly(); + private static readonly string[] _publicImportMessageLiteFieldNames = new string[] { "e" }; + private static readonly uint[] _publicImportMessageLiteFieldTags = new uint[] { 8 }; + public static PublicImportMessageLite DefaultInstance { + get { return defaultInstance; } + } + + public override PublicImportMessageLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override PublicImportMessageLite ThisMessage { + get { return this; } + } + + public const int EFieldNumber = 1; + private bool hasE; + private int e_; + public bool HasE { + get { return hasE; } + } + public int E { + get { return e_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _publicImportMessageLiteFieldNames; + if (hasE) { + output.WriteInt32(1, field_names[0], E); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasE) { + size += pb::CodedOutputStream.ComputeInt32Size(1, E); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasE) hash ^= e_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + PublicImportMessageLite other = obj as PublicImportMessageLite; + if (other == null) return false; + if (hasE != other.hasE || (hasE && !e_.Equals(other.e_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("e", hasE, e_, writer); + } + #endregion + + public static PublicImportMessageLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static PublicImportMessageLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static PublicImportMessageLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static PublicImportMessageLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static PublicImportMessageLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static PublicImportMessageLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static PublicImportMessageLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static PublicImportMessageLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static PublicImportMessageLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static PublicImportMessageLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private PublicImportMessageLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(PublicImportMessageLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(PublicImportMessageLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private PublicImportMessageLite result; + + private PublicImportMessageLite PrepareBuilder() { + if (resultIsReadOnly) { + PublicImportMessageLite original = result; + result = new PublicImportMessageLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override PublicImportMessageLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override PublicImportMessageLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite.DefaultInstance; } + } + + public override PublicImportMessageLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is PublicImportMessageLite) { + return MergeFrom((PublicImportMessageLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(PublicImportMessageLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasE) { + E = other.E; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_publicImportMessageLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _publicImportMessageLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasE = input.ReadInt32(ref result.e_); + break; + } + } + } + + return this; + } + + + public bool HasE { + get { return result.hasE; } + } + public int E { + get { return result.E; } + set { SetE(value); } + } + public Builder SetE(int value) { + PrepareBuilder(); + result.hasE = true; + result.e_ = value; + return this; + } + public Builder ClearE() { + PrepareBuilder(); + result.hasE = false; + result.e_ = 0; + return this; + } + } + static PublicImportMessageLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestImportPublicLite.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestIssues.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestIssues.cs new file mode 100644 index 00000000..e0bc151b --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestIssues.cs @@ -0,0 +1,3437 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: unittest_issues.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace UnitTest.Issues.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class UnittestIssues { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + } + #endregion + #region Static variables + internal static pbd::MessageDescriptor internal__static_unittest_issues_A__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_A__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_unittest_issues_B__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_B__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_unittest_issues_AB__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_AB__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_unittest_issues_NumberField__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_NumberField__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_unittest_issues_MyMessageAReferenceB__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_MyMessageAReferenceB__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_unittest_issues_MyMessageBReferenceA__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_MyMessageBReferenceA__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_unittest_issues_NegativeEnumMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_NegativeEnumMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_unittest_issues_DeprecatedChild__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_DeprecatedChild__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_unittest_issues_DeprecatedFieldsMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_DeprecatedFieldsMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_unittest_issues_ItemField__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_ItemField__FieldAccessorTable; + #endregion + #region Descriptor + public static pbd::FileDescriptor Descriptor { + get { return descriptor; } + } + private static pbd::FileDescriptor descriptor; + + static UnittestIssues() { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "ChV1bml0dGVzdF9pc3N1ZXMucHJvdG8SD3VuaXR0ZXN0X2lzc3VlcyIPCgFB", + "EgoKAl9BGAEgASgFIg8KAUISCgoCQl8YASABKAUiEQoCQUISCwoDYV9iGAEg", + "ASgFIhoKC051bWJlckZpZWxkEgsKA18wMRgBIAEoBSJMChRNeU1lc3NhZ2VB", + "UmVmZXJlbmNlQhI0CgV2YWx1ZRgBIAIoCzIlLnVuaXR0ZXN0X2lzc3Vlcy5N", + "eU1lc3NhZ2VCUmVmZXJlbmNlQSJMChRNeU1lc3NhZ2VCUmVmZXJlbmNlQRI0", + "CgV2YWx1ZRgBIAIoCzIlLnVuaXR0ZXN0X2lzc3Vlcy5NeU1lc3NhZ2VBUmVm", + "ZXJlbmNlQiKsAQoTTmVnYXRpdmVFbnVtTWVzc2FnZRIsCgV2YWx1ZRgBIAEo", + "DjIdLnVuaXR0ZXN0X2lzc3Vlcy5OZWdhdGl2ZUVudW0SLQoGdmFsdWVzGAIg", + "AygOMh0udW5pdHRlc3RfaXNzdWVzLk5lZ2F0aXZlRW51bRI4Cg1wYWNrZWRf", + "dmFsdWVzGAMgAygOMh0udW5pdHRlc3RfaXNzdWVzLk5lZ2F0aXZlRW51bUIC", + "EAEiEQoPRGVwcmVjYXRlZENoaWxkIrkCChdEZXByZWNhdGVkRmllbGRzTWVz", + "c2FnZRIaCg5QcmltaXRpdmVWYWx1ZRgBIAEoBUICGAESGgoOUHJpbWl0aXZl", + "QXJyYXkYAiADKAVCAhgBEjoKDE1lc3NhZ2VWYWx1ZRgDIAEoCzIgLnVuaXR0", + "ZXN0X2lzc3Vlcy5EZXByZWNhdGVkQ2hpbGRCAhgBEjoKDE1lc3NhZ2VBcnJh", + "eRgEIAMoCzIgLnVuaXR0ZXN0X2lzc3Vlcy5EZXByZWNhdGVkQ2hpbGRCAhgB", + "EjYKCUVudW1WYWx1ZRgFIAEoDjIfLnVuaXR0ZXN0X2lzc3Vlcy5EZXByZWNh", + "dGVkRW51bUICGAESNgoJRW51bUFycmF5GAYgAygOMh8udW5pdHRlc3RfaXNz", + "dWVzLkRlcHJlY2F0ZWRFbnVtQgIYASIZCglJdGVtRmllbGQSDAoEaXRlbRgB", + "IAEoBSpHCgxOZWdhdGl2ZUVudW0SFgoJRml2ZUJlbG93EPv//////////wES", + "FQoITWludXNPbmUQ////////////ARIICgRaZXJvEAAqGQoORGVwcmVjYXRl", + "ZEVudW0SBwoDb25lEAFCH0gBqgIaVW5pdFRlc3QuSXNzdWVzLlRlc3RQcm90", + "b3M=")); + pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { + descriptor = root; + internal__static_unittest_issues_A__Descriptor = Descriptor.MessageTypes[0]; + internal__static_unittest_issues_A__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_A__Descriptor, + new string[] { "A_", }); + internal__static_unittest_issues_B__Descriptor = Descriptor.MessageTypes[1]; + internal__static_unittest_issues_B__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_B__Descriptor, + new string[] { "B_", }); + internal__static_unittest_issues_AB__Descriptor = Descriptor.MessageTypes[2]; + internal__static_unittest_issues_AB__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_AB__Descriptor, + new string[] { "AB_", }); + internal__static_unittest_issues_NumberField__Descriptor = Descriptor.MessageTypes[3]; + internal__static_unittest_issues_NumberField__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_NumberField__Descriptor, + new string[] { "01", }); + internal__static_unittest_issues_MyMessageAReferenceB__Descriptor = Descriptor.MessageTypes[4]; + internal__static_unittest_issues_MyMessageAReferenceB__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_MyMessageAReferenceB__Descriptor, + new string[] { "Value", }); + internal__static_unittest_issues_MyMessageBReferenceA__Descriptor = Descriptor.MessageTypes[5]; + internal__static_unittest_issues_MyMessageBReferenceA__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_MyMessageBReferenceA__Descriptor, + new string[] { "Value", }); + internal__static_unittest_issues_NegativeEnumMessage__Descriptor = Descriptor.MessageTypes[6]; + internal__static_unittest_issues_NegativeEnumMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_NegativeEnumMessage__Descriptor, + new string[] { "Value", "Values", "PackedValues", }); + internal__static_unittest_issues_DeprecatedChild__Descriptor = Descriptor.MessageTypes[7]; + internal__static_unittest_issues_DeprecatedChild__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_DeprecatedChild__Descriptor, + new string[] { }); + internal__static_unittest_issues_DeprecatedFieldsMessage__Descriptor = Descriptor.MessageTypes[8]; + internal__static_unittest_issues_DeprecatedFieldsMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_DeprecatedFieldsMessage__Descriptor, + new string[] { "PrimitiveValue", "PrimitiveArray", "MessageValue", "MessageArray", "EnumValue", "EnumArray", }); + internal__static_unittest_issues_ItemField__Descriptor = Descriptor.MessageTypes[9]; + internal__static_unittest_issues_ItemField__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_ItemField__Descriptor, + new string[] { "Item", }); + pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); + RegisterAllExtensions(registry); + return registry; + }; + pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, + new pbd::FileDescriptor[] { + }, assigner); + } + #endregion + + } + #region Enums + public enum NegativeEnum { + FiveBelow = -5, + MinusOne = -1, + Zero = 0, + } + + public enum DeprecatedEnum { + one = 1, + } + + #endregion + + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class A : pb::GeneratedMessage { + private A() { } + private static readonly A defaultInstance = new A().MakeReadOnly(); + private static readonly string[] _aFieldNames = new string[] { "_A" }; + private static readonly uint[] _aFieldTags = new uint[] { 8 }; + public static A DefaultInstance { + get { return defaultInstance; } + } + + public override A DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override A ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_A__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_A__FieldAccessorTable; } + } + + public const int A_FieldNumber = 1; + private bool hasA_; + private int A_; + public bool HasA_ { + get { return hasA_; } + } + public int A_ { + get { return A_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _aFieldNames; + if (hasA_) { + output.WriteInt32(1, field_names[0], A_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA_) { + size += pb::CodedOutputStream.ComputeInt32Size(1, A_); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static A ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static A ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static A ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static A ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static A ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static A ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static A ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static A ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static A ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static A ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private A MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(A prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(A cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private A result; + + private A PrepareBuilder() { + if (resultIsReadOnly) { + A original = result; + result = new A(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override A MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::UnitTest.Issues.TestProtos.A.Descriptor; } + } + + public override A DefaultInstanceForType { + get { return global::UnitTest.Issues.TestProtos.A.DefaultInstance; } + } + + public override A BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is A) { + return MergeFrom((A) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(A other) { + if (other == global::UnitTest.Issues.TestProtos.A.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA_) { + A_ = other.A_; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_aFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _aFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasA_ = input.ReadInt32(ref result.A_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA_ { + get { return result.hasA_; } + } + public int A_ { + get { return result.A_; } + set { SetA_(value); } + } + public Builder SetA_(int value) { + PrepareBuilder(); + result.hasA_ = true; + result.A_ = value; + return this; + } + public Builder ClearA_() { + PrepareBuilder(); + result.hasA_ = false; + result.A_ = 0; + return this; + } + } + static A() { + object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class B : pb::GeneratedMessage { + private B() { } + private static readonly B defaultInstance = new B().MakeReadOnly(); + private static readonly string[] _bFieldNames = new string[] { "B_" }; + private static readonly uint[] _bFieldTags = new uint[] { 8 }; + public static B DefaultInstance { + get { return defaultInstance; } + } + + public override B DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override B ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_B__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_B__FieldAccessorTable; } + } + + public const int B_FieldNumber = 1; + private bool hasB_; + private int b_; + public bool HasB_ { + get { return hasB_; } + } + public int B_ { + get { return b_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _bFieldNames; + if (hasB_) { + output.WriteInt32(1, field_names[0], B_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasB_) { + size += pb::CodedOutputStream.ComputeInt32Size(1, B_); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static B ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static B ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static B ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static B ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static B ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static B ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static B ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static B ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static B ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static B ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private B MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(B prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(B cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private B result; + + private B PrepareBuilder() { + if (resultIsReadOnly) { + B original = result; + result = new B(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override B MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::UnitTest.Issues.TestProtos.B.Descriptor; } + } + + public override B DefaultInstanceForType { + get { return global::UnitTest.Issues.TestProtos.B.DefaultInstance; } + } + + public override B BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is B) { + return MergeFrom((B) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(B other) { + if (other == global::UnitTest.Issues.TestProtos.B.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasB_) { + B_ = other.B_; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_bFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _bFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasB_ = input.ReadInt32(ref result.b_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasB_ { + get { return result.hasB_; } + } + public int B_ { + get { return result.B_; } + set { SetB_(value); } + } + public Builder SetB_(int value) { + PrepareBuilder(); + result.hasB_ = true; + result.b_ = value; + return this; + } + public Builder ClearB_() { + PrepareBuilder(); + result.hasB_ = false; + result.b_ = 0; + return this; + } + } + static B() { + object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class AB : pb::GeneratedMessage { + private AB() { } + private static readonly AB defaultInstance = new AB().MakeReadOnly(); + private static readonly string[] _aBFieldNames = new string[] { "a_b" }; + private static readonly uint[] _aBFieldTags = new uint[] { 8 }; + public static AB DefaultInstance { + get { return defaultInstance; } + } + + public override AB DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override AB ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_AB__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_AB__FieldAccessorTable; } + } + + public const int AB_FieldNumber = 1; + private bool hasAB_; + private int aB_; + public bool HasAB_ { + get { return hasAB_; } + } + public int AB_ { + get { return aB_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _aBFieldNames; + if (hasAB_) { + output.WriteInt32(1, field_names[0], AB_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasAB_) { + size += pb::CodedOutputStream.ComputeInt32Size(1, AB_); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static AB ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static AB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static AB ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static AB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static AB ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static AB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static AB ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static AB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static AB ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static AB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private AB MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(AB prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(AB cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private AB result; + + private AB PrepareBuilder() { + if (resultIsReadOnly) { + AB original = result; + result = new AB(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override AB MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::UnitTest.Issues.TestProtos.AB.Descriptor; } + } + + public override AB DefaultInstanceForType { + get { return global::UnitTest.Issues.TestProtos.AB.DefaultInstance; } + } + + public override AB BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is AB) { + return MergeFrom((AB) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(AB other) { + if (other == global::UnitTest.Issues.TestProtos.AB.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasAB_) { + AB_ = other.AB_; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_aBFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _aBFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasAB_ = input.ReadInt32(ref result.aB_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasAB_ { + get { return result.hasAB_; } + } + public int AB_ { + get { return result.AB_; } + set { SetAB_(value); } + } + public Builder SetAB_(int value) { + PrepareBuilder(); + result.hasAB_ = true; + result.aB_ = value; + return this; + } + public Builder ClearAB_() { + PrepareBuilder(); + result.hasAB_ = false; + result.aB_ = 0; + return this; + } + } + static AB() { + object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NumberField : pb::GeneratedMessage { + private NumberField() { } + private static readonly NumberField defaultInstance = new NumberField().MakeReadOnly(); + private static readonly string[] _numberFieldFieldNames = new string[] { "_01" }; + private static readonly uint[] _numberFieldFieldTags = new uint[] { 8 }; + public static NumberField DefaultInstance { + get { return defaultInstance; } + } + + public override NumberField DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override NumberField ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_NumberField__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_NumberField__FieldAccessorTable; } + } + + public const int 01FieldNumber = 1; + private bool has01; + private int 01_; + public bool Has01 { + get { return has01; } + } + public int 01 { + get { return 01_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _numberFieldFieldNames; + if (has01) { + output.WriteInt32(1, field_names[0], 01); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (has01) { + size += pb::CodedOutputStream.ComputeInt32Size(1, 01); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NumberField ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NumberField ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NumberField ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NumberField ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NumberField ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NumberField ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NumberField ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NumberField ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NumberField ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NumberField ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NumberField MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NumberField prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NumberField cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NumberField result; + + private NumberField PrepareBuilder() { + if (resultIsReadOnly) { + NumberField original = result; + result = new NumberField(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override NumberField MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::UnitTest.Issues.TestProtos.NumberField.Descriptor; } + } + + public override NumberField DefaultInstanceForType { + get { return global::UnitTest.Issues.TestProtos.NumberField.DefaultInstance; } + } + + public override NumberField BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is NumberField) { + return MergeFrom((NumberField) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NumberField other) { + if (other == global::UnitTest.Issues.TestProtos.NumberField.DefaultInstance) return this; + PrepareBuilder(); + if (other.Has01) { + 01 = other.01; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_numberFieldFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _numberFieldFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.has01 = input.ReadInt32(ref result.01_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool Has01 { + get { return result.has01; } + } + public int 01 { + get { return result.01; } + set { Set01(value); } + } + public Builder Set01(int value) { + PrepareBuilder(); + result.has01 = true; + result.01_ = value; + return this; + } + public Builder Clear01() { + PrepareBuilder(); + result.has01 = false; + result.01_ = 0; + return this; + } + } + static NumberField() { + object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class MyMessageAReferenceB : pb::GeneratedMessage { + private MyMessageAReferenceB() { } + private static readonly MyMessageAReferenceB defaultInstance = new MyMessageAReferenceB().MakeReadOnly(); + private static readonly string[] _myMessageAReferenceBFieldNames = new string[] { "value" }; + private static readonly uint[] _myMessageAReferenceBFieldTags = new uint[] { 10 }; + public static MyMessageAReferenceB DefaultInstance { + get { return defaultInstance; } + } + + public override MyMessageAReferenceB DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override MyMessageAReferenceB ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_MyMessageAReferenceB__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_MyMessageAReferenceB__FieldAccessorTable; } + } + + public const int ValueFieldNumber = 1; + private bool hasValue; + private global::UnitTest.Issues.TestProtos.MyMessageBReferenceA value_; + public bool HasValue { + get { return hasValue; } + } + public global::UnitTest.Issues.TestProtos.MyMessageBReferenceA Value { + get { return value_ ?? global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.DefaultInstance; } + } + + public override bool IsInitialized { + get { + if (!hasValue) return false; + if (!Value.IsInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _myMessageAReferenceBFieldNames; + if (hasValue) { + output.WriteMessage(1, field_names[0], Value); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasValue) { + size += pb::CodedOutputStream.ComputeMessageSize(1, Value); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static MyMessageAReferenceB ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MyMessageAReferenceB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MyMessageAReferenceB ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MyMessageAReferenceB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MyMessageAReferenceB ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MyMessageAReferenceB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static MyMessageAReferenceB ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static MyMessageAReferenceB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static MyMessageAReferenceB ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MyMessageAReferenceB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private MyMessageAReferenceB MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(MyMessageAReferenceB prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(MyMessageAReferenceB cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private MyMessageAReferenceB result; + + private MyMessageAReferenceB PrepareBuilder() { + if (resultIsReadOnly) { + MyMessageAReferenceB original = result; + result = new MyMessageAReferenceB(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override MyMessageAReferenceB MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.Descriptor; } + } + + public override MyMessageAReferenceB DefaultInstanceForType { + get { return global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.DefaultInstance; } + } + + public override MyMessageAReferenceB BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is MyMessageAReferenceB) { + return MergeFrom((MyMessageAReferenceB) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(MyMessageAReferenceB other) { + if (other == global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasValue) { + MergeValue(other.Value); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_myMessageAReferenceBFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _myMessageAReferenceBFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.Builder subBuilder = global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.CreateBuilder(); + if (result.hasValue) { + subBuilder.MergeFrom(Value); + } + input.ReadMessage(subBuilder, extensionRegistry); + Value = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasValue { + get { return result.hasValue; } + } + public global::UnitTest.Issues.TestProtos.MyMessageBReferenceA Value { + get { return result.Value; } + set { SetValue(value); } + } + public Builder SetValue(global::UnitTest.Issues.TestProtos.MyMessageBReferenceA value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasValue = true; + result.value_ = value; + return this; + } + public Builder SetValue(global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasValue = true; + result.value_ = builderForValue.Build(); + return this; + } + public Builder MergeValue(global::UnitTest.Issues.TestProtos.MyMessageBReferenceA value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasValue && + result.value_ != global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.DefaultInstance) { + result.value_ = global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.CreateBuilder(result.value_).MergeFrom(value).BuildPartial(); + } else { + result.value_ = value; + } + result.hasValue = true; + return this; + } + public Builder ClearValue() { + PrepareBuilder(); + result.hasValue = false; + result.value_ = null; + return this; + } + } + static MyMessageAReferenceB() { + object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class MyMessageBReferenceA : pb::GeneratedMessage { + private MyMessageBReferenceA() { } + private static readonly MyMessageBReferenceA defaultInstance = new MyMessageBReferenceA().MakeReadOnly(); + private static readonly string[] _myMessageBReferenceAFieldNames = new string[] { "value" }; + private static readonly uint[] _myMessageBReferenceAFieldTags = new uint[] { 10 }; + public static MyMessageBReferenceA DefaultInstance { + get { return defaultInstance; } + } + + public override MyMessageBReferenceA DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override MyMessageBReferenceA ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_MyMessageBReferenceA__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_MyMessageBReferenceA__FieldAccessorTable; } + } + + public const int ValueFieldNumber = 1; + private bool hasValue; + private global::UnitTest.Issues.TestProtos.MyMessageAReferenceB value_; + public bool HasValue { + get { return hasValue; } + } + public global::UnitTest.Issues.TestProtos.MyMessageAReferenceB Value { + get { return value_ ?? global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.DefaultInstance; } + } + + public override bool IsInitialized { + get { + if (!hasValue) return false; + if (!Value.IsInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _myMessageBReferenceAFieldNames; + if (hasValue) { + output.WriteMessage(1, field_names[0], Value); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasValue) { + size += pb::CodedOutputStream.ComputeMessageSize(1, Value); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static MyMessageBReferenceA ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MyMessageBReferenceA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MyMessageBReferenceA ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MyMessageBReferenceA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MyMessageBReferenceA ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MyMessageBReferenceA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static MyMessageBReferenceA ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static MyMessageBReferenceA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static MyMessageBReferenceA ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MyMessageBReferenceA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private MyMessageBReferenceA MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(MyMessageBReferenceA prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(MyMessageBReferenceA cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private MyMessageBReferenceA result; + + private MyMessageBReferenceA PrepareBuilder() { + if (resultIsReadOnly) { + MyMessageBReferenceA original = result; + result = new MyMessageBReferenceA(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override MyMessageBReferenceA MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.Descriptor; } + } + + public override MyMessageBReferenceA DefaultInstanceForType { + get { return global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.DefaultInstance; } + } + + public override MyMessageBReferenceA BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is MyMessageBReferenceA) { + return MergeFrom((MyMessageBReferenceA) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(MyMessageBReferenceA other) { + if (other == global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasValue) { + MergeValue(other.Value); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_myMessageBReferenceAFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _myMessageBReferenceAFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.Builder subBuilder = global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.CreateBuilder(); + if (result.hasValue) { + subBuilder.MergeFrom(Value); + } + input.ReadMessage(subBuilder, extensionRegistry); + Value = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasValue { + get { return result.hasValue; } + } + public global::UnitTest.Issues.TestProtos.MyMessageAReferenceB Value { + get { return result.Value; } + set { SetValue(value); } + } + public Builder SetValue(global::UnitTest.Issues.TestProtos.MyMessageAReferenceB value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasValue = true; + result.value_ = value; + return this; + } + public Builder SetValue(global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasValue = true; + result.value_ = builderForValue.Build(); + return this; + } + public Builder MergeValue(global::UnitTest.Issues.TestProtos.MyMessageAReferenceB value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasValue && + result.value_ != global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.DefaultInstance) { + result.value_ = global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.CreateBuilder(result.value_).MergeFrom(value).BuildPartial(); + } else { + result.value_ = value; + } + result.hasValue = true; + return this; + } + public Builder ClearValue() { + PrepareBuilder(); + result.hasValue = false; + result.value_ = null; + return this; + } + } + static MyMessageBReferenceA() { + object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NegativeEnumMessage : pb::GeneratedMessage { + private NegativeEnumMessage() { } + private static readonly NegativeEnumMessage defaultInstance = new NegativeEnumMessage().MakeReadOnly(); + private static readonly string[] _negativeEnumMessageFieldNames = new string[] { "packed_values", "value", "values" }; + private static readonly uint[] _negativeEnumMessageFieldTags = new uint[] { 26, 8, 16 }; + public static NegativeEnumMessage DefaultInstance { + get { return defaultInstance; } + } + + public override NegativeEnumMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override NegativeEnumMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_NegativeEnumMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_NegativeEnumMessage__FieldAccessorTable; } + } + + public const int ValueFieldNumber = 1; + private bool hasValue; + private global::UnitTest.Issues.TestProtos.NegativeEnum value_ = global::UnitTest.Issues.TestProtos.NegativeEnum.FiveBelow; + public bool HasValue { + get { return hasValue; } + } + public global::UnitTest.Issues.TestProtos.NegativeEnum Value { + get { return value_; } + } + + public const int ValuesFieldNumber = 2; + private pbc::PopsicleList values_ = new pbc::PopsicleList(); + public scg::IList ValuesList { + get { return pbc::Lists.AsReadOnly(values_); } + } + public int ValuesCount { + get { return values_.Count; } + } + public global::UnitTest.Issues.TestProtos.NegativeEnum GetValues(int index) { + return values_[index]; + } + + public const int PackedValuesFieldNumber = 3; + private int packedValuesMemoizedSerializedSize; + private pbc::PopsicleList packedValues_ = new pbc::PopsicleList(); + public scg::IList PackedValuesList { + get { return pbc::Lists.AsReadOnly(packedValues_); } + } + public int PackedValuesCount { + get { return packedValues_.Count; } + } + public global::UnitTest.Issues.TestProtos.NegativeEnum GetPackedValues(int index) { + return packedValues_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _negativeEnumMessageFieldNames; + if (hasValue) { + output.WriteEnum(1, field_names[1], (int) Value, Value); + } + if (values_.Count > 0) { + output.WriteEnumArray(2, field_names[2], values_); + } + if (packedValues_.Count > 0) { + output.WritePackedEnumArray(3, field_names[0], packedValuesMemoizedSerializedSize, packedValues_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasValue) { + size += pb::CodedOutputStream.ComputeEnumSize(1, (int) Value); + } + { + int dataSize = 0; + if (values_.Count > 0) { + foreach (global::UnitTest.Issues.TestProtos.NegativeEnum element in values_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 1 * values_.Count; + } + } + { + int dataSize = 0; + if (packedValues_.Count > 0) { + foreach (global::UnitTest.Issues.TestProtos.NegativeEnum element in packedValues_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 1; + size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); + } + packedValuesMemoizedSerializedSize = dataSize; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NegativeEnumMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NegativeEnumMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NegativeEnumMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NegativeEnumMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NegativeEnumMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NegativeEnumMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NegativeEnumMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NegativeEnumMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NegativeEnumMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NegativeEnumMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NegativeEnumMessage MakeReadOnly() { + values_.MakeReadOnly(); + packedValues_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NegativeEnumMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NegativeEnumMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NegativeEnumMessage result; + + private NegativeEnumMessage PrepareBuilder() { + if (resultIsReadOnly) { + NegativeEnumMessage original = result; + result = new NegativeEnumMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override NegativeEnumMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::UnitTest.Issues.TestProtos.NegativeEnumMessage.Descriptor; } + } + + public override NegativeEnumMessage DefaultInstanceForType { + get { return global::UnitTest.Issues.TestProtos.NegativeEnumMessage.DefaultInstance; } + } + + public override NegativeEnumMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is NegativeEnumMessage) { + return MergeFrom((NegativeEnumMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NegativeEnumMessage other) { + if (other == global::UnitTest.Issues.TestProtos.NegativeEnumMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasValue) { + Value = other.Value; + } + if (other.values_.Count != 0) { + result.values_.Add(other.values_); + } + if (other.packedValues_.Count != 0) { + result.packedValues_.Add(other.packedValues_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_negativeEnumMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _negativeEnumMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + object unknown; + if(input.ReadEnum(ref result.value_, out unknown)) { + result.hasValue = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(1, (ulong)(int)unknown); + } + break; + } + case 18: + case 16: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.values_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(2, (ulong)(int)rawValue); + } + break; + } + case 26: + case 24: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.packedValues_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(3, (ulong)(int)rawValue); + } + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasValue { + get { return result.hasValue; } + } + public global::UnitTest.Issues.TestProtos.NegativeEnum Value { + get { return result.Value; } + set { SetValue(value); } + } + public Builder SetValue(global::UnitTest.Issues.TestProtos.NegativeEnum value) { + PrepareBuilder(); + result.hasValue = true; + result.value_ = value; + return this; + } + public Builder ClearValue() { + PrepareBuilder(); + result.hasValue = false; + result.value_ = global::UnitTest.Issues.TestProtos.NegativeEnum.FiveBelow; + return this; + } + + public pbc::IPopsicleList ValuesList { + get { return PrepareBuilder().values_; } + } + public int ValuesCount { + get { return result.ValuesCount; } + } + public global::UnitTest.Issues.TestProtos.NegativeEnum GetValues(int index) { + return result.GetValues(index); + } + public Builder SetValues(int index, global::UnitTest.Issues.TestProtos.NegativeEnum value) { + PrepareBuilder(); + result.values_[index] = value; + return this; + } + public Builder AddValues(global::UnitTest.Issues.TestProtos.NegativeEnum value) { + PrepareBuilder(); + result.values_.Add(value); + return this; + } + public Builder AddRangeValues(scg::IEnumerable values) { + PrepareBuilder(); + result.values_.Add(values); + return this; + } + public Builder ClearValues() { + PrepareBuilder(); + result.values_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedValuesList { + get { return PrepareBuilder().packedValues_; } + } + public int PackedValuesCount { + get { return result.PackedValuesCount; } + } + public global::UnitTest.Issues.TestProtos.NegativeEnum GetPackedValues(int index) { + return result.GetPackedValues(index); + } + public Builder SetPackedValues(int index, global::UnitTest.Issues.TestProtos.NegativeEnum value) { + PrepareBuilder(); + result.packedValues_[index] = value; + return this; + } + public Builder AddPackedValues(global::UnitTest.Issues.TestProtos.NegativeEnum value) { + PrepareBuilder(); + result.packedValues_.Add(value); + return this; + } + public Builder AddRangePackedValues(scg::IEnumerable values) { + PrepareBuilder(); + result.packedValues_.Add(values); + return this; + } + public Builder ClearPackedValues() { + PrepareBuilder(); + result.packedValues_.Clear(); + return this; + } + } + static NegativeEnumMessage() { + object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class DeprecatedChild : pb::GeneratedMessage { + private DeprecatedChild() { } + private static readonly DeprecatedChild defaultInstance = new DeprecatedChild().MakeReadOnly(); + private static readonly string[] _deprecatedChildFieldNames = new string[] { }; + private static readonly uint[] _deprecatedChildFieldTags = new uint[] { }; + public static DeprecatedChild DefaultInstance { + get { return defaultInstance; } + } + + public override DeprecatedChild DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override DeprecatedChild ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_DeprecatedChild__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_DeprecatedChild__FieldAccessorTable; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _deprecatedChildFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static DeprecatedChild ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static DeprecatedChild ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static DeprecatedChild ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static DeprecatedChild ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static DeprecatedChild ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static DeprecatedChild ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static DeprecatedChild ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static DeprecatedChild ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static DeprecatedChild ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static DeprecatedChild ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private DeprecatedChild MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(DeprecatedChild prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(DeprecatedChild cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private DeprecatedChild result; + + private DeprecatedChild PrepareBuilder() { + if (resultIsReadOnly) { + DeprecatedChild original = result; + result = new DeprecatedChild(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override DeprecatedChild MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::UnitTest.Issues.TestProtos.DeprecatedChild.Descriptor; } + } + + public override DeprecatedChild DefaultInstanceForType { + get { return global::UnitTest.Issues.TestProtos.DeprecatedChild.DefaultInstance; } + } + + public override DeprecatedChild BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is DeprecatedChild) { + return MergeFrom((DeprecatedChild) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(DeprecatedChild other) { + if (other == global::UnitTest.Issues.TestProtos.DeprecatedChild.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_deprecatedChildFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _deprecatedChildFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static DeprecatedChild() { + object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class DeprecatedFieldsMessage : pb::GeneratedMessage { + private DeprecatedFieldsMessage() { } + private static readonly DeprecatedFieldsMessage defaultInstance = new DeprecatedFieldsMessage().MakeReadOnly(); + private static readonly string[] _deprecatedFieldsMessageFieldNames = new string[] { "EnumArray", "EnumValue", "MessageArray", "MessageValue", "PrimitiveArray", "PrimitiveValue" }; + private static readonly uint[] _deprecatedFieldsMessageFieldTags = new uint[] { 48, 40, 34, 26, 16, 8 }; + public static DeprecatedFieldsMessage DefaultInstance { + get { return defaultInstance; } + } + + public override DeprecatedFieldsMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override DeprecatedFieldsMessage ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_DeprecatedFieldsMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_DeprecatedFieldsMessage__FieldAccessorTable; } + } + + public const int PrimitiveValueFieldNumber = 1; + private bool hasPrimitiveValue; + private int primitiveValue_; + [global::System.ObsoleteAttribute()] + public bool HasPrimitiveValue { + get { return hasPrimitiveValue; } + } + [global::System.ObsoleteAttribute()] + public int PrimitiveValue { + get { return primitiveValue_; } + } + + public const int PrimitiveArrayFieldNumber = 2; + private pbc::PopsicleList primitiveArray_ = new pbc::PopsicleList(); + [global::System.ObsoleteAttribute()] + public scg::IList PrimitiveArrayList { + get { return pbc::Lists.AsReadOnly(primitiveArray_); } + } + [global::System.ObsoleteAttribute()] + public int PrimitiveArrayCount { + get { return primitiveArray_.Count; } + } + [global::System.ObsoleteAttribute()] + public int GetPrimitiveArray(int index) { + return primitiveArray_[index]; + } + + public const int MessageValueFieldNumber = 3; + private bool hasMessageValue; + private global::UnitTest.Issues.TestProtos.DeprecatedChild messageValue_; + [global::System.ObsoleteAttribute()] + public bool HasMessageValue { + get { return hasMessageValue; } + } + [global::System.ObsoleteAttribute()] + public global::UnitTest.Issues.TestProtos.DeprecatedChild MessageValue { + get { return messageValue_ ?? global::UnitTest.Issues.TestProtos.DeprecatedChild.DefaultInstance; } + } + + public const int MessageArrayFieldNumber = 4; + private pbc::PopsicleList messageArray_ = new pbc::PopsicleList(); + [global::System.ObsoleteAttribute()] + public scg::IList MessageArrayList { + get { return messageArray_; } + } + [global::System.ObsoleteAttribute()] + public int MessageArrayCount { + get { return messageArray_.Count; } + } + [global::System.ObsoleteAttribute()] + public global::UnitTest.Issues.TestProtos.DeprecatedChild GetMessageArray(int index) { + return messageArray_[index]; + } + + public const int EnumValueFieldNumber = 5; + private bool hasEnumValue; + private global::UnitTest.Issues.TestProtos.DeprecatedEnum enumValue_ = global::UnitTest.Issues.TestProtos.DeprecatedEnum.one; + [global::System.ObsoleteAttribute()] + public bool HasEnumValue { + get { return hasEnumValue; } + } + [global::System.ObsoleteAttribute()] + public global::UnitTest.Issues.TestProtos.DeprecatedEnum EnumValue { + get { return enumValue_; } + } + + public const int EnumArrayFieldNumber = 6; + private pbc::PopsicleList enumArray_ = new pbc::PopsicleList(); + [global::System.ObsoleteAttribute()] + public scg::IList EnumArrayList { + get { return pbc::Lists.AsReadOnly(enumArray_); } + } + [global::System.ObsoleteAttribute()] + public int EnumArrayCount { + get { return enumArray_.Count; } + } + [global::System.ObsoleteAttribute()] + public global::UnitTest.Issues.TestProtos.DeprecatedEnum GetEnumArray(int index) { + return enumArray_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _deprecatedFieldsMessageFieldNames; + if (hasPrimitiveValue) { + output.WriteInt32(1, field_names[5], PrimitiveValue); + } + if (primitiveArray_.Count > 0) { + output.WriteInt32Array(2, field_names[4], primitiveArray_); + } + if (hasMessageValue) { + output.WriteMessage(3, field_names[3], MessageValue); + } + if (messageArray_.Count > 0) { + output.WriteMessageArray(4, field_names[2], messageArray_); + } + if (hasEnumValue) { + output.WriteEnum(5, field_names[1], (int) EnumValue, EnumValue); + } + if (enumArray_.Count > 0) { + output.WriteEnumArray(6, field_names[0], enumArray_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasPrimitiveValue) { + size += pb::CodedOutputStream.ComputeInt32Size(1, PrimitiveValue); + } + { + int dataSize = 0; + foreach (int element in PrimitiveArrayList) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 1 * primitiveArray_.Count; + } + if (hasMessageValue) { + size += pb::CodedOutputStream.ComputeMessageSize(3, MessageValue); + } + foreach (global::UnitTest.Issues.TestProtos.DeprecatedChild element in MessageArrayList) { + size += pb::CodedOutputStream.ComputeMessageSize(4, element); + } + if (hasEnumValue) { + size += pb::CodedOutputStream.ComputeEnumSize(5, (int) EnumValue); + } + { + int dataSize = 0; + if (enumArray_.Count > 0) { + foreach (global::UnitTest.Issues.TestProtos.DeprecatedEnum element in enumArray_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 1 * enumArray_.Count; + } + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static DeprecatedFieldsMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static DeprecatedFieldsMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static DeprecatedFieldsMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static DeprecatedFieldsMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static DeprecatedFieldsMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static DeprecatedFieldsMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static DeprecatedFieldsMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static DeprecatedFieldsMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static DeprecatedFieldsMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static DeprecatedFieldsMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private DeprecatedFieldsMessage MakeReadOnly() { + primitiveArray_.MakeReadOnly(); + messageArray_.MakeReadOnly(); + enumArray_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(DeprecatedFieldsMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(DeprecatedFieldsMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private DeprecatedFieldsMessage result; + + private DeprecatedFieldsMessage PrepareBuilder() { + if (resultIsReadOnly) { + DeprecatedFieldsMessage original = result; + result = new DeprecatedFieldsMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override DeprecatedFieldsMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::UnitTest.Issues.TestProtos.DeprecatedFieldsMessage.Descriptor; } + } + + public override DeprecatedFieldsMessage DefaultInstanceForType { + get { return global::UnitTest.Issues.TestProtos.DeprecatedFieldsMessage.DefaultInstance; } + } + + public override DeprecatedFieldsMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is DeprecatedFieldsMessage) { + return MergeFrom((DeprecatedFieldsMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(DeprecatedFieldsMessage other) { + if (other == global::UnitTest.Issues.TestProtos.DeprecatedFieldsMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasPrimitiveValue) { + PrimitiveValue = other.PrimitiveValue; + } + if (other.primitiveArray_.Count != 0) { + result.primitiveArray_.Add(other.primitiveArray_); + } + if (other.HasMessageValue) { + MergeMessageValue(other.MessageValue); + } + if (other.messageArray_.Count != 0) { + result.messageArray_.Add(other.messageArray_); + } + if (other.HasEnumValue) { + EnumValue = other.EnumValue; + } + if (other.enumArray_.Count != 0) { + result.enumArray_.Add(other.enumArray_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_deprecatedFieldsMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _deprecatedFieldsMessageFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasPrimitiveValue = input.ReadInt32(ref result.primitiveValue_); + break; + } + case 18: + case 16: { + input.ReadInt32Array(tag, field_name, result.primitiveArray_); + break; + } + case 26: { + global::UnitTest.Issues.TestProtos.DeprecatedChild.Builder subBuilder = global::UnitTest.Issues.TestProtos.DeprecatedChild.CreateBuilder(); + if (result.hasMessageValue) { + subBuilder.MergeFrom(MessageValue); + } + input.ReadMessage(subBuilder, extensionRegistry); + MessageValue = subBuilder.BuildPartial(); + break; + } + case 34: { + input.ReadMessageArray(tag, field_name, result.messageArray_, global::UnitTest.Issues.TestProtos.DeprecatedChild.DefaultInstance, extensionRegistry); + break; + } + case 40: { + object unknown; + if(input.ReadEnum(ref result.enumValue_, out unknown)) { + result.hasEnumValue = true; + } else if(unknown is int) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(5, (ulong)(int)unknown); + } + break; + } + case 50: + case 48: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.enumArray_, out unknownItems); + if (unknownItems != null) { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(6, (ulong)(int)rawValue); + } + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + [global::System.ObsoleteAttribute()] + public bool HasPrimitiveValue { + get { return result.hasPrimitiveValue; } + } + [global::System.ObsoleteAttribute()] + public int PrimitiveValue { + get { return result.PrimitiveValue; } + set { SetPrimitiveValue(value); } + } + [global::System.ObsoleteAttribute()] + public Builder SetPrimitiveValue(int value) { + PrepareBuilder(); + result.hasPrimitiveValue = true; + result.primitiveValue_ = value; + return this; + } + [global::System.ObsoleteAttribute()] + public Builder ClearPrimitiveValue() { + PrepareBuilder(); + result.hasPrimitiveValue = false; + result.primitiveValue_ = 0; + return this; + } + + [global::System.ObsoleteAttribute()] + public pbc::IPopsicleList PrimitiveArrayList { + get { return PrepareBuilder().primitiveArray_; } + } + [global::System.ObsoleteAttribute()] + public int PrimitiveArrayCount { + get { return result.PrimitiveArrayCount; } + } + [global::System.ObsoleteAttribute()] + public int GetPrimitiveArray(int index) { + return result.GetPrimitiveArray(index); + } + [global::System.ObsoleteAttribute()] + public Builder SetPrimitiveArray(int index, int value) { + PrepareBuilder(); + result.primitiveArray_[index] = value; + return this; + } + [global::System.ObsoleteAttribute()] + public Builder AddPrimitiveArray(int value) { + PrepareBuilder(); + result.primitiveArray_.Add(value); + return this; + } + [global::System.ObsoleteAttribute()] + public Builder AddRangePrimitiveArray(scg::IEnumerable values) { + PrepareBuilder(); + result.primitiveArray_.Add(values); + return this; + } + [global::System.ObsoleteAttribute()] + public Builder ClearPrimitiveArray() { + PrepareBuilder(); + result.primitiveArray_.Clear(); + return this; + } + + [global::System.ObsoleteAttribute()] + public bool HasMessageValue { + get { return result.hasMessageValue; } + } + [global::System.ObsoleteAttribute()] + public global::UnitTest.Issues.TestProtos.DeprecatedChild MessageValue { + get { return result.MessageValue; } + set { SetMessageValue(value); } + } + [global::System.ObsoleteAttribute()] + public Builder SetMessageValue(global::UnitTest.Issues.TestProtos.DeprecatedChild value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasMessageValue = true; + result.messageValue_ = value; + return this; + } + [global::System.ObsoleteAttribute()] + public Builder SetMessageValue(global::UnitTest.Issues.TestProtos.DeprecatedChild.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasMessageValue = true; + result.messageValue_ = builderForValue.Build(); + return this; + } + [global::System.ObsoleteAttribute()] + public Builder MergeMessageValue(global::UnitTest.Issues.TestProtos.DeprecatedChild value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasMessageValue && + result.messageValue_ != global::UnitTest.Issues.TestProtos.DeprecatedChild.DefaultInstance) { + result.messageValue_ = global::UnitTest.Issues.TestProtos.DeprecatedChild.CreateBuilder(result.messageValue_).MergeFrom(value).BuildPartial(); + } else { + result.messageValue_ = value; + } + result.hasMessageValue = true; + return this; + } + [global::System.ObsoleteAttribute()] + public Builder ClearMessageValue() { + PrepareBuilder(); + result.hasMessageValue = false; + result.messageValue_ = null; + return this; + } + + [global::System.ObsoleteAttribute()] + public pbc::IPopsicleList MessageArrayList { + get { return PrepareBuilder().messageArray_; } + } + [global::System.ObsoleteAttribute()] + public int MessageArrayCount { + get { return result.MessageArrayCount; } + } + [global::System.ObsoleteAttribute()] + public global::UnitTest.Issues.TestProtos.DeprecatedChild GetMessageArray(int index) { + return result.GetMessageArray(index); + } + [global::System.ObsoleteAttribute()] + public Builder SetMessageArray(int index, global::UnitTest.Issues.TestProtos.DeprecatedChild value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.messageArray_[index] = value; + return this; + } + [global::System.ObsoleteAttribute()] + public Builder SetMessageArray(int index, global::UnitTest.Issues.TestProtos.DeprecatedChild.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.messageArray_[index] = builderForValue.Build(); + return this; + } + [global::System.ObsoleteAttribute()] + public Builder AddMessageArray(global::UnitTest.Issues.TestProtos.DeprecatedChild value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.messageArray_.Add(value); + return this; + } + [global::System.ObsoleteAttribute()] + public Builder AddMessageArray(global::UnitTest.Issues.TestProtos.DeprecatedChild.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.messageArray_.Add(builderForValue.Build()); + return this; + } + [global::System.ObsoleteAttribute()] + public Builder AddRangeMessageArray(scg::IEnumerable values) { + PrepareBuilder(); + result.messageArray_.Add(values); + return this; + } + [global::System.ObsoleteAttribute()] + public Builder ClearMessageArray() { + PrepareBuilder(); + result.messageArray_.Clear(); + return this; + } + + [global::System.ObsoleteAttribute()] + public bool HasEnumValue { + get { return result.hasEnumValue; } + } + [global::System.ObsoleteAttribute()] + public global::UnitTest.Issues.TestProtos.DeprecatedEnum EnumValue { + get { return result.EnumValue; } + set { SetEnumValue(value); } + } + [global::System.ObsoleteAttribute()] + public Builder SetEnumValue(global::UnitTest.Issues.TestProtos.DeprecatedEnum value) { + PrepareBuilder(); + result.hasEnumValue = true; + result.enumValue_ = value; + return this; + } + [global::System.ObsoleteAttribute()] + public Builder ClearEnumValue() { + PrepareBuilder(); + result.hasEnumValue = false; + result.enumValue_ = global::UnitTest.Issues.TestProtos.DeprecatedEnum.one; + return this; + } + + [global::System.ObsoleteAttribute()] + public pbc::IPopsicleList EnumArrayList { + get { return PrepareBuilder().enumArray_; } + } + [global::System.ObsoleteAttribute()] + public int EnumArrayCount { + get { return result.EnumArrayCount; } + } + [global::System.ObsoleteAttribute()] + public global::UnitTest.Issues.TestProtos.DeprecatedEnum GetEnumArray(int index) { + return result.GetEnumArray(index); + } + [global::System.ObsoleteAttribute()] + public Builder SetEnumArray(int index, global::UnitTest.Issues.TestProtos.DeprecatedEnum value) { + PrepareBuilder(); + result.enumArray_[index] = value; + return this; + } + [global::System.ObsoleteAttribute()] + public Builder AddEnumArray(global::UnitTest.Issues.TestProtos.DeprecatedEnum value) { + PrepareBuilder(); + result.enumArray_.Add(value); + return this; + } + [global::System.ObsoleteAttribute()] + public Builder AddRangeEnumArray(scg::IEnumerable values) { + PrepareBuilder(); + result.enumArray_.Add(values); + return this; + } + [global::System.ObsoleteAttribute()] + public Builder ClearEnumArray() { + PrepareBuilder(); + result.enumArray_.Clear(); + return this; + } + } + static DeprecatedFieldsMessage() { + object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class ItemField : pb::GeneratedMessage { + private ItemField() { } + private static readonly ItemField defaultInstance = new ItemField().MakeReadOnly(); + private static readonly string[] _itemFieldFieldNames = new string[] { "item" }; + private static readonly uint[] _itemFieldFieldTags = new uint[] { 8 }; + public static ItemField DefaultInstance { + get { return defaultInstance; } + } + + public override ItemField DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override ItemField ThisMessage { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_ItemField__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { + get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_ItemField__FieldAccessorTable; } + } + + public const int ItemFieldNumber = 1; + private bool hasItem; + private int item_; + public bool HasItem { + get { return hasItem; } + } + public int Item { + get { return item_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _itemFieldFieldNames; + if (hasItem) { + output.WriteInt32(1, field_names[0], Item); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasItem) { + size += pb::CodedOutputStream.ComputeInt32Size(1, Item); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static ItemField ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ItemField ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ItemField ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ItemField ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ItemField ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ItemField ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static ItemField ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static ItemField ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static ItemField ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ItemField ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private ItemField MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(ItemField prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(ItemField cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private ItemField result; + + private ItemField PrepareBuilder() { + if (resultIsReadOnly) { + ItemField original = result; + result = new ItemField(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override ItemField MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType { + get { return global::UnitTest.Issues.TestProtos.ItemField.Descriptor; } + } + + public override ItemField DefaultInstanceForType { + get { return global::UnitTest.Issues.TestProtos.ItemField.DefaultInstance; } + } + + public override ItemField BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) { + if (other is ItemField) { + return MergeFrom((ItemField) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(ItemField other) { + if (other == global::UnitTest.Issues.TestProtos.ItemField.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasItem) { + Item = other.Item; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_itemFieldFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _itemFieldFieldTags[field_ordinal]; + else { + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasItem = input.ReadInt32(ref result.item_); + break; + } + } + } + + if (unknownFields != null) { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasItem { + get { return result.hasItem; } + } + public int Item { + get { return result.Item; } + set { SetItem(value); } + } + public Builder SetItem(int value) { + PrepareBuilder(); + result.hasItem = true; + result.item_ = value; + return this; + } + public Builder ClearItem() { + PrepareBuilder(); + result.hasItem = false; + result.item_ = 0; + return this; + } + } + static ItemField() { + object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestLite.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestLite.cs new file mode 100644 index 00000000..de378704 --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestLite.cs @@ -0,0 +1,12460 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/protobuf/unittest_lite.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace Google.ProtocolBuffers.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class UnittestLite { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalInt32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalInt64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalUint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalUint64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSint64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalFixed32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalFixed64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSfixed32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSfixed64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalFloatExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalDoubleExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalBoolExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalStringExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalBytesExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalGroupExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalNestedMessageExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalForeignMessageExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalImportMessageExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalNestedEnumExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalForeignEnumExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalImportEnumExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalStringPieceExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalCordExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalPublicImportMessageExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalLazyMessageExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedInt32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedInt64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedUint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedUint64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSint64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedFixed32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedFixed64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSfixed32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSfixed64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedFloatExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedDoubleExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedBoolExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedStringExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedBytesExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedGroupExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedNestedMessageExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedForeignMessageExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedImportMessageExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedNestedEnumExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedForeignEnumExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedImportEnumExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedStringPieceExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedCordExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedLazyMessageExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultInt32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultInt64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultUint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultUint64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSint64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultFixed32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultFixed64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSfixed32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSfixed64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultFloatExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultDoubleExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultBoolExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultStringExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultBytesExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultNestedEnumExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultForeignEnumExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultImportEnumExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultStringPieceExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultCordExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofUint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofNestedMessageExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofStringExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofBytesExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedInt32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedInt64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedUint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedUint64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSint32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSint64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedFixed32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedFixed64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSfixed32ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSfixed64ExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedFloatExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedDoubleExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedBoolExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedEnumExtensionLite); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestNestedExtensionLite.NestedExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.OptionalExt); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.RepeatedExt); + } + #endregion + #region Extensions + public const int OptionalInt32ExtensionLiteFieldNumber = 1; + public static pb::GeneratedExtensionLite OptionalInt32ExtensionLite; + public const int OptionalInt64ExtensionLiteFieldNumber = 2; + public static pb::GeneratedExtensionLite OptionalInt64ExtensionLite; + public const int OptionalUint32ExtensionLiteFieldNumber = 3; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionLite OptionalUint32ExtensionLite; + public const int OptionalUint64ExtensionLiteFieldNumber = 4; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionLite OptionalUint64ExtensionLite; + public const int OptionalSint32ExtensionLiteFieldNumber = 5; + public static pb::GeneratedExtensionLite OptionalSint32ExtensionLite; + public const int OptionalSint64ExtensionLiteFieldNumber = 6; + public static pb::GeneratedExtensionLite OptionalSint64ExtensionLite; + public const int OptionalFixed32ExtensionLiteFieldNumber = 7; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionLite OptionalFixed32ExtensionLite; + public const int OptionalFixed64ExtensionLiteFieldNumber = 8; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionLite OptionalFixed64ExtensionLite; + public const int OptionalSfixed32ExtensionLiteFieldNumber = 9; + public static pb::GeneratedExtensionLite OptionalSfixed32ExtensionLite; + public const int OptionalSfixed64ExtensionLiteFieldNumber = 10; + public static pb::GeneratedExtensionLite OptionalSfixed64ExtensionLite; + public const int OptionalFloatExtensionLiteFieldNumber = 11; + public static pb::GeneratedExtensionLite OptionalFloatExtensionLite; + public const int OptionalDoubleExtensionLiteFieldNumber = 12; + public static pb::GeneratedExtensionLite OptionalDoubleExtensionLite; + public const int OptionalBoolExtensionLiteFieldNumber = 13; + public static pb::GeneratedExtensionLite OptionalBoolExtensionLite; + public const int OptionalStringExtensionLiteFieldNumber = 14; + public static pb::GeneratedExtensionLite OptionalStringExtensionLite; + public const int OptionalBytesExtensionLiteFieldNumber = 15; + public static pb::GeneratedExtensionLite OptionalBytesExtensionLite; + public const int OptionalGroupExtensionLiteFieldNumber = 16; + public static pb::GeneratedExtensionLite OptionalGroupExtensionLite; + public const int OptionalNestedMessageExtensionLiteFieldNumber = 18; + public static pb::GeneratedExtensionLite OptionalNestedMessageExtensionLite; + public const int OptionalForeignMessageExtensionLiteFieldNumber = 19; + public static pb::GeneratedExtensionLite OptionalForeignMessageExtensionLite; + public const int OptionalImportMessageExtensionLiteFieldNumber = 20; + public static pb::GeneratedExtensionLite OptionalImportMessageExtensionLite; + public const int OptionalNestedEnumExtensionLiteFieldNumber = 21; + public static pb::GeneratedExtensionLite OptionalNestedEnumExtensionLite; + public const int OptionalForeignEnumExtensionLiteFieldNumber = 22; + public static pb::GeneratedExtensionLite OptionalForeignEnumExtensionLite; + public const int OptionalImportEnumExtensionLiteFieldNumber = 23; + public static pb::GeneratedExtensionLite OptionalImportEnumExtensionLite; + public const int OptionalStringPieceExtensionLiteFieldNumber = 24; + public static pb::GeneratedExtensionLite OptionalStringPieceExtensionLite; + public const int OptionalCordExtensionLiteFieldNumber = 25; + public static pb::GeneratedExtensionLite OptionalCordExtensionLite; + public const int OptionalPublicImportMessageExtensionLiteFieldNumber = 26; + public static pb::GeneratedExtensionLite OptionalPublicImportMessageExtensionLite; + public const int OptionalLazyMessageExtensionLiteFieldNumber = 27; + public static pb::GeneratedExtensionLite OptionalLazyMessageExtensionLite; + public const int RepeatedInt32ExtensionLiteFieldNumber = 31; + public static pb::GeneratedRepeatExtensionLite RepeatedInt32ExtensionLite; + public const int RepeatedInt64ExtensionLiteFieldNumber = 32; + public static pb::GeneratedRepeatExtensionLite RepeatedInt64ExtensionLite; + public const int RepeatedUint32ExtensionLiteFieldNumber = 33; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite RepeatedUint32ExtensionLite; + public const int RepeatedUint64ExtensionLiteFieldNumber = 34; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite RepeatedUint64ExtensionLite; + public const int RepeatedSint32ExtensionLiteFieldNumber = 35; + public static pb::GeneratedRepeatExtensionLite RepeatedSint32ExtensionLite; + public const int RepeatedSint64ExtensionLiteFieldNumber = 36; + public static pb::GeneratedRepeatExtensionLite RepeatedSint64ExtensionLite; + public const int RepeatedFixed32ExtensionLiteFieldNumber = 37; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite RepeatedFixed32ExtensionLite; + public const int RepeatedFixed64ExtensionLiteFieldNumber = 38; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite RepeatedFixed64ExtensionLite; + public const int RepeatedSfixed32ExtensionLiteFieldNumber = 39; + public static pb::GeneratedRepeatExtensionLite RepeatedSfixed32ExtensionLite; + public const int RepeatedSfixed64ExtensionLiteFieldNumber = 40; + public static pb::GeneratedRepeatExtensionLite RepeatedSfixed64ExtensionLite; + public const int RepeatedFloatExtensionLiteFieldNumber = 41; + public static pb::GeneratedRepeatExtensionLite RepeatedFloatExtensionLite; + public const int RepeatedDoubleExtensionLiteFieldNumber = 42; + public static pb::GeneratedRepeatExtensionLite RepeatedDoubleExtensionLite; + public const int RepeatedBoolExtensionLiteFieldNumber = 43; + public static pb::GeneratedRepeatExtensionLite RepeatedBoolExtensionLite; + public const int RepeatedStringExtensionLiteFieldNumber = 44; + public static pb::GeneratedRepeatExtensionLite RepeatedStringExtensionLite; + public const int RepeatedBytesExtensionLiteFieldNumber = 45; + public static pb::GeneratedRepeatExtensionLite RepeatedBytesExtensionLite; + public const int RepeatedGroupExtensionLiteFieldNumber = 46; + public static pb::GeneratedRepeatExtensionLite RepeatedGroupExtensionLite; + public const int RepeatedNestedMessageExtensionLiteFieldNumber = 48; + public static pb::GeneratedRepeatExtensionLite RepeatedNestedMessageExtensionLite; + public const int RepeatedForeignMessageExtensionLiteFieldNumber = 49; + public static pb::GeneratedRepeatExtensionLite RepeatedForeignMessageExtensionLite; + public const int RepeatedImportMessageExtensionLiteFieldNumber = 50; + public static pb::GeneratedRepeatExtensionLite RepeatedImportMessageExtensionLite; + public const int RepeatedNestedEnumExtensionLiteFieldNumber = 51; + public static pb::GeneratedRepeatExtensionLite RepeatedNestedEnumExtensionLite; + public const int RepeatedForeignEnumExtensionLiteFieldNumber = 52; + public static pb::GeneratedRepeatExtensionLite RepeatedForeignEnumExtensionLite; + public const int RepeatedImportEnumExtensionLiteFieldNumber = 53; + public static pb::GeneratedRepeatExtensionLite RepeatedImportEnumExtensionLite; + public const int RepeatedStringPieceExtensionLiteFieldNumber = 54; + public static pb::GeneratedRepeatExtensionLite RepeatedStringPieceExtensionLite; + public const int RepeatedCordExtensionLiteFieldNumber = 55; + public static pb::GeneratedRepeatExtensionLite RepeatedCordExtensionLite; + public const int RepeatedLazyMessageExtensionLiteFieldNumber = 57; + public static pb::GeneratedRepeatExtensionLite RepeatedLazyMessageExtensionLite; + public const int DefaultInt32ExtensionLiteFieldNumber = 61; + public static pb::GeneratedExtensionLite DefaultInt32ExtensionLite; + public const int DefaultInt64ExtensionLiteFieldNumber = 62; + public static pb::GeneratedExtensionLite DefaultInt64ExtensionLite; + public const int DefaultUint32ExtensionLiteFieldNumber = 63; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionLite DefaultUint32ExtensionLite; + public const int DefaultUint64ExtensionLiteFieldNumber = 64; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionLite DefaultUint64ExtensionLite; + public const int DefaultSint32ExtensionLiteFieldNumber = 65; + public static pb::GeneratedExtensionLite DefaultSint32ExtensionLite; + public const int DefaultSint64ExtensionLiteFieldNumber = 66; + public static pb::GeneratedExtensionLite DefaultSint64ExtensionLite; + public const int DefaultFixed32ExtensionLiteFieldNumber = 67; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionLite DefaultFixed32ExtensionLite; + public const int DefaultFixed64ExtensionLiteFieldNumber = 68; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionLite DefaultFixed64ExtensionLite; + public const int DefaultSfixed32ExtensionLiteFieldNumber = 69; + public static pb::GeneratedExtensionLite DefaultSfixed32ExtensionLite; + public const int DefaultSfixed64ExtensionLiteFieldNumber = 70; + public static pb::GeneratedExtensionLite DefaultSfixed64ExtensionLite; + public const int DefaultFloatExtensionLiteFieldNumber = 71; + public static pb::GeneratedExtensionLite DefaultFloatExtensionLite; + public const int DefaultDoubleExtensionLiteFieldNumber = 72; + public static pb::GeneratedExtensionLite DefaultDoubleExtensionLite; + public const int DefaultBoolExtensionLiteFieldNumber = 73; + public static pb::GeneratedExtensionLite DefaultBoolExtensionLite; + public const int DefaultStringExtensionLiteFieldNumber = 74; + public static pb::GeneratedExtensionLite DefaultStringExtensionLite; + public const int DefaultBytesExtensionLiteFieldNumber = 75; + public static pb::GeneratedExtensionLite DefaultBytesExtensionLite; + public const int DefaultNestedEnumExtensionLiteFieldNumber = 81; + public static pb::GeneratedExtensionLite DefaultNestedEnumExtensionLite; + public const int DefaultForeignEnumExtensionLiteFieldNumber = 82; + public static pb::GeneratedExtensionLite DefaultForeignEnumExtensionLite; + public const int DefaultImportEnumExtensionLiteFieldNumber = 83; + public static pb::GeneratedExtensionLite DefaultImportEnumExtensionLite; + public const int DefaultStringPieceExtensionLiteFieldNumber = 84; + public static pb::GeneratedExtensionLite DefaultStringPieceExtensionLite; + public const int DefaultCordExtensionLiteFieldNumber = 85; + public static pb::GeneratedExtensionLite DefaultCordExtensionLite; + public const int OneofUint32ExtensionLiteFieldNumber = 111; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionLite OneofUint32ExtensionLite; + public const int OneofNestedMessageExtensionLiteFieldNumber = 112; + public static pb::GeneratedExtensionLite OneofNestedMessageExtensionLite; + public const int OneofStringExtensionLiteFieldNumber = 113; + public static pb::GeneratedExtensionLite OneofStringExtensionLite; + public const int OneofBytesExtensionLiteFieldNumber = 114; + public static pb::GeneratedExtensionLite OneofBytesExtensionLite; + public const int PackedInt32ExtensionLiteFieldNumber = 90; + public static pb::GeneratedRepeatExtensionLite PackedInt32ExtensionLite; + public const int PackedInt64ExtensionLiteFieldNumber = 91; + public static pb::GeneratedRepeatExtensionLite PackedInt64ExtensionLite; + public const int PackedUint32ExtensionLiteFieldNumber = 92; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite PackedUint32ExtensionLite; + public const int PackedUint64ExtensionLiteFieldNumber = 93; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite PackedUint64ExtensionLite; + public const int PackedSint32ExtensionLiteFieldNumber = 94; + public static pb::GeneratedRepeatExtensionLite PackedSint32ExtensionLite; + public const int PackedSint64ExtensionLiteFieldNumber = 95; + public static pb::GeneratedRepeatExtensionLite PackedSint64ExtensionLite; + public const int PackedFixed32ExtensionLiteFieldNumber = 96; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite PackedFixed32ExtensionLite; + public const int PackedFixed64ExtensionLiteFieldNumber = 97; + [global::System.CLSCompliant(false)] + public static pb::GeneratedRepeatExtensionLite PackedFixed64ExtensionLite; + public const int PackedSfixed32ExtensionLiteFieldNumber = 98; + public static pb::GeneratedRepeatExtensionLite PackedSfixed32ExtensionLite; + public const int PackedSfixed64ExtensionLiteFieldNumber = 99; + public static pb::GeneratedRepeatExtensionLite PackedSfixed64ExtensionLite; + public const int PackedFloatExtensionLiteFieldNumber = 100; + public static pb::GeneratedRepeatExtensionLite PackedFloatExtensionLite; + public const int PackedDoubleExtensionLiteFieldNumber = 101; + public static pb::GeneratedRepeatExtensionLite PackedDoubleExtensionLite; + public const int PackedBoolExtensionLiteFieldNumber = 102; + public static pb::GeneratedRepeatExtensionLite PackedBoolExtensionLite; + public const int PackedEnumExtensionLiteFieldNumber = 103; + public static pb::GeneratedRepeatExtensionLite PackedEnumExtensionLite; + #endregion + + #region Static variables + #endregion + #region Extensions + internal static readonly object Descriptor; + static UnittestLite() { + Descriptor = null; + global::Google.ProtocolBuffers.TestProtos.TestNestedExtensionLite.NestedExtension = + new pb::GeneratedExtensionLite( + "protobuf_unittest.TestNestedExtensionLite.nested_extension", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(int), + null, + null, + global::Google.ProtocolBuffers.TestProtos.TestNestedExtensionLite.NestedExtensionFieldNumber, + pbd::FieldType.Int32); + global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.OptionalExt = + new pb::GeneratedExtensionLite( + "protobuf_unittest.TestParsingMergeLite.optional_ext", + global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.OptionalExtFieldNumber, + pbd::FieldType.Message); + global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.RepeatedExt = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.TestParsingMergeLite.repeated_ext", + global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.DefaultInstance, + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.RepeatedExtFieldNumber, + pbd::FieldType.Message, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalInt32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_int32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(int), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalInt32ExtensionLiteFieldNumber, + pbd::FieldType.Int32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalInt64ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_int64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(long), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalInt64ExtensionLiteFieldNumber, + pbd::FieldType.Int64); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalUint32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_uint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(uint), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalUint32ExtensionLiteFieldNumber, + pbd::FieldType.UInt32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalUint64ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_uint64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(ulong), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalUint64ExtensionLiteFieldNumber, + pbd::FieldType.UInt64); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSint32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_sint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(int), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSint32ExtensionLiteFieldNumber, + pbd::FieldType.SInt32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSint64ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_sint64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(long), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSint64ExtensionLiteFieldNumber, + pbd::FieldType.SInt64); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalFixed32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_fixed32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(uint), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalFixed32ExtensionLiteFieldNumber, + pbd::FieldType.Fixed32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalFixed64ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_fixed64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(ulong), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalFixed64ExtensionLiteFieldNumber, + pbd::FieldType.Fixed64); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSfixed32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_sfixed32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(int), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSfixed32ExtensionLiteFieldNumber, + pbd::FieldType.SFixed32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSfixed64ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_sfixed64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(long), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalSfixed64ExtensionLiteFieldNumber, + pbd::FieldType.SFixed64); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalFloatExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_float_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(float), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalFloatExtensionLiteFieldNumber, + pbd::FieldType.Float); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalDoubleExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_double_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(double), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalDoubleExtensionLiteFieldNumber, + pbd::FieldType.Double); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalBoolExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_bool_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(bool), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalBoolExtensionLiteFieldNumber, + pbd::FieldType.Bool); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalStringExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_string_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalStringExtensionLiteFieldNumber, + pbd::FieldType.String); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalBytesExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_bytes_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalBytesExtensionLiteFieldNumber, + pbd::FieldType.Bytes); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalGroupExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optionalgroup_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension_lite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalGroupExtensionLiteFieldNumber, + pbd::FieldType.Group); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalNestedMessageExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_nested_message_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalNestedMessageExtensionLiteFieldNumber, + pbd::FieldType.Message); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalForeignMessageExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_foreign_message_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalForeignMessageExtensionLiteFieldNumber, + pbd::FieldType.Message); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalImportMessageExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_import_message_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalImportMessageExtensionLiteFieldNumber, + pbd::FieldType.Message); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalNestedEnumExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_nested_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum), + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalNestedEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalForeignEnumExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_foreign_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite), + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalForeignEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalImportEnumExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_import_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(global::Google.ProtocolBuffers.TestProtos.ImportEnumLite), + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalImportEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalStringPieceExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_string_piece_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalStringPieceExtensionLiteFieldNumber, + pbd::FieldType.String); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalCordExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_cord_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalCordExtensionLiteFieldNumber, + pbd::FieldType.String); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalPublicImportMessageExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_public_import_message_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalPublicImportMessageExtensionLiteFieldNumber, + pbd::FieldType.Message); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalLazyMessageExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.optional_lazy_message_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OptionalLazyMessageExtensionLiteFieldNumber, + pbd::FieldType.Message); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedInt32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_int32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedInt32ExtensionLiteFieldNumber, + pbd::FieldType.Int32, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedInt64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_int64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedInt64ExtensionLiteFieldNumber, + pbd::FieldType.Int64, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedUint32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_uint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedUint32ExtensionLiteFieldNumber, + pbd::FieldType.UInt32, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedUint64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_uint64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedUint64ExtensionLiteFieldNumber, + pbd::FieldType.UInt64, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSint32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_sint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSint32ExtensionLiteFieldNumber, + pbd::FieldType.SInt32, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSint64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_sint64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSint64ExtensionLiteFieldNumber, + pbd::FieldType.SInt64, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedFixed32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_fixed32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedFixed32ExtensionLiteFieldNumber, + pbd::FieldType.Fixed32, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedFixed64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_fixed64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedFixed64ExtensionLiteFieldNumber, + pbd::FieldType.Fixed64, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSfixed32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_sfixed32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSfixed32ExtensionLiteFieldNumber, + pbd::FieldType.SFixed32, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSfixed64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_sfixed64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedSfixed64ExtensionLiteFieldNumber, + pbd::FieldType.SFixed64, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedFloatExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_float_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedFloatExtensionLiteFieldNumber, + pbd::FieldType.Float, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedDoubleExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_double_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedDoubleExtensionLiteFieldNumber, + pbd::FieldType.Double, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedBoolExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_bool_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedBoolExtensionLiteFieldNumber, + pbd::FieldType.Bool, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedStringExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_string_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedStringExtensionLiteFieldNumber, + pbd::FieldType.String, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedBytesExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_bytes_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedBytesExtensionLiteFieldNumber, + pbd::FieldType.Bytes, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedGroupExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeatedgroup_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension_lite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedGroupExtensionLiteFieldNumber, + pbd::FieldType.Group, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedNestedMessageExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_nested_message_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedNestedMessageExtensionLiteFieldNumber, + pbd::FieldType.Message, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedForeignMessageExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_foreign_message_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedForeignMessageExtensionLiteFieldNumber, + pbd::FieldType.Message, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedImportMessageExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_import_message_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedImportMessageExtensionLiteFieldNumber, + pbd::FieldType.Message, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedNestedEnumExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_nested_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedNestedEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedForeignEnumExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_foreign_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedForeignEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedImportEnumExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_import_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedImportEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedStringPieceExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_string_piece_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedStringPieceExtensionLiteFieldNumber, + pbd::FieldType.String, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedCordExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_cord_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedCordExtensionLiteFieldNumber, + pbd::FieldType.String, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedLazyMessageExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.repeated_lazy_message_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.RepeatedLazyMessageExtensionLiteFieldNumber, + pbd::FieldType.Message, + false); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultInt32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_int32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + 41, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultInt32ExtensionLiteFieldNumber, + pbd::FieldType.Int32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultInt64ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_int64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + 42L, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultInt64ExtensionLiteFieldNumber, + pbd::FieldType.Int64); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultUint32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_uint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + 43, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultUint32ExtensionLiteFieldNumber, + pbd::FieldType.UInt32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultUint64ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_uint64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + 44UL, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultUint64ExtensionLiteFieldNumber, + pbd::FieldType.UInt64); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSint32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_sint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + -45, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSint32ExtensionLiteFieldNumber, + pbd::FieldType.SInt32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSint64ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_sint64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + 46L, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSint64ExtensionLiteFieldNumber, + pbd::FieldType.SInt64); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultFixed32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_fixed32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + 47, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultFixed32ExtensionLiteFieldNumber, + pbd::FieldType.Fixed32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultFixed64ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_fixed64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + 48UL, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultFixed64ExtensionLiteFieldNumber, + pbd::FieldType.Fixed64); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSfixed32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_sfixed32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + 49, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSfixed32ExtensionLiteFieldNumber, + pbd::FieldType.SFixed32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSfixed64ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_sfixed64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + -50L, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultSfixed64ExtensionLiteFieldNumber, + pbd::FieldType.SFixed64); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultFloatExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_float_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + 51.5F, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultFloatExtensionLiteFieldNumber, + pbd::FieldType.Float); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultDoubleExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_double_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + 52000D, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultDoubleExtensionLiteFieldNumber, + pbd::FieldType.Double); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultBoolExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_bool_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + true, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultBoolExtensionLiteFieldNumber, + pbd::FieldType.Bool); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultStringExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_string_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + "hello", + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultStringExtensionLiteFieldNumber, + pbd::FieldType.String); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultBytesExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_bytes_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + pb::ByteString.FromBase64("d29ybGQ="), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultBytesExtensionLiteFieldNumber, + pbd::FieldType.Bytes); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultNestedEnumExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_nested_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum.BAR, + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultNestedEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultForeignEnumExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_foreign_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite.FOREIGN_LITE_BAR, + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultForeignEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultImportEnumExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_import_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + global::Google.ProtocolBuffers.TestProtos.ImportEnumLite.IMPORT_LITE_BAR, + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultImportEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultStringPieceExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_string_piece_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + "abc", + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultStringPieceExtensionLiteFieldNumber, + pbd::FieldType.String); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultCordExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.default_cord_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + "123", + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.DefaultCordExtensionLiteFieldNumber, + pbd::FieldType.String); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofUint32ExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.oneof_uint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + default(uint), + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofUint32ExtensionLiteFieldNumber, + pbd::FieldType.UInt32); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofNestedMessageExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.oneof_nested_message_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofNestedMessageExtensionLiteFieldNumber, + pbd::FieldType.Message); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofStringExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.oneof_string_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofStringExtensionLiteFieldNumber, + pbd::FieldType.String); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofBytesExtensionLite = + new pb::GeneratedExtensionLite( + "protobuf_unittest.oneof_bytes_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance, + null, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.OneofBytesExtensionLiteFieldNumber, + pbd::FieldType.Bytes); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedInt32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_int32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedInt32ExtensionLiteFieldNumber, + pbd::FieldType.Int32, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedInt64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_int64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedInt64ExtensionLiteFieldNumber, + pbd::FieldType.Int64, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedUint32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_uint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedUint32ExtensionLiteFieldNumber, + pbd::FieldType.UInt32, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedUint64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_uint64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedUint64ExtensionLiteFieldNumber, + pbd::FieldType.UInt64, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSint32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_sint32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSint32ExtensionLiteFieldNumber, + pbd::FieldType.SInt32, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSint64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_sint64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSint64ExtensionLiteFieldNumber, + pbd::FieldType.SInt64, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedFixed32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_fixed32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedFixed32ExtensionLiteFieldNumber, + pbd::FieldType.Fixed32, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedFixed64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_fixed64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedFixed64ExtensionLiteFieldNumber, + pbd::FieldType.Fixed64, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSfixed32ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_sfixed32_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSfixed32ExtensionLiteFieldNumber, + pbd::FieldType.SFixed32, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSfixed64ExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_sfixed64_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedSfixed64ExtensionLiteFieldNumber, + pbd::FieldType.SFixed64, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedFloatExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_float_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedFloatExtensionLiteFieldNumber, + pbd::FieldType.Float, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedDoubleExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_double_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedDoubleExtensionLiteFieldNumber, + pbd::FieldType.Double, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedBoolExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_bool_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + null, + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedBoolExtensionLiteFieldNumber, + pbd::FieldType.Bool, + true); + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedEnumExtensionLite = + new pb::GeneratedRepeatExtensionLite( + "protobuf_unittest.packed_enum_extension_lite", + global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance, + null, + new EnumLiteMap(), + global::Google.ProtocolBuffers.TestProtos.UnittestLite.PackedEnumExtensionLiteFieldNumber, + pbd::FieldType.Enum, + true); + } + #endregion + + } + #region Enums + public enum ForeignEnumLite { + FOREIGN_LITE_FOO = 4, + FOREIGN_LITE_BAR = 5, + FOREIGN_LITE_BAZ = 6, + } + + #endregion + + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestAllTypesLite : pb::GeneratedMessageLite { + private TestAllTypesLite() { } + private static readonly TestAllTypesLite defaultInstance = new TestAllTypesLite().MakeReadOnly(); + private static readonly string[] _testAllTypesLiteFieldNames = new string[] { "default_bool", "default_bytes", "default_cord", "default_double", "default_fixed32", "default_fixed64", "default_float", "default_foreign_enum", "default_import_enum", "default_int32", "default_int64", "default_nested_enum", "default_sfixed32", "default_sfixed64", "default_sint32", "default_sint64", "default_string", "default_string_piece", "default_uint32", "default_uint64", "oneof_bytes", "oneof_nested_message", "oneof_string", "oneof_uint32", "optional_bool", "optional_bytes", "optional_cord", "optional_double", "optional_fixed32", "optional_fixed64", "optional_float", "optional_foreign_enum", "optional_foreign_message", "optional_import_enum", "optional_import_message", "optional_int32", "optional_int64", "optional_lazy_message", "optional_nested_enum", "optional_nested_message", "optional_public_import_message", "optional_sfixed32", "optional_sfixed64", "optional_sint32", "optional_sint64", "optional_string", "optional_string_piece", "optional_uint32", "optional_uint64", "optionalgroup", "repeated_bool", "repeated_bytes", "repeated_cord", "repeated_double", "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_foreign_enum", "repeated_foreign_message", "repeated_import_enum", "repeated_import_message", "repeated_int32", "repeated_int64", "repeated_lazy_message", "repeated_nested_enum", "repeated_nested_message", "repeated_sfixed32", "repeated_sfixed64", "repeated_sint32", "repeated_sint64", "repeated_string", "repeated_string_piece", "repeated_uint32", "repeated_uint64", "repeatedgroup" }; + private static readonly uint[] _testAllTypesLiteFieldTags = new uint[] { 584, 602, 682, 577, 541, 545, 573, 656, 664, 488, 496, 648, 557, 561, 520, 528, 594, 674, 504, 512, 914, 898, 906, 888, 104, 122, 202, 97, 61, 65, 93, 176, 154, 184, 162, 8, 16, 218, 168, 146, 210, 77, 81, 40, 48, 114, 194, 24, 32, 131, 344, 362, 442, 337, 301, 305, 333, 416, 394, 424, 402, 248, 256, 458, 408, 386, 317, 321, 280, 288, 354, 434, 264, 272, 371 }; + public static TestAllTypesLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestAllTypesLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestAllTypesLite ThisMessage { + get { return this; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + public enum NestedEnum { + FOO = 1, + BAR = 2, + BAZ = 3, + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessageLite { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "bb" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8 }; + public static NestedMessage DefaultInstance { + get { return defaultInstance; } + } + + public override NestedMessage DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override NestedMessage ThisMessage { + get { return this; } + } + + public const int BbFieldNumber = 1; + private bool hasBb; + private int bb_; + public bool HasBb { + get { return hasBb; } + } + public int Bb { + get { return bb_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (hasBb) { + output.WriteInt32(1, field_names[0], Bb); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasBb) { + size += pb::CodedOutputStream.ComputeInt32Size(1, Bb); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasBb) hash ^= bb_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + NestedMessage other = obj as NestedMessage; + if (other == null) return false; + if (hasBb != other.hasBb || (hasBb && !bb_.Equals(other.bb_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("bb", hasBb, bb_, writer); + } + #endregion + + public static NestedMessage ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() { + if (resultIsReadOnly) { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override NestedMessage MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override NestedMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance; } + } + + public override NestedMessage BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is NestedMessage) { + return MergeFrom((NestedMessage) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NestedMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasBb) { + Bb = other.Bb; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasBb = input.ReadInt32(ref result.bb_); + break; + } + } + } + + return this; + } + + + public bool HasBb { + get { return result.hasBb; } + } + public int Bb { + get { return result.Bb; } + set { SetBb(value); } + } + public Builder SetBb(int value) { + PrepareBuilder(); + result.hasBb = true; + result.bb_ = value; + return this; + } + public Builder ClearBb() { + PrepareBuilder(); + result.hasBb = false; + result.bb_ = 0; + return this; + } + } + static NestedMessage() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OptionalGroup : pb::GeneratedMessageLite { + private OptionalGroup() { } + private static readonly OptionalGroup defaultInstance = new OptionalGroup().MakeReadOnly(); + private static readonly string[] _optionalGroupFieldNames = new string[] { "a" }; + private static readonly uint[] _optionalGroupFieldTags = new uint[] { 136 }; + public static OptionalGroup DefaultInstance { + get { return defaultInstance; } + } + + public override OptionalGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override OptionalGroup ThisMessage { + get { return this; } + } + + public const int AFieldNumber = 17; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _optionalGroupFieldNames; + if (hasA) { + output.WriteInt32(17, field_names[0], A); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(17, A); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasA) hash ^= a_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + OptionalGroup other = obj as OptionalGroup; + if (other == null) return false; + if (hasA != other.hasA || (hasA && !a_.Equals(other.a_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("a", hasA, a_, writer); + } + #endregion + + public static OptionalGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OptionalGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OptionalGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OptionalGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OptionalGroup result; + + private OptionalGroup PrepareBuilder() { + if (resultIsReadOnly) { + OptionalGroup original = result; + result = new OptionalGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override OptionalGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override OptionalGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.DefaultInstance; } + } + + public override OptionalGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is OptionalGroup) { + return MergeFrom((OptionalGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OptionalGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _optionalGroupFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 136: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static OptionalGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedGroup : pb::GeneratedMessageLite { + private RepeatedGroup() { } + private static readonly RepeatedGroup defaultInstance = new RepeatedGroup().MakeReadOnly(); + private static readonly string[] _repeatedGroupFieldNames = new string[] { "a" }; + private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 376 }; + public static RepeatedGroup DefaultInstance { + get { return defaultInstance; } + } + + public override RepeatedGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override RepeatedGroup ThisMessage { + get { return this; } + } + + public const int AFieldNumber = 47; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _repeatedGroupFieldNames; + if (hasA) { + output.WriteInt32(47, field_names[0], A); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(47, A); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasA) hash ^= a_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + RepeatedGroup other = obj as RepeatedGroup; + if (other == null) return false; + if (hasA != other.hasA || (hasA && !a_.Equals(other.a_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("a", hasA, a_, writer); + } + #endregion + + public static RepeatedGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private RepeatedGroup result; + + private RepeatedGroup PrepareBuilder() { + if (resultIsReadOnly) { + RepeatedGroup original = result; + result = new RepeatedGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override RepeatedGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override RepeatedGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup.DefaultInstance; } + } + + public override RepeatedGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is RepeatedGroup) { + return MergeFrom((RepeatedGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(RepeatedGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _repeatedGroupFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 376: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static RepeatedGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + } + #endregion + + public const int OptionalInt32FieldNumber = 1; + private bool hasOptionalInt32; + private int optionalInt32_; + public bool HasOptionalInt32 { + get { return hasOptionalInt32; } + } + public int OptionalInt32 { + get { return optionalInt32_; } + } + + public const int OptionalInt64FieldNumber = 2; + private bool hasOptionalInt64; + private long optionalInt64_; + public bool HasOptionalInt64 { + get { return hasOptionalInt64; } + } + public long OptionalInt64 { + get { return optionalInt64_; } + } + + public const int OptionalUint32FieldNumber = 3; + private bool hasOptionalUint32; + private uint optionalUint32_; + public bool HasOptionalUint32 { + get { return hasOptionalUint32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalUint32 { + get { return optionalUint32_; } + } + + public const int OptionalUint64FieldNumber = 4; + private bool hasOptionalUint64; + private ulong optionalUint64_; + public bool HasOptionalUint64 { + get { return hasOptionalUint64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalUint64 { + get { return optionalUint64_; } + } + + public const int OptionalSint32FieldNumber = 5; + private bool hasOptionalSint32; + private int optionalSint32_; + public bool HasOptionalSint32 { + get { return hasOptionalSint32; } + } + public int OptionalSint32 { + get { return optionalSint32_; } + } + + public const int OptionalSint64FieldNumber = 6; + private bool hasOptionalSint64; + private long optionalSint64_; + public bool HasOptionalSint64 { + get { return hasOptionalSint64; } + } + public long OptionalSint64 { + get { return optionalSint64_; } + } + + public const int OptionalFixed32FieldNumber = 7; + private bool hasOptionalFixed32; + private uint optionalFixed32_; + public bool HasOptionalFixed32 { + get { return hasOptionalFixed32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalFixed32 { + get { return optionalFixed32_; } + } + + public const int OptionalFixed64FieldNumber = 8; + private bool hasOptionalFixed64; + private ulong optionalFixed64_; + public bool HasOptionalFixed64 { + get { return hasOptionalFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalFixed64 { + get { return optionalFixed64_; } + } + + public const int OptionalSfixed32FieldNumber = 9; + private bool hasOptionalSfixed32; + private int optionalSfixed32_; + public bool HasOptionalSfixed32 { + get { return hasOptionalSfixed32; } + } + public int OptionalSfixed32 { + get { return optionalSfixed32_; } + } + + public const int OptionalSfixed64FieldNumber = 10; + private bool hasOptionalSfixed64; + private long optionalSfixed64_; + public bool HasOptionalSfixed64 { + get { return hasOptionalSfixed64; } + } + public long OptionalSfixed64 { + get { return optionalSfixed64_; } + } + + public const int OptionalFloatFieldNumber = 11; + private bool hasOptionalFloat; + private float optionalFloat_; + public bool HasOptionalFloat { + get { return hasOptionalFloat; } + } + public float OptionalFloat { + get { return optionalFloat_; } + } + + public const int OptionalDoubleFieldNumber = 12; + private bool hasOptionalDouble; + private double optionalDouble_; + public bool HasOptionalDouble { + get { return hasOptionalDouble; } + } + public double OptionalDouble { + get { return optionalDouble_; } + } + + public const int OptionalBoolFieldNumber = 13; + private bool hasOptionalBool; + private bool optionalBool_; + public bool HasOptionalBool { + get { return hasOptionalBool; } + } + public bool OptionalBool { + get { return optionalBool_; } + } + + public const int OptionalStringFieldNumber = 14; + private bool hasOptionalString; + private string optionalString_ = ""; + public bool HasOptionalString { + get { return hasOptionalString; } + } + public string OptionalString { + get { return optionalString_; } + } + + public const int OptionalBytesFieldNumber = 15; + private bool hasOptionalBytes; + private pb::ByteString optionalBytes_ = pb::ByteString.Empty; + public bool HasOptionalBytes { + get { return hasOptionalBytes; } + } + public pb::ByteString OptionalBytes { + get { return optionalBytes_; } + } + + public const int OptionalGroupFieldNumber = 16; + private bool hasOptionalGroup; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup optionalGroup_; + public bool HasOptionalGroup { + get { return hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup OptionalGroup { + get { return optionalGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.DefaultInstance; } + } + + public const int OptionalNestedMessageFieldNumber = 18; + private bool hasOptionalNestedMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage optionalNestedMessage_; + public bool HasOptionalNestedMessage { + get { return hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage OptionalNestedMessage { + get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance; } + } + + public const int OptionalForeignMessageFieldNumber = 19; + private bool hasOptionalForeignMessage; + private global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite optionalForeignMessage_; + public bool HasOptionalForeignMessage { + get { return hasOptionalForeignMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite OptionalForeignMessage { + get { return optionalForeignMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance; } + } + + public const int OptionalImportMessageFieldNumber = 20; + private bool hasOptionalImportMessage; + private global::Google.ProtocolBuffers.TestProtos.ImportMessageLite optionalImportMessage_; + public bool HasOptionalImportMessage { + get { return hasOptionalImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessageLite OptionalImportMessage { + get { return optionalImportMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance; } + } + + public const int OptionalNestedEnumFieldNumber = 21; + private bool hasOptionalNestedEnum; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum.FOO; + public bool HasOptionalNestedEnum { + get { return hasOptionalNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum OptionalNestedEnum { + get { return optionalNestedEnum_; } + } + + public const int OptionalForeignEnumFieldNumber = 22; + private bool hasOptionalForeignEnum; + private global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite.FOREIGN_LITE_FOO; + public bool HasOptionalForeignEnum { + get { return hasOptionalForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite OptionalForeignEnum { + get { return optionalForeignEnum_; } + } + + public const int OptionalImportEnumFieldNumber = 23; + private bool hasOptionalImportEnum; + private global::Google.ProtocolBuffers.TestProtos.ImportEnumLite optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnumLite.IMPORT_LITE_FOO; + public bool HasOptionalImportEnum { + get { return hasOptionalImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite OptionalImportEnum { + get { return optionalImportEnum_; } + } + + public const int OptionalStringPieceFieldNumber = 24; + private bool hasOptionalStringPiece; + private string optionalStringPiece_ = ""; + public bool HasOptionalStringPiece { + get { return hasOptionalStringPiece; } + } + public string OptionalStringPiece { + get { return optionalStringPiece_; } + } + + public const int OptionalCordFieldNumber = 25; + private bool hasOptionalCord; + private string optionalCord_ = ""; + public bool HasOptionalCord { + get { return hasOptionalCord; } + } + public string OptionalCord { + get { return optionalCord_; } + } + + public const int OptionalPublicImportMessageFieldNumber = 26; + private bool hasOptionalPublicImportMessage; + private global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite optionalPublicImportMessage_; + public bool HasOptionalPublicImportMessage { + get { return hasOptionalPublicImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite OptionalPublicImportMessage { + get { return optionalPublicImportMessage_ ?? global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite.DefaultInstance; } + } + + public const int OptionalLazyMessageFieldNumber = 27; + private bool hasOptionalLazyMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage optionalLazyMessage_; + public bool HasOptionalLazyMessage { + get { return hasOptionalLazyMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage OptionalLazyMessage { + get { return optionalLazyMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance; } + } + + public const int RepeatedInt32FieldNumber = 31; + private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); + public scg::IList RepeatedInt32List { + get { return pbc::Lists.AsReadOnly(repeatedInt32_); } + } + public int RepeatedInt32Count { + get { return repeatedInt32_.Count; } + } + public int GetRepeatedInt32(int index) { + return repeatedInt32_[index]; + } + + public const int RepeatedInt64FieldNumber = 32; + private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); + public scg::IList RepeatedInt64List { + get { return pbc::Lists.AsReadOnly(repeatedInt64_); } + } + public int RepeatedInt64Count { + get { return repeatedInt64_.Count; } + } + public long GetRepeatedInt64(int index) { + return repeatedInt64_[index]; + } + + public const int RepeatedUint32FieldNumber = 33; + private pbc::PopsicleList repeatedUint32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedUint32List { + get { return pbc::Lists.AsReadOnly(repeatedUint32_); } + } + public int RepeatedUint32Count { + get { return repeatedUint32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedUint32(int index) { + return repeatedUint32_[index]; + } + + public const int RepeatedUint64FieldNumber = 34; + private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedUint64List { + get { return pbc::Lists.AsReadOnly(repeatedUint64_); } + } + public int RepeatedUint64Count { + get { return repeatedUint64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedUint64(int index) { + return repeatedUint64_[index]; + } + + public const int RepeatedSint32FieldNumber = 35; + private pbc::PopsicleList repeatedSint32_ = new pbc::PopsicleList(); + public scg::IList RepeatedSint32List { + get { return pbc::Lists.AsReadOnly(repeatedSint32_); } + } + public int RepeatedSint32Count { + get { return repeatedSint32_.Count; } + } + public int GetRepeatedSint32(int index) { + return repeatedSint32_[index]; + } + + public const int RepeatedSint64FieldNumber = 36; + private pbc::PopsicleList repeatedSint64_ = new pbc::PopsicleList(); + public scg::IList RepeatedSint64List { + get { return pbc::Lists.AsReadOnly(repeatedSint64_); } + } + public int RepeatedSint64Count { + get { return repeatedSint64_.Count; } + } + public long GetRepeatedSint64(int index) { + return repeatedSint64_[index]; + } + + public const int RepeatedFixed32FieldNumber = 37; + private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedFixed32List { + get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } + } + public int RepeatedFixed32Count { + get { return repeatedFixed32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedFixed32(int index) { + return repeatedFixed32_[index]; + } + + public const int RepeatedFixed64FieldNumber = 38; + private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedFixed64List { + get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } + } + public int RepeatedFixed64Count { + get { return repeatedFixed64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedFixed64(int index) { + return repeatedFixed64_[index]; + } + + public const int RepeatedSfixed32FieldNumber = 39; + private pbc::PopsicleList repeatedSfixed32_ = new pbc::PopsicleList(); + public scg::IList RepeatedSfixed32List { + get { return pbc::Lists.AsReadOnly(repeatedSfixed32_); } + } + public int RepeatedSfixed32Count { + get { return repeatedSfixed32_.Count; } + } + public int GetRepeatedSfixed32(int index) { + return repeatedSfixed32_[index]; + } + + public const int RepeatedSfixed64FieldNumber = 40; + private pbc::PopsicleList repeatedSfixed64_ = new pbc::PopsicleList(); + public scg::IList RepeatedSfixed64List { + get { return pbc::Lists.AsReadOnly(repeatedSfixed64_); } + } + public int RepeatedSfixed64Count { + get { return repeatedSfixed64_.Count; } + } + public long GetRepeatedSfixed64(int index) { + return repeatedSfixed64_[index]; + } + + public const int RepeatedFloatFieldNumber = 41; + private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); + public scg::IList RepeatedFloatList { + get { return pbc::Lists.AsReadOnly(repeatedFloat_); } + } + public int RepeatedFloatCount { + get { return repeatedFloat_.Count; } + } + public float GetRepeatedFloat(int index) { + return repeatedFloat_[index]; + } + + public const int RepeatedDoubleFieldNumber = 42; + private pbc::PopsicleList repeatedDouble_ = new pbc::PopsicleList(); + public scg::IList RepeatedDoubleList { + get { return pbc::Lists.AsReadOnly(repeatedDouble_); } + } + public int RepeatedDoubleCount { + get { return repeatedDouble_.Count; } + } + public double GetRepeatedDouble(int index) { + return repeatedDouble_[index]; + } + + public const int RepeatedBoolFieldNumber = 43; + private pbc::PopsicleList repeatedBool_ = new pbc::PopsicleList(); + public scg::IList RepeatedBoolList { + get { return pbc::Lists.AsReadOnly(repeatedBool_); } + } + public int RepeatedBoolCount { + get { return repeatedBool_.Count; } + } + public bool GetRepeatedBool(int index) { + return repeatedBool_[index]; + } + + public const int RepeatedStringFieldNumber = 44; + private pbc::PopsicleList repeatedString_ = new pbc::PopsicleList(); + public scg::IList RepeatedStringList { + get { return pbc::Lists.AsReadOnly(repeatedString_); } + } + public int RepeatedStringCount { + get { return repeatedString_.Count; } + } + public string GetRepeatedString(int index) { + return repeatedString_[index]; + } + + public const int RepeatedBytesFieldNumber = 45; + private pbc::PopsicleList repeatedBytes_ = new pbc::PopsicleList(); + public scg::IList RepeatedBytesList { + get { return pbc::Lists.AsReadOnly(repeatedBytes_); } + } + public int RepeatedBytesCount { + get { return repeatedBytes_.Count; } + } + public pb::ByteString GetRepeatedBytes(int index) { + return repeatedBytes_[index]; + } + + public const int RepeatedGroupFieldNumber = 46; + private pbc::PopsicleList repeatedGroup_ = new pbc::PopsicleList(); + public scg::IList RepeatedGroupList { + get { return repeatedGroup_; } + } + public int RepeatedGroupCount { + get { return repeatedGroup_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup GetRepeatedGroup(int index) { + return repeatedGroup_[index]; + } + + public const int RepeatedNestedMessageFieldNumber = 48; + private pbc::PopsicleList repeatedNestedMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedNestedMessageList { + get { return repeatedNestedMessage_; } + } + public int RepeatedNestedMessageCount { + get { return repeatedNestedMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage GetRepeatedNestedMessage(int index) { + return repeatedNestedMessage_[index]; + } + + public const int RepeatedForeignMessageFieldNumber = 49; + private pbc::PopsicleList repeatedForeignMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedForeignMessageList { + get { return repeatedForeignMessage_; } + } + public int RepeatedForeignMessageCount { + get { return repeatedForeignMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite GetRepeatedForeignMessage(int index) { + return repeatedForeignMessage_[index]; + } + + public const int RepeatedImportMessageFieldNumber = 50; + private pbc::PopsicleList repeatedImportMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedImportMessageList { + get { return repeatedImportMessage_; } + } + public int RepeatedImportMessageCount { + get { return repeatedImportMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessageLite GetRepeatedImportMessage(int index) { + return repeatedImportMessage_[index]; + } + + public const int RepeatedNestedEnumFieldNumber = 51; + private pbc::PopsicleList repeatedNestedEnum_ = new pbc::PopsicleList(); + public scg::IList RepeatedNestedEnumList { + get { return pbc::Lists.AsReadOnly(repeatedNestedEnum_); } + } + public int RepeatedNestedEnumCount { + get { return repeatedNestedEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum GetRepeatedNestedEnum(int index) { + return repeatedNestedEnum_[index]; + } + + public const int RepeatedForeignEnumFieldNumber = 52; + private pbc::PopsicleList repeatedForeignEnum_ = new pbc::PopsicleList(); + public scg::IList RepeatedForeignEnumList { + get { return pbc::Lists.AsReadOnly(repeatedForeignEnum_); } + } + public int RepeatedForeignEnumCount { + get { return repeatedForeignEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite GetRepeatedForeignEnum(int index) { + return repeatedForeignEnum_[index]; + } + + public const int RepeatedImportEnumFieldNumber = 53; + private pbc::PopsicleList repeatedImportEnum_ = new pbc::PopsicleList(); + public scg::IList RepeatedImportEnumList { + get { return pbc::Lists.AsReadOnly(repeatedImportEnum_); } + } + public int RepeatedImportEnumCount { + get { return repeatedImportEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite GetRepeatedImportEnum(int index) { + return repeatedImportEnum_[index]; + } + + public const int RepeatedStringPieceFieldNumber = 54; + private pbc::PopsicleList repeatedStringPiece_ = new pbc::PopsicleList(); + public scg::IList RepeatedStringPieceList { + get { return pbc::Lists.AsReadOnly(repeatedStringPiece_); } + } + public int RepeatedStringPieceCount { + get { return repeatedStringPiece_.Count; } + } + public string GetRepeatedStringPiece(int index) { + return repeatedStringPiece_[index]; + } + + public const int RepeatedCordFieldNumber = 55; + private pbc::PopsicleList repeatedCord_ = new pbc::PopsicleList(); + public scg::IList RepeatedCordList { + get { return pbc::Lists.AsReadOnly(repeatedCord_); } + } + public int RepeatedCordCount { + get { return repeatedCord_.Count; } + } + public string GetRepeatedCord(int index) { + return repeatedCord_[index]; + } + + public const int RepeatedLazyMessageFieldNumber = 57; + private pbc::PopsicleList repeatedLazyMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedLazyMessageList { + get { return repeatedLazyMessage_; } + } + public int RepeatedLazyMessageCount { + get { return repeatedLazyMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage GetRepeatedLazyMessage(int index) { + return repeatedLazyMessage_[index]; + } + + public const int DefaultInt32FieldNumber = 61; + private bool hasDefaultInt32; + private int defaultInt32_ = 41; + public bool HasDefaultInt32 { + get { return hasDefaultInt32; } + } + public int DefaultInt32 { + get { return defaultInt32_; } + } + + public const int DefaultInt64FieldNumber = 62; + private bool hasDefaultInt64; + private long defaultInt64_ = 42L; + public bool HasDefaultInt64 { + get { return hasDefaultInt64; } + } + public long DefaultInt64 { + get { return defaultInt64_; } + } + + public const int DefaultUint32FieldNumber = 63; + private bool hasDefaultUint32; + private uint defaultUint32_ = 43; + public bool HasDefaultUint32 { + get { return hasDefaultUint32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultUint32 { + get { return defaultUint32_; } + } + + public const int DefaultUint64FieldNumber = 64; + private bool hasDefaultUint64; + private ulong defaultUint64_ = 44UL; + public bool HasDefaultUint64 { + get { return hasDefaultUint64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultUint64 { + get { return defaultUint64_; } + } + + public const int DefaultSint32FieldNumber = 65; + private bool hasDefaultSint32; + private int defaultSint32_ = -45; + public bool HasDefaultSint32 { + get { return hasDefaultSint32; } + } + public int DefaultSint32 { + get { return defaultSint32_; } + } + + public const int DefaultSint64FieldNumber = 66; + private bool hasDefaultSint64; + private long defaultSint64_ = 46L; + public bool HasDefaultSint64 { + get { return hasDefaultSint64; } + } + public long DefaultSint64 { + get { return defaultSint64_; } + } + + public const int DefaultFixed32FieldNumber = 67; + private bool hasDefaultFixed32; + private uint defaultFixed32_ = 47; + public bool HasDefaultFixed32 { + get { return hasDefaultFixed32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultFixed32 { + get { return defaultFixed32_; } + } + + public const int DefaultFixed64FieldNumber = 68; + private bool hasDefaultFixed64; + private ulong defaultFixed64_ = 48UL; + public bool HasDefaultFixed64 { + get { return hasDefaultFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultFixed64 { + get { return defaultFixed64_; } + } + + public const int DefaultSfixed32FieldNumber = 69; + private bool hasDefaultSfixed32; + private int defaultSfixed32_ = 49; + public bool HasDefaultSfixed32 { + get { return hasDefaultSfixed32; } + } + public int DefaultSfixed32 { + get { return defaultSfixed32_; } + } + + public const int DefaultSfixed64FieldNumber = 70; + private bool hasDefaultSfixed64; + private long defaultSfixed64_ = -50L; + public bool HasDefaultSfixed64 { + get { return hasDefaultSfixed64; } + } + public long DefaultSfixed64 { + get { return defaultSfixed64_; } + } + + public const int DefaultFloatFieldNumber = 71; + private bool hasDefaultFloat; + private float defaultFloat_ = 51.5F; + public bool HasDefaultFloat { + get { return hasDefaultFloat; } + } + public float DefaultFloat { + get { return defaultFloat_; } + } + + public const int DefaultDoubleFieldNumber = 72; + private bool hasDefaultDouble; + private double defaultDouble_ = 52000D; + public bool HasDefaultDouble { + get { return hasDefaultDouble; } + } + public double DefaultDouble { + get { return defaultDouble_; } + } + + public const int DefaultBoolFieldNumber = 73; + private bool hasDefaultBool; + private bool defaultBool_ = true; + public bool HasDefaultBool { + get { return hasDefaultBool; } + } + public bool DefaultBool { + get { return defaultBool_; } + } + + public const int DefaultStringFieldNumber = 74; + private bool hasDefaultString; + private string defaultString_ = "hello"; + public bool HasDefaultString { + get { return hasDefaultString; } + } + public string DefaultString { + get { return defaultString_; } + } + + public const int DefaultBytesFieldNumber = 75; + private bool hasDefaultBytes; + private pb::ByteString defaultBytes_ = pb::ByteString.FromBase64("d29ybGQ="); + public bool HasDefaultBytes { + get { return hasDefaultBytes; } + } + public pb::ByteString DefaultBytes { + get { return defaultBytes_; } + } + + public const int DefaultNestedEnumFieldNumber = 81; + private bool hasDefaultNestedEnum; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum.BAR; + public bool HasDefaultNestedEnum { + get { return hasDefaultNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum DefaultNestedEnum { + get { return defaultNestedEnum_; } + } + + public const int DefaultForeignEnumFieldNumber = 82; + private bool hasDefaultForeignEnum; + private global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite.FOREIGN_LITE_BAR; + public bool HasDefaultForeignEnum { + get { return hasDefaultForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite DefaultForeignEnum { + get { return defaultForeignEnum_; } + } + + public const int DefaultImportEnumFieldNumber = 83; + private bool hasDefaultImportEnum; + private global::Google.ProtocolBuffers.TestProtos.ImportEnumLite defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnumLite.IMPORT_LITE_BAR; + public bool HasDefaultImportEnum { + get { return hasDefaultImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite DefaultImportEnum { + get { return defaultImportEnum_; } + } + + public const int DefaultStringPieceFieldNumber = 84; + private bool hasDefaultStringPiece; + private string defaultStringPiece_ = "abc"; + public bool HasDefaultStringPiece { + get { return hasDefaultStringPiece; } + } + public string DefaultStringPiece { + get { return defaultStringPiece_; } + } + + public const int DefaultCordFieldNumber = 85; + private bool hasDefaultCord; + private string defaultCord_ = "123"; + public bool HasDefaultCord { + get { return hasDefaultCord; } + } + public string DefaultCord { + get { return defaultCord_; } + } + + public const int OneofUint32FieldNumber = 111; + private bool hasOneofUint32; + private uint oneofUint32_; + public bool HasOneofUint32 { + get { return hasOneofUint32; } + } + [global::System.CLSCompliant(false)] + public uint OneofUint32 { + get { return oneofUint32_; } + } + + public const int OneofNestedMessageFieldNumber = 112; + private bool hasOneofNestedMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage oneofNestedMessage_; + public bool HasOneofNestedMessage { + get { return hasOneofNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage OneofNestedMessage { + get { return oneofNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance; } + } + + public const int OneofStringFieldNumber = 113; + private bool hasOneofString; + private string oneofString_ = ""; + public bool HasOneofString { + get { return hasOneofString; } + } + public string OneofString { + get { return oneofString_; } + } + + public const int OneofBytesFieldNumber = 114; + private bool hasOneofBytes; + private pb::ByteString oneofBytes_ = pb::ByteString.Empty; + public bool HasOneofBytes { + get { return hasOneofBytes; } + } + public pb::ByteString OneofBytes { + get { return oneofBytes_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testAllTypesLiteFieldNames; + if (hasOptionalInt32) { + output.WriteInt32(1, field_names[35], OptionalInt32); + } + if (hasOptionalInt64) { + output.WriteInt64(2, field_names[36], OptionalInt64); + } + if (hasOptionalUint32) { + output.WriteUInt32(3, field_names[47], OptionalUint32); + } + if (hasOptionalUint64) { + output.WriteUInt64(4, field_names[48], OptionalUint64); + } + if (hasOptionalSint32) { + output.WriteSInt32(5, field_names[43], OptionalSint32); + } + if (hasOptionalSint64) { + output.WriteSInt64(6, field_names[44], OptionalSint64); + } + if (hasOptionalFixed32) { + output.WriteFixed32(7, field_names[28], OptionalFixed32); + } + if (hasOptionalFixed64) { + output.WriteFixed64(8, field_names[29], OptionalFixed64); + } + if (hasOptionalSfixed32) { + output.WriteSFixed32(9, field_names[41], OptionalSfixed32); + } + if (hasOptionalSfixed64) { + output.WriteSFixed64(10, field_names[42], OptionalSfixed64); + } + if (hasOptionalFloat) { + output.WriteFloat(11, field_names[30], OptionalFloat); + } + if (hasOptionalDouble) { + output.WriteDouble(12, field_names[27], OptionalDouble); + } + if (hasOptionalBool) { + output.WriteBool(13, field_names[24], OptionalBool); + } + if (hasOptionalString) { + output.WriteString(14, field_names[45], OptionalString); + } + if (hasOptionalBytes) { + output.WriteBytes(15, field_names[25], OptionalBytes); + } + if (hasOptionalGroup) { + output.WriteGroup(16, field_names[49], OptionalGroup); + } + if (hasOptionalNestedMessage) { + output.WriteMessage(18, field_names[39], OptionalNestedMessage); + } + if (hasOptionalForeignMessage) { + output.WriteMessage(19, field_names[32], OptionalForeignMessage); + } + if (hasOptionalImportMessage) { + output.WriteMessage(20, field_names[34], OptionalImportMessage); + } + if (hasOptionalNestedEnum) { + output.WriteEnum(21, field_names[38], (int) OptionalNestedEnum, OptionalNestedEnum); + } + if (hasOptionalForeignEnum) { + output.WriteEnum(22, field_names[31], (int) OptionalForeignEnum, OptionalForeignEnum); + } + if (hasOptionalImportEnum) { + output.WriteEnum(23, field_names[33], (int) OptionalImportEnum, OptionalImportEnum); + } + if (hasOptionalStringPiece) { + output.WriteString(24, field_names[46], OptionalStringPiece); + } + if (hasOptionalCord) { + output.WriteString(25, field_names[26], OptionalCord); + } + if (hasOptionalPublicImportMessage) { + output.WriteMessage(26, field_names[40], OptionalPublicImportMessage); + } + if (hasOptionalLazyMessage) { + output.WriteMessage(27, field_names[37], OptionalLazyMessage); + } + if (repeatedInt32_.Count > 0) { + output.WriteInt32Array(31, field_names[61], repeatedInt32_); + } + if (repeatedInt64_.Count > 0) { + output.WriteInt64Array(32, field_names[62], repeatedInt64_); + } + if (repeatedUint32_.Count > 0) { + output.WriteUInt32Array(33, field_names[72], repeatedUint32_); + } + if (repeatedUint64_.Count > 0) { + output.WriteUInt64Array(34, field_names[73], repeatedUint64_); + } + if (repeatedSint32_.Count > 0) { + output.WriteSInt32Array(35, field_names[68], repeatedSint32_); + } + if (repeatedSint64_.Count > 0) { + output.WriteSInt64Array(36, field_names[69], repeatedSint64_); + } + if (repeatedFixed32_.Count > 0) { + output.WriteFixed32Array(37, field_names[54], repeatedFixed32_); + } + if (repeatedFixed64_.Count > 0) { + output.WriteFixed64Array(38, field_names[55], repeatedFixed64_); + } + if (repeatedSfixed32_.Count > 0) { + output.WriteSFixed32Array(39, field_names[66], repeatedSfixed32_); + } + if (repeatedSfixed64_.Count > 0) { + output.WriteSFixed64Array(40, field_names[67], repeatedSfixed64_); + } + if (repeatedFloat_.Count > 0) { + output.WriteFloatArray(41, field_names[56], repeatedFloat_); + } + if (repeatedDouble_.Count > 0) { + output.WriteDoubleArray(42, field_names[53], repeatedDouble_); + } + if (repeatedBool_.Count > 0) { + output.WriteBoolArray(43, field_names[50], repeatedBool_); + } + if (repeatedString_.Count > 0) { + output.WriteStringArray(44, field_names[70], repeatedString_); + } + if (repeatedBytes_.Count > 0) { + output.WriteBytesArray(45, field_names[51], repeatedBytes_); + } + if (repeatedGroup_.Count > 0) { + output.WriteGroupArray(46, field_names[74], repeatedGroup_); + } + if (repeatedNestedMessage_.Count > 0) { + output.WriteMessageArray(48, field_names[65], repeatedNestedMessage_); + } + if (repeatedForeignMessage_.Count > 0) { + output.WriteMessageArray(49, field_names[58], repeatedForeignMessage_); + } + if (repeatedImportMessage_.Count > 0) { + output.WriteMessageArray(50, field_names[60], repeatedImportMessage_); + } + if (repeatedNestedEnum_.Count > 0) { + output.WriteEnumArray(51, field_names[64], repeatedNestedEnum_); + } + if (repeatedForeignEnum_.Count > 0) { + output.WriteEnumArray(52, field_names[57], repeatedForeignEnum_); + } + if (repeatedImportEnum_.Count > 0) { + output.WriteEnumArray(53, field_names[59], repeatedImportEnum_); + } + if (repeatedStringPiece_.Count > 0) { + output.WriteStringArray(54, field_names[71], repeatedStringPiece_); + } + if (repeatedCord_.Count > 0) { + output.WriteStringArray(55, field_names[52], repeatedCord_); + } + if (repeatedLazyMessage_.Count > 0) { + output.WriteMessageArray(57, field_names[63], repeatedLazyMessage_); + } + if (hasDefaultInt32) { + output.WriteInt32(61, field_names[9], DefaultInt32); + } + if (hasDefaultInt64) { + output.WriteInt64(62, field_names[10], DefaultInt64); + } + if (hasDefaultUint32) { + output.WriteUInt32(63, field_names[18], DefaultUint32); + } + if (hasDefaultUint64) { + output.WriteUInt64(64, field_names[19], DefaultUint64); + } + if (hasDefaultSint32) { + output.WriteSInt32(65, field_names[14], DefaultSint32); + } + if (hasDefaultSint64) { + output.WriteSInt64(66, field_names[15], DefaultSint64); + } + if (hasDefaultFixed32) { + output.WriteFixed32(67, field_names[4], DefaultFixed32); + } + if (hasDefaultFixed64) { + output.WriteFixed64(68, field_names[5], DefaultFixed64); + } + if (hasDefaultSfixed32) { + output.WriteSFixed32(69, field_names[12], DefaultSfixed32); + } + if (hasDefaultSfixed64) { + output.WriteSFixed64(70, field_names[13], DefaultSfixed64); + } + if (hasDefaultFloat) { + output.WriteFloat(71, field_names[6], DefaultFloat); + } + if (hasDefaultDouble) { + output.WriteDouble(72, field_names[3], DefaultDouble); + } + if (hasDefaultBool) { + output.WriteBool(73, field_names[0], DefaultBool); + } + if (hasDefaultString) { + output.WriteString(74, field_names[16], DefaultString); + } + if (hasDefaultBytes) { + output.WriteBytes(75, field_names[1], DefaultBytes); + } + if (hasDefaultNestedEnum) { + output.WriteEnum(81, field_names[11], (int) DefaultNestedEnum, DefaultNestedEnum); + } + if (hasDefaultForeignEnum) { + output.WriteEnum(82, field_names[7], (int) DefaultForeignEnum, DefaultForeignEnum); + } + if (hasDefaultImportEnum) { + output.WriteEnum(83, field_names[8], (int) DefaultImportEnum, DefaultImportEnum); + } + if (hasDefaultStringPiece) { + output.WriteString(84, field_names[17], DefaultStringPiece); + } + if (hasDefaultCord) { + output.WriteString(85, field_names[2], DefaultCord); + } + if (hasOneofUint32) { + output.WriteUInt32(111, field_names[23], OneofUint32); + } + if (hasOneofNestedMessage) { + output.WriteMessage(112, field_names[21], OneofNestedMessage); + } + if (hasOneofString) { + output.WriteString(113, field_names[22], OneofString); + } + if (hasOneofBytes) { + output.WriteBytes(114, field_names[20], OneofBytes); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOptionalInt32) { + size += pb::CodedOutputStream.ComputeInt32Size(1, OptionalInt32); + } + if (hasOptionalInt64) { + size += pb::CodedOutputStream.ComputeInt64Size(2, OptionalInt64); + } + if (hasOptionalUint32) { + size += pb::CodedOutputStream.ComputeUInt32Size(3, OptionalUint32); + } + if (hasOptionalUint64) { + size += pb::CodedOutputStream.ComputeUInt64Size(4, OptionalUint64); + } + if (hasOptionalSint32) { + size += pb::CodedOutputStream.ComputeSInt32Size(5, OptionalSint32); + } + if (hasOptionalSint64) { + size += pb::CodedOutputStream.ComputeSInt64Size(6, OptionalSint64); + } + if (hasOptionalFixed32) { + size += pb::CodedOutputStream.ComputeFixed32Size(7, OptionalFixed32); + } + if (hasOptionalFixed64) { + size += pb::CodedOutputStream.ComputeFixed64Size(8, OptionalFixed64); + } + if (hasOptionalSfixed32) { + size += pb::CodedOutputStream.ComputeSFixed32Size(9, OptionalSfixed32); + } + if (hasOptionalSfixed64) { + size += pb::CodedOutputStream.ComputeSFixed64Size(10, OptionalSfixed64); + } + if (hasOptionalFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(11, OptionalFloat); + } + if (hasOptionalDouble) { + size += pb::CodedOutputStream.ComputeDoubleSize(12, OptionalDouble); + } + if (hasOptionalBool) { + size += pb::CodedOutputStream.ComputeBoolSize(13, OptionalBool); + } + if (hasOptionalString) { + size += pb::CodedOutputStream.ComputeStringSize(14, OptionalString); + } + if (hasOptionalBytes) { + size += pb::CodedOutputStream.ComputeBytesSize(15, OptionalBytes); + } + if (hasOptionalGroup) { + size += pb::CodedOutputStream.ComputeGroupSize(16, OptionalGroup); + } + if (hasOptionalNestedMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(18, OptionalNestedMessage); + } + if (hasOptionalForeignMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(19, OptionalForeignMessage); + } + if (hasOptionalImportMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(20, OptionalImportMessage); + } + if (hasOptionalNestedEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(21, (int) OptionalNestedEnum); + } + if (hasOptionalForeignEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(22, (int) OptionalForeignEnum); + } + if (hasOptionalImportEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(23, (int) OptionalImportEnum); + } + if (hasOptionalStringPiece) { + size += pb::CodedOutputStream.ComputeStringSize(24, OptionalStringPiece); + } + if (hasOptionalCord) { + size += pb::CodedOutputStream.ComputeStringSize(25, OptionalCord); + } + if (hasOptionalPublicImportMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(26, OptionalPublicImportMessage); + } + if (hasOptionalLazyMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(27, OptionalLazyMessage); + } + { + int dataSize = 0; + foreach (int element in RepeatedInt32List) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedInt32_.Count; + } + { + int dataSize = 0; + foreach (long element in RepeatedInt64List) { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedInt64_.Count; + } + { + int dataSize = 0; + foreach (uint element in RepeatedUint32List) { + dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedUint32_.Count; + } + { + int dataSize = 0; + foreach (ulong element in RepeatedUint64List) { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedUint64_.Count; + } + { + int dataSize = 0; + foreach (int element in RepeatedSint32List) { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedSint32_.Count; + } + { + int dataSize = 0; + foreach (long element in RepeatedSint64List) { + dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedSint64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedFixed32_.Count; + size += dataSize; + size += 2 * repeatedFixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedFixed64_.Count; + size += dataSize; + size += 2 * repeatedFixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedSfixed32_.Count; + size += dataSize; + size += 2 * repeatedSfixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedSfixed64_.Count; + size += dataSize; + size += 2 * repeatedSfixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedFloat_.Count; + size += dataSize; + size += 2 * repeatedFloat_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedDouble_.Count; + size += dataSize; + size += 2 * repeatedDouble_.Count; + } + { + int dataSize = 0; + dataSize = 1 * repeatedBool_.Count; + size += dataSize; + size += 2 * repeatedBool_.Count; + } + { + int dataSize = 0; + foreach (string element in RepeatedStringList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedString_.Count; + } + { + int dataSize = 0; + foreach (pb::ByteString element in RepeatedBytesList) { + dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedBytes_.Count; + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup element in RepeatedGroupList) { + size += pb::CodedOutputStream.ComputeGroupSize(46, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage element in RepeatedNestedMessageList) { + size += pb::CodedOutputStream.ComputeMessageSize(48, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite element in RepeatedForeignMessageList) { + size += pb::CodedOutputStream.ComputeMessageSize(49, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.ImportMessageLite element in RepeatedImportMessageList) { + size += pb::CodedOutputStream.ComputeMessageSize(50, element); + } + { + int dataSize = 0; + if (repeatedNestedEnum_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum element in repeatedNestedEnum_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 2 * repeatedNestedEnum_.Count; + } + } + { + int dataSize = 0; + if (repeatedForeignEnum_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite element in repeatedForeignEnum_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 2 * repeatedForeignEnum_.Count; + } + } + { + int dataSize = 0; + if (repeatedImportEnum_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.ImportEnumLite element in repeatedImportEnum_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 2 * repeatedImportEnum_.Count; + } + } + { + int dataSize = 0; + foreach (string element in RepeatedStringPieceList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedStringPiece_.Count; + } + { + int dataSize = 0; + foreach (string element in RepeatedCordList) { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedCord_.Count; + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage element in RepeatedLazyMessageList) { + size += pb::CodedOutputStream.ComputeMessageSize(57, element); + } + if (hasDefaultInt32) { + size += pb::CodedOutputStream.ComputeInt32Size(61, DefaultInt32); + } + if (hasDefaultInt64) { + size += pb::CodedOutputStream.ComputeInt64Size(62, DefaultInt64); + } + if (hasDefaultUint32) { + size += pb::CodedOutputStream.ComputeUInt32Size(63, DefaultUint32); + } + if (hasDefaultUint64) { + size += pb::CodedOutputStream.ComputeUInt64Size(64, DefaultUint64); + } + if (hasDefaultSint32) { + size += pb::CodedOutputStream.ComputeSInt32Size(65, DefaultSint32); + } + if (hasDefaultSint64) { + size += pb::CodedOutputStream.ComputeSInt64Size(66, DefaultSint64); + } + if (hasDefaultFixed32) { + size += pb::CodedOutputStream.ComputeFixed32Size(67, DefaultFixed32); + } + if (hasDefaultFixed64) { + size += pb::CodedOutputStream.ComputeFixed64Size(68, DefaultFixed64); + } + if (hasDefaultSfixed32) { + size += pb::CodedOutputStream.ComputeSFixed32Size(69, DefaultSfixed32); + } + if (hasDefaultSfixed64) { + size += pb::CodedOutputStream.ComputeSFixed64Size(70, DefaultSfixed64); + } + if (hasDefaultFloat) { + size += pb::CodedOutputStream.ComputeFloatSize(71, DefaultFloat); + } + if (hasDefaultDouble) { + size += pb::CodedOutputStream.ComputeDoubleSize(72, DefaultDouble); + } + if (hasDefaultBool) { + size += pb::CodedOutputStream.ComputeBoolSize(73, DefaultBool); + } + if (hasDefaultString) { + size += pb::CodedOutputStream.ComputeStringSize(74, DefaultString); + } + if (hasDefaultBytes) { + size += pb::CodedOutputStream.ComputeBytesSize(75, DefaultBytes); + } + if (hasDefaultNestedEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(81, (int) DefaultNestedEnum); + } + if (hasDefaultForeignEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(82, (int) DefaultForeignEnum); + } + if (hasDefaultImportEnum) { + size += pb::CodedOutputStream.ComputeEnumSize(83, (int) DefaultImportEnum); + } + if (hasDefaultStringPiece) { + size += pb::CodedOutputStream.ComputeStringSize(84, DefaultStringPiece); + } + if (hasDefaultCord) { + size += pb::CodedOutputStream.ComputeStringSize(85, DefaultCord); + } + if (hasOneofUint32) { + size += pb::CodedOutputStream.ComputeUInt32Size(111, OneofUint32); + } + if (hasOneofNestedMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(112, OneofNestedMessage); + } + if (hasOneofString) { + size += pb::CodedOutputStream.ComputeStringSize(113, OneofString); + } + if (hasOneofBytes) { + size += pb::CodedOutputStream.ComputeBytesSize(114, OneofBytes); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasOptionalInt32) hash ^= optionalInt32_.GetHashCode(); + if (hasOptionalInt64) hash ^= optionalInt64_.GetHashCode(); + if (hasOptionalUint32) hash ^= optionalUint32_.GetHashCode(); + if (hasOptionalUint64) hash ^= optionalUint64_.GetHashCode(); + if (hasOptionalSint32) hash ^= optionalSint32_.GetHashCode(); + if (hasOptionalSint64) hash ^= optionalSint64_.GetHashCode(); + if (hasOptionalFixed32) hash ^= optionalFixed32_.GetHashCode(); + if (hasOptionalFixed64) hash ^= optionalFixed64_.GetHashCode(); + if (hasOptionalSfixed32) hash ^= optionalSfixed32_.GetHashCode(); + if (hasOptionalSfixed64) hash ^= optionalSfixed64_.GetHashCode(); + if (hasOptionalFloat) hash ^= optionalFloat_.GetHashCode(); + if (hasOptionalDouble) hash ^= optionalDouble_.GetHashCode(); + if (hasOptionalBool) hash ^= optionalBool_.GetHashCode(); + if (hasOptionalString) hash ^= optionalString_.GetHashCode(); + if (hasOptionalBytes) hash ^= optionalBytes_.GetHashCode(); + if (hasOptionalGroup) hash ^= optionalGroup_.GetHashCode(); + if (hasOptionalNestedMessage) hash ^= optionalNestedMessage_.GetHashCode(); + if (hasOptionalForeignMessage) hash ^= optionalForeignMessage_.GetHashCode(); + if (hasOptionalImportMessage) hash ^= optionalImportMessage_.GetHashCode(); + if (hasOptionalNestedEnum) hash ^= optionalNestedEnum_.GetHashCode(); + if (hasOptionalForeignEnum) hash ^= optionalForeignEnum_.GetHashCode(); + if (hasOptionalImportEnum) hash ^= optionalImportEnum_.GetHashCode(); + if (hasOptionalStringPiece) hash ^= optionalStringPiece_.GetHashCode(); + if (hasOptionalCord) hash ^= optionalCord_.GetHashCode(); + if (hasOptionalPublicImportMessage) hash ^= optionalPublicImportMessage_.GetHashCode(); + if (hasOptionalLazyMessage) hash ^= optionalLazyMessage_.GetHashCode(); + foreach(int i in repeatedInt32_) + hash ^= i.GetHashCode(); + foreach(long i in repeatedInt64_) + hash ^= i.GetHashCode(); + foreach(uint i in repeatedUint32_) + hash ^= i.GetHashCode(); + foreach(ulong i in repeatedUint64_) + hash ^= i.GetHashCode(); + foreach(int i in repeatedSint32_) + hash ^= i.GetHashCode(); + foreach(long i in repeatedSint64_) + hash ^= i.GetHashCode(); + foreach(uint i in repeatedFixed32_) + hash ^= i.GetHashCode(); + foreach(ulong i in repeatedFixed64_) + hash ^= i.GetHashCode(); + foreach(int i in repeatedSfixed32_) + hash ^= i.GetHashCode(); + foreach(long i in repeatedSfixed64_) + hash ^= i.GetHashCode(); + foreach(float i in repeatedFloat_) + hash ^= i.GetHashCode(); + foreach(double i in repeatedDouble_) + hash ^= i.GetHashCode(); + foreach(bool i in repeatedBool_) + hash ^= i.GetHashCode(); + foreach(string i in repeatedString_) + hash ^= i.GetHashCode(); + foreach(pb::ByteString i in repeatedBytes_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup i in repeatedGroup_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage i in repeatedNestedMessage_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite i in repeatedForeignMessage_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite i in repeatedImportMessage_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum i in repeatedNestedEnum_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite i in repeatedForeignEnum_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.ImportEnumLite i in repeatedImportEnum_) + hash ^= i.GetHashCode(); + foreach(string i in repeatedStringPiece_) + hash ^= i.GetHashCode(); + foreach(string i in repeatedCord_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage i in repeatedLazyMessage_) + hash ^= i.GetHashCode(); + if (hasDefaultInt32) hash ^= defaultInt32_.GetHashCode(); + if (hasDefaultInt64) hash ^= defaultInt64_.GetHashCode(); + if (hasDefaultUint32) hash ^= defaultUint32_.GetHashCode(); + if (hasDefaultUint64) hash ^= defaultUint64_.GetHashCode(); + if (hasDefaultSint32) hash ^= defaultSint32_.GetHashCode(); + if (hasDefaultSint64) hash ^= defaultSint64_.GetHashCode(); + if (hasDefaultFixed32) hash ^= defaultFixed32_.GetHashCode(); + if (hasDefaultFixed64) hash ^= defaultFixed64_.GetHashCode(); + if (hasDefaultSfixed32) hash ^= defaultSfixed32_.GetHashCode(); + if (hasDefaultSfixed64) hash ^= defaultSfixed64_.GetHashCode(); + if (hasDefaultFloat) hash ^= defaultFloat_.GetHashCode(); + if (hasDefaultDouble) hash ^= defaultDouble_.GetHashCode(); + if (hasDefaultBool) hash ^= defaultBool_.GetHashCode(); + if (hasDefaultString) hash ^= defaultString_.GetHashCode(); + if (hasDefaultBytes) hash ^= defaultBytes_.GetHashCode(); + if (hasDefaultNestedEnum) hash ^= defaultNestedEnum_.GetHashCode(); + if (hasDefaultForeignEnum) hash ^= defaultForeignEnum_.GetHashCode(); + if (hasDefaultImportEnum) hash ^= defaultImportEnum_.GetHashCode(); + if (hasDefaultStringPiece) hash ^= defaultStringPiece_.GetHashCode(); + if (hasDefaultCord) hash ^= defaultCord_.GetHashCode(); + if (hasOneofUint32) hash ^= oneofUint32_.GetHashCode(); + if (hasOneofNestedMessage) hash ^= oneofNestedMessage_.GetHashCode(); + if (hasOneofString) hash ^= oneofString_.GetHashCode(); + if (hasOneofBytes) hash ^= oneofBytes_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestAllTypesLite other = obj as TestAllTypesLite; + if (other == null) return false; + if (hasOptionalInt32 != other.hasOptionalInt32 || (hasOptionalInt32 && !optionalInt32_.Equals(other.optionalInt32_))) return false; + if (hasOptionalInt64 != other.hasOptionalInt64 || (hasOptionalInt64 && !optionalInt64_.Equals(other.optionalInt64_))) return false; + if (hasOptionalUint32 != other.hasOptionalUint32 || (hasOptionalUint32 && !optionalUint32_.Equals(other.optionalUint32_))) return false; + if (hasOptionalUint64 != other.hasOptionalUint64 || (hasOptionalUint64 && !optionalUint64_.Equals(other.optionalUint64_))) return false; + if (hasOptionalSint32 != other.hasOptionalSint32 || (hasOptionalSint32 && !optionalSint32_.Equals(other.optionalSint32_))) return false; + if (hasOptionalSint64 != other.hasOptionalSint64 || (hasOptionalSint64 && !optionalSint64_.Equals(other.optionalSint64_))) return false; + if (hasOptionalFixed32 != other.hasOptionalFixed32 || (hasOptionalFixed32 && !optionalFixed32_.Equals(other.optionalFixed32_))) return false; + if (hasOptionalFixed64 != other.hasOptionalFixed64 || (hasOptionalFixed64 && !optionalFixed64_.Equals(other.optionalFixed64_))) return false; + if (hasOptionalSfixed32 != other.hasOptionalSfixed32 || (hasOptionalSfixed32 && !optionalSfixed32_.Equals(other.optionalSfixed32_))) return false; + if (hasOptionalSfixed64 != other.hasOptionalSfixed64 || (hasOptionalSfixed64 && !optionalSfixed64_.Equals(other.optionalSfixed64_))) return false; + if (hasOptionalFloat != other.hasOptionalFloat || (hasOptionalFloat && !optionalFloat_.Equals(other.optionalFloat_))) return false; + if (hasOptionalDouble != other.hasOptionalDouble || (hasOptionalDouble && !optionalDouble_.Equals(other.optionalDouble_))) return false; + if (hasOptionalBool != other.hasOptionalBool || (hasOptionalBool && !optionalBool_.Equals(other.optionalBool_))) return false; + if (hasOptionalString != other.hasOptionalString || (hasOptionalString && !optionalString_.Equals(other.optionalString_))) return false; + if (hasOptionalBytes != other.hasOptionalBytes || (hasOptionalBytes && !optionalBytes_.Equals(other.optionalBytes_))) return false; + if (hasOptionalGroup != other.hasOptionalGroup || (hasOptionalGroup && !optionalGroup_.Equals(other.optionalGroup_))) return false; + if (hasOptionalNestedMessage != other.hasOptionalNestedMessage || (hasOptionalNestedMessage && !optionalNestedMessage_.Equals(other.optionalNestedMessage_))) return false; + if (hasOptionalForeignMessage != other.hasOptionalForeignMessage || (hasOptionalForeignMessage && !optionalForeignMessage_.Equals(other.optionalForeignMessage_))) return false; + if (hasOptionalImportMessage != other.hasOptionalImportMessage || (hasOptionalImportMessage && !optionalImportMessage_.Equals(other.optionalImportMessage_))) return false; + if (hasOptionalNestedEnum != other.hasOptionalNestedEnum || (hasOptionalNestedEnum && !optionalNestedEnum_.Equals(other.optionalNestedEnum_))) return false; + if (hasOptionalForeignEnum != other.hasOptionalForeignEnum || (hasOptionalForeignEnum && !optionalForeignEnum_.Equals(other.optionalForeignEnum_))) return false; + if (hasOptionalImportEnum != other.hasOptionalImportEnum || (hasOptionalImportEnum && !optionalImportEnum_.Equals(other.optionalImportEnum_))) return false; + if (hasOptionalStringPiece != other.hasOptionalStringPiece || (hasOptionalStringPiece && !optionalStringPiece_.Equals(other.optionalStringPiece_))) return false; + if (hasOptionalCord != other.hasOptionalCord || (hasOptionalCord && !optionalCord_.Equals(other.optionalCord_))) return false; + if (hasOptionalPublicImportMessage != other.hasOptionalPublicImportMessage || (hasOptionalPublicImportMessage && !optionalPublicImportMessage_.Equals(other.optionalPublicImportMessage_))) return false; + if (hasOptionalLazyMessage != other.hasOptionalLazyMessage || (hasOptionalLazyMessage && !optionalLazyMessage_.Equals(other.optionalLazyMessage_))) return false; + if(repeatedInt32_.Count != other.repeatedInt32_.Count) return false; + for(int ix=0; ix < repeatedInt32_.Count; ix++) + if(!repeatedInt32_[ix].Equals(other.repeatedInt32_[ix])) return false; + if(repeatedInt64_.Count != other.repeatedInt64_.Count) return false; + for(int ix=0; ix < repeatedInt64_.Count; ix++) + if(!repeatedInt64_[ix].Equals(other.repeatedInt64_[ix])) return false; + if(repeatedUint32_.Count != other.repeatedUint32_.Count) return false; + for(int ix=0; ix < repeatedUint32_.Count; ix++) + if(!repeatedUint32_[ix].Equals(other.repeatedUint32_[ix])) return false; + if(repeatedUint64_.Count != other.repeatedUint64_.Count) return false; + for(int ix=0; ix < repeatedUint64_.Count; ix++) + if(!repeatedUint64_[ix].Equals(other.repeatedUint64_[ix])) return false; + if(repeatedSint32_.Count != other.repeatedSint32_.Count) return false; + for(int ix=0; ix < repeatedSint32_.Count; ix++) + if(!repeatedSint32_[ix].Equals(other.repeatedSint32_[ix])) return false; + if(repeatedSint64_.Count != other.repeatedSint64_.Count) return false; + for(int ix=0; ix < repeatedSint64_.Count; ix++) + if(!repeatedSint64_[ix].Equals(other.repeatedSint64_[ix])) return false; + if(repeatedFixed32_.Count != other.repeatedFixed32_.Count) return false; + for(int ix=0; ix < repeatedFixed32_.Count; ix++) + if(!repeatedFixed32_[ix].Equals(other.repeatedFixed32_[ix])) return false; + if(repeatedFixed64_.Count != other.repeatedFixed64_.Count) return false; + for(int ix=0; ix < repeatedFixed64_.Count; ix++) + if(!repeatedFixed64_[ix].Equals(other.repeatedFixed64_[ix])) return false; + if(repeatedSfixed32_.Count != other.repeatedSfixed32_.Count) return false; + for(int ix=0; ix < repeatedSfixed32_.Count; ix++) + if(!repeatedSfixed32_[ix].Equals(other.repeatedSfixed32_[ix])) return false; + if(repeatedSfixed64_.Count != other.repeatedSfixed64_.Count) return false; + for(int ix=0; ix < repeatedSfixed64_.Count; ix++) + if(!repeatedSfixed64_[ix].Equals(other.repeatedSfixed64_[ix])) return false; + if(repeatedFloat_.Count != other.repeatedFloat_.Count) return false; + for(int ix=0; ix < repeatedFloat_.Count; ix++) + if(!repeatedFloat_[ix].Equals(other.repeatedFloat_[ix])) return false; + if(repeatedDouble_.Count != other.repeatedDouble_.Count) return false; + for(int ix=0; ix < repeatedDouble_.Count; ix++) + if(!repeatedDouble_[ix].Equals(other.repeatedDouble_[ix])) return false; + if(repeatedBool_.Count != other.repeatedBool_.Count) return false; + for(int ix=0; ix < repeatedBool_.Count; ix++) + if(!repeatedBool_[ix].Equals(other.repeatedBool_[ix])) return false; + if(repeatedString_.Count != other.repeatedString_.Count) return false; + for(int ix=0; ix < repeatedString_.Count; ix++) + if(!repeatedString_[ix].Equals(other.repeatedString_[ix])) return false; + if(repeatedBytes_.Count != other.repeatedBytes_.Count) return false; + for(int ix=0; ix < repeatedBytes_.Count; ix++) + if(!repeatedBytes_[ix].Equals(other.repeatedBytes_[ix])) return false; + if(repeatedGroup_.Count != other.repeatedGroup_.Count) return false; + for(int ix=0; ix < repeatedGroup_.Count; ix++) + if(!repeatedGroup_[ix].Equals(other.repeatedGroup_[ix])) return false; + if(repeatedNestedMessage_.Count != other.repeatedNestedMessage_.Count) return false; + for(int ix=0; ix < repeatedNestedMessage_.Count; ix++) + if(!repeatedNestedMessage_[ix].Equals(other.repeatedNestedMessage_[ix])) return false; + if(repeatedForeignMessage_.Count != other.repeatedForeignMessage_.Count) return false; + for(int ix=0; ix < repeatedForeignMessage_.Count; ix++) + if(!repeatedForeignMessage_[ix].Equals(other.repeatedForeignMessage_[ix])) return false; + if(repeatedImportMessage_.Count != other.repeatedImportMessage_.Count) return false; + for(int ix=0; ix < repeatedImportMessage_.Count; ix++) + if(!repeatedImportMessage_[ix].Equals(other.repeatedImportMessage_[ix])) return false; + if(repeatedNestedEnum_.Count != other.repeatedNestedEnum_.Count) return false; + for(int ix=0; ix < repeatedNestedEnum_.Count; ix++) + if(!repeatedNestedEnum_[ix].Equals(other.repeatedNestedEnum_[ix])) return false; + if(repeatedForeignEnum_.Count != other.repeatedForeignEnum_.Count) return false; + for(int ix=0; ix < repeatedForeignEnum_.Count; ix++) + if(!repeatedForeignEnum_[ix].Equals(other.repeatedForeignEnum_[ix])) return false; + if(repeatedImportEnum_.Count != other.repeatedImportEnum_.Count) return false; + for(int ix=0; ix < repeatedImportEnum_.Count; ix++) + if(!repeatedImportEnum_[ix].Equals(other.repeatedImportEnum_[ix])) return false; + if(repeatedStringPiece_.Count != other.repeatedStringPiece_.Count) return false; + for(int ix=0; ix < repeatedStringPiece_.Count; ix++) + if(!repeatedStringPiece_[ix].Equals(other.repeatedStringPiece_[ix])) return false; + if(repeatedCord_.Count != other.repeatedCord_.Count) return false; + for(int ix=0; ix < repeatedCord_.Count; ix++) + if(!repeatedCord_[ix].Equals(other.repeatedCord_[ix])) return false; + if(repeatedLazyMessage_.Count != other.repeatedLazyMessage_.Count) return false; + for(int ix=0; ix < repeatedLazyMessage_.Count; ix++) + if(!repeatedLazyMessage_[ix].Equals(other.repeatedLazyMessage_[ix])) return false; + if (hasDefaultInt32 != other.hasDefaultInt32 || (hasDefaultInt32 && !defaultInt32_.Equals(other.defaultInt32_))) return false; + if (hasDefaultInt64 != other.hasDefaultInt64 || (hasDefaultInt64 && !defaultInt64_.Equals(other.defaultInt64_))) return false; + if (hasDefaultUint32 != other.hasDefaultUint32 || (hasDefaultUint32 && !defaultUint32_.Equals(other.defaultUint32_))) return false; + if (hasDefaultUint64 != other.hasDefaultUint64 || (hasDefaultUint64 && !defaultUint64_.Equals(other.defaultUint64_))) return false; + if (hasDefaultSint32 != other.hasDefaultSint32 || (hasDefaultSint32 && !defaultSint32_.Equals(other.defaultSint32_))) return false; + if (hasDefaultSint64 != other.hasDefaultSint64 || (hasDefaultSint64 && !defaultSint64_.Equals(other.defaultSint64_))) return false; + if (hasDefaultFixed32 != other.hasDefaultFixed32 || (hasDefaultFixed32 && !defaultFixed32_.Equals(other.defaultFixed32_))) return false; + if (hasDefaultFixed64 != other.hasDefaultFixed64 || (hasDefaultFixed64 && !defaultFixed64_.Equals(other.defaultFixed64_))) return false; + if (hasDefaultSfixed32 != other.hasDefaultSfixed32 || (hasDefaultSfixed32 && !defaultSfixed32_.Equals(other.defaultSfixed32_))) return false; + if (hasDefaultSfixed64 != other.hasDefaultSfixed64 || (hasDefaultSfixed64 && !defaultSfixed64_.Equals(other.defaultSfixed64_))) return false; + if (hasDefaultFloat != other.hasDefaultFloat || (hasDefaultFloat && !defaultFloat_.Equals(other.defaultFloat_))) return false; + if (hasDefaultDouble != other.hasDefaultDouble || (hasDefaultDouble && !defaultDouble_.Equals(other.defaultDouble_))) return false; + if (hasDefaultBool != other.hasDefaultBool || (hasDefaultBool && !defaultBool_.Equals(other.defaultBool_))) return false; + if (hasDefaultString != other.hasDefaultString || (hasDefaultString && !defaultString_.Equals(other.defaultString_))) return false; + if (hasDefaultBytes != other.hasDefaultBytes || (hasDefaultBytes && !defaultBytes_.Equals(other.defaultBytes_))) return false; + if (hasDefaultNestedEnum != other.hasDefaultNestedEnum || (hasDefaultNestedEnum && !defaultNestedEnum_.Equals(other.defaultNestedEnum_))) return false; + if (hasDefaultForeignEnum != other.hasDefaultForeignEnum || (hasDefaultForeignEnum && !defaultForeignEnum_.Equals(other.defaultForeignEnum_))) return false; + if (hasDefaultImportEnum != other.hasDefaultImportEnum || (hasDefaultImportEnum && !defaultImportEnum_.Equals(other.defaultImportEnum_))) return false; + if (hasDefaultStringPiece != other.hasDefaultStringPiece || (hasDefaultStringPiece && !defaultStringPiece_.Equals(other.defaultStringPiece_))) return false; + if (hasDefaultCord != other.hasDefaultCord || (hasDefaultCord && !defaultCord_.Equals(other.defaultCord_))) return false; + if (hasOneofUint32 != other.hasOneofUint32 || (hasOneofUint32 && !oneofUint32_.Equals(other.oneofUint32_))) return false; + if (hasOneofNestedMessage != other.hasOneofNestedMessage || (hasOneofNestedMessage && !oneofNestedMessage_.Equals(other.oneofNestedMessage_))) return false; + if (hasOneofString != other.hasOneofString || (hasOneofString && !oneofString_.Equals(other.oneofString_))) return false; + if (hasOneofBytes != other.hasOneofBytes || (hasOneofBytes && !oneofBytes_.Equals(other.oneofBytes_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("optional_int32", hasOptionalInt32, optionalInt32_, writer); + PrintField("optional_int64", hasOptionalInt64, optionalInt64_, writer); + PrintField("optional_uint32", hasOptionalUint32, optionalUint32_, writer); + PrintField("optional_uint64", hasOptionalUint64, optionalUint64_, writer); + PrintField("optional_sint32", hasOptionalSint32, optionalSint32_, writer); + PrintField("optional_sint64", hasOptionalSint64, optionalSint64_, writer); + PrintField("optional_fixed32", hasOptionalFixed32, optionalFixed32_, writer); + PrintField("optional_fixed64", hasOptionalFixed64, optionalFixed64_, writer); + PrintField("optional_sfixed32", hasOptionalSfixed32, optionalSfixed32_, writer); + PrintField("optional_sfixed64", hasOptionalSfixed64, optionalSfixed64_, writer); + PrintField("optional_float", hasOptionalFloat, optionalFloat_, writer); + PrintField("optional_double", hasOptionalDouble, optionalDouble_, writer); + PrintField("optional_bool", hasOptionalBool, optionalBool_, writer); + PrintField("optional_string", hasOptionalString, optionalString_, writer); + PrintField("optional_bytes", hasOptionalBytes, optionalBytes_, writer); + PrintField("OptionalGroup", hasOptionalGroup, optionalGroup_, writer); + PrintField("optional_nested_message", hasOptionalNestedMessage, optionalNestedMessage_, writer); + PrintField("optional_foreign_message", hasOptionalForeignMessage, optionalForeignMessage_, writer); + PrintField("optional_import_message", hasOptionalImportMessage, optionalImportMessage_, writer); + PrintField("optional_nested_enum", hasOptionalNestedEnum, optionalNestedEnum_, writer); + PrintField("optional_foreign_enum", hasOptionalForeignEnum, optionalForeignEnum_, writer); + PrintField("optional_import_enum", hasOptionalImportEnum, optionalImportEnum_, writer); + PrintField("optional_string_piece", hasOptionalStringPiece, optionalStringPiece_, writer); + PrintField("optional_cord", hasOptionalCord, optionalCord_, writer); + PrintField("optional_public_import_message", hasOptionalPublicImportMessage, optionalPublicImportMessage_, writer); + PrintField("optional_lazy_message", hasOptionalLazyMessage, optionalLazyMessage_, writer); + PrintField("repeated_int32", repeatedInt32_, writer); + PrintField("repeated_int64", repeatedInt64_, writer); + PrintField("repeated_uint32", repeatedUint32_, writer); + PrintField("repeated_uint64", repeatedUint64_, writer); + PrintField("repeated_sint32", repeatedSint32_, writer); + PrintField("repeated_sint64", repeatedSint64_, writer); + PrintField("repeated_fixed32", repeatedFixed32_, writer); + PrintField("repeated_fixed64", repeatedFixed64_, writer); + PrintField("repeated_sfixed32", repeatedSfixed32_, writer); + PrintField("repeated_sfixed64", repeatedSfixed64_, writer); + PrintField("repeated_float", repeatedFloat_, writer); + PrintField("repeated_double", repeatedDouble_, writer); + PrintField("repeated_bool", repeatedBool_, writer); + PrintField("repeated_string", repeatedString_, writer); + PrintField("repeated_bytes", repeatedBytes_, writer); + PrintField("RepeatedGroup", repeatedGroup_, writer); + PrintField("repeated_nested_message", repeatedNestedMessage_, writer); + PrintField("repeated_foreign_message", repeatedForeignMessage_, writer); + PrintField("repeated_import_message", repeatedImportMessage_, writer); + PrintField("repeated_nested_enum", repeatedNestedEnum_, writer); + PrintField("repeated_foreign_enum", repeatedForeignEnum_, writer); + PrintField("repeated_import_enum", repeatedImportEnum_, writer); + PrintField("repeated_string_piece", repeatedStringPiece_, writer); + PrintField("repeated_cord", repeatedCord_, writer); + PrintField("repeated_lazy_message", repeatedLazyMessage_, writer); + PrintField("default_int32", hasDefaultInt32, defaultInt32_, writer); + PrintField("default_int64", hasDefaultInt64, defaultInt64_, writer); + PrintField("default_uint32", hasDefaultUint32, defaultUint32_, writer); + PrintField("default_uint64", hasDefaultUint64, defaultUint64_, writer); + PrintField("default_sint32", hasDefaultSint32, defaultSint32_, writer); + PrintField("default_sint64", hasDefaultSint64, defaultSint64_, writer); + PrintField("default_fixed32", hasDefaultFixed32, defaultFixed32_, writer); + PrintField("default_fixed64", hasDefaultFixed64, defaultFixed64_, writer); + PrintField("default_sfixed32", hasDefaultSfixed32, defaultSfixed32_, writer); + PrintField("default_sfixed64", hasDefaultSfixed64, defaultSfixed64_, writer); + PrintField("default_float", hasDefaultFloat, defaultFloat_, writer); + PrintField("default_double", hasDefaultDouble, defaultDouble_, writer); + PrintField("default_bool", hasDefaultBool, defaultBool_, writer); + PrintField("default_string", hasDefaultString, defaultString_, writer); + PrintField("default_bytes", hasDefaultBytes, defaultBytes_, writer); + PrintField("default_nested_enum", hasDefaultNestedEnum, defaultNestedEnum_, writer); + PrintField("default_foreign_enum", hasDefaultForeignEnum, defaultForeignEnum_, writer); + PrintField("default_import_enum", hasDefaultImportEnum, defaultImportEnum_, writer); + PrintField("default_string_piece", hasDefaultStringPiece, defaultStringPiece_, writer); + PrintField("default_cord", hasDefaultCord, defaultCord_, writer); + PrintField("oneof_uint32", hasOneofUint32, oneofUint32_, writer); + PrintField("oneof_nested_message", hasOneofNestedMessage, oneofNestedMessage_, writer); + PrintField("oneof_string", hasOneofString, oneofString_, writer); + PrintField("oneof_bytes", hasOneofBytes, oneofBytes_, writer); + } + #endregion + + public static TestAllTypesLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllTypesLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllTypesLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllTypesLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllTypesLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllTypesLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestAllTypesLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestAllTypesLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestAllTypesLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllTypesLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestAllTypesLite MakeReadOnly() { + repeatedInt32_.MakeReadOnly(); + repeatedInt64_.MakeReadOnly(); + repeatedUint32_.MakeReadOnly(); + repeatedUint64_.MakeReadOnly(); + repeatedSint32_.MakeReadOnly(); + repeatedSint64_.MakeReadOnly(); + repeatedFixed32_.MakeReadOnly(); + repeatedFixed64_.MakeReadOnly(); + repeatedSfixed32_.MakeReadOnly(); + repeatedSfixed64_.MakeReadOnly(); + repeatedFloat_.MakeReadOnly(); + repeatedDouble_.MakeReadOnly(); + repeatedBool_.MakeReadOnly(); + repeatedString_.MakeReadOnly(); + repeatedBytes_.MakeReadOnly(); + repeatedGroup_.MakeReadOnly(); + repeatedNestedMessage_.MakeReadOnly(); + repeatedForeignMessage_.MakeReadOnly(); + repeatedImportMessage_.MakeReadOnly(); + repeatedNestedEnum_.MakeReadOnly(); + repeatedForeignEnum_.MakeReadOnly(); + repeatedImportEnum_.MakeReadOnly(); + repeatedStringPiece_.MakeReadOnly(); + repeatedCord_.MakeReadOnly(); + repeatedLazyMessage_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestAllTypesLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestAllTypesLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestAllTypesLite result; + + private TestAllTypesLite PrepareBuilder() { + if (resultIsReadOnly) { + TestAllTypesLite original = result; + result = new TestAllTypesLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestAllTypesLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestAllTypesLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance; } + } + + public override TestAllTypesLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestAllTypesLite) { + return MergeFrom((TestAllTypesLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestAllTypesLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOptionalInt32) { + OptionalInt32 = other.OptionalInt32; + } + if (other.HasOptionalInt64) { + OptionalInt64 = other.OptionalInt64; + } + if (other.HasOptionalUint32) { + OptionalUint32 = other.OptionalUint32; + } + if (other.HasOptionalUint64) { + OptionalUint64 = other.OptionalUint64; + } + if (other.HasOptionalSint32) { + OptionalSint32 = other.OptionalSint32; + } + if (other.HasOptionalSint64) { + OptionalSint64 = other.OptionalSint64; + } + if (other.HasOptionalFixed32) { + OptionalFixed32 = other.OptionalFixed32; + } + if (other.HasOptionalFixed64) { + OptionalFixed64 = other.OptionalFixed64; + } + if (other.HasOptionalSfixed32) { + OptionalSfixed32 = other.OptionalSfixed32; + } + if (other.HasOptionalSfixed64) { + OptionalSfixed64 = other.OptionalSfixed64; + } + if (other.HasOptionalFloat) { + OptionalFloat = other.OptionalFloat; + } + if (other.HasOptionalDouble) { + OptionalDouble = other.OptionalDouble; + } + if (other.HasOptionalBool) { + OptionalBool = other.OptionalBool; + } + if (other.HasOptionalString) { + OptionalString = other.OptionalString; + } + if (other.HasOptionalBytes) { + OptionalBytes = other.OptionalBytes; + } + if (other.HasOptionalGroup) { + MergeOptionalGroup(other.OptionalGroup); + } + if (other.HasOptionalNestedMessage) { + MergeOptionalNestedMessage(other.OptionalNestedMessage); + } + if (other.HasOptionalForeignMessage) { + MergeOptionalForeignMessage(other.OptionalForeignMessage); + } + if (other.HasOptionalImportMessage) { + MergeOptionalImportMessage(other.OptionalImportMessage); + } + if (other.HasOptionalNestedEnum) { + OptionalNestedEnum = other.OptionalNestedEnum; + } + if (other.HasOptionalForeignEnum) { + OptionalForeignEnum = other.OptionalForeignEnum; + } + if (other.HasOptionalImportEnum) { + OptionalImportEnum = other.OptionalImportEnum; + } + if (other.HasOptionalStringPiece) { + OptionalStringPiece = other.OptionalStringPiece; + } + if (other.HasOptionalCord) { + OptionalCord = other.OptionalCord; + } + if (other.HasOptionalPublicImportMessage) { + MergeOptionalPublicImportMessage(other.OptionalPublicImportMessage); + } + if (other.HasOptionalLazyMessage) { + MergeOptionalLazyMessage(other.OptionalLazyMessage); + } + if (other.repeatedInt32_.Count != 0) { + result.repeatedInt32_.Add(other.repeatedInt32_); + } + if (other.repeatedInt64_.Count != 0) { + result.repeatedInt64_.Add(other.repeatedInt64_); + } + if (other.repeatedUint32_.Count != 0) { + result.repeatedUint32_.Add(other.repeatedUint32_); + } + if (other.repeatedUint64_.Count != 0) { + result.repeatedUint64_.Add(other.repeatedUint64_); + } + if (other.repeatedSint32_.Count != 0) { + result.repeatedSint32_.Add(other.repeatedSint32_); + } + if (other.repeatedSint64_.Count != 0) { + result.repeatedSint64_.Add(other.repeatedSint64_); + } + if (other.repeatedFixed32_.Count != 0) { + result.repeatedFixed32_.Add(other.repeatedFixed32_); + } + if (other.repeatedFixed64_.Count != 0) { + result.repeatedFixed64_.Add(other.repeatedFixed64_); + } + if (other.repeatedSfixed32_.Count != 0) { + result.repeatedSfixed32_.Add(other.repeatedSfixed32_); + } + if (other.repeatedSfixed64_.Count != 0) { + result.repeatedSfixed64_.Add(other.repeatedSfixed64_); + } + if (other.repeatedFloat_.Count != 0) { + result.repeatedFloat_.Add(other.repeatedFloat_); + } + if (other.repeatedDouble_.Count != 0) { + result.repeatedDouble_.Add(other.repeatedDouble_); + } + if (other.repeatedBool_.Count != 0) { + result.repeatedBool_.Add(other.repeatedBool_); + } + if (other.repeatedString_.Count != 0) { + result.repeatedString_.Add(other.repeatedString_); + } + if (other.repeatedBytes_.Count != 0) { + result.repeatedBytes_.Add(other.repeatedBytes_); + } + if (other.repeatedGroup_.Count != 0) { + result.repeatedGroup_.Add(other.repeatedGroup_); + } + if (other.repeatedNestedMessage_.Count != 0) { + result.repeatedNestedMessage_.Add(other.repeatedNestedMessage_); + } + if (other.repeatedForeignMessage_.Count != 0) { + result.repeatedForeignMessage_.Add(other.repeatedForeignMessage_); + } + if (other.repeatedImportMessage_.Count != 0) { + result.repeatedImportMessage_.Add(other.repeatedImportMessage_); + } + if (other.repeatedNestedEnum_.Count != 0) { + result.repeatedNestedEnum_.Add(other.repeatedNestedEnum_); + } + if (other.repeatedForeignEnum_.Count != 0) { + result.repeatedForeignEnum_.Add(other.repeatedForeignEnum_); + } + if (other.repeatedImportEnum_.Count != 0) { + result.repeatedImportEnum_.Add(other.repeatedImportEnum_); + } + if (other.repeatedStringPiece_.Count != 0) { + result.repeatedStringPiece_.Add(other.repeatedStringPiece_); + } + if (other.repeatedCord_.Count != 0) { + result.repeatedCord_.Add(other.repeatedCord_); + } + if (other.repeatedLazyMessage_.Count != 0) { + result.repeatedLazyMessage_.Add(other.repeatedLazyMessage_); + } + if (other.HasDefaultInt32) { + DefaultInt32 = other.DefaultInt32; + } + if (other.HasDefaultInt64) { + DefaultInt64 = other.DefaultInt64; + } + if (other.HasDefaultUint32) { + DefaultUint32 = other.DefaultUint32; + } + if (other.HasDefaultUint64) { + DefaultUint64 = other.DefaultUint64; + } + if (other.HasDefaultSint32) { + DefaultSint32 = other.DefaultSint32; + } + if (other.HasDefaultSint64) { + DefaultSint64 = other.DefaultSint64; + } + if (other.HasDefaultFixed32) { + DefaultFixed32 = other.DefaultFixed32; + } + if (other.HasDefaultFixed64) { + DefaultFixed64 = other.DefaultFixed64; + } + if (other.HasDefaultSfixed32) { + DefaultSfixed32 = other.DefaultSfixed32; + } + if (other.HasDefaultSfixed64) { + DefaultSfixed64 = other.DefaultSfixed64; + } + if (other.HasDefaultFloat) { + DefaultFloat = other.DefaultFloat; + } + if (other.HasDefaultDouble) { + DefaultDouble = other.DefaultDouble; + } + if (other.HasDefaultBool) { + DefaultBool = other.DefaultBool; + } + if (other.HasDefaultString) { + DefaultString = other.DefaultString; + } + if (other.HasDefaultBytes) { + DefaultBytes = other.DefaultBytes; + } + if (other.HasDefaultNestedEnum) { + DefaultNestedEnum = other.DefaultNestedEnum; + } + if (other.HasDefaultForeignEnum) { + DefaultForeignEnum = other.DefaultForeignEnum; + } + if (other.HasDefaultImportEnum) { + DefaultImportEnum = other.DefaultImportEnum; + } + if (other.HasDefaultStringPiece) { + DefaultStringPiece = other.DefaultStringPiece; + } + if (other.HasDefaultCord) { + DefaultCord = other.DefaultCord; + } + if (other.HasOneofUint32) { + OneofUint32 = other.OneofUint32; + } + if (other.HasOneofNestedMessage) { + MergeOneofNestedMessage(other.OneofNestedMessage); + } + if (other.HasOneofString) { + OneofString = other.OneofString; + } + if (other.HasOneofBytes) { + OneofBytes = other.OneofBytes; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testAllTypesLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testAllTypesLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); + break; + } + case 16: { + result.hasOptionalInt64 = input.ReadInt64(ref result.optionalInt64_); + break; + } + case 24: { + result.hasOptionalUint32 = input.ReadUInt32(ref result.optionalUint32_); + break; + } + case 32: { + result.hasOptionalUint64 = input.ReadUInt64(ref result.optionalUint64_); + break; + } + case 40: { + result.hasOptionalSint32 = input.ReadSInt32(ref result.optionalSint32_); + break; + } + case 48: { + result.hasOptionalSint64 = input.ReadSInt64(ref result.optionalSint64_); + break; + } + case 61: { + result.hasOptionalFixed32 = input.ReadFixed32(ref result.optionalFixed32_); + break; + } + case 65: { + result.hasOptionalFixed64 = input.ReadFixed64(ref result.optionalFixed64_); + break; + } + case 77: { + result.hasOptionalSfixed32 = input.ReadSFixed32(ref result.optionalSfixed32_); + break; + } + case 81: { + result.hasOptionalSfixed64 = input.ReadSFixed64(ref result.optionalSfixed64_); + break; + } + case 93: { + result.hasOptionalFloat = input.ReadFloat(ref result.optionalFloat_); + break; + } + case 97: { + result.hasOptionalDouble = input.ReadDouble(ref result.optionalDouble_); + break; + } + case 104: { + result.hasOptionalBool = input.ReadBool(ref result.optionalBool_); + break; + } + case 114: { + result.hasOptionalString = input.ReadString(ref result.optionalString_); + break; + } + case 122: { + result.hasOptionalBytes = input.ReadBytes(ref result.optionalBytes_); + break; + } + case 131: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.CreateBuilder(); + if (result.hasOptionalGroup) { + subBuilder.MergeFrom(OptionalGroup); + } + input.ReadGroup(16, subBuilder, extensionRegistry); + OptionalGroup = subBuilder.BuildPartial(); + break; + } + case 146: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.CreateBuilder(); + if (result.hasOptionalNestedMessage) { + subBuilder.MergeFrom(OptionalNestedMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalNestedMessage = subBuilder.BuildPartial(); + break; + } + case 154: { + global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.CreateBuilder(); + if (result.hasOptionalForeignMessage) { + subBuilder.MergeFrom(OptionalForeignMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalForeignMessage = subBuilder.BuildPartial(); + break; + } + case 162: { + global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.CreateBuilder(); + if (result.hasOptionalImportMessage) { + subBuilder.MergeFrom(OptionalImportMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalImportMessage = subBuilder.BuildPartial(); + break; + } + case 168: { + object unknown; + if(input.ReadEnum(ref result.optionalNestedEnum_, out unknown)) { + result.hasOptionalNestedEnum = true; + } else if(unknown is int) { + } + break; + } + case 176: { + object unknown; + if(input.ReadEnum(ref result.optionalForeignEnum_, out unknown)) { + result.hasOptionalForeignEnum = true; + } else if(unknown is int) { + } + break; + } + case 184: { + object unknown; + if(input.ReadEnum(ref result.optionalImportEnum_, out unknown)) { + result.hasOptionalImportEnum = true; + } else if(unknown is int) { + } + break; + } + case 194: { + result.hasOptionalStringPiece = input.ReadString(ref result.optionalStringPiece_); + break; + } + case 202: { + result.hasOptionalCord = input.ReadString(ref result.optionalCord_); + break; + } + case 210: { + global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite.CreateBuilder(); + if (result.hasOptionalPublicImportMessage) { + subBuilder.MergeFrom(OptionalPublicImportMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalPublicImportMessage = subBuilder.BuildPartial(); + break; + } + case 218: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.CreateBuilder(); + if (result.hasOptionalLazyMessage) { + subBuilder.MergeFrom(OptionalLazyMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalLazyMessage = subBuilder.BuildPartial(); + break; + } + case 250: + case 248: { + input.ReadInt32Array(tag, field_name, result.repeatedInt32_); + break; + } + case 258: + case 256: { + input.ReadInt64Array(tag, field_name, result.repeatedInt64_); + break; + } + case 266: + case 264: { + input.ReadUInt32Array(tag, field_name, result.repeatedUint32_); + break; + } + case 274: + case 272: { + input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); + break; + } + case 282: + case 280: { + input.ReadSInt32Array(tag, field_name, result.repeatedSint32_); + break; + } + case 290: + case 288: { + input.ReadSInt64Array(tag, field_name, result.repeatedSint64_); + break; + } + case 298: + case 301: { + input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); + break; + } + case 306: + case 305: { + input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); + break; + } + case 314: + case 317: { + input.ReadSFixed32Array(tag, field_name, result.repeatedSfixed32_); + break; + } + case 322: + case 321: { + input.ReadSFixed64Array(tag, field_name, result.repeatedSfixed64_); + break; + } + case 330: + case 333: { + input.ReadFloatArray(tag, field_name, result.repeatedFloat_); + break; + } + case 338: + case 337: { + input.ReadDoubleArray(tag, field_name, result.repeatedDouble_); + break; + } + case 346: + case 344: { + input.ReadBoolArray(tag, field_name, result.repeatedBool_); + break; + } + case 354: { + input.ReadStringArray(tag, field_name, result.repeatedString_); + break; + } + case 362: { + input.ReadBytesArray(tag, field_name, result.repeatedBytes_); + break; + } + case 371: { + input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup.DefaultInstance, extensionRegistry); + break; + } + case 386: { + input.ReadMessageArray(tag, field_name, result.repeatedNestedMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance, extensionRegistry); + break; + } + case 394: { + input.ReadMessageArray(tag, field_name, result.repeatedForeignMessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance, extensionRegistry); + break; + } + case 402: { + input.ReadMessageArray(tag, field_name, result.repeatedImportMessage_, global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance, extensionRegistry); + break; + } + case 410: + case 408: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedNestedEnum_, out unknownItems); + break; + } + case 418: + case 416: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedForeignEnum_, out unknownItems); + break; + } + case 426: + case 424: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedImportEnum_, out unknownItems); + break; + } + case 434: { + input.ReadStringArray(tag, field_name, result.repeatedStringPiece_); + break; + } + case 442: { + input.ReadStringArray(tag, field_name, result.repeatedCord_); + break; + } + case 458: { + input.ReadMessageArray(tag, field_name, result.repeatedLazyMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance, extensionRegistry); + break; + } + case 488: { + result.hasDefaultInt32 = input.ReadInt32(ref result.defaultInt32_); + break; + } + case 496: { + result.hasDefaultInt64 = input.ReadInt64(ref result.defaultInt64_); + break; + } + case 504: { + result.hasDefaultUint32 = input.ReadUInt32(ref result.defaultUint32_); + break; + } + case 512: { + result.hasDefaultUint64 = input.ReadUInt64(ref result.defaultUint64_); + break; + } + case 520: { + result.hasDefaultSint32 = input.ReadSInt32(ref result.defaultSint32_); + break; + } + case 528: { + result.hasDefaultSint64 = input.ReadSInt64(ref result.defaultSint64_); + break; + } + case 541: { + result.hasDefaultFixed32 = input.ReadFixed32(ref result.defaultFixed32_); + break; + } + case 545: { + result.hasDefaultFixed64 = input.ReadFixed64(ref result.defaultFixed64_); + break; + } + case 557: { + result.hasDefaultSfixed32 = input.ReadSFixed32(ref result.defaultSfixed32_); + break; + } + case 561: { + result.hasDefaultSfixed64 = input.ReadSFixed64(ref result.defaultSfixed64_); + break; + } + case 573: { + result.hasDefaultFloat = input.ReadFloat(ref result.defaultFloat_); + break; + } + case 577: { + result.hasDefaultDouble = input.ReadDouble(ref result.defaultDouble_); + break; + } + case 584: { + result.hasDefaultBool = input.ReadBool(ref result.defaultBool_); + break; + } + case 594: { + result.hasDefaultString = input.ReadString(ref result.defaultString_); + break; + } + case 602: { + result.hasDefaultBytes = input.ReadBytes(ref result.defaultBytes_); + break; + } + case 648: { + object unknown; + if(input.ReadEnum(ref result.defaultNestedEnum_, out unknown)) { + result.hasDefaultNestedEnum = true; + } else if(unknown is int) { + } + break; + } + case 656: { + object unknown; + if(input.ReadEnum(ref result.defaultForeignEnum_, out unknown)) { + result.hasDefaultForeignEnum = true; + } else if(unknown is int) { + } + break; + } + case 664: { + object unknown; + if(input.ReadEnum(ref result.defaultImportEnum_, out unknown)) { + result.hasDefaultImportEnum = true; + } else if(unknown is int) { + } + break; + } + case 674: { + result.hasDefaultStringPiece = input.ReadString(ref result.defaultStringPiece_); + break; + } + case 682: { + result.hasDefaultCord = input.ReadString(ref result.defaultCord_); + break; + } + case 888: { + result.hasOneofUint32 = input.ReadUInt32(ref result.oneofUint32_); + break; + } + case 898: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.CreateBuilder(); + if (result.hasOneofNestedMessage) { + subBuilder.MergeFrom(OneofNestedMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OneofNestedMessage = subBuilder.BuildPartial(); + break; + } + case 906: { + result.hasOneofString = input.ReadString(ref result.oneofString_); + break; + } + case 914: { + result.hasOneofBytes = input.ReadBytes(ref result.oneofBytes_); + break; + } + } + } + + return this; + } + + + public bool HasOptionalInt32 { + get { return result.hasOptionalInt32; } + } + public int OptionalInt32 { + get { return result.OptionalInt32; } + set { SetOptionalInt32(value); } + } + public Builder SetOptionalInt32(int value) { + PrepareBuilder(); + result.hasOptionalInt32 = true; + result.optionalInt32_ = value; + return this; + } + public Builder ClearOptionalInt32() { + PrepareBuilder(); + result.hasOptionalInt32 = false; + result.optionalInt32_ = 0; + return this; + } + + public bool HasOptionalInt64 { + get { return result.hasOptionalInt64; } + } + public long OptionalInt64 { + get { return result.OptionalInt64; } + set { SetOptionalInt64(value); } + } + public Builder SetOptionalInt64(long value) { + PrepareBuilder(); + result.hasOptionalInt64 = true; + result.optionalInt64_ = value; + return this; + } + public Builder ClearOptionalInt64() { + PrepareBuilder(); + result.hasOptionalInt64 = false; + result.optionalInt64_ = 0L; + return this; + } + + public bool HasOptionalUint32 { + get { return result.hasOptionalUint32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalUint32 { + get { return result.OptionalUint32; } + set { SetOptionalUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalUint32(uint value) { + PrepareBuilder(); + result.hasOptionalUint32 = true; + result.optionalUint32_ = value; + return this; + } + public Builder ClearOptionalUint32() { + PrepareBuilder(); + result.hasOptionalUint32 = false; + result.optionalUint32_ = 0; + return this; + } + + public bool HasOptionalUint64 { + get { return result.hasOptionalUint64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalUint64 { + get { return result.OptionalUint64; } + set { SetOptionalUint64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalUint64(ulong value) { + PrepareBuilder(); + result.hasOptionalUint64 = true; + result.optionalUint64_ = value; + return this; + } + public Builder ClearOptionalUint64() { + PrepareBuilder(); + result.hasOptionalUint64 = false; + result.optionalUint64_ = 0UL; + return this; + } + + public bool HasOptionalSint32 { + get { return result.hasOptionalSint32; } + } + public int OptionalSint32 { + get { return result.OptionalSint32; } + set { SetOptionalSint32(value); } + } + public Builder SetOptionalSint32(int value) { + PrepareBuilder(); + result.hasOptionalSint32 = true; + result.optionalSint32_ = value; + return this; + } + public Builder ClearOptionalSint32() { + PrepareBuilder(); + result.hasOptionalSint32 = false; + result.optionalSint32_ = 0; + return this; + } + + public bool HasOptionalSint64 { + get { return result.hasOptionalSint64; } + } + public long OptionalSint64 { + get { return result.OptionalSint64; } + set { SetOptionalSint64(value); } + } + public Builder SetOptionalSint64(long value) { + PrepareBuilder(); + result.hasOptionalSint64 = true; + result.optionalSint64_ = value; + return this; + } + public Builder ClearOptionalSint64() { + PrepareBuilder(); + result.hasOptionalSint64 = false; + result.optionalSint64_ = 0L; + return this; + } + + public bool HasOptionalFixed32 { + get { return result.hasOptionalFixed32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalFixed32 { + get { return result.OptionalFixed32; } + set { SetOptionalFixed32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalFixed32(uint value) { + PrepareBuilder(); + result.hasOptionalFixed32 = true; + result.optionalFixed32_ = value; + return this; + } + public Builder ClearOptionalFixed32() { + PrepareBuilder(); + result.hasOptionalFixed32 = false; + result.optionalFixed32_ = 0; + return this; + } + + public bool HasOptionalFixed64 { + get { return result.hasOptionalFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalFixed64 { + get { return result.OptionalFixed64; } + set { SetOptionalFixed64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalFixed64(ulong value) { + PrepareBuilder(); + result.hasOptionalFixed64 = true; + result.optionalFixed64_ = value; + return this; + } + public Builder ClearOptionalFixed64() { + PrepareBuilder(); + result.hasOptionalFixed64 = false; + result.optionalFixed64_ = 0UL; + return this; + } + + public bool HasOptionalSfixed32 { + get { return result.hasOptionalSfixed32; } + } + public int OptionalSfixed32 { + get { return result.OptionalSfixed32; } + set { SetOptionalSfixed32(value); } + } + public Builder SetOptionalSfixed32(int value) { + PrepareBuilder(); + result.hasOptionalSfixed32 = true; + result.optionalSfixed32_ = value; + return this; + } + public Builder ClearOptionalSfixed32() { + PrepareBuilder(); + result.hasOptionalSfixed32 = false; + result.optionalSfixed32_ = 0; + return this; + } + + public bool HasOptionalSfixed64 { + get { return result.hasOptionalSfixed64; } + } + public long OptionalSfixed64 { + get { return result.OptionalSfixed64; } + set { SetOptionalSfixed64(value); } + } + public Builder SetOptionalSfixed64(long value) { + PrepareBuilder(); + result.hasOptionalSfixed64 = true; + result.optionalSfixed64_ = value; + return this; + } + public Builder ClearOptionalSfixed64() { + PrepareBuilder(); + result.hasOptionalSfixed64 = false; + result.optionalSfixed64_ = 0L; + return this; + } + + public bool HasOptionalFloat { + get { return result.hasOptionalFloat; } + } + public float OptionalFloat { + get { return result.OptionalFloat; } + set { SetOptionalFloat(value); } + } + public Builder SetOptionalFloat(float value) { + PrepareBuilder(); + result.hasOptionalFloat = true; + result.optionalFloat_ = value; + return this; + } + public Builder ClearOptionalFloat() { + PrepareBuilder(); + result.hasOptionalFloat = false; + result.optionalFloat_ = 0F; + return this; + } + + public bool HasOptionalDouble { + get { return result.hasOptionalDouble; } + } + public double OptionalDouble { + get { return result.OptionalDouble; } + set { SetOptionalDouble(value); } + } + public Builder SetOptionalDouble(double value) { + PrepareBuilder(); + result.hasOptionalDouble = true; + result.optionalDouble_ = value; + return this; + } + public Builder ClearOptionalDouble() { + PrepareBuilder(); + result.hasOptionalDouble = false; + result.optionalDouble_ = 0D; + return this; + } + + public bool HasOptionalBool { + get { return result.hasOptionalBool; } + } + public bool OptionalBool { + get { return result.OptionalBool; } + set { SetOptionalBool(value); } + } + public Builder SetOptionalBool(bool value) { + PrepareBuilder(); + result.hasOptionalBool = true; + result.optionalBool_ = value; + return this; + } + public Builder ClearOptionalBool() { + PrepareBuilder(); + result.hasOptionalBool = false; + result.optionalBool_ = false; + return this; + } + + public bool HasOptionalString { + get { return result.hasOptionalString; } + } + public string OptionalString { + get { return result.OptionalString; } + set { SetOptionalString(value); } + } + public Builder SetOptionalString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalString = true; + result.optionalString_ = value; + return this; + } + public Builder ClearOptionalString() { + PrepareBuilder(); + result.hasOptionalString = false; + result.optionalString_ = ""; + return this; + } + + public bool HasOptionalBytes { + get { return result.hasOptionalBytes; } + } + public pb::ByteString OptionalBytes { + get { return result.OptionalBytes; } + set { SetOptionalBytes(value); } + } + public Builder SetOptionalBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalBytes = true; + result.optionalBytes_ = value; + return this; + } + public Builder ClearOptionalBytes() { + PrepareBuilder(); + result.hasOptionalBytes = false; + result.optionalBytes_ = pb::ByteString.Empty; + return this; + } + + public bool HasOptionalGroup { + get { return result.hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup OptionalGroup { + get { return result.OptionalGroup; } + set { SetOptionalGroup(value); } + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = value; + return this; + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalGroup && + result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.DefaultInstance) { + result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial(); + } else { + result.optionalGroup_ = value; + } + result.hasOptionalGroup = true; + return this; + } + public Builder ClearOptionalGroup() { + PrepareBuilder(); + result.hasOptionalGroup = false; + result.optionalGroup_ = null; + return this; + } + + public bool HasOptionalNestedMessage { + get { return result.hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage OptionalNestedMessage { + get { return result.OptionalNestedMessage; } + set { SetOptionalNestedMessage(value); } + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = value; + return this; + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalNestedMessage && + result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance) { + result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalNestedMessage_ = value; + } + result.hasOptionalNestedMessage = true; + return this; + } + public Builder ClearOptionalNestedMessage() { + PrepareBuilder(); + result.hasOptionalNestedMessage = false; + result.optionalNestedMessage_ = null; + return this; + } + + public bool HasOptionalForeignMessage { + get { return result.hasOptionalForeignMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite OptionalForeignMessage { + get { return result.OptionalForeignMessage; } + set { SetOptionalForeignMessage(value); } + } + public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalForeignMessage = true; + result.optionalForeignMessage_ = value; + return this; + } + public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalForeignMessage = true; + result.optionalForeignMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalForeignMessage && + result.optionalForeignMessage_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance) { + result.optionalForeignMessage_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.CreateBuilder(result.optionalForeignMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalForeignMessage_ = value; + } + result.hasOptionalForeignMessage = true; + return this; + } + public Builder ClearOptionalForeignMessage() { + PrepareBuilder(); + result.hasOptionalForeignMessage = false; + result.optionalForeignMessage_ = null; + return this; + } + + public bool HasOptionalImportMessage { + get { return result.hasOptionalImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessageLite OptionalImportMessage { + get { return result.OptionalImportMessage; } + set { SetOptionalImportMessage(value); } + } + public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalImportMessage = true; + result.optionalImportMessage_ = value; + return this; + } + public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalImportMessage = true; + result.optionalImportMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalImportMessage && + result.optionalImportMessage_ != global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.DefaultInstance) { + result.optionalImportMessage_ = global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.CreateBuilder(result.optionalImportMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalImportMessage_ = value; + } + result.hasOptionalImportMessage = true; + return this; + } + public Builder ClearOptionalImportMessage() { + PrepareBuilder(); + result.hasOptionalImportMessage = false; + result.optionalImportMessage_ = null; + return this; + } + + public bool HasOptionalNestedEnum { + get { return result.hasOptionalNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum OptionalNestedEnum { + get { return result.OptionalNestedEnum; } + set { SetOptionalNestedEnum(value); } + } + public Builder SetOptionalNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum value) { + PrepareBuilder(); + result.hasOptionalNestedEnum = true; + result.optionalNestedEnum_ = value; + return this; + } + public Builder ClearOptionalNestedEnum() { + PrepareBuilder(); + result.hasOptionalNestedEnum = false; + result.optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum.FOO; + return this; + } + + public bool HasOptionalForeignEnum { + get { return result.hasOptionalForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite OptionalForeignEnum { + get { return result.OptionalForeignEnum; } + set { SetOptionalForeignEnum(value); } + } + public Builder SetOptionalForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { + PrepareBuilder(); + result.hasOptionalForeignEnum = true; + result.optionalForeignEnum_ = value; + return this; + } + public Builder ClearOptionalForeignEnum() { + PrepareBuilder(); + result.hasOptionalForeignEnum = false; + result.optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite.FOREIGN_LITE_FOO; + return this; + } + + public bool HasOptionalImportEnum { + get { return result.hasOptionalImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite OptionalImportEnum { + get { return result.OptionalImportEnum; } + set { SetOptionalImportEnum(value); } + } + public Builder SetOptionalImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnumLite value) { + PrepareBuilder(); + result.hasOptionalImportEnum = true; + result.optionalImportEnum_ = value; + return this; + } + public Builder ClearOptionalImportEnum() { + PrepareBuilder(); + result.hasOptionalImportEnum = false; + result.optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnumLite.IMPORT_LITE_FOO; + return this; + } + + public bool HasOptionalStringPiece { + get { return result.hasOptionalStringPiece; } + } + public string OptionalStringPiece { + get { return result.OptionalStringPiece; } + set { SetOptionalStringPiece(value); } + } + public Builder SetOptionalStringPiece(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalStringPiece = true; + result.optionalStringPiece_ = value; + return this; + } + public Builder ClearOptionalStringPiece() { + PrepareBuilder(); + result.hasOptionalStringPiece = false; + result.optionalStringPiece_ = ""; + return this; + } + + public bool HasOptionalCord { + get { return result.hasOptionalCord; } + } + public string OptionalCord { + get { return result.OptionalCord; } + set { SetOptionalCord(value); } + } + public Builder SetOptionalCord(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalCord = true; + result.optionalCord_ = value; + return this; + } + public Builder ClearOptionalCord() { + PrepareBuilder(); + result.hasOptionalCord = false; + result.optionalCord_ = ""; + return this; + } + + public bool HasOptionalPublicImportMessage { + get { return result.hasOptionalPublicImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite OptionalPublicImportMessage { + get { return result.OptionalPublicImportMessage; } + set { SetOptionalPublicImportMessage(value); } + } + public Builder SetOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalPublicImportMessage = true; + result.optionalPublicImportMessage_ = value; + return this; + } + public Builder SetOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalPublicImportMessage = true; + result.optionalPublicImportMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalPublicImportMessage && + result.optionalPublicImportMessage_ != global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite.DefaultInstance) { + result.optionalPublicImportMessage_ = global::Google.ProtocolBuffers.TestProtos.PublicImportMessageLite.CreateBuilder(result.optionalPublicImportMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalPublicImportMessage_ = value; + } + result.hasOptionalPublicImportMessage = true; + return this; + } + public Builder ClearOptionalPublicImportMessage() { + PrepareBuilder(); + result.hasOptionalPublicImportMessage = false; + result.optionalPublicImportMessage_ = null; + return this; + } + + public bool HasOptionalLazyMessage { + get { return result.hasOptionalLazyMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage OptionalLazyMessage { + get { return result.OptionalLazyMessage; } + set { SetOptionalLazyMessage(value); } + } + public Builder SetOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalLazyMessage = true; + result.optionalLazyMessage_ = value; + return this; + } + public Builder SetOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalLazyMessage = true; + result.optionalLazyMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalLazyMessage && + result.optionalLazyMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance) { + result.optionalLazyMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.CreateBuilder(result.optionalLazyMessage_).MergeFrom(value).BuildPartial(); + } else { + result.optionalLazyMessage_ = value; + } + result.hasOptionalLazyMessage = true; + return this; + } + public Builder ClearOptionalLazyMessage() { + PrepareBuilder(); + result.hasOptionalLazyMessage = false; + result.optionalLazyMessage_ = null; + return this; + } + + public pbc::IPopsicleList RepeatedInt32List { + get { return PrepareBuilder().repeatedInt32_; } + } + public int RepeatedInt32Count { + get { return result.RepeatedInt32Count; } + } + public int GetRepeatedInt32(int index) { + return result.GetRepeatedInt32(index); + } + public Builder SetRepeatedInt32(int index, int value) { + PrepareBuilder(); + result.repeatedInt32_[index] = value; + return this; + } + public Builder AddRepeatedInt32(int value) { + PrepareBuilder(); + result.repeatedInt32_.Add(value); + return this; + } + public Builder AddRangeRepeatedInt32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedInt32_.Add(values); + return this; + } + public Builder ClearRepeatedInt32() { + PrepareBuilder(); + result.repeatedInt32_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedInt64List { + get { return PrepareBuilder().repeatedInt64_; } + } + public int RepeatedInt64Count { + get { return result.RepeatedInt64Count; } + } + public long GetRepeatedInt64(int index) { + return result.GetRepeatedInt64(index); + } + public Builder SetRepeatedInt64(int index, long value) { + PrepareBuilder(); + result.repeatedInt64_[index] = value; + return this; + } + public Builder AddRepeatedInt64(long value) { + PrepareBuilder(); + result.repeatedInt64_.Add(value); + return this; + } + public Builder AddRangeRepeatedInt64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedInt64_.Add(values); + return this; + } + public Builder ClearRepeatedInt64() { + PrepareBuilder(); + result.repeatedInt64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedUint32List { + get { return PrepareBuilder().repeatedUint32_; } + } + public int RepeatedUint32Count { + get { return result.RepeatedUint32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedUint32(int index) { + return result.GetRepeatedUint32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedUint32(int index, uint value) { + PrepareBuilder(); + result.repeatedUint32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedUint32(uint value) { + PrepareBuilder(); + result.repeatedUint32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedUint32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedUint32_.Add(values); + return this; + } + public Builder ClearRepeatedUint32() { + PrepareBuilder(); + result.repeatedUint32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedUint64List { + get { return PrepareBuilder().repeatedUint64_; } + } + public int RepeatedUint64Count { + get { return result.RepeatedUint64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedUint64(int index) { + return result.GetRepeatedUint64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedUint64(int index, ulong value) { + PrepareBuilder(); + result.repeatedUint64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedUint64(ulong value) { + PrepareBuilder(); + result.repeatedUint64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedUint64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedUint64_.Add(values); + return this; + } + public Builder ClearRepeatedUint64() { + PrepareBuilder(); + result.repeatedUint64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSint32List { + get { return PrepareBuilder().repeatedSint32_; } + } + public int RepeatedSint32Count { + get { return result.RepeatedSint32Count; } + } + public int GetRepeatedSint32(int index) { + return result.GetRepeatedSint32(index); + } + public Builder SetRepeatedSint32(int index, int value) { + PrepareBuilder(); + result.repeatedSint32_[index] = value; + return this; + } + public Builder AddRepeatedSint32(int value) { + PrepareBuilder(); + result.repeatedSint32_.Add(value); + return this; + } + public Builder AddRangeRepeatedSint32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedSint32_.Add(values); + return this; + } + public Builder ClearRepeatedSint32() { + PrepareBuilder(); + result.repeatedSint32_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSint64List { + get { return PrepareBuilder().repeatedSint64_; } + } + public int RepeatedSint64Count { + get { return result.RepeatedSint64Count; } + } + public long GetRepeatedSint64(int index) { + return result.GetRepeatedSint64(index); + } + public Builder SetRepeatedSint64(int index, long value) { + PrepareBuilder(); + result.repeatedSint64_[index] = value; + return this; + } + public Builder AddRepeatedSint64(long value) { + PrepareBuilder(); + result.repeatedSint64_.Add(value); + return this; + } + public Builder AddRangeRepeatedSint64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedSint64_.Add(values); + return this; + } + public Builder ClearRepeatedSint64() { + PrepareBuilder(); + result.repeatedSint64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedFixed32List { + get { return PrepareBuilder().repeatedFixed32_; } + } + public int RepeatedFixed32Count { + get { return result.RepeatedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedFixed32(int index) { + return result.GetRepeatedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedFixed32(int index, uint value) { + PrepareBuilder(); + result.repeatedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedFixed32(uint value) { + PrepareBuilder(); + result.repeatedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedFixed32_.Add(values); + return this; + } + public Builder ClearRepeatedFixed32() { + PrepareBuilder(); + result.repeatedFixed32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedFixed64List { + get { return PrepareBuilder().repeatedFixed64_; } + } + public int RepeatedFixed64Count { + get { return result.RepeatedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedFixed64(int index) { + return result.GetRepeatedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedFixed64(int index, ulong value) { + PrepareBuilder(); + result.repeatedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedFixed64(ulong value) { + PrepareBuilder(); + result.repeatedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedFixed64_.Add(values); + return this; + } + public Builder ClearRepeatedFixed64() { + PrepareBuilder(); + result.repeatedFixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSfixed32List { + get { return PrepareBuilder().repeatedSfixed32_; } + } + public int RepeatedSfixed32Count { + get { return result.RepeatedSfixed32Count; } + } + public int GetRepeatedSfixed32(int index) { + return result.GetRepeatedSfixed32(index); + } + public Builder SetRepeatedSfixed32(int index, int value) { + PrepareBuilder(); + result.repeatedSfixed32_[index] = value; + return this; + } + public Builder AddRepeatedSfixed32(int value) { + PrepareBuilder(); + result.repeatedSfixed32_.Add(value); + return this; + } + public Builder AddRangeRepeatedSfixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedSfixed32_.Add(values); + return this; + } + public Builder ClearRepeatedSfixed32() { + PrepareBuilder(); + result.repeatedSfixed32_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSfixed64List { + get { return PrepareBuilder().repeatedSfixed64_; } + } + public int RepeatedSfixed64Count { + get { return result.RepeatedSfixed64Count; } + } + public long GetRepeatedSfixed64(int index) { + return result.GetRepeatedSfixed64(index); + } + public Builder SetRepeatedSfixed64(int index, long value) { + PrepareBuilder(); + result.repeatedSfixed64_[index] = value; + return this; + } + public Builder AddRepeatedSfixed64(long value) { + PrepareBuilder(); + result.repeatedSfixed64_.Add(value); + return this; + } + public Builder AddRangeRepeatedSfixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedSfixed64_.Add(values); + return this; + } + public Builder ClearRepeatedSfixed64() { + PrepareBuilder(); + result.repeatedSfixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedFloatList { + get { return PrepareBuilder().repeatedFloat_; } + } + public int RepeatedFloatCount { + get { return result.RepeatedFloatCount; } + } + public float GetRepeatedFloat(int index) { + return result.GetRepeatedFloat(index); + } + public Builder SetRepeatedFloat(int index, float value) { + PrepareBuilder(); + result.repeatedFloat_[index] = value; + return this; + } + public Builder AddRepeatedFloat(float value) { + PrepareBuilder(); + result.repeatedFloat_.Add(value); + return this; + } + public Builder AddRangeRepeatedFloat(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedFloat_.Add(values); + return this; + } + public Builder ClearRepeatedFloat() { + PrepareBuilder(); + result.repeatedFloat_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedDoubleList { + get { return PrepareBuilder().repeatedDouble_; } + } + public int RepeatedDoubleCount { + get { return result.RepeatedDoubleCount; } + } + public double GetRepeatedDouble(int index) { + return result.GetRepeatedDouble(index); + } + public Builder SetRepeatedDouble(int index, double value) { + PrepareBuilder(); + result.repeatedDouble_[index] = value; + return this; + } + public Builder AddRepeatedDouble(double value) { + PrepareBuilder(); + result.repeatedDouble_.Add(value); + return this; + } + public Builder AddRangeRepeatedDouble(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedDouble_.Add(values); + return this; + } + public Builder ClearRepeatedDouble() { + PrepareBuilder(); + result.repeatedDouble_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedBoolList { + get { return PrepareBuilder().repeatedBool_; } + } + public int RepeatedBoolCount { + get { return result.RepeatedBoolCount; } + } + public bool GetRepeatedBool(int index) { + return result.GetRepeatedBool(index); + } + public Builder SetRepeatedBool(int index, bool value) { + PrepareBuilder(); + result.repeatedBool_[index] = value; + return this; + } + public Builder AddRepeatedBool(bool value) { + PrepareBuilder(); + result.repeatedBool_.Add(value); + return this; + } + public Builder AddRangeRepeatedBool(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedBool_.Add(values); + return this; + } + public Builder ClearRepeatedBool() { + PrepareBuilder(); + result.repeatedBool_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedStringList { + get { return PrepareBuilder().repeatedString_; } + } + public int RepeatedStringCount { + get { return result.RepeatedStringCount; } + } + public string GetRepeatedString(int index) { + return result.GetRepeatedString(index); + } + public Builder SetRepeatedString(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedString_[index] = value; + return this; + } + public Builder AddRepeatedString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedString_.Add(value); + return this; + } + public Builder AddRangeRepeatedString(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedString_.Add(values); + return this; + } + public Builder ClearRepeatedString() { + PrepareBuilder(); + result.repeatedString_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedBytesList { + get { return PrepareBuilder().repeatedBytes_; } + } + public int RepeatedBytesCount { + get { return result.RepeatedBytesCount; } + } + public pb::ByteString GetRepeatedBytes(int index) { + return result.GetRepeatedBytes(index); + } + public Builder SetRepeatedBytes(int index, pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedBytes_[index] = value; + return this; + } + public Builder AddRepeatedBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedBytes_.Add(value); + return this; + } + public Builder AddRangeRepeatedBytes(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedBytes_.Add(values); + return this; + } + public Builder ClearRepeatedBytes() { + PrepareBuilder(); + result.repeatedBytes_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedGroupList { + get { return PrepareBuilder().repeatedGroup_; } + } + public int RepeatedGroupCount { + get { return result.RepeatedGroupCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup GetRepeatedGroup(int index) { + return result.GetRepeatedGroup(index); + } + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_[index] = value; + return this; + } + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_.Add(value); + return this; + } + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.RepeatedGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedGroup(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedGroup_.Add(values); + return this; + } + public Builder ClearRepeatedGroup() { + PrepareBuilder(); + result.repeatedGroup_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedNestedMessageList { + get { return PrepareBuilder().repeatedNestedMessage_; } + } + public int RepeatedNestedMessageCount { + get { return result.RepeatedNestedMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage GetRepeatedNestedMessage(int index) { + return result.GetRepeatedNestedMessage(index); + } + public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedNestedMessage_[index] = value; + return this; + } + public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedNestedMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedNestedMessage_.Add(value); + return this; + } + public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedNestedMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedNestedMessage(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedNestedMessage_.Add(values); + return this; + } + public Builder ClearRepeatedNestedMessage() { + PrepareBuilder(); + result.repeatedNestedMessage_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedForeignMessageList { + get { return PrepareBuilder().repeatedForeignMessage_; } + } + public int RepeatedForeignMessageCount { + get { return result.RepeatedForeignMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite GetRepeatedForeignMessage(int index) { + return result.GetRepeatedForeignMessage(index); + } + public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedForeignMessage_[index] = value; + return this; + } + public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedForeignMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedForeignMessage_.Add(value); + return this; + } + public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedForeignMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedForeignMessage(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedForeignMessage_.Add(values); + return this; + } + public Builder ClearRepeatedForeignMessage() { + PrepareBuilder(); + result.repeatedForeignMessage_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedImportMessageList { + get { return PrepareBuilder().repeatedImportMessage_; } + } + public int RepeatedImportMessageCount { + get { return result.RepeatedImportMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessageLite GetRepeatedImportMessage(int index) { + return result.GetRepeatedImportMessage(index); + } + public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessageLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedImportMessage_[index] = value; + return this; + } + public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedImportMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedImportMessage_.Add(value); + return this; + } + public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessageLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedImportMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedImportMessage(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedImportMessage_.Add(values); + return this; + } + public Builder ClearRepeatedImportMessage() { + PrepareBuilder(); + result.repeatedImportMessage_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedNestedEnumList { + get { return PrepareBuilder().repeatedNestedEnum_; } + } + public int RepeatedNestedEnumCount { + get { return result.RepeatedNestedEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum GetRepeatedNestedEnum(int index) { + return result.GetRepeatedNestedEnum(index); + } + public Builder SetRepeatedNestedEnum(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum value) { + PrepareBuilder(); + result.repeatedNestedEnum_[index] = value; + return this; + } + public Builder AddRepeatedNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum value) { + PrepareBuilder(); + result.repeatedNestedEnum_.Add(value); + return this; + } + public Builder AddRangeRepeatedNestedEnum(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedNestedEnum_.Add(values); + return this; + } + public Builder ClearRepeatedNestedEnum() { + PrepareBuilder(); + result.repeatedNestedEnum_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedForeignEnumList { + get { return PrepareBuilder().repeatedForeignEnum_; } + } + public int RepeatedForeignEnumCount { + get { return result.RepeatedForeignEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite GetRepeatedForeignEnum(int index) { + return result.GetRepeatedForeignEnum(index); + } + public Builder SetRepeatedForeignEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { + PrepareBuilder(); + result.repeatedForeignEnum_[index] = value; + return this; + } + public Builder AddRepeatedForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { + PrepareBuilder(); + result.repeatedForeignEnum_.Add(value); + return this; + } + public Builder AddRangeRepeatedForeignEnum(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedForeignEnum_.Add(values); + return this; + } + public Builder ClearRepeatedForeignEnum() { + PrepareBuilder(); + result.repeatedForeignEnum_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedImportEnumList { + get { return PrepareBuilder().repeatedImportEnum_; } + } + public int RepeatedImportEnumCount { + get { return result.RepeatedImportEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite GetRepeatedImportEnum(int index) { + return result.GetRepeatedImportEnum(index); + } + public Builder SetRepeatedImportEnum(int index, global::Google.ProtocolBuffers.TestProtos.ImportEnumLite value) { + PrepareBuilder(); + result.repeatedImportEnum_[index] = value; + return this; + } + public Builder AddRepeatedImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnumLite value) { + PrepareBuilder(); + result.repeatedImportEnum_.Add(value); + return this; + } + public Builder AddRangeRepeatedImportEnum(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedImportEnum_.Add(values); + return this; + } + public Builder ClearRepeatedImportEnum() { + PrepareBuilder(); + result.repeatedImportEnum_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedStringPieceList { + get { return PrepareBuilder().repeatedStringPiece_; } + } + public int RepeatedStringPieceCount { + get { return result.RepeatedStringPieceCount; } + } + public string GetRepeatedStringPiece(int index) { + return result.GetRepeatedStringPiece(index); + } + public Builder SetRepeatedStringPiece(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringPiece_[index] = value; + return this; + } + public Builder AddRepeatedStringPiece(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringPiece_.Add(value); + return this; + } + public Builder AddRangeRepeatedStringPiece(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedStringPiece_.Add(values); + return this; + } + public Builder ClearRepeatedStringPiece() { + PrepareBuilder(); + result.repeatedStringPiece_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedCordList { + get { return PrepareBuilder().repeatedCord_; } + } + public int RepeatedCordCount { + get { return result.RepeatedCordCount; } + } + public string GetRepeatedCord(int index) { + return result.GetRepeatedCord(index); + } + public Builder SetRepeatedCord(int index, string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedCord_[index] = value; + return this; + } + public Builder AddRepeatedCord(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedCord_.Add(value); + return this; + } + public Builder AddRangeRepeatedCord(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedCord_.Add(values); + return this; + } + public Builder ClearRepeatedCord() { + PrepareBuilder(); + result.repeatedCord_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedLazyMessageList { + get { return PrepareBuilder().repeatedLazyMessage_; } + } + public int RepeatedLazyMessageCount { + get { return result.RepeatedLazyMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage GetRepeatedLazyMessage(int index) { + return result.GetRepeatedLazyMessage(index); + } + public Builder SetRepeatedLazyMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedLazyMessage_[index] = value; + return this; + } + public Builder SetRepeatedLazyMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedLazyMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedLazyMessage_.Add(value); + return this; + } + public Builder AddRepeatedLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedLazyMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedLazyMessage(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedLazyMessage_.Add(values); + return this; + } + public Builder ClearRepeatedLazyMessage() { + PrepareBuilder(); + result.repeatedLazyMessage_.Clear(); + return this; + } + + public bool HasDefaultInt32 { + get { return result.hasDefaultInt32; } + } + public int DefaultInt32 { + get { return result.DefaultInt32; } + set { SetDefaultInt32(value); } + } + public Builder SetDefaultInt32(int value) { + PrepareBuilder(); + result.hasDefaultInt32 = true; + result.defaultInt32_ = value; + return this; + } + public Builder ClearDefaultInt32() { + PrepareBuilder(); + result.hasDefaultInt32 = false; + result.defaultInt32_ = 41; + return this; + } + + public bool HasDefaultInt64 { + get { return result.hasDefaultInt64; } + } + public long DefaultInt64 { + get { return result.DefaultInt64; } + set { SetDefaultInt64(value); } + } + public Builder SetDefaultInt64(long value) { + PrepareBuilder(); + result.hasDefaultInt64 = true; + result.defaultInt64_ = value; + return this; + } + public Builder ClearDefaultInt64() { + PrepareBuilder(); + result.hasDefaultInt64 = false; + result.defaultInt64_ = 42L; + return this; + } + + public bool HasDefaultUint32 { + get { return result.hasDefaultUint32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultUint32 { + get { return result.DefaultUint32; } + set { SetDefaultUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultUint32(uint value) { + PrepareBuilder(); + result.hasDefaultUint32 = true; + result.defaultUint32_ = value; + return this; + } + public Builder ClearDefaultUint32() { + PrepareBuilder(); + result.hasDefaultUint32 = false; + result.defaultUint32_ = 43; + return this; + } + + public bool HasDefaultUint64 { + get { return result.hasDefaultUint64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultUint64 { + get { return result.DefaultUint64; } + set { SetDefaultUint64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultUint64(ulong value) { + PrepareBuilder(); + result.hasDefaultUint64 = true; + result.defaultUint64_ = value; + return this; + } + public Builder ClearDefaultUint64() { + PrepareBuilder(); + result.hasDefaultUint64 = false; + result.defaultUint64_ = 44UL; + return this; + } + + public bool HasDefaultSint32 { + get { return result.hasDefaultSint32; } + } + public int DefaultSint32 { + get { return result.DefaultSint32; } + set { SetDefaultSint32(value); } + } + public Builder SetDefaultSint32(int value) { + PrepareBuilder(); + result.hasDefaultSint32 = true; + result.defaultSint32_ = value; + return this; + } + public Builder ClearDefaultSint32() { + PrepareBuilder(); + result.hasDefaultSint32 = false; + result.defaultSint32_ = -45; + return this; + } + + public bool HasDefaultSint64 { + get { return result.hasDefaultSint64; } + } + public long DefaultSint64 { + get { return result.DefaultSint64; } + set { SetDefaultSint64(value); } + } + public Builder SetDefaultSint64(long value) { + PrepareBuilder(); + result.hasDefaultSint64 = true; + result.defaultSint64_ = value; + return this; + } + public Builder ClearDefaultSint64() { + PrepareBuilder(); + result.hasDefaultSint64 = false; + result.defaultSint64_ = 46L; + return this; + } + + public bool HasDefaultFixed32 { + get { return result.hasDefaultFixed32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultFixed32 { + get { return result.DefaultFixed32; } + set { SetDefaultFixed32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultFixed32(uint value) { + PrepareBuilder(); + result.hasDefaultFixed32 = true; + result.defaultFixed32_ = value; + return this; + } + public Builder ClearDefaultFixed32() { + PrepareBuilder(); + result.hasDefaultFixed32 = false; + result.defaultFixed32_ = 47; + return this; + } + + public bool HasDefaultFixed64 { + get { return result.hasDefaultFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultFixed64 { + get { return result.DefaultFixed64; } + set { SetDefaultFixed64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultFixed64(ulong value) { + PrepareBuilder(); + result.hasDefaultFixed64 = true; + result.defaultFixed64_ = value; + return this; + } + public Builder ClearDefaultFixed64() { + PrepareBuilder(); + result.hasDefaultFixed64 = false; + result.defaultFixed64_ = 48UL; + return this; + } + + public bool HasDefaultSfixed32 { + get { return result.hasDefaultSfixed32; } + } + public int DefaultSfixed32 { + get { return result.DefaultSfixed32; } + set { SetDefaultSfixed32(value); } + } + public Builder SetDefaultSfixed32(int value) { + PrepareBuilder(); + result.hasDefaultSfixed32 = true; + result.defaultSfixed32_ = value; + return this; + } + public Builder ClearDefaultSfixed32() { + PrepareBuilder(); + result.hasDefaultSfixed32 = false; + result.defaultSfixed32_ = 49; + return this; + } + + public bool HasDefaultSfixed64 { + get { return result.hasDefaultSfixed64; } + } + public long DefaultSfixed64 { + get { return result.DefaultSfixed64; } + set { SetDefaultSfixed64(value); } + } + public Builder SetDefaultSfixed64(long value) { + PrepareBuilder(); + result.hasDefaultSfixed64 = true; + result.defaultSfixed64_ = value; + return this; + } + public Builder ClearDefaultSfixed64() { + PrepareBuilder(); + result.hasDefaultSfixed64 = false; + result.defaultSfixed64_ = -50L; + return this; + } + + public bool HasDefaultFloat { + get { return result.hasDefaultFloat; } + } + public float DefaultFloat { + get { return result.DefaultFloat; } + set { SetDefaultFloat(value); } + } + public Builder SetDefaultFloat(float value) { + PrepareBuilder(); + result.hasDefaultFloat = true; + result.defaultFloat_ = value; + return this; + } + public Builder ClearDefaultFloat() { + PrepareBuilder(); + result.hasDefaultFloat = false; + result.defaultFloat_ = 51.5F; + return this; + } + + public bool HasDefaultDouble { + get { return result.hasDefaultDouble; } + } + public double DefaultDouble { + get { return result.DefaultDouble; } + set { SetDefaultDouble(value); } + } + public Builder SetDefaultDouble(double value) { + PrepareBuilder(); + result.hasDefaultDouble = true; + result.defaultDouble_ = value; + return this; + } + public Builder ClearDefaultDouble() { + PrepareBuilder(); + result.hasDefaultDouble = false; + result.defaultDouble_ = 52000D; + return this; + } + + public bool HasDefaultBool { + get { return result.hasDefaultBool; } + } + public bool DefaultBool { + get { return result.DefaultBool; } + set { SetDefaultBool(value); } + } + public Builder SetDefaultBool(bool value) { + PrepareBuilder(); + result.hasDefaultBool = true; + result.defaultBool_ = value; + return this; + } + public Builder ClearDefaultBool() { + PrepareBuilder(); + result.hasDefaultBool = false; + result.defaultBool_ = true; + return this; + } + + public bool HasDefaultString { + get { return result.hasDefaultString; } + } + public string DefaultString { + get { return result.DefaultString; } + set { SetDefaultString(value); } + } + public Builder SetDefaultString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultString = true; + result.defaultString_ = value; + return this; + } + public Builder ClearDefaultString() { + PrepareBuilder(); + result.hasDefaultString = false; + result.defaultString_ = "hello"; + return this; + } + + public bool HasDefaultBytes { + get { return result.hasDefaultBytes; } + } + public pb::ByteString DefaultBytes { + get { return result.DefaultBytes; } + set { SetDefaultBytes(value); } + } + public Builder SetDefaultBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultBytes = true; + result.defaultBytes_ = value; + return this; + } + public Builder ClearDefaultBytes() { + PrepareBuilder(); + result.hasDefaultBytes = false; + result.defaultBytes_ = pb::ByteString.FromBase64("d29ybGQ="); + return this; + } + + public bool HasDefaultNestedEnum { + get { return result.hasDefaultNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum DefaultNestedEnum { + get { return result.DefaultNestedEnum; } + set { SetDefaultNestedEnum(value); } + } + public Builder SetDefaultNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum value) { + PrepareBuilder(); + result.hasDefaultNestedEnum = true; + result.defaultNestedEnum_ = value; + return this; + } + public Builder ClearDefaultNestedEnum() { + PrepareBuilder(); + result.hasDefaultNestedEnum = false; + result.defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedEnum.BAR; + return this; + } + + public bool HasDefaultForeignEnum { + get { return result.hasDefaultForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite DefaultForeignEnum { + get { return result.DefaultForeignEnum; } + set { SetDefaultForeignEnum(value); } + } + public Builder SetDefaultForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { + PrepareBuilder(); + result.hasDefaultForeignEnum = true; + result.defaultForeignEnum_ = value; + return this; + } + public Builder ClearDefaultForeignEnum() { + PrepareBuilder(); + result.hasDefaultForeignEnum = false; + result.defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite.FOREIGN_LITE_BAR; + return this; + } + + public bool HasDefaultImportEnum { + get { return result.hasDefaultImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnumLite DefaultImportEnum { + get { return result.DefaultImportEnum; } + set { SetDefaultImportEnum(value); } + } + public Builder SetDefaultImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnumLite value) { + PrepareBuilder(); + result.hasDefaultImportEnum = true; + result.defaultImportEnum_ = value; + return this; + } + public Builder ClearDefaultImportEnum() { + PrepareBuilder(); + result.hasDefaultImportEnum = false; + result.defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnumLite.IMPORT_LITE_BAR; + return this; + } + + public bool HasDefaultStringPiece { + get { return result.hasDefaultStringPiece; } + } + public string DefaultStringPiece { + get { return result.DefaultStringPiece; } + set { SetDefaultStringPiece(value); } + } + public Builder SetDefaultStringPiece(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultStringPiece = true; + result.defaultStringPiece_ = value; + return this; + } + public Builder ClearDefaultStringPiece() { + PrepareBuilder(); + result.hasDefaultStringPiece = false; + result.defaultStringPiece_ = "abc"; + return this; + } + + public bool HasDefaultCord { + get { return result.hasDefaultCord; } + } + public string DefaultCord { + get { return result.DefaultCord; } + set { SetDefaultCord(value); } + } + public Builder SetDefaultCord(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultCord = true; + result.defaultCord_ = value; + return this; + } + public Builder ClearDefaultCord() { + PrepareBuilder(); + result.hasDefaultCord = false; + result.defaultCord_ = "123"; + return this; + } + + public bool HasOneofUint32 { + get { return result.hasOneofUint32; } + } + [global::System.CLSCompliant(false)] + public uint OneofUint32 { + get { return result.OneofUint32; } + set { SetOneofUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOneofUint32(uint value) { + PrepareBuilder(); + result.hasOneofUint32 = true; + result.oneofUint32_ = value; + return this; + } + public Builder ClearOneofUint32() { + PrepareBuilder(); + result.hasOneofUint32 = false; + result.oneofUint32_ = 0; + return this; + } + + public bool HasOneofNestedMessage { + get { return result.hasOneofNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage OneofNestedMessage { + get { return result.OneofNestedMessage; } + set { SetOneofNestedMessage(value); } + } + public Builder SetOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOneofNestedMessage = true; + result.oneofNestedMessage_ = value; + return this; + } + public Builder SetOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOneofNestedMessage = true; + result.oneofNestedMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOneofNestedMessage && + result.oneofNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.DefaultInstance) { + result.oneofNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Types.NestedMessage.CreateBuilder(result.oneofNestedMessage_).MergeFrom(value).BuildPartial(); + } else { + result.oneofNestedMessage_ = value; + } + result.hasOneofNestedMessage = true; + return this; + } + public Builder ClearOneofNestedMessage() { + PrepareBuilder(); + result.hasOneofNestedMessage = false; + result.oneofNestedMessage_ = null; + return this; + } + + public bool HasOneofString { + get { return result.hasOneofString; } + } + public string OneofString { + get { return result.OneofString; } + set { SetOneofString(value); } + } + public Builder SetOneofString(string value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOneofString = true; + result.oneofString_ = value; + return this; + } + public Builder ClearOneofString() { + PrepareBuilder(); + result.hasOneofString = false; + result.oneofString_ = ""; + return this; + } + + public bool HasOneofBytes { + get { return result.hasOneofBytes; } + } + public pb::ByteString OneofBytes { + get { return result.OneofBytes; } + set { SetOneofBytes(value); } + } + public Builder SetOneofBytes(pb::ByteString value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOneofBytes = true; + result.oneofBytes_ = value; + return this; + } + public Builder ClearOneofBytes() { + PrepareBuilder(); + result.hasOneofBytes = false; + result.oneofBytes_ = pb::ByteString.Empty; + return this; + } + } + static TestAllTypesLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class ForeignMessageLite : pb::GeneratedMessageLite { + private ForeignMessageLite() { } + private static readonly ForeignMessageLite defaultInstance = new ForeignMessageLite().MakeReadOnly(); + private static readonly string[] _foreignMessageLiteFieldNames = new string[] { "c" }; + private static readonly uint[] _foreignMessageLiteFieldTags = new uint[] { 8 }; + public static ForeignMessageLite DefaultInstance { + get { return defaultInstance; } + } + + public override ForeignMessageLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override ForeignMessageLite ThisMessage { + get { return this; } + } + + public const int CFieldNumber = 1; + private bool hasC; + private int c_; + public bool HasC { + get { return hasC; } + } + public int C { + get { return c_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _foreignMessageLiteFieldNames; + if (hasC) { + output.WriteInt32(1, field_names[0], C); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasC) { + size += pb::CodedOutputStream.ComputeInt32Size(1, C); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasC) hash ^= c_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + ForeignMessageLite other = obj as ForeignMessageLite; + if (other == null) return false; + if (hasC != other.hasC || (hasC && !c_.Equals(other.c_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("c", hasC, c_, writer); + } + #endregion + + public static ForeignMessageLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ForeignMessageLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ForeignMessageLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ForeignMessageLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ForeignMessageLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ForeignMessageLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static ForeignMessageLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static ForeignMessageLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static ForeignMessageLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ForeignMessageLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private ForeignMessageLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(ForeignMessageLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(ForeignMessageLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private ForeignMessageLite result; + + private ForeignMessageLite PrepareBuilder() { + if (resultIsReadOnly) { + ForeignMessageLite original = result; + result = new ForeignMessageLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override ForeignMessageLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override ForeignMessageLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance; } + } + + public override ForeignMessageLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is ForeignMessageLite) { + return MergeFrom((ForeignMessageLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(ForeignMessageLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.ForeignMessageLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasC) { + C = other.C; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_foreignMessageLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _foreignMessageLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasC = input.ReadInt32(ref result.c_); + break; + } + } + } + + return this; + } + + + public bool HasC { + get { return result.hasC; } + } + public int C { + get { return result.C; } + set { SetC(value); } + } + public Builder SetC(int value) { + PrepareBuilder(); + result.hasC = true; + result.c_ = value; + return this; + } + public Builder ClearC() { + PrepareBuilder(); + result.hasC = false; + result.c_ = 0; + return this; + } + } + static ForeignMessageLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestPackedTypesLite : pb::GeneratedMessageLite { + private TestPackedTypesLite() { } + private static readonly TestPackedTypesLite defaultInstance = new TestPackedTypesLite().MakeReadOnly(); + private static readonly string[] _testPackedTypesLiteFieldNames = new string[] { "packed_bool", "packed_double", "packed_enum", "packed_fixed32", "packed_fixed64", "packed_float", "packed_int32", "packed_int64", "packed_sfixed32", "packed_sfixed64", "packed_sint32", "packed_sint64", "packed_uint32", "packed_uint64" }; + private static readonly uint[] _testPackedTypesLiteFieldTags = new uint[] { 818, 810, 826, 770, 778, 802, 722, 730, 786, 794, 754, 762, 738, 746 }; + public static TestPackedTypesLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestPackedTypesLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestPackedTypesLite ThisMessage { + get { return this; } + } + + public const int PackedInt32FieldNumber = 90; + private int packedInt32MemoizedSerializedSize; + private pbc::PopsicleList packedInt32_ = new pbc::PopsicleList(); + public scg::IList PackedInt32List { + get { return pbc::Lists.AsReadOnly(packedInt32_); } + } + public int PackedInt32Count { + get { return packedInt32_.Count; } + } + public int GetPackedInt32(int index) { + return packedInt32_[index]; + } + + public const int PackedInt64FieldNumber = 91; + private int packedInt64MemoizedSerializedSize; + private pbc::PopsicleList packedInt64_ = new pbc::PopsicleList(); + public scg::IList PackedInt64List { + get { return pbc::Lists.AsReadOnly(packedInt64_); } + } + public int PackedInt64Count { + get { return packedInt64_.Count; } + } + public long GetPackedInt64(int index) { + return packedInt64_[index]; + } + + public const int PackedUint32FieldNumber = 92; + private int packedUint32MemoizedSerializedSize; + private pbc::PopsicleList packedUint32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedUint32List { + get { return pbc::Lists.AsReadOnly(packedUint32_); } + } + public int PackedUint32Count { + get { return packedUint32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedUint32(int index) { + return packedUint32_[index]; + } + + public const int PackedUint64FieldNumber = 93; + private int packedUint64MemoizedSerializedSize; + private pbc::PopsicleList packedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedUint64List { + get { return pbc::Lists.AsReadOnly(packedUint64_); } + } + public int PackedUint64Count { + get { return packedUint64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedUint64(int index) { + return packedUint64_[index]; + } + + public const int PackedSint32FieldNumber = 94; + private int packedSint32MemoizedSerializedSize; + private pbc::PopsicleList packedSint32_ = new pbc::PopsicleList(); + public scg::IList PackedSint32List { + get { return pbc::Lists.AsReadOnly(packedSint32_); } + } + public int PackedSint32Count { + get { return packedSint32_.Count; } + } + public int GetPackedSint32(int index) { + return packedSint32_[index]; + } + + public const int PackedSint64FieldNumber = 95; + private int packedSint64MemoizedSerializedSize; + private pbc::PopsicleList packedSint64_ = new pbc::PopsicleList(); + public scg::IList PackedSint64List { + get { return pbc::Lists.AsReadOnly(packedSint64_); } + } + public int PackedSint64Count { + get { return packedSint64_.Count; } + } + public long GetPackedSint64(int index) { + return packedSint64_[index]; + } + + public const int PackedFixed32FieldNumber = 96; + private int packedFixed32MemoizedSerializedSize; + private pbc::PopsicleList packedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedFixed32List { + get { return pbc::Lists.AsReadOnly(packedFixed32_); } + } + public int PackedFixed32Count { + get { return packedFixed32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedFixed32(int index) { + return packedFixed32_[index]; + } + + public const int PackedFixed64FieldNumber = 97; + private int packedFixed64MemoizedSerializedSize; + private pbc::PopsicleList packedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedFixed64List { + get { return pbc::Lists.AsReadOnly(packedFixed64_); } + } + public int PackedFixed64Count { + get { return packedFixed64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedFixed64(int index) { + return packedFixed64_[index]; + } + + public const int PackedSfixed32FieldNumber = 98; + private int packedSfixed32MemoizedSerializedSize; + private pbc::PopsicleList packedSfixed32_ = new pbc::PopsicleList(); + public scg::IList PackedSfixed32List { + get { return pbc::Lists.AsReadOnly(packedSfixed32_); } + } + public int PackedSfixed32Count { + get { return packedSfixed32_.Count; } + } + public int GetPackedSfixed32(int index) { + return packedSfixed32_[index]; + } + + public const int PackedSfixed64FieldNumber = 99; + private int packedSfixed64MemoizedSerializedSize; + private pbc::PopsicleList packedSfixed64_ = new pbc::PopsicleList(); + public scg::IList PackedSfixed64List { + get { return pbc::Lists.AsReadOnly(packedSfixed64_); } + } + public int PackedSfixed64Count { + get { return packedSfixed64_.Count; } + } + public long GetPackedSfixed64(int index) { + return packedSfixed64_[index]; + } + + public const int PackedFloatFieldNumber = 100; + private int packedFloatMemoizedSerializedSize; + private pbc::PopsicleList packedFloat_ = new pbc::PopsicleList(); + public scg::IList PackedFloatList { + get { return pbc::Lists.AsReadOnly(packedFloat_); } + } + public int PackedFloatCount { + get { return packedFloat_.Count; } + } + public float GetPackedFloat(int index) { + return packedFloat_[index]; + } + + public const int PackedDoubleFieldNumber = 101; + private int packedDoubleMemoizedSerializedSize; + private pbc::PopsicleList packedDouble_ = new pbc::PopsicleList(); + public scg::IList PackedDoubleList { + get { return pbc::Lists.AsReadOnly(packedDouble_); } + } + public int PackedDoubleCount { + get { return packedDouble_.Count; } + } + public double GetPackedDouble(int index) { + return packedDouble_[index]; + } + + public const int PackedBoolFieldNumber = 102; + private int packedBoolMemoizedSerializedSize; + private pbc::PopsicleList packedBool_ = new pbc::PopsicleList(); + public scg::IList PackedBoolList { + get { return pbc::Lists.AsReadOnly(packedBool_); } + } + public int PackedBoolCount { + get { return packedBool_.Count; } + } + public bool GetPackedBool(int index) { + return packedBool_[index]; + } + + public const int PackedEnumFieldNumber = 103; + private int packedEnumMemoizedSerializedSize; + private pbc::PopsicleList packedEnum_ = new pbc::PopsicleList(); + public scg::IList PackedEnumList { + get { return pbc::Lists.AsReadOnly(packedEnum_); } + } + public int PackedEnumCount { + get { return packedEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite GetPackedEnum(int index) { + return packedEnum_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testPackedTypesLiteFieldNames; + if (packedInt32_.Count > 0) { + output.WritePackedInt32Array(90, field_names[6], packedInt32MemoizedSerializedSize, packedInt32_); + } + if (packedInt64_.Count > 0) { + output.WritePackedInt64Array(91, field_names[7], packedInt64MemoizedSerializedSize, packedInt64_); + } + if (packedUint32_.Count > 0) { + output.WritePackedUInt32Array(92, field_names[12], packedUint32MemoizedSerializedSize, packedUint32_); + } + if (packedUint64_.Count > 0) { + output.WritePackedUInt64Array(93, field_names[13], packedUint64MemoizedSerializedSize, packedUint64_); + } + if (packedSint32_.Count > 0) { + output.WritePackedSInt32Array(94, field_names[10], packedSint32MemoizedSerializedSize, packedSint32_); + } + if (packedSint64_.Count > 0) { + output.WritePackedSInt64Array(95, field_names[11], packedSint64MemoizedSerializedSize, packedSint64_); + } + if (packedFixed32_.Count > 0) { + output.WritePackedFixed32Array(96, field_names[3], packedFixed32MemoizedSerializedSize, packedFixed32_); + } + if (packedFixed64_.Count > 0) { + output.WritePackedFixed64Array(97, field_names[4], packedFixed64MemoizedSerializedSize, packedFixed64_); + } + if (packedSfixed32_.Count > 0) { + output.WritePackedSFixed32Array(98, field_names[8], packedSfixed32MemoizedSerializedSize, packedSfixed32_); + } + if (packedSfixed64_.Count > 0) { + output.WritePackedSFixed64Array(99, field_names[9], packedSfixed64MemoizedSerializedSize, packedSfixed64_); + } + if (packedFloat_.Count > 0) { + output.WritePackedFloatArray(100, field_names[5], packedFloatMemoizedSerializedSize, packedFloat_); + } + if (packedDouble_.Count > 0) { + output.WritePackedDoubleArray(101, field_names[1], packedDoubleMemoizedSerializedSize, packedDouble_); + } + if (packedBool_.Count > 0) { + output.WritePackedBoolArray(102, field_names[0], packedBoolMemoizedSerializedSize, packedBool_); + } + if (packedEnum_.Count > 0) { + output.WritePackedEnumArray(103, field_names[2], packedEnumMemoizedSerializedSize, packedEnum_); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + foreach (int element in PackedInt32List) { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + if (packedInt32_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedInt32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + foreach (long element in PackedInt64List) { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + if (packedInt64_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedInt64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + foreach (uint element in PackedUint32List) { + dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); + } + size += dataSize; + if (packedUint32_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedUint32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + foreach (ulong element in PackedUint64List) { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); + } + size += dataSize; + if (packedUint64_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedUint64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + foreach (int element in PackedSint32List) { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + if (packedSint32_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSint32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + foreach (long element in PackedSint64List) { + dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); + } + size += dataSize; + if (packedSint64_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSint64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 4 * packedFixed32_.Count; + size += dataSize; + if (packedFixed32_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedFixed32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 8 * packedFixed64_.Count; + size += dataSize; + if (packedFixed64_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedFixed64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 4 * packedSfixed32_.Count; + size += dataSize; + if (packedSfixed32_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSfixed32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 8 * packedSfixed64_.Count; + size += dataSize; + if (packedSfixed64_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSfixed64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 4 * packedFloat_.Count; + size += dataSize; + if (packedFloat_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedFloatMemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 8 * packedDouble_.Count; + size += dataSize; + if (packedDouble_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedDoubleMemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 1 * packedBool_.Count; + size += dataSize; + if (packedBool_.Count != 0) { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedBoolMemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + if (packedEnum_.Count > 0) { + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite element in packedEnum_) { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); + } + size += dataSize; + size += 2; + size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); + } + packedEnumMemoizedSerializedSize = dataSize; + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + foreach(int i in packedInt32_) + hash ^= i.GetHashCode(); + foreach(long i in packedInt64_) + hash ^= i.GetHashCode(); + foreach(uint i in packedUint32_) + hash ^= i.GetHashCode(); + foreach(ulong i in packedUint64_) + hash ^= i.GetHashCode(); + foreach(int i in packedSint32_) + hash ^= i.GetHashCode(); + foreach(long i in packedSint64_) + hash ^= i.GetHashCode(); + foreach(uint i in packedFixed32_) + hash ^= i.GetHashCode(); + foreach(ulong i in packedFixed64_) + hash ^= i.GetHashCode(); + foreach(int i in packedSfixed32_) + hash ^= i.GetHashCode(); + foreach(long i in packedSfixed64_) + hash ^= i.GetHashCode(); + foreach(float i in packedFloat_) + hash ^= i.GetHashCode(); + foreach(double i in packedDouble_) + hash ^= i.GetHashCode(); + foreach(bool i in packedBool_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite i in packedEnum_) + hash ^= i.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestPackedTypesLite other = obj as TestPackedTypesLite; + if (other == null) return false; + if(packedInt32_.Count != other.packedInt32_.Count) return false; + for(int ix=0; ix < packedInt32_.Count; ix++) + if(!packedInt32_[ix].Equals(other.packedInt32_[ix])) return false; + if(packedInt64_.Count != other.packedInt64_.Count) return false; + for(int ix=0; ix < packedInt64_.Count; ix++) + if(!packedInt64_[ix].Equals(other.packedInt64_[ix])) return false; + if(packedUint32_.Count != other.packedUint32_.Count) return false; + for(int ix=0; ix < packedUint32_.Count; ix++) + if(!packedUint32_[ix].Equals(other.packedUint32_[ix])) return false; + if(packedUint64_.Count != other.packedUint64_.Count) return false; + for(int ix=0; ix < packedUint64_.Count; ix++) + if(!packedUint64_[ix].Equals(other.packedUint64_[ix])) return false; + if(packedSint32_.Count != other.packedSint32_.Count) return false; + for(int ix=0; ix < packedSint32_.Count; ix++) + if(!packedSint32_[ix].Equals(other.packedSint32_[ix])) return false; + if(packedSint64_.Count != other.packedSint64_.Count) return false; + for(int ix=0; ix < packedSint64_.Count; ix++) + if(!packedSint64_[ix].Equals(other.packedSint64_[ix])) return false; + if(packedFixed32_.Count != other.packedFixed32_.Count) return false; + for(int ix=0; ix < packedFixed32_.Count; ix++) + if(!packedFixed32_[ix].Equals(other.packedFixed32_[ix])) return false; + if(packedFixed64_.Count != other.packedFixed64_.Count) return false; + for(int ix=0; ix < packedFixed64_.Count; ix++) + if(!packedFixed64_[ix].Equals(other.packedFixed64_[ix])) return false; + if(packedSfixed32_.Count != other.packedSfixed32_.Count) return false; + for(int ix=0; ix < packedSfixed32_.Count; ix++) + if(!packedSfixed32_[ix].Equals(other.packedSfixed32_[ix])) return false; + if(packedSfixed64_.Count != other.packedSfixed64_.Count) return false; + for(int ix=0; ix < packedSfixed64_.Count; ix++) + if(!packedSfixed64_[ix].Equals(other.packedSfixed64_[ix])) return false; + if(packedFloat_.Count != other.packedFloat_.Count) return false; + for(int ix=0; ix < packedFloat_.Count; ix++) + if(!packedFloat_[ix].Equals(other.packedFloat_[ix])) return false; + if(packedDouble_.Count != other.packedDouble_.Count) return false; + for(int ix=0; ix < packedDouble_.Count; ix++) + if(!packedDouble_[ix].Equals(other.packedDouble_[ix])) return false; + if(packedBool_.Count != other.packedBool_.Count) return false; + for(int ix=0; ix < packedBool_.Count; ix++) + if(!packedBool_[ix].Equals(other.packedBool_[ix])) return false; + if(packedEnum_.Count != other.packedEnum_.Count) return false; + for(int ix=0; ix < packedEnum_.Count; ix++) + if(!packedEnum_[ix].Equals(other.packedEnum_[ix])) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("packed_int32", packedInt32_, writer); + PrintField("packed_int64", packedInt64_, writer); + PrintField("packed_uint32", packedUint32_, writer); + PrintField("packed_uint64", packedUint64_, writer); + PrintField("packed_sint32", packedSint32_, writer); + PrintField("packed_sint64", packedSint64_, writer); + PrintField("packed_fixed32", packedFixed32_, writer); + PrintField("packed_fixed64", packedFixed64_, writer); + PrintField("packed_sfixed32", packedSfixed32_, writer); + PrintField("packed_sfixed64", packedSfixed64_, writer); + PrintField("packed_float", packedFloat_, writer); + PrintField("packed_double", packedDouble_, writer); + PrintField("packed_bool", packedBool_, writer); + PrintField("packed_enum", packedEnum_, writer); + } + #endregion + + public static TestPackedTypesLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestPackedTypesLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestPackedTypesLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestPackedTypesLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestPackedTypesLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestPackedTypesLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestPackedTypesLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestPackedTypesLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestPackedTypesLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestPackedTypesLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestPackedTypesLite MakeReadOnly() { + packedInt32_.MakeReadOnly(); + packedInt64_.MakeReadOnly(); + packedUint32_.MakeReadOnly(); + packedUint64_.MakeReadOnly(); + packedSint32_.MakeReadOnly(); + packedSint64_.MakeReadOnly(); + packedFixed32_.MakeReadOnly(); + packedFixed64_.MakeReadOnly(); + packedSfixed32_.MakeReadOnly(); + packedSfixed64_.MakeReadOnly(); + packedFloat_.MakeReadOnly(); + packedDouble_.MakeReadOnly(); + packedBool_.MakeReadOnly(); + packedEnum_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestPackedTypesLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestPackedTypesLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestPackedTypesLite result; + + private TestPackedTypesLite PrepareBuilder() { + if (resultIsReadOnly) { + TestPackedTypesLite original = result; + result = new TestPackedTypesLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestPackedTypesLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestPackedTypesLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypesLite.DefaultInstance; } + } + + public override TestPackedTypesLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestPackedTypesLite) { + return MergeFrom((TestPackedTypesLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestPackedTypesLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedTypesLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.packedInt32_.Count != 0) { + result.packedInt32_.Add(other.packedInt32_); + } + if (other.packedInt64_.Count != 0) { + result.packedInt64_.Add(other.packedInt64_); + } + if (other.packedUint32_.Count != 0) { + result.packedUint32_.Add(other.packedUint32_); + } + if (other.packedUint64_.Count != 0) { + result.packedUint64_.Add(other.packedUint64_); + } + if (other.packedSint32_.Count != 0) { + result.packedSint32_.Add(other.packedSint32_); + } + if (other.packedSint64_.Count != 0) { + result.packedSint64_.Add(other.packedSint64_); + } + if (other.packedFixed32_.Count != 0) { + result.packedFixed32_.Add(other.packedFixed32_); + } + if (other.packedFixed64_.Count != 0) { + result.packedFixed64_.Add(other.packedFixed64_); + } + if (other.packedSfixed32_.Count != 0) { + result.packedSfixed32_.Add(other.packedSfixed32_); + } + if (other.packedSfixed64_.Count != 0) { + result.packedSfixed64_.Add(other.packedSfixed64_); + } + if (other.packedFloat_.Count != 0) { + result.packedFloat_.Add(other.packedFloat_); + } + if (other.packedDouble_.Count != 0) { + result.packedDouble_.Add(other.packedDouble_); + } + if (other.packedBool_.Count != 0) { + result.packedBool_.Add(other.packedBool_); + } + if (other.packedEnum_.Count != 0) { + result.packedEnum_.Add(other.packedEnum_); + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testPackedTypesLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testPackedTypesLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 722: + case 720: { + input.ReadInt32Array(tag, field_name, result.packedInt32_); + break; + } + case 730: + case 728: { + input.ReadInt64Array(tag, field_name, result.packedInt64_); + break; + } + case 738: + case 736: { + input.ReadUInt32Array(tag, field_name, result.packedUint32_); + break; + } + case 746: + case 744: { + input.ReadUInt64Array(tag, field_name, result.packedUint64_); + break; + } + case 754: + case 752: { + input.ReadSInt32Array(tag, field_name, result.packedSint32_); + break; + } + case 762: + case 760: { + input.ReadSInt64Array(tag, field_name, result.packedSint64_); + break; + } + case 770: + case 773: { + input.ReadFixed32Array(tag, field_name, result.packedFixed32_); + break; + } + case 778: + case 777: { + input.ReadFixed64Array(tag, field_name, result.packedFixed64_); + break; + } + case 786: + case 789: { + input.ReadSFixed32Array(tag, field_name, result.packedSfixed32_); + break; + } + case 794: + case 793: { + input.ReadSFixed64Array(tag, field_name, result.packedSfixed64_); + break; + } + case 802: + case 805: { + input.ReadFloatArray(tag, field_name, result.packedFloat_); + break; + } + case 810: + case 809: { + input.ReadDoubleArray(tag, field_name, result.packedDouble_); + break; + } + case 818: + case 816: { + input.ReadBoolArray(tag, field_name, result.packedBool_); + break; + } + case 826: + case 824: { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.packedEnum_, out unknownItems); + break; + } + } + } + + return this; + } + + + public pbc::IPopsicleList PackedInt32List { + get { return PrepareBuilder().packedInt32_; } + } + public int PackedInt32Count { + get { return result.PackedInt32Count; } + } + public int GetPackedInt32(int index) { + return result.GetPackedInt32(index); + } + public Builder SetPackedInt32(int index, int value) { + PrepareBuilder(); + result.packedInt32_[index] = value; + return this; + } + public Builder AddPackedInt32(int value) { + PrepareBuilder(); + result.packedInt32_.Add(value); + return this; + } + public Builder AddRangePackedInt32(scg::IEnumerable values) { + PrepareBuilder(); + result.packedInt32_.Add(values); + return this; + } + public Builder ClearPackedInt32() { + PrepareBuilder(); + result.packedInt32_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedInt64List { + get { return PrepareBuilder().packedInt64_; } + } + public int PackedInt64Count { + get { return result.PackedInt64Count; } + } + public long GetPackedInt64(int index) { + return result.GetPackedInt64(index); + } + public Builder SetPackedInt64(int index, long value) { + PrepareBuilder(); + result.packedInt64_[index] = value; + return this; + } + public Builder AddPackedInt64(long value) { + PrepareBuilder(); + result.packedInt64_.Add(value); + return this; + } + public Builder AddRangePackedInt64(scg::IEnumerable values) { + PrepareBuilder(); + result.packedInt64_.Add(values); + return this; + } + public Builder ClearPackedInt64() { + PrepareBuilder(); + result.packedInt64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedUint32List { + get { return PrepareBuilder().packedUint32_; } + } + public int PackedUint32Count { + get { return result.PackedUint32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedUint32(int index) { + return result.GetPackedUint32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedUint32(int index, uint value) { + PrepareBuilder(); + result.packedUint32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedUint32(uint value) { + PrepareBuilder(); + result.packedUint32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedUint32(scg::IEnumerable values) { + PrepareBuilder(); + result.packedUint32_.Add(values); + return this; + } + public Builder ClearPackedUint32() { + PrepareBuilder(); + result.packedUint32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedUint64List { + get { return PrepareBuilder().packedUint64_; } + } + public int PackedUint64Count { + get { return result.PackedUint64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedUint64(int index) { + return result.GetPackedUint64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedUint64(int index, ulong value) { + PrepareBuilder(); + result.packedUint64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedUint64(ulong value) { + PrepareBuilder(); + result.packedUint64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedUint64(scg::IEnumerable values) { + PrepareBuilder(); + result.packedUint64_.Add(values); + return this; + } + public Builder ClearPackedUint64() { + PrepareBuilder(); + result.packedUint64_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedSint32List { + get { return PrepareBuilder().packedSint32_; } + } + public int PackedSint32Count { + get { return result.PackedSint32Count; } + } + public int GetPackedSint32(int index) { + return result.GetPackedSint32(index); + } + public Builder SetPackedSint32(int index, int value) { + PrepareBuilder(); + result.packedSint32_[index] = value; + return this; + } + public Builder AddPackedSint32(int value) { + PrepareBuilder(); + result.packedSint32_.Add(value); + return this; + } + public Builder AddRangePackedSint32(scg::IEnumerable values) { + PrepareBuilder(); + result.packedSint32_.Add(values); + return this; + } + public Builder ClearPackedSint32() { + PrepareBuilder(); + result.packedSint32_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedSint64List { + get { return PrepareBuilder().packedSint64_; } + } + public int PackedSint64Count { + get { return result.PackedSint64Count; } + } + public long GetPackedSint64(int index) { + return result.GetPackedSint64(index); + } + public Builder SetPackedSint64(int index, long value) { + PrepareBuilder(); + result.packedSint64_[index] = value; + return this; + } + public Builder AddPackedSint64(long value) { + PrepareBuilder(); + result.packedSint64_.Add(value); + return this; + } + public Builder AddRangePackedSint64(scg::IEnumerable values) { + PrepareBuilder(); + result.packedSint64_.Add(values); + return this; + } + public Builder ClearPackedSint64() { + PrepareBuilder(); + result.packedSint64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedFixed32List { + get { return PrepareBuilder().packedFixed32_; } + } + public int PackedFixed32Count { + get { return result.PackedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedFixed32(int index) { + return result.GetPackedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedFixed32(int index, uint value) { + PrepareBuilder(); + result.packedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedFixed32(uint value) { + PrepareBuilder(); + result.packedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedFixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.packedFixed32_.Add(values); + return this; + } + public Builder ClearPackedFixed32() { + PrepareBuilder(); + result.packedFixed32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedFixed64List { + get { return PrepareBuilder().packedFixed64_; } + } + public int PackedFixed64Count { + get { return result.PackedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedFixed64(int index) { + return result.GetPackedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedFixed64(int index, ulong value) { + PrepareBuilder(); + result.packedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedFixed64(ulong value) { + PrepareBuilder(); + result.packedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedFixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.packedFixed64_.Add(values); + return this; + } + public Builder ClearPackedFixed64() { + PrepareBuilder(); + result.packedFixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedSfixed32List { + get { return PrepareBuilder().packedSfixed32_; } + } + public int PackedSfixed32Count { + get { return result.PackedSfixed32Count; } + } + public int GetPackedSfixed32(int index) { + return result.GetPackedSfixed32(index); + } + public Builder SetPackedSfixed32(int index, int value) { + PrepareBuilder(); + result.packedSfixed32_[index] = value; + return this; + } + public Builder AddPackedSfixed32(int value) { + PrepareBuilder(); + result.packedSfixed32_.Add(value); + return this; + } + public Builder AddRangePackedSfixed32(scg::IEnumerable values) { + PrepareBuilder(); + result.packedSfixed32_.Add(values); + return this; + } + public Builder ClearPackedSfixed32() { + PrepareBuilder(); + result.packedSfixed32_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedSfixed64List { + get { return PrepareBuilder().packedSfixed64_; } + } + public int PackedSfixed64Count { + get { return result.PackedSfixed64Count; } + } + public long GetPackedSfixed64(int index) { + return result.GetPackedSfixed64(index); + } + public Builder SetPackedSfixed64(int index, long value) { + PrepareBuilder(); + result.packedSfixed64_[index] = value; + return this; + } + public Builder AddPackedSfixed64(long value) { + PrepareBuilder(); + result.packedSfixed64_.Add(value); + return this; + } + public Builder AddRangePackedSfixed64(scg::IEnumerable values) { + PrepareBuilder(); + result.packedSfixed64_.Add(values); + return this; + } + public Builder ClearPackedSfixed64() { + PrepareBuilder(); + result.packedSfixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedFloatList { + get { return PrepareBuilder().packedFloat_; } + } + public int PackedFloatCount { + get { return result.PackedFloatCount; } + } + public float GetPackedFloat(int index) { + return result.GetPackedFloat(index); + } + public Builder SetPackedFloat(int index, float value) { + PrepareBuilder(); + result.packedFloat_[index] = value; + return this; + } + public Builder AddPackedFloat(float value) { + PrepareBuilder(); + result.packedFloat_.Add(value); + return this; + } + public Builder AddRangePackedFloat(scg::IEnumerable values) { + PrepareBuilder(); + result.packedFloat_.Add(values); + return this; + } + public Builder ClearPackedFloat() { + PrepareBuilder(); + result.packedFloat_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedDoubleList { + get { return PrepareBuilder().packedDouble_; } + } + public int PackedDoubleCount { + get { return result.PackedDoubleCount; } + } + public double GetPackedDouble(int index) { + return result.GetPackedDouble(index); + } + public Builder SetPackedDouble(int index, double value) { + PrepareBuilder(); + result.packedDouble_[index] = value; + return this; + } + public Builder AddPackedDouble(double value) { + PrepareBuilder(); + result.packedDouble_.Add(value); + return this; + } + public Builder AddRangePackedDouble(scg::IEnumerable values) { + PrepareBuilder(); + result.packedDouble_.Add(values); + return this; + } + public Builder ClearPackedDouble() { + PrepareBuilder(); + result.packedDouble_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedBoolList { + get { return PrepareBuilder().packedBool_; } + } + public int PackedBoolCount { + get { return result.PackedBoolCount; } + } + public bool GetPackedBool(int index) { + return result.GetPackedBool(index); + } + public Builder SetPackedBool(int index, bool value) { + PrepareBuilder(); + result.packedBool_[index] = value; + return this; + } + public Builder AddPackedBool(bool value) { + PrepareBuilder(); + result.packedBool_.Add(value); + return this; + } + public Builder AddRangePackedBool(scg::IEnumerable values) { + PrepareBuilder(); + result.packedBool_.Add(values); + return this; + } + public Builder ClearPackedBool() { + PrepareBuilder(); + result.packedBool_.Clear(); + return this; + } + + public pbc::IPopsicleList PackedEnumList { + get { return PrepareBuilder().packedEnum_; } + } + public int PackedEnumCount { + get { return result.PackedEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite GetPackedEnum(int index) { + return result.GetPackedEnum(index); + } + public Builder SetPackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { + PrepareBuilder(); + result.packedEnum_[index] = value; + return this; + } + public Builder AddPackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnumLite value) { + PrepareBuilder(); + result.packedEnum_.Add(value); + return this; + } + public Builder AddRangePackedEnum(scg::IEnumerable values) { + PrepareBuilder(); + result.packedEnum_.Add(values); + return this; + } + public Builder ClearPackedEnum() { + PrepareBuilder(); + result.packedEnum_.Clear(); + return this; + } + } + static TestPackedTypesLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestAllExtensionsLite : pb::ExtendableMessageLite { + private TestAllExtensionsLite() { } + private static readonly TestAllExtensionsLite defaultInstance = new TestAllExtensionsLite().MakeReadOnly(); + private static readonly string[] _testAllExtensionsLiteFieldNames = new string[] { }; + private static readonly uint[] _testAllExtensionsLiteFieldTags = new uint[] { }; + public static TestAllExtensionsLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestAllExtensionsLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestAllExtensionsLite ThisMessage { + get { return this; } + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testAllExtensionsLiteFieldNames; + pb::ExtendableMessageLite.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + hash ^= base.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestAllExtensionsLite other = obj as TestAllExtensionsLite; + if (other == null) return false; + if (!base.Equals(other)) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + base.PrintTo(writer); + } + #endregion + + public static TestAllExtensionsLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllExtensionsLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllExtensionsLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllExtensionsLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllExtensionsLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllExtensionsLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestAllExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestAllExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestAllExtensionsLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllExtensionsLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestAllExtensionsLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestAllExtensionsLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestAllExtensionsLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestAllExtensionsLite result; + + private TestAllExtensionsLite PrepareBuilder() { + if (resultIsReadOnly) { + TestAllExtensionsLite original = result; + result = new TestAllExtensionsLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestAllExtensionsLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestAllExtensionsLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance; } + } + + public override TestAllExtensionsLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestAllExtensionsLite) { + return MergeFrom((TestAllExtensionsLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestAllExtensionsLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllExtensionsLite.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testAllExtensionsLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testAllExtensionsLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + } + } + + return this; + } + + } + static TestAllExtensionsLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OptionalGroup_extension_lite : pb::GeneratedMessageLite { + private OptionalGroup_extension_lite() { } + private static readonly OptionalGroup_extension_lite defaultInstance = new OptionalGroup_extension_lite().MakeReadOnly(); + private static readonly string[] _optionalGroupExtensionLiteFieldNames = new string[] { "a" }; + private static readonly uint[] _optionalGroupExtensionLiteFieldTags = new uint[] { 136 }; + public static OptionalGroup_extension_lite DefaultInstance { + get { return defaultInstance; } + } + + public override OptionalGroup_extension_lite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override OptionalGroup_extension_lite ThisMessage { + get { return this; } + } + + public const int AFieldNumber = 17; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _optionalGroupExtensionLiteFieldNames; + if (hasA) { + output.WriteInt32(17, field_names[0], A); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(17, A); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasA) hash ^= a_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + OptionalGroup_extension_lite other = obj as OptionalGroup_extension_lite; + if (other == null) return false; + if (hasA != other.hasA || (hasA && !a_.Equals(other.a_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("a", hasA, a_, writer); + } + #endregion + + public static OptionalGroup_extension_lite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup_extension_lite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup_extension_lite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup_extension_lite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup_extension_lite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup_extension_lite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup_extension_lite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OptionalGroup_extension_lite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OptionalGroup_extension_lite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup_extension_lite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OptionalGroup_extension_lite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OptionalGroup_extension_lite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OptionalGroup_extension_lite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OptionalGroup_extension_lite result; + + private OptionalGroup_extension_lite PrepareBuilder() { + if (resultIsReadOnly) { + OptionalGroup_extension_lite original = result; + result = new OptionalGroup_extension_lite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override OptionalGroup_extension_lite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override OptionalGroup_extension_lite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension_lite.DefaultInstance; } + } + + public override OptionalGroup_extension_lite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is OptionalGroup_extension_lite) { + return MergeFrom((OptionalGroup_extension_lite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OptionalGroup_extension_lite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension_lite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_optionalGroupExtensionLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _optionalGroupExtensionLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 136: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static OptionalGroup_extension_lite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedGroup_extension_lite : pb::GeneratedMessageLite { + private RepeatedGroup_extension_lite() { } + private static readonly RepeatedGroup_extension_lite defaultInstance = new RepeatedGroup_extension_lite().MakeReadOnly(); + private static readonly string[] _repeatedGroupExtensionLiteFieldNames = new string[] { "a" }; + private static readonly uint[] _repeatedGroupExtensionLiteFieldTags = new uint[] { 376 }; + public static RepeatedGroup_extension_lite DefaultInstance { + get { return defaultInstance; } + } + + public override RepeatedGroup_extension_lite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override RepeatedGroup_extension_lite ThisMessage { + get { return this; } + } + + public const int AFieldNumber = 47; + private bool hasA; + private int a_; + public bool HasA { + get { return hasA; } + } + public int A { + get { return a_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _repeatedGroupExtensionLiteFieldNames; + if (hasA) { + output.WriteInt32(47, field_names[0], A); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) { + size += pb::CodedOutputStream.ComputeInt32Size(47, A); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasA) hash ^= a_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + RepeatedGroup_extension_lite other = obj as RepeatedGroup_extension_lite; + if (other == null) return false; + if (hasA != other.hasA || (hasA && !a_.Equals(other.a_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("a", hasA, a_, writer); + } + #endregion + + public static RepeatedGroup_extension_lite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup_extension_lite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup_extension_lite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup_extension_lite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup_extension_lite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup_extension_lite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup_extension_lite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedGroup_extension_lite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedGroup_extension_lite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup_extension_lite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedGroup_extension_lite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedGroup_extension_lite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedGroup_extension_lite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private RepeatedGroup_extension_lite result; + + private RepeatedGroup_extension_lite PrepareBuilder() { + if (resultIsReadOnly) { + RepeatedGroup_extension_lite original = result; + result = new RepeatedGroup_extension_lite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override RepeatedGroup_extension_lite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override RepeatedGroup_extension_lite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension_lite.DefaultInstance; } + } + + public override RepeatedGroup_extension_lite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is RepeatedGroup_extension_lite) { + return MergeFrom((RepeatedGroup_extension_lite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(RepeatedGroup_extension_lite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension_lite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) { + A = other.A; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupExtensionLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _repeatedGroupExtensionLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 376: { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + return this; + } + + + public bool HasA { + get { return result.hasA; } + } + public int A { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static RepeatedGroup_extension_lite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestPackedExtensionsLite : pb::ExtendableMessageLite { + private TestPackedExtensionsLite() { } + private static readonly TestPackedExtensionsLite defaultInstance = new TestPackedExtensionsLite().MakeReadOnly(); + private static readonly string[] _testPackedExtensionsLiteFieldNames = new string[] { }; + private static readonly uint[] _testPackedExtensionsLiteFieldTags = new uint[] { }; + public static TestPackedExtensionsLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestPackedExtensionsLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestPackedExtensionsLite ThisMessage { + get { return this; } + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testPackedExtensionsLiteFieldNames; + pb::ExtendableMessageLite.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + hash ^= base.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestPackedExtensionsLite other = obj as TestPackedExtensionsLite; + if (other == null) return false; + if (!base.Equals(other)) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + base.PrintTo(writer); + } + #endregion + + public static TestPackedExtensionsLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestPackedExtensionsLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestPackedExtensionsLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestPackedExtensionsLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestPackedExtensionsLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestPackedExtensionsLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestPackedExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestPackedExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestPackedExtensionsLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestPackedExtensionsLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestPackedExtensionsLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestPackedExtensionsLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestPackedExtensionsLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestPackedExtensionsLite result; + + private TestPackedExtensionsLite PrepareBuilder() { + if (resultIsReadOnly) { + TestPackedExtensionsLite original = result; + result = new TestPackedExtensionsLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestPackedExtensionsLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestPackedExtensionsLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance; } + } + + public override TestPackedExtensionsLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestPackedExtensionsLite) { + return MergeFrom((TestPackedExtensionsLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestPackedExtensionsLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedExtensionsLite.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testPackedExtensionsLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testPackedExtensionsLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + } + } + + return this; + } + + } + static TestPackedExtensionsLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestNestedExtensionLite : pb::GeneratedMessageLite { + private TestNestedExtensionLite() { } + private static readonly TestNestedExtensionLite defaultInstance = new TestNestedExtensionLite().MakeReadOnly(); + private static readonly string[] _testNestedExtensionLiteFieldNames = new string[] { }; + private static readonly uint[] _testNestedExtensionLiteFieldTags = new uint[] { }; + public static TestNestedExtensionLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestNestedExtensionLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestNestedExtensionLite ThisMessage { + get { return this; } + } + + public const int NestedExtensionFieldNumber = 12345; + public static pb::GeneratedExtensionLite NestedExtension; + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testNestedExtensionLiteFieldNames; + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestNestedExtensionLite other = obj as TestNestedExtensionLite; + if (other == null) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + } + #endregion + + public static TestNestedExtensionLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestNestedExtensionLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestNestedExtensionLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestNestedExtensionLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestNestedExtensionLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestNestedExtensionLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestNestedExtensionLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestNestedExtensionLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestNestedExtensionLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestNestedExtensionLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestNestedExtensionLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestNestedExtensionLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestNestedExtensionLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestNestedExtensionLite result; + + private TestNestedExtensionLite PrepareBuilder() { + if (resultIsReadOnly) { + TestNestedExtensionLite original = result; + result = new TestNestedExtensionLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestNestedExtensionLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestNestedExtensionLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtensionLite.DefaultInstance; } + } + + public override TestNestedExtensionLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestNestedExtensionLite) { + return MergeFrom((TestNestedExtensionLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestNestedExtensionLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedExtensionLite.DefaultInstance) return this; + PrepareBuilder(); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testNestedExtensionLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testNestedExtensionLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + } + } + + return this; + } + + } + static TestNestedExtensionLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestDeprecatedLite : pb::GeneratedMessageLite { + private TestDeprecatedLite() { } + private static readonly TestDeprecatedLite defaultInstance = new TestDeprecatedLite().MakeReadOnly(); + private static readonly string[] _testDeprecatedLiteFieldNames = new string[] { "deprecated_field" }; + private static readonly uint[] _testDeprecatedLiteFieldTags = new uint[] { 8 }; + public static TestDeprecatedLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestDeprecatedLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestDeprecatedLite ThisMessage { + get { return this; } + } + + public const int DeprecatedFieldFieldNumber = 1; + private bool hasDeprecatedField; + private int deprecatedField_; + [global::System.ObsoleteAttribute()] + public bool HasDeprecatedField { + get { return hasDeprecatedField; } + } + [global::System.ObsoleteAttribute()] + public int DeprecatedField { + get { return deprecatedField_; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testDeprecatedLiteFieldNames; + if (hasDeprecatedField) { + output.WriteInt32(1, field_names[0], DeprecatedField); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasDeprecatedField) { + size += pb::CodedOutputStream.ComputeInt32Size(1, DeprecatedField); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasDeprecatedField) hash ^= deprecatedField_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestDeprecatedLite other = obj as TestDeprecatedLite; + if (other == null) return false; + if (hasDeprecatedField != other.hasDeprecatedField || (hasDeprecatedField && !deprecatedField_.Equals(other.deprecatedField_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("deprecated_field", hasDeprecatedField, deprecatedField_, writer); + } + #endregion + + public static TestDeprecatedLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDeprecatedLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDeprecatedLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDeprecatedLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDeprecatedLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDeprecatedLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestDeprecatedLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestDeprecatedLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestDeprecatedLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDeprecatedLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestDeprecatedLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestDeprecatedLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestDeprecatedLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestDeprecatedLite result; + + private TestDeprecatedLite PrepareBuilder() { + if (resultIsReadOnly) { + TestDeprecatedLite original = result; + result = new TestDeprecatedLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestDeprecatedLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestDeprecatedLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedLite.DefaultInstance; } + } + + public override TestDeprecatedLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestDeprecatedLite) { + return MergeFrom((TestDeprecatedLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestDeprecatedLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDeprecatedLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasDeprecatedField) { + DeprecatedField = other.DeprecatedField; + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testDeprecatedLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testDeprecatedLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 8: { + result.hasDeprecatedField = input.ReadInt32(ref result.deprecatedField_); + break; + } + } + } + + return this; + } + + + [global::System.ObsoleteAttribute()] + public bool HasDeprecatedField { + get { return result.hasDeprecatedField; } + } + [global::System.ObsoleteAttribute()] + public int DeprecatedField { + get { return result.DeprecatedField; } + set { SetDeprecatedField(value); } + } + [global::System.ObsoleteAttribute()] + public Builder SetDeprecatedField(int value) { + PrepareBuilder(); + result.hasDeprecatedField = true; + result.deprecatedField_ = value; + return this; + } + [global::System.ObsoleteAttribute()] + public Builder ClearDeprecatedField() { + PrepareBuilder(); + result.hasDeprecatedField = false; + result.deprecatedField_ = 0; + return this; + } + } + static TestDeprecatedLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestParsingMergeLite : pb::ExtendableMessageLite { + private TestParsingMergeLite() { } + private static readonly TestParsingMergeLite defaultInstance = new TestParsingMergeLite().MakeReadOnly(); + private static readonly string[] _testParsingMergeLiteFieldNames = new string[] { "optional_all_types", "optionalgroup", "repeated_all_types", "repeatedgroup", "required_all_types" }; + private static readonly uint[] _testParsingMergeLiteFieldTags = new uint[] { 18, 83, 26, 163, 10 }; + public static TestParsingMergeLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestParsingMergeLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestParsingMergeLite ThisMessage { + get { return this; } + } + + public const int OptionalExtFieldNumber = 1000; + public static pb::GeneratedExtensionLite OptionalExt; + public const int RepeatedExtFieldNumber = 1001; + public static pb::GeneratedRepeatExtensionLite RepeatedExt; + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedFieldsGenerator : pb::GeneratedMessageLite { + private RepeatedFieldsGenerator() { } + private static readonly RepeatedFieldsGenerator defaultInstance = new RepeatedFieldsGenerator().MakeReadOnly(); + private static readonly string[] _repeatedFieldsGeneratorFieldNames = new string[] { "ext1", "ext2", "field1", "field2", "field3", "group1", "group2" }; + private static readonly uint[] _repeatedFieldsGeneratorFieldTags = new uint[] { 8002, 8010, 10, 18, 26, 83, 163 }; + public static RepeatedFieldsGenerator DefaultInstance { + get { return defaultInstance; } + } + + public override RepeatedFieldsGenerator DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override RepeatedFieldsGenerator ThisMessage { + get { return this; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Group1 : pb::GeneratedMessageLite { + private Group1() { } + private static readonly Group1 defaultInstance = new Group1().MakeReadOnly(); + private static readonly string[] _group1FieldNames = new string[] { "field1" }; + private static readonly uint[] _group1FieldTags = new uint[] { 90 }; + public static Group1 DefaultInstance { + get { return defaultInstance; } + } + + public override Group1 DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Group1 ThisMessage { + get { return this; } + } + + public const int Field1FieldNumber = 11; + private bool hasField1; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite field1_; + public bool HasField1 { + get { return hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite Field1 { + get { return field1_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _group1FieldNames; + if (hasField1) { + output.WriteMessage(11, field_names[0], Field1); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasField1) { + size += pb::CodedOutputStream.ComputeMessageSize(11, Field1); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasField1) hash ^= field1_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + Group1 other = obj as Group1; + if (other == null) return false; + if (hasField1 != other.hasField1 || (hasField1 && !field1_.Equals(other.field1_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("field1", hasField1, field1_, writer); + } + #endregion + + public static Group1 ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group1 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group1 ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group1 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group1 ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group1 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Group1 ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Group1 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Group1 ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group1 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Group1 MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Group1 prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Group1 cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Group1 result; + + private Group1 PrepareBuilder() { + if (resultIsReadOnly) { + Group1 original = result; + result = new Group1(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Group1 MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override Group1 DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance; } + } + + public override Group1 BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is Group1) { + return MergeFrom((Group1) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Group1 other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasField1) { + MergeField1(other.Field1); + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_group1FieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _group1FieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 90: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(); + if (result.hasField1) { + subBuilder.MergeFrom(Field1); + } + input.ReadMessage(subBuilder, extensionRegistry); + Field1 = subBuilder.BuildPartial(); + break; + } + } + } + + return this; + } + + + public bool HasField1 { + get { return result.hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite Field1 { + get { return result.Field1; } + set { SetField1(value); } + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = value; + return this; + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = builderForValue.Build(); + return this; + } + public Builder MergeField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasField1 && + result.field1_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance) { + result.field1_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(result.field1_).MergeFrom(value).BuildPartial(); + } else { + result.field1_ = value; + } + result.hasField1 = true; + return this; + } + public Builder ClearField1() { + PrepareBuilder(); + result.hasField1 = false; + result.field1_ = null; + return this; + } + } + static Group1() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Group2 : pb::GeneratedMessageLite { + private Group2() { } + private static readonly Group2 defaultInstance = new Group2().MakeReadOnly(); + private static readonly string[] _group2FieldNames = new string[] { "field1" }; + private static readonly uint[] _group2FieldTags = new uint[] { 170 }; + public static Group2 DefaultInstance { + get { return defaultInstance; } + } + + public override Group2 DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override Group2 ThisMessage { + get { return this; } + } + + public const int Field1FieldNumber = 21; + private bool hasField1; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite field1_; + public bool HasField1 { + get { return hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite Field1 { + get { return field1_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _group2FieldNames; + if (hasField1) { + output.WriteMessage(21, field_names[0], Field1); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasField1) { + size += pb::CodedOutputStream.ComputeMessageSize(21, Field1); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasField1) hash ^= field1_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + Group2 other = obj as Group2; + if (other == null) return false; + if (hasField1 != other.hasField1 || (hasField1 && !field1_.Equals(other.field1_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("field1", hasField1, field1_, writer); + } + #endregion + + public static Group2 ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group2 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group2 ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group2 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group2 ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group2 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Group2 ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Group2 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Group2 ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group2 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Group2 MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Group2 prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Group2 cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Group2 result; + + private Group2 PrepareBuilder() { + if (resultIsReadOnly) { + Group2 original = result; + result = new Group2(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override Group2 MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override Group2 DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance; } + } + + public override Group2 BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is Group2) { + return MergeFrom((Group2) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Group2 other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasField1) { + MergeField1(other.Field1); + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_group2FieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _group2FieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 170: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(); + if (result.hasField1) { + subBuilder.MergeFrom(Field1); + } + input.ReadMessage(subBuilder, extensionRegistry); + Field1 = subBuilder.BuildPartial(); + break; + } + } + } + + return this; + } + + + public bool HasField1 { + get { return result.hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite Field1 { + get { return result.Field1; } + set { SetField1(value); } + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = value; + return this; + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = builderForValue.Build(); + return this; + } + public Builder MergeField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasField1 && + result.field1_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance) { + result.field1_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(result.field1_).MergeFrom(value).BuildPartial(); + } else { + result.field1_ = value; + } + result.hasField1 = true; + return this; + } + public Builder ClearField1() { + PrepareBuilder(); + result.hasField1 = false; + result.field1_ = null; + return this; + } + } + static Group2() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + } + #endregion + + public const int Field1FieldNumber = 1; + private pbc::PopsicleList field1_ = new pbc::PopsicleList(); + public scg::IList Field1List { + get { return field1_; } + } + public int Field1Count { + get { return field1_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetField1(int index) { + return field1_[index]; + } + + public const int Field2FieldNumber = 2; + private pbc::PopsicleList field2_ = new pbc::PopsicleList(); + public scg::IList Field2List { + get { return field2_; } + } + public int Field2Count { + get { return field2_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetField2(int index) { + return field2_[index]; + } + + public const int Field3FieldNumber = 3; + private pbc::PopsicleList field3_ = new pbc::PopsicleList(); + public scg::IList Field3List { + get { return field3_; } + } + public int Field3Count { + get { return field3_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetField3(int index) { + return field3_[index]; + } + + public const int Group1FieldNumber = 10; + private pbc::PopsicleList group1_ = new pbc::PopsicleList(); + public scg::IList Group1List { + get { return group1_; } + } + public int Group1Count { + get { return group1_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1 GetGroup1(int index) { + return group1_[index]; + } + + public const int Group2FieldNumber = 20; + private pbc::PopsicleList group2_ = new pbc::PopsicleList(); + public scg::IList Group2List { + get { return group2_; } + } + public int Group2Count { + get { return group2_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2 GetGroup2(int index) { + return group2_[index]; + } + + public const int Ext1FieldNumber = 1000; + private pbc::PopsicleList ext1_ = new pbc::PopsicleList(); + public scg::IList Ext1List { + get { return ext1_; } + } + public int Ext1Count { + get { return ext1_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetExt1(int index) { + return ext1_[index]; + } + + public const int Ext2FieldNumber = 1001; + private pbc::PopsicleList ext2_ = new pbc::PopsicleList(); + public scg::IList Ext2List { + get { return ext2_; } + } + public int Ext2Count { + get { return ext2_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetExt2(int index) { + return ext2_[index]; + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _repeatedFieldsGeneratorFieldNames; + if (field1_.Count > 0) { + output.WriteMessageArray(1, field_names[2], field1_); + } + if (field2_.Count > 0) { + output.WriteMessageArray(2, field_names[3], field2_); + } + if (field3_.Count > 0) { + output.WriteMessageArray(3, field_names[4], field3_); + } + if (group1_.Count > 0) { + output.WriteGroupArray(10, field_names[5], group1_); + } + if (group2_.Count > 0) { + output.WriteGroupArray(20, field_names[6], group2_); + } + if (ext1_.Count > 0) { + output.WriteMessageArray(1000, field_names[0], ext1_); + } + if (ext2_.Count > 0) { + output.WriteMessageArray(1001, field_names[1], ext2_); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite element in Field1List) { + size += pb::CodedOutputStream.ComputeMessageSize(1, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite element in Field2List) { + size += pb::CodedOutputStream.ComputeMessageSize(2, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite element in Field3List) { + size += pb::CodedOutputStream.ComputeMessageSize(3, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1 element in Group1List) { + size += pb::CodedOutputStream.ComputeGroupSize(10, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2 element in Group2List) { + size += pb::CodedOutputStream.ComputeGroupSize(20, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite element in Ext1List) { + size += pb::CodedOutputStream.ComputeMessageSize(1000, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite element in Ext2List) { + size += pb::CodedOutputStream.ComputeMessageSize(1001, element); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite i in field1_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite i in field2_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite i in field3_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1 i in group1_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2 i in group2_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite i in ext1_) + hash ^= i.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite i in ext2_) + hash ^= i.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + RepeatedFieldsGenerator other = obj as RepeatedFieldsGenerator; + if (other == null) return false; + if(field1_.Count != other.field1_.Count) return false; + for(int ix=0; ix < field1_.Count; ix++) + if(!field1_[ix].Equals(other.field1_[ix])) return false; + if(field2_.Count != other.field2_.Count) return false; + for(int ix=0; ix < field2_.Count; ix++) + if(!field2_[ix].Equals(other.field2_[ix])) return false; + if(field3_.Count != other.field3_.Count) return false; + for(int ix=0; ix < field3_.Count; ix++) + if(!field3_[ix].Equals(other.field3_[ix])) return false; + if(group1_.Count != other.group1_.Count) return false; + for(int ix=0; ix < group1_.Count; ix++) + if(!group1_[ix].Equals(other.group1_[ix])) return false; + if(group2_.Count != other.group2_.Count) return false; + for(int ix=0; ix < group2_.Count; ix++) + if(!group2_[ix].Equals(other.group2_[ix])) return false; + if(ext1_.Count != other.ext1_.Count) return false; + for(int ix=0; ix < ext1_.Count; ix++) + if(!ext1_[ix].Equals(other.ext1_[ix])) return false; + if(ext2_.Count != other.ext2_.Count) return false; + for(int ix=0; ix < ext2_.Count; ix++) + if(!ext2_[ix].Equals(other.ext2_[ix])) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("field1", field1_, writer); + PrintField("field2", field2_, writer); + PrintField("field3", field3_, writer); + PrintField("Group1", group1_, writer); + PrintField("Group2", group2_, writer); + PrintField("ext1", ext1_, writer); + PrintField("ext2", ext2_, writer); + } + #endregion + + public static RepeatedFieldsGenerator ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedFieldsGenerator MakeReadOnly() { + field1_.MakeReadOnly(); + field2_.MakeReadOnly(); + field3_.MakeReadOnly(); + group1_.MakeReadOnly(); + group2_.MakeReadOnly(); + ext1_.MakeReadOnly(); + ext2_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedFieldsGenerator prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedFieldsGenerator cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private RepeatedFieldsGenerator result; + + private RepeatedFieldsGenerator PrepareBuilder() { + if (resultIsReadOnly) { + RepeatedFieldsGenerator original = result; + result = new RepeatedFieldsGenerator(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override RepeatedFieldsGenerator MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override RepeatedFieldsGenerator DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.DefaultInstance; } + } + + public override RepeatedFieldsGenerator BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is RepeatedFieldsGenerator) { + return MergeFrom((RepeatedFieldsGenerator) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(RepeatedFieldsGenerator other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.DefaultInstance) return this; + PrepareBuilder(); + if (other.field1_.Count != 0) { + result.field1_.Add(other.field1_); + } + if (other.field2_.Count != 0) { + result.field2_.Add(other.field2_); + } + if (other.field3_.Count != 0) { + result.field3_.Add(other.field3_); + } + if (other.group1_.Count != 0) { + result.group1_.Add(other.group1_); + } + if (other.group2_.Count != 0) { + result.group2_.Add(other.group2_); + } + if (other.ext1_.Count != 0) { + result.ext1_.Add(other.ext1_); + } + if (other.ext2_.Count != 0) { + result.ext2_.Add(other.ext2_); + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_repeatedFieldsGeneratorFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _repeatedFieldsGeneratorFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 10: { + input.ReadMessageArray(tag, field_name, result.field1_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance, extensionRegistry); + break; + } + case 18: { + input.ReadMessageArray(tag, field_name, result.field2_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance, extensionRegistry); + break; + } + case 26: { + input.ReadMessageArray(tag, field_name, result.field3_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance, extensionRegistry); + break; + } + case 83: { + input.ReadGroupArray(tag, field_name, result.group1_, global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance, extensionRegistry); + break; + } + case 163: { + input.ReadGroupArray(tag, field_name, result.group2_, global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance, extensionRegistry); + break; + } + case 8002: { + input.ReadMessageArray(tag, field_name, result.ext1_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance, extensionRegistry); + break; + } + case 8010: { + input.ReadMessageArray(tag, field_name, result.ext2_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance, extensionRegistry); + break; + } + } + } + + return this; + } + + + public pbc::IPopsicleList Field1List { + get { return PrepareBuilder().field1_; } + } + public int Field1Count { + get { return result.Field1Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetField1(int index) { + return result.GetField1(index); + } + public Builder SetField1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field1_[index] = value; + return this; + } + public Builder SetField1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field1_[index] = builderForValue.Build(); + return this; + } + public Builder AddField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field1_.Add(value); + return this; + } + public Builder AddField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field1_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeField1(scg::IEnumerable values) { + PrepareBuilder(); + result.field1_.Add(values); + return this; + } + public Builder ClearField1() { + PrepareBuilder(); + result.field1_.Clear(); + return this; + } + + public pbc::IPopsicleList Field2List { + get { return PrepareBuilder().field2_; } + } + public int Field2Count { + get { return result.Field2Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetField2(int index) { + return result.GetField2(index); + } + public Builder SetField2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field2_[index] = value; + return this; + } + public Builder SetField2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field2_[index] = builderForValue.Build(); + return this; + } + public Builder AddField2(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field2_.Add(value); + return this; + } + public Builder AddField2(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field2_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeField2(scg::IEnumerable values) { + PrepareBuilder(); + result.field2_.Add(values); + return this; + } + public Builder ClearField2() { + PrepareBuilder(); + result.field2_.Clear(); + return this; + } + + public pbc::IPopsicleList Field3List { + get { return PrepareBuilder().field3_; } + } + public int Field3Count { + get { return result.Field3Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetField3(int index) { + return result.GetField3(index); + } + public Builder SetField3(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field3_[index] = value; + return this; + } + public Builder SetField3(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field3_[index] = builderForValue.Build(); + return this; + } + public Builder AddField3(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field3_.Add(value); + return this; + } + public Builder AddField3(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field3_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeField3(scg::IEnumerable values) { + PrepareBuilder(); + result.field3_.Add(values); + return this; + } + public Builder ClearField3() { + PrepareBuilder(); + result.field3_.Clear(); + return this; + } + + public pbc::IPopsicleList Group1List { + get { return PrepareBuilder().group1_; } + } + public int Group1Count { + get { return result.Group1Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1 GetGroup1(int index) { + return result.GetGroup1(index); + } + public Builder SetGroup1(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1 value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group1_[index] = value; + return this; + } + public Builder SetGroup1(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group1_[index] = builderForValue.Build(); + return this; + } + public Builder AddGroup1(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1 value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group1_.Add(value); + return this; + } + public Builder AddGroup1(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group1.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group1_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeGroup1(scg::IEnumerable values) { + PrepareBuilder(); + result.group1_.Add(values); + return this; + } + public Builder ClearGroup1() { + PrepareBuilder(); + result.group1_.Clear(); + return this; + } + + public pbc::IPopsicleList Group2List { + get { return PrepareBuilder().group2_; } + } + public int Group2Count { + get { return result.Group2Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2 GetGroup2(int index) { + return result.GetGroup2(index); + } + public Builder SetGroup2(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2 value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group2_[index] = value; + return this; + } + public Builder SetGroup2(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group2_[index] = builderForValue.Build(); + return this; + } + public Builder AddGroup2(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2 value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group2_.Add(value); + return this; + } + public Builder AddGroup2(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedFieldsGenerator.Types.Group2.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group2_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeGroup2(scg::IEnumerable values) { + PrepareBuilder(); + result.group2_.Add(values); + return this; + } + public Builder ClearGroup2() { + PrepareBuilder(); + result.group2_.Clear(); + return this; + } + + public pbc::IPopsicleList Ext1List { + get { return PrepareBuilder().ext1_; } + } + public int Ext1Count { + get { return result.Ext1Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetExt1(int index) { + return result.GetExt1(index); + } + public Builder SetExt1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext1_[index] = value; + return this; + } + public Builder SetExt1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext1_[index] = builderForValue.Build(); + return this; + } + public Builder AddExt1(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext1_.Add(value); + return this; + } + public Builder AddExt1(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext1_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeExt1(scg::IEnumerable values) { + PrepareBuilder(); + result.ext1_.Add(values); + return this; + } + public Builder ClearExt1() { + PrepareBuilder(); + result.ext1_.Clear(); + return this; + } + + public pbc::IPopsicleList Ext2List { + get { return PrepareBuilder().ext2_; } + } + public int Ext2Count { + get { return result.Ext2Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetExt2(int index) { + return result.GetExt2(index); + } + public Builder SetExt2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext2_[index] = value; + return this; + } + public Builder SetExt2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext2_[index] = builderForValue.Build(); + return this; + } + public Builder AddExt2(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext2_.Add(value); + return this; + } + public Builder AddExt2(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext2_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeExt2(scg::IEnumerable values) { + PrepareBuilder(); + result.ext2_.Add(values); + return this; + } + public Builder ClearExt2() { + PrepareBuilder(); + result.ext2_.Clear(); + return this; + } + } + static RepeatedFieldsGenerator() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OptionalGroup : pb::GeneratedMessageLite { + private OptionalGroup() { } + private static readonly OptionalGroup defaultInstance = new OptionalGroup().MakeReadOnly(); + private static readonly string[] _optionalGroupFieldNames = new string[] { "optional_group_all_types" }; + private static readonly uint[] _optionalGroupFieldTags = new uint[] { 90 }; + public static OptionalGroup DefaultInstance { + get { return defaultInstance; } + } + + public override OptionalGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override OptionalGroup ThisMessage { + get { return this; } + } + + public const int OptionalGroupAllTypesFieldNumber = 11; + private bool hasOptionalGroupAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite optionalGroupAllTypes_; + public bool HasOptionalGroupAllTypes { + get { return hasOptionalGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite OptionalGroupAllTypes { + get { return optionalGroupAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _optionalGroupFieldNames; + if (hasOptionalGroupAllTypes) { + output.WriteMessage(11, field_names[0], OptionalGroupAllTypes); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOptionalGroupAllTypes) { + size += pb::CodedOutputStream.ComputeMessageSize(11, OptionalGroupAllTypes); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasOptionalGroupAllTypes) hash ^= optionalGroupAllTypes_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + OptionalGroup other = obj as OptionalGroup; + if (other == null) return false; + if (hasOptionalGroupAllTypes != other.hasOptionalGroupAllTypes || (hasOptionalGroupAllTypes && !optionalGroupAllTypes_.Equals(other.optionalGroupAllTypes_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("optional_group_all_types", hasOptionalGroupAllTypes, optionalGroupAllTypes_, writer); + } + #endregion + + public static OptionalGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OptionalGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OptionalGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OptionalGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OptionalGroup result; + + private OptionalGroup PrepareBuilder() { + if (resultIsReadOnly) { + OptionalGroup original = result; + result = new OptionalGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override OptionalGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override OptionalGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup.DefaultInstance; } + } + + public override OptionalGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is OptionalGroup) { + return MergeFrom((OptionalGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OptionalGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOptionalGroupAllTypes) { + MergeOptionalGroupAllTypes(other.OptionalGroupAllTypes); + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _optionalGroupFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 90: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(); + if (result.hasOptionalGroupAllTypes) { + subBuilder.MergeFrom(OptionalGroupAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalGroupAllTypes = subBuilder.BuildPartial(); + break; + } + } + } + + return this; + } + + + public bool HasOptionalGroupAllTypes { + get { return result.hasOptionalGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite OptionalGroupAllTypes { + get { return result.OptionalGroupAllTypes; } + set { SetOptionalGroupAllTypes(value); } + } + public Builder SetOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalGroupAllTypes = true; + result.optionalGroupAllTypes_ = value; + return this; + } + public Builder SetOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalGroupAllTypes = true; + result.optionalGroupAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalGroupAllTypes && + result.optionalGroupAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance) { + result.optionalGroupAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(result.optionalGroupAllTypes_).MergeFrom(value).BuildPartial(); + } else { + result.optionalGroupAllTypes_ = value; + } + result.hasOptionalGroupAllTypes = true; + return this; + } + public Builder ClearOptionalGroupAllTypes() { + PrepareBuilder(); + result.hasOptionalGroupAllTypes = false; + result.optionalGroupAllTypes_ = null; + return this; + } + } + static OptionalGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedGroup : pb::GeneratedMessageLite { + private RepeatedGroup() { } + private static readonly RepeatedGroup defaultInstance = new RepeatedGroup().MakeReadOnly(); + private static readonly string[] _repeatedGroupFieldNames = new string[] { "repeated_group_all_types" }; + private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 170 }; + public static RepeatedGroup DefaultInstance { + get { return defaultInstance; } + } + + public override RepeatedGroup DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override RepeatedGroup ThisMessage { + get { return this; } + } + + public const int RepeatedGroupAllTypesFieldNumber = 21; + private bool hasRepeatedGroupAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite repeatedGroupAllTypes_; + public bool HasRepeatedGroupAllTypes { + get { return hasRepeatedGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite RepeatedGroupAllTypes { + get { return repeatedGroupAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _repeatedGroupFieldNames; + if (hasRepeatedGroupAllTypes) { + output.WriteMessage(21, field_names[0], RepeatedGroupAllTypes); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasRepeatedGroupAllTypes) { + size += pb::CodedOutputStream.ComputeMessageSize(21, RepeatedGroupAllTypes); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasRepeatedGroupAllTypes) hash ^= repeatedGroupAllTypes_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + RepeatedGroup other = obj as RepeatedGroup; + if (other == null) return false; + if (hasRepeatedGroupAllTypes != other.hasRepeatedGroupAllTypes || (hasRepeatedGroupAllTypes && !repeatedGroupAllTypes_.Equals(other.repeatedGroupAllTypes_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("repeated_group_all_types", hasRepeatedGroupAllTypes, repeatedGroupAllTypes_, writer); + } + #endregion + + public static RepeatedGroup ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedGroup MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedGroup prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedGroup cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private RepeatedGroup result; + + private RepeatedGroup PrepareBuilder() { + if (resultIsReadOnly) { + RepeatedGroup original = result; + result = new RepeatedGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override RepeatedGroup MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override RepeatedGroup DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup.DefaultInstance; } + } + + public override RepeatedGroup BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is RepeatedGroup) { + return MergeFrom((RepeatedGroup) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(RepeatedGroup other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasRepeatedGroupAllTypes) { + MergeRepeatedGroupAllTypes(other.RepeatedGroupAllTypes); + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _repeatedGroupFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 170: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(); + if (result.hasRepeatedGroupAllTypes) { + subBuilder.MergeFrom(RepeatedGroupAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + RepeatedGroupAllTypes = subBuilder.BuildPartial(); + break; + } + } + } + + return this; + } + + + public bool HasRepeatedGroupAllTypes { + get { return result.hasRepeatedGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite RepeatedGroupAllTypes { + get { return result.RepeatedGroupAllTypes; } + set { SetRepeatedGroupAllTypes(value); } + } + public Builder SetRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasRepeatedGroupAllTypes = true; + result.repeatedGroupAllTypes_ = value; + return this; + } + public Builder SetRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasRepeatedGroupAllTypes = true; + result.repeatedGroupAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasRepeatedGroupAllTypes && + result.repeatedGroupAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance) { + result.repeatedGroupAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(result.repeatedGroupAllTypes_).MergeFrom(value).BuildPartial(); + } else { + result.repeatedGroupAllTypes_ = value; + } + result.hasRepeatedGroupAllTypes = true; + return this; + } + public Builder ClearRepeatedGroupAllTypes() { + PrepareBuilder(); + result.hasRepeatedGroupAllTypes = false; + result.repeatedGroupAllTypes_ = null; + return this; + } + } + static RepeatedGroup() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + } + #endregion + + public const int RequiredAllTypesFieldNumber = 1; + private bool hasRequiredAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite requiredAllTypes_; + public bool HasRequiredAllTypes { + get { return hasRequiredAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite RequiredAllTypes { + get { return requiredAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance; } + } + + public const int OptionalAllTypesFieldNumber = 2; + private bool hasOptionalAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite optionalAllTypes_; + public bool HasOptionalAllTypes { + get { return hasOptionalAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite OptionalAllTypes { + get { return optionalAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance; } + } + + public const int RepeatedAllTypesFieldNumber = 3; + private pbc::PopsicleList repeatedAllTypes_ = new pbc::PopsicleList(); + public scg::IList RepeatedAllTypesList { + get { return repeatedAllTypes_; } + } + public int RepeatedAllTypesCount { + get { return repeatedAllTypes_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetRepeatedAllTypes(int index) { + return repeatedAllTypes_[index]; + } + + public const int OptionalGroupFieldNumber = 10; + private bool hasOptionalGroup; + private global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup optionalGroup_; + public bool HasOptionalGroup { + get { return hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup OptionalGroup { + get { return optionalGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup.DefaultInstance; } + } + + public const int RepeatedGroupFieldNumber = 20; + private pbc::PopsicleList repeatedGroup_ = new pbc::PopsicleList(); + public scg::IList RepeatedGroupList { + get { return repeatedGroup_; } + } + public int RepeatedGroupCount { + get { return repeatedGroup_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup GetRepeatedGroup(int index) { + return repeatedGroup_[index]; + } + + public override bool IsInitialized { + get { + if (!hasRequiredAllTypes) return false; + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testParsingMergeLiteFieldNames; + pb::ExtendableMessageLite.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + if (hasRequiredAllTypes) { + output.WriteMessage(1, field_names[4], RequiredAllTypes); + } + if (hasOptionalAllTypes) { + output.WriteMessage(2, field_names[0], OptionalAllTypes); + } + if (repeatedAllTypes_.Count > 0) { + output.WriteMessageArray(3, field_names[2], repeatedAllTypes_); + } + if (hasOptionalGroup) { + output.WriteGroup(10, field_names[1], OptionalGroup); + } + if (repeatedGroup_.Count > 0) { + output.WriteGroupArray(20, field_names[3], repeatedGroup_); + } + extensionWriter.WriteUntil(536870912, output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasRequiredAllTypes) { + size += pb::CodedOutputStream.ComputeMessageSize(1, RequiredAllTypes); + } + if (hasOptionalAllTypes) { + size += pb::CodedOutputStream.ComputeMessageSize(2, OptionalAllTypes); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite element in RepeatedAllTypesList) { + size += pb::CodedOutputStream.ComputeMessageSize(3, element); + } + if (hasOptionalGroup) { + size += pb::CodedOutputStream.ComputeGroupSize(10, OptionalGroup); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup element in RepeatedGroupList) { + size += pb::CodedOutputStream.ComputeGroupSize(20, element); + } + size += ExtensionsSerializedSize; + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasRequiredAllTypes) hash ^= requiredAllTypes_.GetHashCode(); + if (hasOptionalAllTypes) hash ^= optionalAllTypes_.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite i in repeatedAllTypes_) + hash ^= i.GetHashCode(); + if (hasOptionalGroup) hash ^= optionalGroup_.GetHashCode(); + foreach(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup i in repeatedGroup_) + hash ^= i.GetHashCode(); + hash ^= base.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestParsingMergeLite other = obj as TestParsingMergeLite; + if (other == null) return false; + if (hasRequiredAllTypes != other.hasRequiredAllTypes || (hasRequiredAllTypes && !requiredAllTypes_.Equals(other.requiredAllTypes_))) return false; + if (hasOptionalAllTypes != other.hasOptionalAllTypes || (hasOptionalAllTypes && !optionalAllTypes_.Equals(other.optionalAllTypes_))) return false; + if(repeatedAllTypes_.Count != other.repeatedAllTypes_.Count) return false; + for(int ix=0; ix < repeatedAllTypes_.Count; ix++) + if(!repeatedAllTypes_[ix].Equals(other.repeatedAllTypes_[ix])) return false; + if (hasOptionalGroup != other.hasOptionalGroup || (hasOptionalGroup && !optionalGroup_.Equals(other.optionalGroup_))) return false; + if(repeatedGroup_.Count != other.repeatedGroup_.Count) return false; + for(int ix=0; ix < repeatedGroup_.Count; ix++) + if(!repeatedGroup_[ix].Equals(other.repeatedGroup_[ix])) return false; + if (!base.Equals(other)) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("required_all_types", hasRequiredAllTypes, requiredAllTypes_, writer); + PrintField("optional_all_types", hasOptionalAllTypes, optionalAllTypes_, writer); + PrintField("repeated_all_types", repeatedAllTypes_, writer); + PrintField("OptionalGroup", hasOptionalGroup, optionalGroup_, writer); + PrintField("RepeatedGroup", repeatedGroup_, writer); + base.PrintTo(writer); + } + #endregion + + public static TestParsingMergeLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestParsingMergeLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestParsingMergeLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestParsingMergeLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestParsingMergeLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestParsingMergeLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestParsingMergeLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestParsingMergeLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestParsingMergeLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestParsingMergeLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestParsingMergeLite MakeReadOnly() { + repeatedAllTypes_.MakeReadOnly(); + repeatedGroup_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestParsingMergeLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestParsingMergeLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestParsingMergeLite result; + + private TestParsingMergeLite PrepareBuilder() { + if (resultIsReadOnly) { + TestParsingMergeLite original = result; + result = new TestParsingMergeLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestParsingMergeLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestParsingMergeLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.DefaultInstance; } + } + + public override TestParsingMergeLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestParsingMergeLite) { + return MergeFrom((TestParsingMergeLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestParsingMergeLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasRequiredAllTypes) { + MergeRequiredAllTypes(other.RequiredAllTypes); + } + if (other.HasOptionalAllTypes) { + MergeOptionalAllTypes(other.OptionalAllTypes); + } + if (other.repeatedAllTypes_.Count != 0) { + result.repeatedAllTypes_.Add(other.repeatedAllTypes_); + } + if (other.HasOptionalGroup) { + MergeOptionalGroup(other.OptionalGroup); + } + if (other.repeatedGroup_.Count != 0) { + result.repeatedGroup_.Add(other.repeatedGroup_); + } + this.MergeExtensionFields(other); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testParsingMergeLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testParsingMergeLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(); + if (result.hasRequiredAllTypes) { + subBuilder.MergeFrom(RequiredAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + RequiredAllTypes = subBuilder.BuildPartial(); + break; + } + case 18: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(); + if (result.hasOptionalAllTypes) { + subBuilder.MergeFrom(OptionalAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalAllTypes = subBuilder.BuildPartial(); + break; + } + case 26: { + input.ReadMessageArray(tag, field_name, result.repeatedAllTypes_, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance, extensionRegistry); + break; + } + case 83: { + global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup.CreateBuilder(); + if (result.hasOptionalGroup) { + subBuilder.MergeFrom(OptionalGroup); + } + input.ReadGroup(10, subBuilder, extensionRegistry); + OptionalGroup = subBuilder.BuildPartial(); + break; + } + case 163: { + input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup.DefaultInstance, extensionRegistry); + break; + } + } + } + + return this; + } + + + public bool HasRequiredAllTypes { + get { return result.hasRequiredAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite RequiredAllTypes { + get { return result.RequiredAllTypes; } + set { SetRequiredAllTypes(value); } + } + public Builder SetRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasRequiredAllTypes = true; + result.requiredAllTypes_ = value; + return this; + } + public Builder SetRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasRequiredAllTypes = true; + result.requiredAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasRequiredAllTypes && + result.requiredAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance) { + result.requiredAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(result.requiredAllTypes_).MergeFrom(value).BuildPartial(); + } else { + result.requiredAllTypes_ = value; + } + result.hasRequiredAllTypes = true; + return this; + } + public Builder ClearRequiredAllTypes() { + PrepareBuilder(); + result.hasRequiredAllTypes = false; + result.requiredAllTypes_ = null; + return this; + } + + public bool HasOptionalAllTypes { + get { return result.hasOptionalAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite OptionalAllTypes { + get { return result.OptionalAllTypes; } + set { SetOptionalAllTypes(value); } + } + public Builder SetOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalAllTypes = true; + result.optionalAllTypes_ = value; + return this; + } + public Builder SetOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalAllTypes = true; + result.optionalAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalAllTypes && + result.optionalAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.DefaultInstance) { + result.optionalAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.CreateBuilder(result.optionalAllTypes_).MergeFrom(value).BuildPartial(); + } else { + result.optionalAllTypes_ = value; + } + result.hasOptionalAllTypes = true; + return this; + } + public Builder ClearOptionalAllTypes() { + PrepareBuilder(); + result.hasOptionalAllTypes = false; + result.optionalAllTypes_ = null; + return this; + } + + public pbc::IPopsicleList RepeatedAllTypesList { + get { return PrepareBuilder().repeatedAllTypes_; } + } + public int RepeatedAllTypesCount { + get { return result.RepeatedAllTypesCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite GetRepeatedAllTypes(int index) { + return result.GetRepeatedAllTypes(index); + } + public Builder SetRepeatedAllTypes(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedAllTypes_[index] = value; + return this; + } + public Builder SetRepeatedAllTypes(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedAllTypes_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedAllTypes_.Add(value); + return this; + } + public Builder AddRepeatedAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypesLite.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedAllTypes_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedAllTypes(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedAllTypes_.Add(values); + return this; + } + public Builder ClearRepeatedAllTypes() { + PrepareBuilder(); + result.repeatedAllTypes_.Clear(); + return this; + } + + public bool HasOptionalGroup { + get { return result.hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup OptionalGroup { + get { return result.OptionalGroup; } + set { SetOptionalGroup(value); } + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = value; + return this; + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalGroup && + result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup.DefaultInstance) { + result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial(); + } else { + result.optionalGroup_ = value; + } + result.hasOptionalGroup = true; + return this; + } + public Builder ClearOptionalGroup() { + PrepareBuilder(); + result.hasOptionalGroup = false; + result.optionalGroup_ = null; + return this; + } + + public pbc::IPopsicleList RepeatedGroupList { + get { return PrepareBuilder().repeatedGroup_; } + } + public int RepeatedGroupCount { + get { return result.RepeatedGroupCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup GetRepeatedGroup(int index) { + return result.GetRepeatedGroup(index); + } + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_[index] = value; + return this; + } + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_.Add(value); + return this; + } + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMergeLite.Types.RepeatedGroup.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedGroup(scg::IEnumerable values) { + PrepareBuilder(); + result.repeatedGroup_.Add(values); + return this; + } + public Builder ClearRepeatedGroup() { + PrepareBuilder(); + result.repeatedGroup_.Clear(); + return this; + } + } + static TestParsingMergeLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestEmptyMessageLite : pb::GeneratedMessageLite { + private TestEmptyMessageLite() { } + private static readonly TestEmptyMessageLite defaultInstance = new TestEmptyMessageLite().MakeReadOnly(); + private static readonly string[] _testEmptyMessageLiteFieldNames = new string[] { }; + private static readonly uint[] _testEmptyMessageLiteFieldTags = new uint[] { }; + public static TestEmptyMessageLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestEmptyMessageLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestEmptyMessageLite ThisMessage { + get { return this; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testEmptyMessageLiteFieldNames; + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestEmptyMessageLite other = obj as TestEmptyMessageLite; + if (other == null) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + } + #endregion + + public static TestEmptyMessageLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessageLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessageLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessageLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestEmptyMessageLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestEmptyMessageLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessageLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestEmptyMessageLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestEmptyMessageLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestEmptyMessageLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestEmptyMessageLite result; + + private TestEmptyMessageLite PrepareBuilder() { + if (resultIsReadOnly) { + TestEmptyMessageLite original = result; + result = new TestEmptyMessageLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestEmptyMessageLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestEmptyMessageLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageLite.DefaultInstance; } + } + + public override TestEmptyMessageLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestEmptyMessageLite) { + return MergeFrom((TestEmptyMessageLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestEmptyMessageLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageLite.DefaultInstance) return this; + PrepareBuilder(); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testEmptyMessageLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + } + } + + return this; + } + + } + static TestEmptyMessageLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestEmptyMessageWithExtensionsLite : pb::ExtendableMessageLite { + private TestEmptyMessageWithExtensionsLite() { } + private static readonly TestEmptyMessageWithExtensionsLite defaultInstance = new TestEmptyMessageWithExtensionsLite().MakeReadOnly(); + private static readonly string[] _testEmptyMessageWithExtensionsLiteFieldNames = new string[] { }; + private static readonly uint[] _testEmptyMessageWithExtensionsLiteFieldTags = new uint[] { }; + public static TestEmptyMessageWithExtensionsLite DefaultInstance { + get { return defaultInstance; } + } + + public override TestEmptyMessageWithExtensionsLite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestEmptyMessageWithExtensionsLite ThisMessage { + get { return this; } + } + + public override bool IsInitialized { + get { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testEmptyMessageWithExtensionsLiteFieldNames; + pb::ExtendableMessageLite.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + hash ^= base.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestEmptyMessageWithExtensionsLite other = obj as TestEmptyMessageWithExtensionsLite; + if (other == null) return false; + if (!base.Equals(other)) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + base.PrintTo(writer); + } + #endregion + + public static TestEmptyMessageWithExtensionsLite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessageWithExtensionsLite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageWithExtensionsLite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessageWithExtensionsLite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageWithExtensionsLite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessageWithExtensionsLite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageWithExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestEmptyMessageWithExtensionsLite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestEmptyMessageWithExtensionsLite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessageWithExtensionsLite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestEmptyMessageWithExtensionsLite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestEmptyMessageWithExtensionsLite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestEmptyMessageWithExtensionsLite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestEmptyMessageWithExtensionsLite result; + + private TestEmptyMessageWithExtensionsLite PrepareBuilder() { + if (resultIsReadOnly) { + TestEmptyMessageWithExtensionsLite original = result; + result = new TestEmptyMessageWithExtensionsLite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestEmptyMessageWithExtensionsLite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestEmptyMessageWithExtensionsLite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensionsLite.DefaultInstance; } + } + + public override TestEmptyMessageWithExtensionsLite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestEmptyMessageWithExtensionsLite) { + return MergeFrom((TestEmptyMessageWithExtensionsLite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestEmptyMessageWithExtensionsLite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensionsLite.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageWithExtensionsLiteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testEmptyMessageWithExtensionsLiteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + } + } + + return this; + } + + } + static TestEmptyMessageWithExtensionsLite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLite.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestLiteImportsNonlite.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestLiteImportsNonlite.cs new file mode 100644 index 00000000..f39ae644 --- /dev/null +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestLiteImportsNonlite.cs @@ -0,0 +1,325 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/protobuf/unittest_lite_imports_nonlite.proto +#pragma warning disable 1591, 0612, 3021 +#region Designer generated code + +using pb = global::Google.ProtocolBuffers; +using pbc = global::Google.ProtocolBuffers.Collections; +using pbd = global::Google.ProtocolBuffers.Descriptors; +using scg = global::System.Collections.Generic; +namespace Google.ProtocolBuffers.TestProtos { + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class UnittestLiteImportsNonlite { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { + } + #endregion + #region Static variables + #endregion + #region Extensions + internal static readonly object Descriptor; + static UnittestLiteImportsNonlite() { + Descriptor = null; + } + #endregion + + } + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestLiteImportsNonlite : pb::GeneratedMessageLite { + private TestLiteImportsNonlite() { } + private static readonly TestLiteImportsNonlite defaultInstance = new TestLiteImportsNonlite().MakeReadOnly(); + private static readonly string[] _testLiteImportsNonliteFieldNames = new string[] { "message" }; + private static readonly uint[] _testLiteImportsNonliteFieldTags = new uint[] { 10 }; + public static TestLiteImportsNonlite DefaultInstance { + get { return defaultInstance; } + } + + public override TestLiteImportsNonlite DefaultInstanceForType { + get { return DefaultInstance; } + } + + protected override TestLiteImportsNonlite ThisMessage { + get { return this; } + } + + public const int MessageFieldNumber = 1; + private bool hasMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes message_; + public bool HasMessage { + get { return hasMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Message { + get { return message_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized { + get { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) { + CalcSerializedSize(); + string[] field_names = _testLiteImportsNonliteFieldNames; + if (hasMessage) { + output.WriteMessage(1, field_names[0], Message); + } + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize { + get { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasMessage) { + size += pb::CodedOutputStream.ComputeMessageSize(1, Message); + } + memoizedSerializedSize = size; + return size; + } + #region Lite runtime methods + public override int GetHashCode() { + int hash = GetType().GetHashCode(); + if (hasMessage) hash ^= message_.GetHashCode(); + return hash; + } + + public override bool Equals(object obj) { + TestLiteImportsNonlite other = obj as TestLiteImportsNonlite; + if (other == null) return false; + if (hasMessage != other.hasMessage || (hasMessage && !message_.Equals(other.message_))) return false; + return true; + } + + public override void PrintTo(global::System.IO.TextWriter writer) { + PrintField("message", hasMessage, message_, writer); + } + #endregion + + public static TestLiteImportsNonlite ParseFrom(pb::ByteString data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestLiteImportsNonlite ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestLiteImportsNonlite ParseFrom(byte[] data) { + return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestLiteImportsNonlite ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestLiteImportsNonlite ParseFrom(global::System.IO.Stream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestLiteImportsNonlite ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestLiteImportsNonlite ParseDelimitedFrom(global::System.IO.Stream input) { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestLiteImportsNonlite ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestLiteImportsNonlite ParseFrom(pb::ICodedInputStream input) { + return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestLiteImportsNonlite ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestLiteImportsNonlite MakeReadOnly() { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestLiteImportsNonlite prototype) { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilderLite { + protected override Builder ThisBuilder { + get { return this; } + } + public Builder() { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestLiteImportsNonlite cloneFrom) { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestLiteImportsNonlite result; + + private TestLiteImportsNonlite PrepareBuilder() { + if (resultIsReadOnly) { + TestLiteImportsNonlite original = result; + result = new TestLiteImportsNonlite(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized { + get { return result.IsInitialized; } + } + + protected override TestLiteImportsNonlite MessageBeingBuilt { + get { return PrepareBuilder(); } + } + + public override Builder Clear() { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() { + if (resultIsReadOnly) { + return new Builder(result); + } else { + return new Builder().MergeFrom(result); + } + } + + public override TestLiteImportsNonlite DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.TestLiteImportsNonlite.DefaultInstance; } + } + + public override TestLiteImportsNonlite BuildPartial() { + if (resultIsReadOnly) { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessageLite other) { + if (other is TestLiteImportsNonlite) { + return MergeFrom((TestLiteImportsNonlite) other); + } else { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestLiteImportsNonlite other) { + if (other == global::Google.ProtocolBuffers.TestProtos.TestLiteImportsNonlite.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasMessage) { + MergeMessage(other.Message); + } + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + PrepareBuilder(); + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) { + if(tag == 0 && field_name != null) { + int field_ordinal = global::System.Array.BinarySearch(_testLiteImportsNonliteFieldNames, field_name, global::System.StringComparer.Ordinal); + if(field_ordinal >= 0) + tag = _testLiteImportsNonliteFieldTags[field_ordinal]; + else { + ParseUnknownField(input, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) { + case 0: { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: { + if (pb::WireFormat.IsEndGroupTag(tag)) { + return this; + } + ParseUnknownField(input, extensionRegistry, tag, field_name); + break; + } + case 10: { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasMessage) { + subBuilder.MergeFrom(Message); + } + input.ReadMessage(subBuilder, extensionRegistry); + Message = subBuilder.BuildPartial(); + break; + } + } + } + + return this; + } + + + public bool HasMessage { + get { return result.hasMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Message { + get { return result.Message; } + set { SetMessage(value); } + } + public Builder SetMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasMessage = true; + result.message_ = value; + return this; + } + public Builder SetMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasMessage = true; + result.message_ = builderForValue.Build(); + return this; + } + public Builder MergeMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasMessage && + result.message_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { + result.message_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.message_).MergeFrom(value).BuildPartial(); + } else { + result.message_ = value; + } + result.hasMessage = true; + return this; + } + public Builder ClearMessage() { + PrepareBuilder(); + result.hasMessage = false; + result.message_ = null; + return this; + } + } + static TestLiteImportsNonlite() { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestLiteImportsNonlite.Descriptor, null); + } + } + + #endregion + +} + +#endregion Designer generated code -- cgit v1.2.3 From 5ca6dd76fb39d7f76297f6a2a95466bbc8d5b691 Mon Sep 17 00:00:00 2001 From: Jon Skeet Date: Tue, 28 Apr 2015 18:47:47 +0100 Subject: Update DescriptorProtoFile.cs and UnitTest.cs to indicate manual changes. (Having regenerated descriptor.proto relative to src, the earlier commented-out code checking that dependencies match may now be okay to uncomment again. Will experiment in later CLs.) --- .../ProtocolBuffers.Test/TestProtos/Unittest.cs | 3 + .../DescriptorProtos/DescriptorProtoFile.cs | 215 +- .../TestProtos/Unittest.cs | 71818 ++++++++++--------- 3 files changed, 39934 insertions(+), 32102 deletions(-) (limited to 'csharp/src/ProtocolBuffersLite.Test/TestProtos') diff --git a/csharp/src/ProtocolBuffers.Test/TestProtos/Unittest.cs b/csharp/src/ProtocolBuffers.Test/TestProtos/Unittest.cs index e828f7bf..d39c9345 100644 --- a/csharp/src/ProtocolBuffers.Test/TestProtos/Unittest.cs +++ b/csharp/src/ProtocolBuffers.Test/TestProtos/Unittest.cs @@ -1,3 +1,6 @@ +// Manual changes: +// - Search and replace of RepeatedFieldsGenerator.Group to RepeatedFieldsGenerator.Types.Group +// // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/protobuf/unittest.proto #pragma warning disable 1591, 0612, 3021 diff --git a/csharp/src/ProtocolBuffers/DescriptorProtos/DescriptorProtoFile.cs b/csharp/src/ProtocolBuffers/DescriptorProtos/DescriptorProtoFile.cs index 69310a2f..b6a099ed 100644 --- a/csharp/src/ProtocolBuffers/DescriptorProtos/DescriptorProtoFile.cs +++ b/csharp/src/ProtocolBuffers/DescriptorProtos/DescriptorProtoFile.cs @@ -1,5 +1,9 @@ +// Manual changes: +// - renamed class to DescriptorProtoFile +// - renamed file to DescriptorProtoFile.cs +// // Generated by the protocol buffer compiler. DO NOT EDIT! -// source: descriptor.proto +// source: google/protobuf/descriptor.proto #pragma warning disable 1591, 0612, 3021 #region Designer generated code @@ -60,7 +64,7 @@ namespace Google.ProtocolBuffers.DescriptorProtos { internal static pbd::MessageDescriptor internal__static_google_protobuf_SourceCodeInfo_Location__Descriptor; internal static pb::FieldAccess.FieldAccessorTable internal__static_google_protobuf_SourceCodeInfo_Location__FieldAccessorTable; #endregion - #region DescriptorProtoFile + #region Descriptor public static pbd::FileDescriptor Descriptor { get { return descriptor; } } @@ -69,110 +73,111 @@ namespace Google.ProtocolBuffers.DescriptorProtos { static DescriptorProtoFile() { byte[] descriptorData = global::System.Convert.FromBase64String( string.Concat( - "ChBkZXNjcmlwdG9yLnByb3RvEg9nb29nbGUucHJvdG9idWYiRwoRRmlsZURl", - "c2NyaXB0b3JTZXQSMgoEZmlsZRgBIAMoCzIkLmdvb2dsZS5wcm90b2J1Zi5G", - "aWxlRGVzY3JpcHRvclByb3RvItsDChNGaWxlRGVzY3JpcHRvclByb3RvEgwK", - "BG5hbWUYASABKAkSDwoHcGFja2FnZRgCIAEoCRISCgpkZXBlbmRlbmN5GAMg", - "AygJEhkKEXB1YmxpY19kZXBlbmRlbmN5GAogAygFEhcKD3dlYWtfZGVwZW5k", - "ZW5jeRgLIAMoBRI2CgxtZXNzYWdlX3R5cGUYBCADKAsyIC5nb29nbGUucHJv", - "dG9idWYuRGVzY3JpcHRvclByb3RvEjcKCWVudW1fdHlwZRgFIAMoCzIkLmdv", - "b2dsZS5wcm90b2J1Zi5FbnVtRGVzY3JpcHRvclByb3RvEjgKB3NlcnZpY2UY", - "BiADKAsyJy5nb29nbGUucHJvdG9idWYuU2VydmljZURlc2NyaXB0b3JQcm90", - "bxI4CglleHRlbnNpb24YByADKAsyJS5nb29nbGUucHJvdG9idWYuRmllbGRE", - "ZXNjcmlwdG9yUHJvdG8SLQoHb3B0aW9ucxgIIAEoCzIcLmdvb2dsZS5wcm90", - "b2J1Zi5GaWxlT3B0aW9ucxI5ChBzb3VyY2VfY29kZV9pbmZvGAkgASgLMh8u", - "Z29vZ2xlLnByb3RvYnVmLlNvdXJjZUNvZGVJbmZvEg4KBnN5bnRheBgMIAEo", - "CSLkAwoPRGVzY3JpcHRvclByb3RvEgwKBG5hbWUYASABKAkSNAoFZmllbGQY", - "AiADKAsyJS5nb29nbGUucHJvdG9idWYuRmllbGREZXNjcmlwdG9yUHJvdG8S", - "OAoJZXh0ZW5zaW9uGAYgAygLMiUuZ29vZ2xlLnByb3RvYnVmLkZpZWxkRGVz", - "Y3JpcHRvclByb3RvEjUKC25lc3RlZF90eXBlGAMgAygLMiAuZ29vZ2xlLnBy", - "b3RvYnVmLkRlc2NyaXB0b3JQcm90bxI3CgllbnVtX3R5cGUYBCADKAsyJC5n", - "b29nbGUucHJvdG9idWYuRW51bURlc2NyaXB0b3JQcm90bxJICg9leHRlbnNp", - "b25fcmFuZ2UYBSADKAsyLy5nb29nbGUucHJvdG9idWYuRGVzY3JpcHRvclBy", - "b3RvLkV4dGVuc2lvblJhbmdlEjkKCm9uZW9mX2RlY2wYCCADKAsyJS5nb29n", - "bGUucHJvdG9idWYuT25lb2ZEZXNjcmlwdG9yUHJvdG8SMAoHb3B0aW9ucxgH", - "IAEoCzIfLmdvb2dsZS5wcm90b2J1Zi5NZXNzYWdlT3B0aW9ucxosCg5FeHRl", - "bnNpb25SYW5nZRINCgVzdGFydBgBIAEoBRILCgNlbmQYAiABKAUiqQUKFEZp", - "ZWxkRGVzY3JpcHRvclByb3RvEgwKBG5hbWUYASABKAkSDgoGbnVtYmVyGAMg", - "ASgFEjoKBWxhYmVsGAQgASgOMisuZ29vZ2xlLnByb3RvYnVmLkZpZWxkRGVz", - "Y3JpcHRvclByb3RvLkxhYmVsEjgKBHR5cGUYBSABKA4yKi5nb29nbGUucHJv", - "dG9idWYuRmllbGREZXNjcmlwdG9yUHJvdG8uVHlwZRIRCgl0eXBlX25hbWUY", - "BiABKAkSEAoIZXh0ZW5kZWUYAiABKAkSFQoNZGVmYXVsdF92YWx1ZRgHIAEo", - "CRITCgtvbmVvZl9pbmRleBgJIAEoBRIuCgdvcHRpb25zGAggASgLMh0uZ29v", - "Z2xlLnByb3RvYnVmLkZpZWxkT3B0aW9ucyK2AgoEVHlwZRIPCgtUWVBFX0RP", - "VUJMRRABEg4KClRZUEVfRkxPQVQQAhIOCgpUWVBFX0lOVDY0EAMSDwoLVFlQ", - "RV9VSU5UNjQQBBIOCgpUWVBFX0lOVDMyEAUSEAoMVFlQRV9GSVhFRDY0EAYS", - "EAoMVFlQRV9GSVhFRDMyEAcSDQoJVFlQRV9CT09MEAgSDwoLVFlQRV9TVFJJ", - "TkcQCRIOCgpUWVBFX0dST1VQEAoSEAoMVFlQRV9NRVNTQUdFEAsSDgoKVFlQ", - "RV9CWVRFUxAMEg8KC1RZUEVfVUlOVDMyEA0SDQoJVFlQRV9FTlVNEA4SEQoN", - "VFlQRV9TRklYRUQzMhAPEhEKDVRZUEVfU0ZJWEVENjQQEBIPCgtUWVBFX1NJ", - "TlQzMhAREg8KC1RZUEVfU0lOVDY0EBIiQwoFTGFiZWwSEgoOTEFCRUxfT1BU", - "SU9OQUwQARISCg5MQUJFTF9SRVFVSVJFRBACEhIKDkxBQkVMX1JFUEVBVEVE", - "EAMiJAoUT25lb2ZEZXNjcmlwdG9yUHJvdG8SDAoEbmFtZRgBIAEoCSKMAQoT", - "RW51bURlc2NyaXB0b3JQcm90bxIMCgRuYW1lGAEgASgJEjgKBXZhbHVlGAIg", - "AygLMikuZ29vZ2xlLnByb3RvYnVmLkVudW1WYWx1ZURlc2NyaXB0b3JQcm90", - "bxItCgdvcHRpb25zGAMgASgLMhwuZ29vZ2xlLnByb3RvYnVmLkVudW1PcHRp", - "b25zImwKGEVudW1WYWx1ZURlc2NyaXB0b3JQcm90bxIMCgRuYW1lGAEgASgJ", - "Eg4KBm51bWJlchgCIAEoBRIyCgdvcHRpb25zGAMgASgLMiEuZ29vZ2xlLnBy", - "b3RvYnVmLkVudW1WYWx1ZU9wdGlvbnMikAEKFlNlcnZpY2VEZXNjcmlwdG9y", - "UHJvdG8SDAoEbmFtZRgBIAEoCRI2CgZtZXRob2QYAiADKAsyJi5nb29nbGUu", - "cHJvdG9idWYuTWV0aG9kRGVzY3JpcHRvclByb3RvEjAKB29wdGlvbnMYAyAB", - "KAsyHy5nb29nbGUucHJvdG9idWYuU2VydmljZU9wdGlvbnMiwQEKFU1ldGhv", - "ZERlc2NyaXB0b3JQcm90bxIMCgRuYW1lGAEgASgJEhIKCmlucHV0X3R5cGUY", - "AiABKAkSEwoLb3V0cHV0X3R5cGUYAyABKAkSLwoHb3B0aW9ucxgEIAEoCzIe", - "Lmdvb2dsZS5wcm90b2J1Zi5NZXRob2RPcHRpb25zEh8KEGNsaWVudF9zdHJl", - "YW1pbmcYBSABKAg6BWZhbHNlEh8KEHNlcnZlcl9zdHJlYW1pbmcYBiABKAg6", - "BWZhbHNlIoEFCgtGaWxlT3B0aW9ucxIUCgxqYXZhX3BhY2thZ2UYASABKAkS", - "HAoUamF2YV9vdXRlcl9jbGFzc25hbWUYCCABKAkSIgoTamF2YV9tdWx0aXBs", - "ZV9maWxlcxgKIAEoCDoFZmFsc2USLAodamF2YV9nZW5lcmF0ZV9lcXVhbHNf", - "YW5kX2hhc2gYFCABKAg6BWZhbHNlEiUKFmphdmFfc3RyaW5nX2NoZWNrX3V0", - "ZjgYGyABKAg6BWZhbHNlEkYKDG9wdGltaXplX2ZvchgJIAEoDjIpLmdvb2ds", - "ZS5wcm90b2J1Zi5GaWxlT3B0aW9ucy5PcHRpbWl6ZU1vZGU6BVNQRUVEEhIK", - "CmdvX3BhY2thZ2UYCyABKAkSIgoTY2NfZ2VuZXJpY19zZXJ2aWNlcxgQIAEo", - "CDoFZmFsc2USJAoVamF2YV9nZW5lcmljX3NlcnZpY2VzGBEgASgIOgVmYWxz", - "ZRIiChNweV9nZW5lcmljX3NlcnZpY2VzGBIgASgIOgVmYWxzZRIZCgpkZXBy", - "ZWNhdGVkGBcgASgIOgVmYWxzZRIfChBjY19lbmFibGVfYXJlbmFzGB8gASgI", - "OgVmYWxzZRIZChFvYmpjX2NsYXNzX3ByZWZpeBgkIAEoCRIYChBjc2hhcnBf", - "bmFtZXNwYWNlGCUgASgJEkMKFHVuaW50ZXJwcmV0ZWRfb3B0aW9uGOcHIAMo", - "CzIkLmdvb2dsZS5wcm90b2J1Zi5VbmludGVycHJldGVkT3B0aW9uIjoKDE9w", - "dGltaXplTW9kZRIJCgVTUEVFRBABEg0KCUNPREVfU0laRRACEhAKDExJVEVf", - "UlVOVElNRRADKgkI6AcQgICAgAIi5gEKDk1lc3NhZ2VPcHRpb25zEiYKF21l", - "c3NhZ2Vfc2V0X3dpcmVfZm9ybWF0GAEgASgIOgVmYWxzZRIuCh9ub19zdGFu", - "ZGFyZF9kZXNjcmlwdG9yX2FjY2Vzc29yGAIgASgIOgVmYWxzZRIZCgpkZXBy", - "ZWNhdGVkGAMgASgIOgVmYWxzZRIRCgltYXBfZW50cnkYByABKAgSQwoUdW5p", - "bnRlcnByZXRlZF9vcHRpb24Y5wcgAygLMiQuZ29vZ2xlLnByb3RvYnVmLlVu", - "aW50ZXJwcmV0ZWRPcHRpb24qCQjoBxCAgICAAiKgAgoMRmllbGRPcHRpb25z", - "EjoKBWN0eXBlGAEgASgOMiMuZ29vZ2xlLnByb3RvYnVmLkZpZWxkT3B0aW9u", - "cy5DVHlwZToGU1RSSU5HEg4KBnBhY2tlZBgCIAEoCBITCgRsYXp5GAUgASgI", - "OgVmYWxzZRIZCgpkZXByZWNhdGVkGAMgASgIOgVmYWxzZRITCgR3ZWFrGAog", - "ASgIOgVmYWxzZRJDChR1bmludGVycHJldGVkX29wdGlvbhjnByADKAsyJC5n", - "b29nbGUucHJvdG9idWYuVW5pbnRlcnByZXRlZE9wdGlvbiIvCgVDVHlwZRIK", - "CgZTVFJJTkcQABIICgRDT1JEEAESEAoMU1RSSU5HX1BJRUNFEAIqCQjoBxCA", - "gICAAiKNAQoLRW51bU9wdGlvbnMSEwoLYWxsb3dfYWxpYXMYAiABKAgSGQoK", - "ZGVwcmVjYXRlZBgDIAEoCDoFZmFsc2USQwoUdW5pbnRlcnByZXRlZF9vcHRp", - "b24Y5wcgAygLMiQuZ29vZ2xlLnByb3RvYnVmLlVuaW50ZXJwcmV0ZWRPcHRp", - "b24qCQjoBxCAgICAAiJ9ChBFbnVtVmFsdWVPcHRpb25zEhkKCmRlcHJlY2F0", - "ZWQYASABKAg6BWZhbHNlEkMKFHVuaW50ZXJwcmV0ZWRfb3B0aW9uGOcHIAMo", - "CzIkLmdvb2dsZS5wcm90b2J1Zi5VbmludGVycHJldGVkT3B0aW9uKgkI6AcQ", - "gICAgAIiewoOU2VydmljZU9wdGlvbnMSGQoKZGVwcmVjYXRlZBghIAEoCDoF", - "ZmFsc2USQwoUdW5pbnRlcnByZXRlZF9vcHRpb24Y5wcgAygLMiQuZ29vZ2xl", - "LnByb3RvYnVmLlVuaW50ZXJwcmV0ZWRPcHRpb24qCQjoBxCAgICAAiJ6Cg1N", - "ZXRob2RPcHRpb25zEhkKCmRlcHJlY2F0ZWQYISABKAg6BWZhbHNlEkMKFHVu", + "CiBnb29nbGUvcHJvdG9idWYvZGVzY3JpcHRvci5wcm90bxIPZ29vZ2xlLnBy", + "b3RvYnVmIkcKEUZpbGVEZXNjcmlwdG9yU2V0EjIKBGZpbGUYASADKAsyJC5n", + "b29nbGUucHJvdG9idWYuRmlsZURlc2NyaXB0b3JQcm90byLbAwoTRmlsZURl", + "c2NyaXB0b3JQcm90bxIMCgRuYW1lGAEgASgJEg8KB3BhY2thZ2UYAiABKAkS", + "EgoKZGVwZW5kZW5jeRgDIAMoCRIZChFwdWJsaWNfZGVwZW5kZW5jeRgKIAMo", + "BRIXCg93ZWFrX2RlcGVuZGVuY3kYCyADKAUSNgoMbWVzc2FnZV90eXBlGAQg", + "AygLMiAuZ29vZ2xlLnByb3RvYnVmLkRlc2NyaXB0b3JQcm90bxI3CgllbnVt", + "X3R5cGUYBSADKAsyJC5nb29nbGUucHJvdG9idWYuRW51bURlc2NyaXB0b3JQ", + "cm90bxI4CgdzZXJ2aWNlGAYgAygLMicuZ29vZ2xlLnByb3RvYnVmLlNlcnZp", + "Y2VEZXNjcmlwdG9yUHJvdG8SOAoJZXh0ZW5zaW9uGAcgAygLMiUuZ29vZ2xl", + "LnByb3RvYnVmLkZpZWxkRGVzY3JpcHRvclByb3RvEi0KB29wdGlvbnMYCCAB", + "KAsyHC5nb29nbGUucHJvdG9idWYuRmlsZU9wdGlvbnMSOQoQc291cmNlX2Nv", + "ZGVfaW5mbxgJIAEoCzIfLmdvb2dsZS5wcm90b2J1Zi5Tb3VyY2VDb2RlSW5m", + "bxIOCgZzeW50YXgYDCABKAki5AMKD0Rlc2NyaXB0b3JQcm90bxIMCgRuYW1l", + "GAEgASgJEjQKBWZpZWxkGAIgAygLMiUuZ29vZ2xlLnByb3RvYnVmLkZpZWxk", + "RGVzY3JpcHRvclByb3RvEjgKCWV4dGVuc2lvbhgGIAMoCzIlLmdvb2dsZS5w", + "cm90b2J1Zi5GaWVsZERlc2NyaXB0b3JQcm90bxI1CgtuZXN0ZWRfdHlwZRgD", + "IAMoCzIgLmdvb2dsZS5wcm90b2J1Zi5EZXNjcmlwdG9yUHJvdG8SNwoJZW51", + "bV90eXBlGAQgAygLMiQuZ29vZ2xlLnByb3RvYnVmLkVudW1EZXNjcmlwdG9y", + "UHJvdG8SSAoPZXh0ZW5zaW9uX3JhbmdlGAUgAygLMi8uZ29vZ2xlLnByb3Rv", + "YnVmLkRlc2NyaXB0b3JQcm90by5FeHRlbnNpb25SYW5nZRI5CgpvbmVvZl9k", + "ZWNsGAggAygLMiUuZ29vZ2xlLnByb3RvYnVmLk9uZW9mRGVzY3JpcHRvclBy", + "b3RvEjAKB29wdGlvbnMYByABKAsyHy5nb29nbGUucHJvdG9idWYuTWVzc2Fn", + "ZU9wdGlvbnMaLAoORXh0ZW5zaW9uUmFuZ2USDQoFc3RhcnQYASABKAUSCwoD", + "ZW5kGAIgASgFIqkFChRGaWVsZERlc2NyaXB0b3JQcm90bxIMCgRuYW1lGAEg", + "ASgJEg4KBm51bWJlchgDIAEoBRI6CgVsYWJlbBgEIAEoDjIrLmdvb2dsZS5w", + "cm90b2J1Zi5GaWVsZERlc2NyaXB0b3JQcm90by5MYWJlbBI4CgR0eXBlGAUg", + "ASgOMiouZ29vZ2xlLnByb3RvYnVmLkZpZWxkRGVzY3JpcHRvclByb3RvLlR5", + "cGUSEQoJdHlwZV9uYW1lGAYgASgJEhAKCGV4dGVuZGVlGAIgASgJEhUKDWRl", + "ZmF1bHRfdmFsdWUYByABKAkSEwoLb25lb2ZfaW5kZXgYCSABKAUSLgoHb3B0", + "aW9ucxgIIAEoCzIdLmdvb2dsZS5wcm90b2J1Zi5GaWVsZE9wdGlvbnMitgIK", + "BFR5cGUSDwoLVFlQRV9ET1VCTEUQARIOCgpUWVBFX0ZMT0FUEAISDgoKVFlQ", + "RV9JTlQ2NBADEg8KC1RZUEVfVUlOVDY0EAQSDgoKVFlQRV9JTlQzMhAFEhAK", + "DFRZUEVfRklYRUQ2NBAGEhAKDFRZUEVfRklYRUQzMhAHEg0KCVRZUEVfQk9P", + "TBAIEg8KC1RZUEVfU1RSSU5HEAkSDgoKVFlQRV9HUk9VUBAKEhAKDFRZUEVf", + "TUVTU0FHRRALEg4KClRZUEVfQllURVMQDBIPCgtUWVBFX1VJTlQzMhANEg0K", + "CVRZUEVfRU5VTRAOEhEKDVRZUEVfU0ZJWEVEMzIQDxIRCg1UWVBFX1NGSVhF", + "RDY0EBASDwoLVFlQRV9TSU5UMzIQERIPCgtUWVBFX1NJTlQ2NBASIkMKBUxh", + "YmVsEhIKDkxBQkVMX09QVElPTkFMEAESEgoOTEFCRUxfUkVRVUlSRUQQAhIS", + "Cg5MQUJFTF9SRVBFQVRFRBADIiQKFE9uZW9mRGVzY3JpcHRvclByb3RvEgwK", + "BG5hbWUYASABKAkijAEKE0VudW1EZXNjcmlwdG9yUHJvdG8SDAoEbmFtZRgB", + "IAEoCRI4CgV2YWx1ZRgCIAMoCzIpLmdvb2dsZS5wcm90b2J1Zi5FbnVtVmFs", + "dWVEZXNjcmlwdG9yUHJvdG8SLQoHb3B0aW9ucxgDIAEoCzIcLmdvb2dsZS5w", + "cm90b2J1Zi5FbnVtT3B0aW9ucyJsChhFbnVtVmFsdWVEZXNjcmlwdG9yUHJv", + "dG8SDAoEbmFtZRgBIAEoCRIOCgZudW1iZXIYAiABKAUSMgoHb3B0aW9ucxgD", + "IAEoCzIhLmdvb2dsZS5wcm90b2J1Zi5FbnVtVmFsdWVPcHRpb25zIpABChZT", + "ZXJ2aWNlRGVzY3JpcHRvclByb3RvEgwKBG5hbWUYASABKAkSNgoGbWV0aG9k", + "GAIgAygLMiYuZ29vZ2xlLnByb3RvYnVmLk1ldGhvZERlc2NyaXB0b3JQcm90", + "bxIwCgdvcHRpb25zGAMgASgLMh8uZ29vZ2xlLnByb3RvYnVmLlNlcnZpY2VP", + "cHRpb25zIsEBChVNZXRob2REZXNjcmlwdG9yUHJvdG8SDAoEbmFtZRgBIAEo", + "CRISCgppbnB1dF90eXBlGAIgASgJEhMKC291dHB1dF90eXBlGAMgASgJEi8K", + "B29wdGlvbnMYBCABKAsyHi5nb29nbGUucHJvdG9idWYuTWV0aG9kT3B0aW9u", + "cxIfChBjbGllbnRfc3RyZWFtaW5nGAUgASgIOgVmYWxzZRIfChBzZXJ2ZXJf", + "c3RyZWFtaW5nGAYgASgIOgVmYWxzZSKBBQoLRmlsZU9wdGlvbnMSFAoMamF2", + "YV9wYWNrYWdlGAEgASgJEhwKFGphdmFfb3V0ZXJfY2xhc3NuYW1lGAggASgJ", + "EiIKE2phdmFfbXVsdGlwbGVfZmlsZXMYCiABKAg6BWZhbHNlEiwKHWphdmFf", + "Z2VuZXJhdGVfZXF1YWxzX2FuZF9oYXNoGBQgASgIOgVmYWxzZRIlChZqYXZh", + "X3N0cmluZ19jaGVja191dGY4GBsgASgIOgVmYWxzZRJGCgxvcHRpbWl6ZV9m", + "b3IYCSABKA4yKS5nb29nbGUucHJvdG9idWYuRmlsZU9wdGlvbnMuT3B0aW1p", + "emVNb2RlOgVTUEVFRBISCgpnb19wYWNrYWdlGAsgASgJEiIKE2NjX2dlbmVy", + "aWNfc2VydmljZXMYECABKAg6BWZhbHNlEiQKFWphdmFfZ2VuZXJpY19zZXJ2", + "aWNlcxgRIAEoCDoFZmFsc2USIgoTcHlfZ2VuZXJpY19zZXJ2aWNlcxgSIAEo", + "CDoFZmFsc2USGQoKZGVwcmVjYXRlZBgXIAEoCDoFZmFsc2USHwoQY2NfZW5h", + "YmxlX2FyZW5hcxgfIAEoCDoFZmFsc2USGQoRb2JqY19jbGFzc19wcmVmaXgY", + "JCABKAkSGAoQY3NoYXJwX25hbWVzcGFjZRglIAEoCRJDChR1bmludGVycHJl", + "dGVkX29wdGlvbhjnByADKAsyJC5nb29nbGUucHJvdG9idWYuVW5pbnRlcnBy", + "ZXRlZE9wdGlvbiI6CgxPcHRpbWl6ZU1vZGUSCQoFU1BFRUQQARINCglDT0RF", + "X1NJWkUQAhIQCgxMSVRFX1JVTlRJTUUQAyoJCOgHEICAgIACIuYBCg5NZXNz", + "YWdlT3B0aW9ucxImChdtZXNzYWdlX3NldF93aXJlX2Zvcm1hdBgBIAEoCDoF", + "ZmFsc2USLgofbm9fc3RhbmRhcmRfZGVzY3JpcHRvcl9hY2Nlc3NvchgCIAEo", + "CDoFZmFsc2USGQoKZGVwcmVjYXRlZBgDIAEoCDoFZmFsc2USEQoJbWFwX2Vu", + "dHJ5GAcgASgIEkMKFHVuaW50ZXJwcmV0ZWRfb3B0aW9uGOcHIAMoCzIkLmdv", + "b2dsZS5wcm90b2J1Zi5VbmludGVycHJldGVkT3B0aW9uKgkI6AcQgICAgAIi", + "oAIKDEZpZWxkT3B0aW9ucxI6CgVjdHlwZRgBIAEoDjIjLmdvb2dsZS5wcm90", + "b2J1Zi5GaWVsZE9wdGlvbnMuQ1R5cGU6BlNUUklORxIOCgZwYWNrZWQYAiAB", + "KAgSEwoEbGF6eRgFIAEoCDoFZmFsc2USGQoKZGVwcmVjYXRlZBgDIAEoCDoF", + "ZmFsc2USEwoEd2VhaxgKIAEoCDoFZmFsc2USQwoUdW5pbnRlcnByZXRlZF9v", + "cHRpb24Y5wcgAygLMiQuZ29vZ2xlLnByb3RvYnVmLlVuaW50ZXJwcmV0ZWRP", + "cHRpb24iLwoFQ1R5cGUSCgoGU1RSSU5HEAASCAoEQ09SRBABEhAKDFNUUklO", + "R19QSUVDRRACKgkI6AcQgICAgAIijQEKC0VudW1PcHRpb25zEhMKC2FsbG93", + "X2FsaWFzGAIgASgIEhkKCmRlcHJlY2F0ZWQYAyABKAg6BWZhbHNlEkMKFHVu", "aW50ZXJwcmV0ZWRfb3B0aW9uGOcHIAMoCzIkLmdvb2dsZS5wcm90b2J1Zi5V", - "bmludGVycHJldGVkT3B0aW9uKgkI6AcQgICAgAIingIKE1VuaW50ZXJwcmV0", - "ZWRPcHRpb24SOwoEbmFtZRgCIAMoCzItLmdvb2dsZS5wcm90b2J1Zi5Vbmlu", - "dGVycHJldGVkT3B0aW9uLk5hbWVQYXJ0EhgKEGlkZW50aWZpZXJfdmFsdWUY", - "AyABKAkSGgoScG9zaXRpdmVfaW50X3ZhbHVlGAQgASgEEhoKEm5lZ2F0aXZl", - "X2ludF92YWx1ZRgFIAEoAxIUCgxkb3VibGVfdmFsdWUYBiABKAESFAoMc3Ry", - "aW5nX3ZhbHVlGAcgASgMEhcKD2FnZ3JlZ2F0ZV92YWx1ZRgIIAEoCRozCghO", - "YW1lUGFydBIRCgluYW1lX3BhcnQYASACKAkSFAoMaXNfZXh0ZW5zaW9uGAIg", - "AigIItUBCg5Tb3VyY2VDb2RlSW5mbxI6Cghsb2NhdGlvbhgBIAMoCzIoLmdv", - "b2dsZS5wcm90b2J1Zi5Tb3VyY2VDb2RlSW5mby5Mb2NhdGlvbhqGAQoITG9j", - "YXRpb24SEAoEcGF0aBgBIAMoBUICEAESEAoEc3BhbhgCIAMoBUICEAESGAoQ", - "bGVhZGluZ19jb21tZW50cxgDIAEoCRIZChF0cmFpbGluZ19jb21tZW50cxgE", - "IAEoCRIhChlsZWFkaW5nX2RldGFjaGVkX2NvbW1lbnRzGAYgAygJQlMKE2Nv", - "bS5nb29nbGUucHJvdG9idWZCEERlc2NyaXB0b3JQcm90b3NIAaoCJ0dvb2ds", - "ZS5Qcm90b2NvbEJ1ZmZlcnMuRGVzY3JpcHRvclByb3Rvcw==")); + "bmludGVycHJldGVkT3B0aW9uKgkI6AcQgICAgAIifQoQRW51bVZhbHVlT3B0", + "aW9ucxIZCgpkZXByZWNhdGVkGAEgASgIOgVmYWxzZRJDChR1bmludGVycHJl", + "dGVkX29wdGlvbhjnByADKAsyJC5nb29nbGUucHJvdG9idWYuVW5pbnRlcnBy", + "ZXRlZE9wdGlvbioJCOgHEICAgIACInsKDlNlcnZpY2VPcHRpb25zEhkKCmRl", + "cHJlY2F0ZWQYISABKAg6BWZhbHNlEkMKFHVuaW50ZXJwcmV0ZWRfb3B0aW9u", + "GOcHIAMoCzIkLmdvb2dsZS5wcm90b2J1Zi5VbmludGVycHJldGVkT3B0aW9u", + "KgkI6AcQgICAgAIiegoNTWV0aG9kT3B0aW9ucxIZCgpkZXByZWNhdGVkGCEg", + "ASgIOgVmYWxzZRJDChR1bmludGVycHJldGVkX29wdGlvbhjnByADKAsyJC5n", + "b29nbGUucHJvdG9idWYuVW5pbnRlcnByZXRlZE9wdGlvbioJCOgHEICAgIAC", + "Ip4CChNVbmludGVycHJldGVkT3B0aW9uEjsKBG5hbWUYAiADKAsyLS5nb29n", + "bGUucHJvdG9idWYuVW5pbnRlcnByZXRlZE9wdGlvbi5OYW1lUGFydBIYChBp", + "ZGVudGlmaWVyX3ZhbHVlGAMgASgJEhoKEnBvc2l0aXZlX2ludF92YWx1ZRgE", + "IAEoBBIaChJuZWdhdGl2ZV9pbnRfdmFsdWUYBSABKAMSFAoMZG91YmxlX3Zh", + "bHVlGAYgASgBEhQKDHN0cmluZ192YWx1ZRgHIAEoDBIXCg9hZ2dyZWdhdGVf", + "dmFsdWUYCCABKAkaMwoITmFtZVBhcnQSEQoJbmFtZV9wYXJ0GAEgAigJEhQK", + "DGlzX2V4dGVuc2lvbhgCIAIoCCLVAQoOU291cmNlQ29kZUluZm8SOgoIbG9j", + "YXRpb24YASADKAsyKC5nb29nbGUucHJvdG9idWYuU291cmNlQ29kZUluZm8u", + "TG9jYXRpb24ahgEKCExvY2F0aW9uEhAKBHBhdGgYASADKAVCAhABEhAKBHNw", + "YW4YAiADKAVCAhABEhgKEGxlYWRpbmdfY29tbWVudHMYAyABKAkSGQoRdHJh", + "aWxpbmdfY29tbWVudHMYBCABKAkSIQoZbGVhZGluZ19kZXRhY2hlZF9jb21t", + "ZW50cxgGIAMoCUJTChNjb20uZ29vZ2xlLnByb3RvYnVmQhBEZXNjcmlwdG9y", + "UHJvdG9zSAGqAidHb29nbGUuUHJvdG9jb2xCdWZmZXJzLkRlc2NyaXB0b3JQ", + "cm90b3M=")); pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { descriptor = root; internal__static_google_protobuf_FileDescriptorSet__Descriptor = Descriptor.MessageTypes[0]; diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/Unittest.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/Unittest.cs index e828f7bf..34645448 100644 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/Unittest.cs +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/Unittest.cs @@ -1,3 +1,6 @@ +// Manual changes: +// - Search and replace of RepeatedFieldsGenerator.Group to RepeatedFieldsGenerator.Types.Group +// // Generated by the protocol buffer compiler. DO NOT EDIT! // source: google/protobuf/unittest.proto #pragma warning disable 1591, 0612, 3021 @@ -7,33506 +10,41327 @@ using pb = global::Google.ProtocolBuffers; using pbc = global::Google.ProtocolBuffers.Collections; using pbd = global::Google.ProtocolBuffers.Descriptors; using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Unittest { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFloatExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalDoubleExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBoolExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBytesExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalGroupExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringPieceExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalCordExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalPublicImportMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalLazyMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFloatExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedDoubleExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBoolExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBytesExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedGroupExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringPieceExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedCordExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedLazyMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFloatExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultDoubleExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBoolExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBytesExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultNestedEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultForeignEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultImportEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringPieceExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultCordExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofUint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofNestedMessageExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofStringExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofBytesExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionString); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionInt); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFloatExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedDoubleExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedBoolExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed32Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed64Extension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFloatExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedDoubleExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedBoolExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedEnumExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Test); - registry.Add(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.NestedStringExtension); - registry.Add(global::Google.ProtocolBuffers.TestProtos.TestRequired.Single); - registry.Add(global::Google.ProtocolBuffers.TestProtos.TestRequired.Multi); - registry.Add(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.OptionalExt); - registry.Add(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.RepeatedExt); - } - #endregion - #region Extensions - public const int OptionalInt32ExtensionFieldNumber = 1; - public static pb::GeneratedExtensionBase OptionalInt32Extension; - public const int OptionalInt64ExtensionFieldNumber = 2; - public static pb::GeneratedExtensionBase OptionalInt64Extension; - public const int OptionalUint32ExtensionFieldNumber = 3; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase OptionalUint32Extension; - public const int OptionalUint64ExtensionFieldNumber = 4; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase OptionalUint64Extension; - public const int OptionalSint32ExtensionFieldNumber = 5; - public static pb::GeneratedExtensionBase OptionalSint32Extension; - public const int OptionalSint64ExtensionFieldNumber = 6; - public static pb::GeneratedExtensionBase OptionalSint64Extension; - public const int OptionalFixed32ExtensionFieldNumber = 7; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase OptionalFixed32Extension; - public const int OptionalFixed64ExtensionFieldNumber = 8; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase OptionalFixed64Extension; - public const int OptionalSfixed32ExtensionFieldNumber = 9; - public static pb::GeneratedExtensionBase OptionalSfixed32Extension; - public const int OptionalSfixed64ExtensionFieldNumber = 10; - public static pb::GeneratedExtensionBase OptionalSfixed64Extension; - public const int OptionalFloatExtensionFieldNumber = 11; - public static pb::GeneratedExtensionBase OptionalFloatExtension; - public const int OptionalDoubleExtensionFieldNumber = 12; - public static pb::GeneratedExtensionBase OptionalDoubleExtension; - public const int OptionalBoolExtensionFieldNumber = 13; - public static pb::GeneratedExtensionBase OptionalBoolExtension; - public const int OptionalStringExtensionFieldNumber = 14; - public static pb::GeneratedExtensionBase OptionalStringExtension; - public const int OptionalBytesExtensionFieldNumber = 15; - public static pb::GeneratedExtensionBase OptionalBytesExtension; - public const int OptionalGroupExtensionFieldNumber = 16; - public static pb::GeneratedExtensionBase OptionalGroupExtension; - public const int OptionalNestedMessageExtensionFieldNumber = 18; - public static pb::GeneratedExtensionBase OptionalNestedMessageExtension; - public const int OptionalForeignMessageExtensionFieldNumber = 19; - public static pb::GeneratedExtensionBase OptionalForeignMessageExtension; - public const int OptionalImportMessageExtensionFieldNumber = 20; - public static pb::GeneratedExtensionBase OptionalImportMessageExtension; - public const int OptionalNestedEnumExtensionFieldNumber = 21; - public static pb::GeneratedExtensionBase OptionalNestedEnumExtension; - public const int OptionalForeignEnumExtensionFieldNumber = 22; - public static pb::GeneratedExtensionBase OptionalForeignEnumExtension; - public const int OptionalImportEnumExtensionFieldNumber = 23; - public static pb::GeneratedExtensionBase OptionalImportEnumExtension; - public const int OptionalStringPieceExtensionFieldNumber = 24; - public static pb::GeneratedExtensionBase OptionalStringPieceExtension; - public const int OptionalCordExtensionFieldNumber = 25; - public static pb::GeneratedExtensionBase OptionalCordExtension; - public const int OptionalPublicImportMessageExtensionFieldNumber = 26; - public static pb::GeneratedExtensionBase OptionalPublicImportMessageExtension; - public const int OptionalLazyMessageExtensionFieldNumber = 27; - public static pb::GeneratedExtensionBase OptionalLazyMessageExtension; - public const int RepeatedInt32ExtensionFieldNumber = 31; - public static pb::GeneratedExtensionBase> RepeatedInt32Extension; - public const int RepeatedInt64ExtensionFieldNumber = 32; - public static pb::GeneratedExtensionBase> RepeatedInt64Extension; - public const int RepeatedUint32ExtensionFieldNumber = 33; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> RepeatedUint32Extension; - public const int RepeatedUint64ExtensionFieldNumber = 34; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> RepeatedUint64Extension; - public const int RepeatedSint32ExtensionFieldNumber = 35; - public static pb::GeneratedExtensionBase> RepeatedSint32Extension; - public const int RepeatedSint64ExtensionFieldNumber = 36; - public static pb::GeneratedExtensionBase> RepeatedSint64Extension; - public const int RepeatedFixed32ExtensionFieldNumber = 37; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> RepeatedFixed32Extension; - public const int RepeatedFixed64ExtensionFieldNumber = 38; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> RepeatedFixed64Extension; - public const int RepeatedSfixed32ExtensionFieldNumber = 39; - public static pb::GeneratedExtensionBase> RepeatedSfixed32Extension; - public const int RepeatedSfixed64ExtensionFieldNumber = 40; - public static pb::GeneratedExtensionBase> RepeatedSfixed64Extension; - public const int RepeatedFloatExtensionFieldNumber = 41; - public static pb::GeneratedExtensionBase> RepeatedFloatExtension; - public const int RepeatedDoubleExtensionFieldNumber = 42; - public static pb::GeneratedExtensionBase> RepeatedDoubleExtension; - public const int RepeatedBoolExtensionFieldNumber = 43; - public static pb::GeneratedExtensionBase> RepeatedBoolExtension; - public const int RepeatedStringExtensionFieldNumber = 44; - public static pb::GeneratedExtensionBase> RepeatedStringExtension; - public const int RepeatedBytesExtensionFieldNumber = 45; - public static pb::GeneratedExtensionBase> RepeatedBytesExtension; - public const int RepeatedGroupExtensionFieldNumber = 46; - public static pb::GeneratedExtensionBase> RepeatedGroupExtension; - public const int RepeatedNestedMessageExtensionFieldNumber = 48; - public static pb::GeneratedExtensionBase> RepeatedNestedMessageExtension; - public const int RepeatedForeignMessageExtensionFieldNumber = 49; - public static pb::GeneratedExtensionBase> RepeatedForeignMessageExtension; - public const int RepeatedImportMessageExtensionFieldNumber = 50; - public static pb::GeneratedExtensionBase> RepeatedImportMessageExtension; - public const int RepeatedNestedEnumExtensionFieldNumber = 51; - public static pb::GeneratedExtensionBase> RepeatedNestedEnumExtension; - public const int RepeatedForeignEnumExtensionFieldNumber = 52; - public static pb::GeneratedExtensionBase> RepeatedForeignEnumExtension; - public const int RepeatedImportEnumExtensionFieldNumber = 53; - public static pb::GeneratedExtensionBase> RepeatedImportEnumExtension; - public const int RepeatedStringPieceExtensionFieldNumber = 54; - public static pb::GeneratedExtensionBase> RepeatedStringPieceExtension; - public const int RepeatedCordExtensionFieldNumber = 55; - public static pb::GeneratedExtensionBase> RepeatedCordExtension; - public const int RepeatedLazyMessageExtensionFieldNumber = 57; - public static pb::GeneratedExtensionBase> RepeatedLazyMessageExtension; - public const int DefaultInt32ExtensionFieldNumber = 61; - public static pb::GeneratedExtensionBase DefaultInt32Extension; - public const int DefaultInt64ExtensionFieldNumber = 62; - public static pb::GeneratedExtensionBase DefaultInt64Extension; - public const int DefaultUint32ExtensionFieldNumber = 63; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase DefaultUint32Extension; - public const int DefaultUint64ExtensionFieldNumber = 64; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase DefaultUint64Extension; - public const int DefaultSint32ExtensionFieldNumber = 65; - public static pb::GeneratedExtensionBase DefaultSint32Extension; - public const int DefaultSint64ExtensionFieldNumber = 66; - public static pb::GeneratedExtensionBase DefaultSint64Extension; - public const int DefaultFixed32ExtensionFieldNumber = 67; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase DefaultFixed32Extension; - public const int DefaultFixed64ExtensionFieldNumber = 68; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase DefaultFixed64Extension; - public const int DefaultSfixed32ExtensionFieldNumber = 69; - public static pb::GeneratedExtensionBase DefaultSfixed32Extension; - public const int DefaultSfixed64ExtensionFieldNumber = 70; - public static pb::GeneratedExtensionBase DefaultSfixed64Extension; - public const int DefaultFloatExtensionFieldNumber = 71; - public static pb::GeneratedExtensionBase DefaultFloatExtension; - public const int DefaultDoubleExtensionFieldNumber = 72; - public static pb::GeneratedExtensionBase DefaultDoubleExtension; - public const int DefaultBoolExtensionFieldNumber = 73; - public static pb::GeneratedExtensionBase DefaultBoolExtension; - public const int DefaultStringExtensionFieldNumber = 74; - public static pb::GeneratedExtensionBase DefaultStringExtension; - public const int DefaultBytesExtensionFieldNumber = 75; - public static pb::GeneratedExtensionBase DefaultBytesExtension; - public const int DefaultNestedEnumExtensionFieldNumber = 81; - public static pb::GeneratedExtensionBase DefaultNestedEnumExtension; - public const int DefaultForeignEnumExtensionFieldNumber = 82; - public static pb::GeneratedExtensionBase DefaultForeignEnumExtension; - public const int DefaultImportEnumExtensionFieldNumber = 83; - public static pb::GeneratedExtensionBase DefaultImportEnumExtension; - public const int DefaultStringPieceExtensionFieldNumber = 84; - public static pb::GeneratedExtensionBase DefaultStringPieceExtension; - public const int DefaultCordExtensionFieldNumber = 85; - public static pb::GeneratedExtensionBase DefaultCordExtension; - public const int OneofUint32ExtensionFieldNumber = 111; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase OneofUint32Extension; - public const int OneofNestedMessageExtensionFieldNumber = 112; - public static pb::GeneratedExtensionBase OneofNestedMessageExtension; - public const int OneofStringExtensionFieldNumber = 113; - public static pb::GeneratedExtensionBase OneofStringExtension; - public const int OneofBytesExtensionFieldNumber = 114; - public static pb::GeneratedExtensionBase OneofBytesExtension; - public const int MyExtensionStringFieldNumber = 50; - public static pb::GeneratedExtensionBase MyExtensionString; - public const int MyExtensionIntFieldNumber = 5; - public static pb::GeneratedExtensionBase MyExtensionInt; - public const int PackedInt32ExtensionFieldNumber = 90; - public static pb::GeneratedExtensionBase> PackedInt32Extension; - public const int PackedInt64ExtensionFieldNumber = 91; - public static pb::GeneratedExtensionBase> PackedInt64Extension; - public const int PackedUint32ExtensionFieldNumber = 92; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> PackedUint32Extension; - public const int PackedUint64ExtensionFieldNumber = 93; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> PackedUint64Extension; - public const int PackedSint32ExtensionFieldNumber = 94; - public static pb::GeneratedExtensionBase> PackedSint32Extension; - public const int PackedSint64ExtensionFieldNumber = 95; - public static pb::GeneratedExtensionBase> PackedSint64Extension; - public const int PackedFixed32ExtensionFieldNumber = 96; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> PackedFixed32Extension; - public const int PackedFixed64ExtensionFieldNumber = 97; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> PackedFixed64Extension; - public const int PackedSfixed32ExtensionFieldNumber = 98; - public static pb::GeneratedExtensionBase> PackedSfixed32Extension; - public const int PackedSfixed64ExtensionFieldNumber = 99; - public static pb::GeneratedExtensionBase> PackedSfixed64Extension; - public const int PackedFloatExtensionFieldNumber = 100; - public static pb::GeneratedExtensionBase> PackedFloatExtension; - public const int PackedDoubleExtensionFieldNumber = 101; - public static pb::GeneratedExtensionBase> PackedDoubleExtension; - public const int PackedBoolExtensionFieldNumber = 102; - public static pb::GeneratedExtensionBase> PackedBoolExtension; - public const int PackedEnumExtensionFieldNumber = 103; - public static pb::GeneratedExtensionBase> PackedEnumExtension; - public const int UnpackedInt32ExtensionFieldNumber = 90; - public static pb::GeneratedExtensionBase> UnpackedInt32Extension; - public const int UnpackedInt64ExtensionFieldNumber = 91; - public static pb::GeneratedExtensionBase> UnpackedInt64Extension; - public const int UnpackedUint32ExtensionFieldNumber = 92; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> UnpackedUint32Extension; - public const int UnpackedUint64ExtensionFieldNumber = 93; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> UnpackedUint64Extension; - public const int UnpackedSint32ExtensionFieldNumber = 94; - public static pb::GeneratedExtensionBase> UnpackedSint32Extension; - public const int UnpackedSint64ExtensionFieldNumber = 95; - public static pb::GeneratedExtensionBase> UnpackedSint64Extension; - public const int UnpackedFixed32ExtensionFieldNumber = 96; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> UnpackedFixed32Extension; - public const int UnpackedFixed64ExtensionFieldNumber = 97; - [global::System.CLSCompliant(false)] - public static pb::GeneratedExtensionBase> UnpackedFixed64Extension; - public const int UnpackedSfixed32ExtensionFieldNumber = 98; - public static pb::GeneratedExtensionBase> UnpackedSfixed32Extension; - public const int UnpackedSfixed64ExtensionFieldNumber = 99; - public static pb::GeneratedExtensionBase> UnpackedSfixed64Extension; - public const int UnpackedFloatExtensionFieldNumber = 100; - public static pb::GeneratedExtensionBase> UnpackedFloatExtension; - public const int UnpackedDoubleExtensionFieldNumber = 101; - public static pb::GeneratedExtensionBase> UnpackedDoubleExtension; - public const int UnpackedBoolExtensionFieldNumber = 102; - public static pb::GeneratedExtensionBase> UnpackedBoolExtension; - public const int UnpackedEnumExtensionFieldNumber = 103; - public static pb::GeneratedExtensionBase> UnpackedEnumExtension; - #endregion +namespace Google.ProtocolBuffers.TestProtos +{ - #region Static variables - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_NestedTestAllTypes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_ForeignMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllExtensions__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedExtension__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequired__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequired__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredForeign__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestForeignNested__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEmptyMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEagerMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEagerMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestLazyMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestLazyMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestFieldOrderings__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_SparseEnumMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OneString__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OneString__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_MoreString__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_MoreString__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OneBytes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OneBytes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_MoreBytes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_MoreBytes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Int32Message__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Int32Message__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Uint32Message__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Uint32Message__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Int64Message__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Int64Message__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Uint64Message__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Uint64Message__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BoolMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BoolMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof_FooGroup__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneofBackwardsCompatible__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof2__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof2__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof2_FooGroup__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof2_NestedMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredOneof__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequiredOneof__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestPackedTypes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestPackedExtensions__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestCommentInjectionMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooRequest__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooRequest__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooResponse__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooResponse__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooClientMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooClientMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooServerMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooServerMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BarRequest__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BarRequest__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BarResponse__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BarResponse__FieldAccessorTable; - #endregion - #region Descriptor - public static pbd::FileDescriptor Descriptor { - get { return descriptor; } - } - private static pbd::FileDescriptor descriptor; - - static Unittest() { - byte[] descriptorData = global::System.Convert.FromBase64String( - string.Concat( - "Ch5nb29nbGUvcHJvdG9idWYvdW5pdHRlc3QucHJvdG8SEXByb3RvYnVmX3Vu", - "aXR0ZXN0GiVnb29nbGUvcHJvdG9idWYvdW5pdHRlc3RfaW1wb3J0LnByb3Rv", - "Iu0YCgxUZXN0QWxsVHlwZXMSFgoOb3B0aW9uYWxfaW50MzIYASABKAUSFgoO", - "b3B0aW9uYWxfaW50NjQYAiABKAMSFwoPb3B0aW9uYWxfdWludDMyGAMgASgN", - "EhcKD29wdGlvbmFsX3VpbnQ2NBgEIAEoBBIXCg9vcHRpb25hbF9zaW50MzIY", - "BSABKBESFwoPb3B0aW9uYWxfc2ludDY0GAYgASgSEhgKEG9wdGlvbmFsX2Zp", - "eGVkMzIYByABKAcSGAoQb3B0aW9uYWxfZml4ZWQ2NBgIIAEoBhIZChFvcHRp", - "b25hbF9zZml4ZWQzMhgJIAEoDxIZChFvcHRpb25hbF9zZml4ZWQ2NBgKIAEo", - "EBIWCg5vcHRpb25hbF9mbG9hdBgLIAEoAhIXCg9vcHRpb25hbF9kb3VibGUY", - "DCABKAESFQoNb3B0aW9uYWxfYm9vbBgNIAEoCBIXCg9vcHRpb25hbF9zdHJp", - "bmcYDiABKAkSFgoOb3B0aW9uYWxfYnl0ZXMYDyABKAwSRAoNb3B0aW9uYWxn", - "cm91cBgQIAEoCjItLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5P", - "cHRpb25hbEdyb3VwEk4KF29wdGlvbmFsX25lc3RlZF9tZXNzYWdlGBIgASgL", - "Mi0ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzLk5lc3RlZE1lc3Nh", - "Z2USQwoYb3B0aW9uYWxfZm9yZWlnbl9tZXNzYWdlGBMgASgLMiEucHJvdG9i", - "dWZfdW5pdHRlc3QuRm9yZWlnbk1lc3NhZ2USSAoXb3B0aW9uYWxfaW1wb3J0", - "X21lc3NhZ2UYFCABKAsyJy5wcm90b2J1Zl91bml0dGVzdF9pbXBvcnQuSW1w", - "b3J0TWVzc2FnZRJIChRvcHRpb25hbF9uZXN0ZWRfZW51bRgVIAEoDjIqLnBy", - "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRFbnVtEj0KFW9w", - "dGlvbmFsX2ZvcmVpZ25fZW51bRgWIAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0", - "LkZvcmVpZ25FbnVtEkIKFG9wdGlvbmFsX2ltcG9ydF9lbnVtGBcgASgOMiQu", - "cHJvdG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydEVudW0SIQoVb3B0aW9u", - "YWxfc3RyaW5nX3BpZWNlGBggASgJQgIIAhIZCg1vcHRpb25hbF9jb3JkGBkg", - "ASgJQgIIARJVCh5vcHRpb25hbF9wdWJsaWNfaW1wb3J0X21lc3NhZ2UYGiAB", - "KAsyLS5wcm90b2J1Zl91bml0dGVzdF9pbXBvcnQuUHVibGljSW1wb3J0TWVz", - "c2FnZRJQChVvcHRpb25hbF9sYXp5X21lc3NhZ2UYGyABKAsyLS5wcm90b2J1", - "Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkTWVzc2FnZUICKAESFgoO", - "cmVwZWF0ZWRfaW50MzIYHyADKAUSFgoOcmVwZWF0ZWRfaW50NjQYICADKAMS", - "FwoPcmVwZWF0ZWRfdWludDMyGCEgAygNEhcKD3JlcGVhdGVkX3VpbnQ2NBgi", - "IAMoBBIXCg9yZXBlYXRlZF9zaW50MzIYIyADKBESFwoPcmVwZWF0ZWRfc2lu", - "dDY0GCQgAygSEhgKEHJlcGVhdGVkX2ZpeGVkMzIYJSADKAcSGAoQcmVwZWF0", - "ZWRfZml4ZWQ2NBgmIAMoBhIZChFyZXBlYXRlZF9zZml4ZWQzMhgnIAMoDxIZ", - "ChFyZXBlYXRlZF9zZml4ZWQ2NBgoIAMoEBIWCg5yZXBlYXRlZF9mbG9hdBgp", - "IAMoAhIXCg9yZXBlYXRlZF9kb3VibGUYKiADKAESFQoNcmVwZWF0ZWRfYm9v", - "bBgrIAMoCBIXCg9yZXBlYXRlZF9zdHJpbmcYLCADKAkSFgoOcmVwZWF0ZWRf", - "Ynl0ZXMYLSADKAwSRAoNcmVwZWF0ZWRncm91cBguIAMoCjItLnByb3RvYnVm", - "X3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5SZXBlYXRlZEdyb3VwEk4KF3JlcGVh", - "dGVkX25lc3RlZF9tZXNzYWdlGDAgAygLMi0ucHJvdG9idWZfdW5pdHRlc3Qu", - "VGVzdEFsbFR5cGVzLk5lc3RlZE1lc3NhZ2USQwoYcmVwZWF0ZWRfZm9yZWln", - "bl9tZXNzYWdlGDEgAygLMiEucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbk1l", - "c3NhZ2USSAoXcmVwZWF0ZWRfaW1wb3J0X21lc3NhZ2UYMiADKAsyJy5wcm90", - "b2J1Zl91bml0dGVzdF9pbXBvcnQuSW1wb3J0TWVzc2FnZRJIChRyZXBlYXRl", - "ZF9uZXN0ZWRfZW51bRgzIAMoDjIqLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", - "bGxUeXBlcy5OZXN0ZWRFbnVtEj0KFXJlcGVhdGVkX2ZvcmVpZ25fZW51bRg0", - "IAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtEkIKFHJlcGVh", - "dGVkX2ltcG9ydF9lbnVtGDUgAygOMiQucHJvdG9idWZfdW5pdHRlc3RfaW1w", - "b3J0LkltcG9ydEVudW0SIQoVcmVwZWF0ZWRfc3RyaW5nX3BpZWNlGDYgAygJ", - "QgIIAhIZCg1yZXBlYXRlZF9jb3JkGDcgAygJQgIIARJQChVyZXBlYXRlZF9s", - "YXp5X21lc3NhZ2UYOSADKAsyLS5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxs", - "VHlwZXMuTmVzdGVkTWVzc2FnZUICKAESGQoNZGVmYXVsdF9pbnQzMhg9IAEo", - "BToCNDESGQoNZGVmYXVsdF9pbnQ2NBg+IAEoAzoCNDISGgoOZGVmYXVsdF91", - "aW50MzIYPyABKA06AjQzEhoKDmRlZmF1bHRfdWludDY0GEAgASgEOgI0NBIb", - "Cg5kZWZhdWx0X3NpbnQzMhhBIAEoEToDLTQ1EhoKDmRlZmF1bHRfc2ludDY0", - "GEIgASgSOgI0NhIbCg9kZWZhdWx0X2ZpeGVkMzIYQyABKAc6AjQ3EhsKD2Rl", - "ZmF1bHRfZml4ZWQ2NBhEIAEoBjoCNDgSHAoQZGVmYXVsdF9zZml4ZWQzMhhF", - "IAEoDzoCNDkSHQoQZGVmYXVsdF9zZml4ZWQ2NBhGIAEoEDoDLTUwEhsKDWRl", - "ZmF1bHRfZmxvYXQYRyABKAI6BDUxLjUSHQoOZGVmYXVsdF9kb3VibGUYSCAB", - "KAE6BTUyMDAwEhoKDGRlZmF1bHRfYm9vbBhJIAEoCDoEdHJ1ZRIdCg5kZWZh", - "dWx0X3N0cmluZxhKIAEoCToFaGVsbG8SHAoNZGVmYXVsdF9ieXRlcxhLIAEo", - "DDoFd29ybGQSTAoTZGVmYXVsdF9uZXN0ZWRfZW51bRhRIAEoDjIqLnByb3Rv", - "YnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRFbnVtOgNCQVISSQoU", - "ZGVmYXVsdF9mb3JlaWduX2VudW0YUiABKA4yHi5wcm90b2J1Zl91bml0dGVz", - "dC5Gb3JlaWduRW51bToLRk9SRUlHTl9CQVISTQoTZGVmYXVsdF9pbXBvcnRf", - "ZW51bRhTIAEoDjIkLnByb3RvYnVmX3VuaXR0ZXN0X2ltcG9ydC5JbXBvcnRF", - "bnVtOgpJTVBPUlRfQkFSEiUKFGRlZmF1bHRfc3RyaW5nX3BpZWNlGFQgASgJ", - "OgNhYmNCAggCEh0KDGRlZmF1bHRfY29yZBhVIAEoCToDMTIzQgIIARIWCgxv", - "bmVvZl91aW50MzIYbyABKA1IABJNChRvbmVvZl9uZXN0ZWRfbWVzc2FnZRhw", - "IAEoCzItLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRN", - "ZXNzYWdlSAASFgoMb25lb2Zfc3RyaW5nGHEgASgJSAASFQoLb25lb2ZfYnl0", - "ZXMYciABKAxIABobCg1OZXN0ZWRNZXNzYWdlEgoKAmJiGAEgASgFGhoKDU9w", - "dGlvbmFsR3JvdXASCQoBYRgRIAEoBRoaCg1SZXBlYXRlZEdyb3VwEgkKAWEY", - "LyABKAUiOQoKTmVzdGVkRW51bRIHCgNGT08QARIHCgNCQVIQAhIHCgNCQVoQ", - "AxIQCgNORUcQ////////////AUINCgtvbmVvZl9maWVsZCJ8ChJOZXN0ZWRU", - "ZXN0QWxsVHlwZXMSNAoFY2hpbGQYASABKAsyJS5wcm90b2J1Zl91bml0dGVz", - "dC5OZXN0ZWRUZXN0QWxsVHlwZXMSMAoHcGF5bG9hZBgCIAEoCzIfLnByb3Rv", - "YnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcyI0ChRUZXN0RGVwcmVjYXRlZEZp", - "ZWxkcxIcChBkZXByZWNhdGVkX2ludDMyGAEgASgFQgIYASIbCg5Gb3JlaWdu", - "TWVzc2FnZRIJCgFjGAEgASgFIh0KEVRlc3RBbGxFeHRlbnNpb25zKggIARCA", - "gICAAiIkChdPcHRpb25hbEdyb3VwX2V4dGVuc2lvbhIJCgFhGBEgASgFIiQK", - "F1JlcGVhdGVkR3JvdXBfZXh0ZW5zaW9uEgkKAWEYLyABKAUimAEKE1Rlc3RO", - "ZXN0ZWRFeHRlbnNpb24yOQoEdGVzdBIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", - "c3RBbGxFeHRlbnNpb25zGOoHIAEoCToEdGVzdDJGChduZXN0ZWRfc3RyaW5n", - "X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNp", - "b25zGOsHIAEoCSLVBQoMVGVzdFJlcXVpcmVkEgkKAWEYASACKAUSDgoGZHVt", - "bXkyGAIgASgFEgkKAWIYAyACKAUSDgoGZHVtbXk0GAQgASgFEg4KBmR1bW15", - "NRgFIAEoBRIOCgZkdW1teTYYBiABKAUSDgoGZHVtbXk3GAcgASgFEg4KBmR1", - "bW15OBgIIAEoBRIOCgZkdW1teTkYCSABKAUSDwoHZHVtbXkxMBgKIAEoBRIP", - "CgdkdW1teTExGAsgASgFEg8KB2R1bW15MTIYDCABKAUSDwoHZHVtbXkxMxgN", - "IAEoBRIPCgdkdW1teTE0GA4gASgFEg8KB2R1bW15MTUYDyABKAUSDwoHZHVt", - "bXkxNhgQIAEoBRIPCgdkdW1teTE3GBEgASgFEg8KB2R1bW15MTgYEiABKAUS", - "DwoHZHVtbXkxORgTIAEoBRIPCgdkdW1teTIwGBQgASgFEg8KB2R1bW15MjEY", - "FSABKAUSDwoHZHVtbXkyMhgWIAEoBRIPCgdkdW1teTIzGBcgASgFEg8KB2R1", - "bW15MjQYGCABKAUSDwoHZHVtbXkyNRgZIAEoBRIPCgdkdW1teTI2GBogASgF", - "Eg8KB2R1bW15MjcYGyABKAUSDwoHZHVtbXkyOBgcIAEoBRIPCgdkdW1teTI5", - "GB0gASgFEg8KB2R1bW15MzAYHiABKAUSDwoHZHVtbXkzMRgfIAEoBRIPCgdk", - "dW1teTMyGCAgASgFEgkKAWMYISACKAUyVgoGc2luZ2xlEiQucHJvdG9idWZf", - "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY6AcgASgLMh8ucHJvdG9idWZf", - "dW5pdHRlc3QuVGVzdFJlcXVpcmVkMlUKBW11bHRpEiQucHJvdG9idWZfdW5p", - "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY6QcgAygLMh8ucHJvdG9idWZfdW5p", - "dHRlc3QuVGVzdFJlcXVpcmVkIpoBChNUZXN0UmVxdWlyZWRGb3JlaWduEjkK", - "EG9wdGlvbmFsX21lc3NhZ2UYASABKAsyHy5wcm90b2J1Zl91bml0dGVzdC5U", - "ZXN0UmVxdWlyZWQSOQoQcmVwZWF0ZWRfbWVzc2FnZRgCIAMoCzIfLnByb3Rv", - "YnVmX3VuaXR0ZXN0LlRlc3RSZXF1aXJlZBINCgVkdW1teRgDIAEoBSJaChFU", - "ZXN0Rm9yZWlnbk5lc3RlZBJFCg5mb3JlaWduX25lc3RlZBgBIAEoCzItLnBy", - "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdlIhIK", - "EFRlc3RFbXB0eU1lc3NhZ2UiKgoeVGVzdEVtcHR5TWVzc2FnZVdpdGhFeHRl", - "bnNpb25zKggIARCAgICAAiI3ChtUZXN0TXVsdGlwbGVFeHRlbnNpb25SYW5n", - "ZXMqBAgqECsqBgivIBCUISoKCICABBCAgICAAiI0ChhUZXN0UmVhbGx5TGFy", - "Z2VUYWdOdW1iZXISCQoBYRgBIAEoBRINCgJiYhj///9/IAEoBSJVChRUZXN0", - "UmVjdXJzaXZlTWVzc2FnZRIyCgFhGAEgASgLMicucHJvdG9idWZfdW5pdHRl", - "c3QuVGVzdFJlY3Vyc2l2ZU1lc3NhZ2USCQoBaRgCIAEoBSJLChRUZXN0TXV0", - "dWFsUmVjdXJzaW9uQRIzCgJiYhgBIAEoCzInLnByb3RvYnVmX3VuaXR0ZXN0", - "LlRlc3RNdXR1YWxSZWN1cnNpb25CImIKFFRlc3RNdXR1YWxSZWN1cnNpb25C", - "EjIKAWEYASABKAsyJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0TXV0dWFsUmVj", - "dXJzaW9uQRIWCg5vcHRpb25hbF9pbnQzMhgCIAEoBSKzAQoSVGVzdER1cEZp", - "ZWxkTnVtYmVyEgkKAWEYASABKAUSNgoDZm9vGAIgASgKMikucHJvdG9idWZf", - "dW5pdHRlc3QuVGVzdER1cEZpZWxkTnVtYmVyLkZvbxI2CgNiYXIYAyABKAoy", - "KS5wcm90b2J1Zl91bml0dGVzdC5UZXN0RHVwRmllbGROdW1iZXIuQmFyGhAK", - "A0ZvbxIJCgFhGAEgASgFGhAKA0JhchIJCgFhGAEgASgFIkwKEFRlc3RFYWdl", - "ck1lc3NhZ2USOAoLc3ViX21lc3NhZ2UYASABKAsyHy5wcm90b2J1Zl91bml0", - "dGVzdC5UZXN0QWxsVHlwZXNCAigAIksKD1Rlc3RMYXp5TWVzc2FnZRI4Cgtz", - "dWJfbWVzc2FnZRgBIAEoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxU", - "eXBlc0ICKAEigAIKGFRlc3ROZXN0ZWRNZXNzYWdlSGFzQml0cxJaChdvcHRp", - "b25hbF9uZXN0ZWRfbWVzc2FnZRgBIAEoCzI5LnByb3RvYnVmX3VuaXR0ZXN0", - "LlRlc3ROZXN0ZWRNZXNzYWdlSGFzQml0cy5OZXN0ZWRNZXNzYWdlGocBCg1O", - "ZXN0ZWRNZXNzYWdlEiQKHG5lc3RlZG1lc3NhZ2VfcmVwZWF0ZWRfaW50MzIY", - "ASADKAUSUAolbmVzdGVkbWVzc2FnZV9yZXBlYXRlZF9mb3JlaWdubWVzc2Fn", - "ZRgCIAMoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25NZXNzYWdlIuUD", - "ChdUZXN0Q2FtZWxDYXNlRmllbGROYW1lcxIWCg5QcmltaXRpdmVGaWVsZBgB", - "IAEoBRITCgtTdHJpbmdGaWVsZBgCIAEoCRIxCglFbnVtRmllbGQYAyABKA4y", - "Hi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bRI3CgxNZXNzYWdlRmll", - "bGQYBCABKAsyIS5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduTWVzc2FnZRIc", - "ChBTdHJpbmdQaWVjZUZpZWxkGAUgASgJQgIIAhIVCglDb3JkRmllbGQYBiAB", - "KAlCAggBEh4KFlJlcGVhdGVkUHJpbWl0aXZlRmllbGQYByADKAUSGwoTUmVw", - "ZWF0ZWRTdHJpbmdGaWVsZBgIIAMoCRI5ChFSZXBlYXRlZEVudW1GaWVsZBgJ", - "IAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtEj8KFFJlcGVh", - "dGVkTWVzc2FnZUZpZWxkGAogAygLMiEucHJvdG9idWZfdW5pdHRlc3QuRm9y", - "ZWlnbk1lc3NhZ2USJAoYUmVwZWF0ZWRTdHJpbmdQaWVjZUZpZWxkGAsgAygJ", - "QgIIAhIdChFSZXBlYXRlZENvcmRGaWVsZBgMIAMoCUICCAEi1QEKElRlc3RG", - "aWVsZE9yZGVyaW5ncxIRCglteV9zdHJpbmcYCyABKAkSDgoGbXlfaW50GAEg", - "ASgDEhAKCG15X2Zsb2F0GGUgASgCElUKF29wdGlvbmFsX25lc3RlZF9tZXNz", - "YWdlGMgBIAEoCzIzLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RGaWVsZE9yZGVy", - "aW5ncy5OZXN0ZWRNZXNzYWdlGicKDU5lc3RlZE1lc3NhZ2USCgoCb28YAiAB", - "KAMSCgoCYmIYASABKAUqBAgCEAsqBAgMEGUitgcKGFRlc3RFeHRyZW1lRGVm", - "YXVsdFZhbHVlcxI/Cg1lc2NhcGVkX2J5dGVzGAEgASgMOihcMDAwXDAwMVww", - "MDdcMDEwXDAxNFxuXHJcdFwwMTNcXFwnXCJcMzc2EiAKDGxhcmdlX3VpbnQz", - "MhgCIAEoDToKNDI5NDk2NzI5NRIqCgxsYXJnZV91aW50NjQYAyABKAQ6FDE4", - "NDQ2NzQ0MDczNzA5NTUxNjE1EiAKC3NtYWxsX2ludDMyGAQgASgFOgstMjE0", - "NzQ4MzY0NxIpCgtzbWFsbF9pbnQ2NBgFIAEoAzoULTkyMjMzNzIwMzY4NTQ3", - "NzU4MDcSJwoScmVhbGx5X3NtYWxsX2ludDMyGBUgASgFOgstMjE0NzQ4MzY0", - "OBIwChJyZWFsbHlfc21hbGxfaW50NjQYFiABKAM6FC05MjIzMzcyMDM2ODU0", - "Nzc1ODA4EhgKC3V0Zjhfc3RyaW5nGAYgASgJOgPhiLQSFQoKemVyb19mbG9h", - "dBgHIAEoAjoBMBIUCglvbmVfZmxvYXQYCCABKAI6ATESGAoLc21hbGxfZmxv", - "YXQYCSABKAI6AzEuNRIeChJuZWdhdGl2ZV9vbmVfZmxvYXQYCiABKAI6Ai0x", - "EhwKDm5lZ2F0aXZlX2Zsb2F0GAsgASgCOgQtMS41EhoKC2xhcmdlX2Zsb2F0", - "GAwgASgCOgUyZSswOBIkChRzbWFsbF9uZWdhdGl2ZV9mbG9hdBgNIAEoAjoG", - "LThlLTI4EhcKCmluZl9kb3VibGUYDiABKAE6A2luZhIcCg5uZWdfaW5mX2Rv", - "dWJsZRgPIAEoAToELWluZhIXCgpuYW5fZG91YmxlGBAgASgBOgNuYW4SFgoJ", - "aW5mX2Zsb2F0GBEgASgCOgNpbmYSGwoNbmVnX2luZl9mbG9hdBgSIAEoAjoE", - "LWluZhIWCgluYW5fZmxvYXQYEyABKAI6A25hbhIrCgxjcHBfdHJpZ3JhcGgY", - "FCABKAk6FT8gPyA/PyA/PyA/Pz8gPz8vID8/LRIgChBzdHJpbmdfd2l0aF96", - "ZXJvGBcgASgJOgZoZWwAbG8SIgoPYnl0ZXNfd2l0aF96ZXJvGBggASgMOgl3", - "b3JcMDAwbGQSKAoWc3RyaW5nX3BpZWNlX3dpdGhfemVybxgZIAEoCToEYWIA", - "Y0ICCAISIAoOY29yZF93aXRoX3plcm8YGiABKAk6BDEyADNCAggBEiYKEnJl", - "cGxhY2VtZW50X3N0cmluZxgbIAEoCToKJHt1bmtub3dufSJLChFTcGFyc2VF", - "bnVtTWVzc2FnZRI2CgtzcGFyc2VfZW51bRgBIAEoDjIhLnByb3RvYnVmX3Vu", - "aXR0ZXN0LlRlc3RTcGFyc2VFbnVtIhkKCU9uZVN0cmluZxIMCgRkYXRhGAEg", - "ASgJIhoKCk1vcmVTdHJpbmcSDAoEZGF0YRgBIAMoCSIYCghPbmVCeXRlcxIM", - "CgRkYXRhGAEgASgMIhkKCU1vcmVCeXRlcxIMCgRkYXRhGAEgAygMIhwKDElu", - "dDMyTWVzc2FnZRIMCgRkYXRhGAEgASgFIh0KDVVpbnQzMk1lc3NhZ2USDAoE", - "ZGF0YRgBIAEoDSIcCgxJbnQ2NE1lc3NhZ2USDAoEZGF0YRgBIAEoAyIdCg1V", - "aW50NjRNZXNzYWdlEgwKBGRhdGEYASABKAQiGwoLQm9vbE1lc3NhZ2USDAoE", - "ZGF0YRgBIAEoCCLQAQoJVGVzdE9uZW9mEhEKB2Zvb19pbnQYASABKAVIABIU", - "Cgpmb29fc3RyaW5nGAIgASgJSAASNgoLZm9vX21lc3NhZ2UYAyABKAsyHy5w", - "cm90b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXNIABI5Cghmb29ncm91cBgE", - "IAEoCjIlLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RPbmVvZi5Gb29Hcm91cEgA", - "GiAKCEZvb0dyb3VwEgkKAWEYBSABKAUSCQoBYhgGIAEoCUIFCgNmb28i5wEK", - "HFRlc3RPbmVvZkJhY2t3YXJkc0NvbXBhdGlibGUSDwoHZm9vX2ludBgBIAEo", - "BRISCgpmb29fc3RyaW5nGAIgASgJEjQKC2Zvb19tZXNzYWdlGAMgASgLMh8u", - "cHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzEkoKCGZvb2dyb3VwGAQg", - "ASgKMjgucHJvdG9idWZfdW5pdHRlc3QuVGVzdE9uZW9mQmFja3dhcmRzQ29t", - "cGF0aWJsZS5Gb29Hcm91cBogCghGb29Hcm91cBIJCgFhGAUgASgFEgkKAWIY", - "BiABKAkingYKClRlc3RPbmVvZjISEQoHZm9vX2ludBgBIAEoBUgAEhQKCmZv", - "b19zdHJpbmcYAiABKAlIABIWCghmb29fY29yZBgDIAEoCUICCAFIABIeChBm", - "b29fc3RyaW5nX3BpZWNlGAQgASgJQgIIAkgAEhMKCWZvb19ieXRlcxgFIAEo", - "DEgAEjwKCGZvb19lbnVtGAYgASgOMigucHJvdG9idWZfdW5pdHRlc3QuVGVz", - "dE9uZW9mMi5OZXN0ZWRFbnVtSAASQgoLZm9vX21lc3NhZ2UYByABKAsyKy5w", - "cm90b2J1Zl91bml0dGVzdC5UZXN0T25lb2YyLk5lc3RlZE1lc3NhZ2VIABI6", - "Cghmb29ncm91cBgIIAEoCjImLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RPbmVv", - "ZjIuRm9vR3JvdXBIABJLChBmb29fbGF6eV9tZXNzYWdlGAsgASgLMisucHJv", - "dG9idWZfdW5pdHRlc3QuVGVzdE9uZW9mMi5OZXN0ZWRNZXNzYWdlQgIoAUgA", - "EhQKB2Jhcl9pbnQYDCABKAU6ATVIARIcCgpiYXJfc3RyaW5nGA0gASgJOgZT", - "VFJJTkdIARIcCghiYXJfY29yZBgOIAEoCToEQ09SREICCAFIARImChBiYXJf", - "c3RyaW5nX3BpZWNlGA8gASgJOgZTUElFQ0VCAggCSAESGgoJYmFyX2J5dGVz", - "GBAgASgMOgVCWVRFU0gBEkEKCGJhcl9lbnVtGBEgASgOMigucHJvdG9idWZf", - "dW5pdHRlc3QuVGVzdE9uZW9mMi5OZXN0ZWRFbnVtOgNCQVJIARIPCgdiYXpf", - "aW50GBIgASgFEhcKCmJhel9zdHJpbmcYEyABKAk6A0JBWhogCghGb29Hcm91", - "cBIJCgFhGAkgASgFEgkKAWIYCiABKAkaMwoNTmVzdGVkTWVzc2FnZRIPCgdx", - "dXhfaW50GAEgASgDEhEKCWNvcmdlX2ludBgCIAMoBSInCgpOZXN0ZWRFbnVt", - "EgcKA0ZPTxABEgcKA0JBUhACEgcKA0JBWhADQgUKA2Zvb0IFCgNiYXIiuAEK", - "EVRlc3RSZXF1aXJlZE9uZW9mEhEKB2Zvb19pbnQYASABKAVIABIUCgpmb29f", - "c3RyaW5nGAIgASgJSAASSQoLZm9vX21lc3NhZ2UYAyABKAsyMi5wcm90b2J1", - "Zl91bml0dGVzdC5UZXN0UmVxdWlyZWRPbmVvZi5OZXN0ZWRNZXNzYWdlSAAa", - "KAoNTmVzdGVkTWVzc2FnZRIXCg9yZXF1aXJlZF9kb3VibGUYASACKAFCBQoD", - "Zm9vIqoDCg9UZXN0UGFja2VkVHlwZXMSGAoMcGFja2VkX2ludDMyGFogAygF", - "QgIQARIYCgxwYWNrZWRfaW50NjQYWyADKANCAhABEhkKDXBhY2tlZF91aW50", - "MzIYXCADKA1CAhABEhkKDXBhY2tlZF91aW50NjQYXSADKARCAhABEhkKDXBh", - "Y2tlZF9zaW50MzIYXiADKBFCAhABEhkKDXBhY2tlZF9zaW50NjQYXyADKBJC", - "AhABEhoKDnBhY2tlZF9maXhlZDMyGGAgAygHQgIQARIaCg5wYWNrZWRfZml4", - "ZWQ2NBhhIAMoBkICEAESGwoPcGFja2VkX3NmaXhlZDMyGGIgAygPQgIQARIb", - "Cg9wYWNrZWRfc2ZpeGVkNjQYYyADKBBCAhABEhgKDHBhY2tlZF9mbG9hdBhk", - "IAMoAkICEAESGQoNcGFja2VkX2RvdWJsZRhlIAMoAUICEAESFwoLcGFja2Vk", - "X2Jvb2wYZiADKAhCAhABEjcKC3BhY2tlZF9lbnVtGGcgAygOMh4ucHJvdG9i", - "dWZfdW5pdHRlc3QuRm9yZWlnbkVudW1CAhABIsgDChFUZXN0VW5wYWNrZWRU", - "eXBlcxIaCg51bnBhY2tlZF9pbnQzMhhaIAMoBUICEAASGgoOdW5wYWNrZWRf", - "aW50NjQYWyADKANCAhAAEhsKD3VucGFja2VkX3VpbnQzMhhcIAMoDUICEAAS", - "GwoPdW5wYWNrZWRfdWludDY0GF0gAygEQgIQABIbCg91bnBhY2tlZF9zaW50", - "MzIYXiADKBFCAhAAEhsKD3VucGFja2VkX3NpbnQ2NBhfIAMoEkICEAASHAoQ", - "dW5wYWNrZWRfZml4ZWQzMhhgIAMoB0ICEAASHAoQdW5wYWNrZWRfZml4ZWQ2", - "NBhhIAMoBkICEAASHQoRdW5wYWNrZWRfc2ZpeGVkMzIYYiADKA9CAhAAEh0K", - "EXVucGFja2VkX3NmaXhlZDY0GGMgAygQQgIQABIaCg51bnBhY2tlZF9mbG9h", - "dBhkIAMoAkICEAASGwoPdW5wYWNrZWRfZG91YmxlGGUgAygBQgIQABIZCg11", - "bnBhY2tlZF9ib29sGGYgAygIQgIQABI5Cg11bnBhY2tlZF9lbnVtGGcgAygO", - "Mh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbkVudW1CAhAAIiAKFFRlc3RQ", - "YWNrZWRFeHRlbnNpb25zKggIARCAgICAAiIiChZUZXN0VW5wYWNrZWRFeHRl", - "bnNpb25zKggIARCAgICAAiKZBAoVVGVzdER5bmFtaWNFeHRlbnNpb25zEhkK", - "EHNjYWxhcl9leHRlbnNpb24Y0A8gASgHEjcKDmVudW1fZXh0ZW5zaW9uGNEP", - "IAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtElkKFmR5bmFt", - "aWNfZW51bV9leHRlbnNpb24Y0g8gASgOMjgucHJvdG9idWZfdW5pdHRlc3Qu", - "VGVzdER5bmFtaWNFeHRlbnNpb25zLkR5bmFtaWNFbnVtVHlwZRI9ChFtZXNz", - "YWdlX2V4dGVuc2lvbhjTDyABKAsyIS5wcm90b2J1Zl91bml0dGVzdC5Gb3Jl", - "aWduTWVzc2FnZRJfChlkeW5hbWljX21lc3NhZ2VfZXh0ZW5zaW9uGNQPIAEo", - "CzI7LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3REeW5hbWljRXh0ZW5zaW9ucy5E", - "eW5hbWljTWVzc2FnZVR5cGUSGwoScmVwZWF0ZWRfZXh0ZW5zaW9uGNUPIAMo", - "CRIdChBwYWNrZWRfZXh0ZW5zaW9uGNYPIAMoEUICEAEaLAoSRHluYW1pY01l", - "c3NhZ2VUeXBlEhYKDWR5bmFtaWNfZmllbGQYtBAgASgFIkcKD0R5bmFtaWNF", - "bnVtVHlwZRIQCgtEWU5BTUlDX0ZPTxCYERIQCgtEWU5BTUlDX0JBUhCZERIQ", - "CgtEWU5BTUlDX0JBWhCaESLAAQojVGVzdFJlcGVhdGVkU2NhbGFyRGlmZmVy", - "ZW50VGFnU2l6ZXMSGAoQcmVwZWF0ZWRfZml4ZWQzMhgMIAMoBxIWCg5yZXBl", - "YXRlZF9pbnQzMhgNIAMoBRIZChByZXBlYXRlZF9maXhlZDY0GP4PIAMoBhIX", - "Cg5yZXBlYXRlZF9pbnQ2NBj/DyADKAMSGAoOcmVwZWF0ZWRfZmxvYXQY/v8P", - "IAMoAhIZCg9yZXBlYXRlZF91aW50NjQY//8PIAMoBCL3CQoQVGVzdFBhcnNp", - "bmdNZXJnZRI7ChJyZXF1aXJlZF9hbGxfdHlwZXMYASACKAsyHy5wcm90b2J1", - "Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMSOwoSb3B0aW9uYWxfYWxsX3R5cGVz", - "GAIgASgLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzEjsKEnJl", - "cGVhdGVkX2FsbF90eXBlcxgDIAMoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRl", - "c3RBbGxUeXBlcxJICg1vcHRpb25hbGdyb3VwGAogASgKMjEucHJvdG9idWZf", - "dW5pdHRlc3QuVGVzdFBhcnNpbmdNZXJnZS5PcHRpb25hbEdyb3VwEkgKDXJl", - "cGVhdGVkZ3JvdXAYFCADKAoyMS5wcm90b2J1Zl91bml0dGVzdC5UZXN0UGFy", - "c2luZ01lcmdlLlJlcGVhdGVkR3JvdXAaqgQKF1JlcGVhdGVkRmllbGRzR2Vu", - "ZXJhdG9yEi8KBmZpZWxkMRgBIAMoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRl", - "c3RBbGxUeXBlcxIvCgZmaWVsZDIYAiADKAsyHy5wcm90b2J1Zl91bml0dGVz", - "dC5UZXN0QWxsVHlwZXMSLwoGZmllbGQzGAMgAygLMh8ucHJvdG9idWZfdW5p", - "dHRlc3QuVGVzdEFsbFR5cGVzElIKBmdyb3VwMRgKIAMoCjJCLnByb3RvYnVm", - "X3VuaXR0ZXN0LlRlc3RQYXJzaW5nTWVyZ2UuUmVwZWF0ZWRGaWVsZHNHZW5l", - "cmF0b3IuR3JvdXAxElIKBmdyb3VwMhgUIAMoCjJCLnByb3RvYnVmX3VuaXR0", - "ZXN0LlRlc3RQYXJzaW5nTWVyZ2UuUmVwZWF0ZWRGaWVsZHNHZW5lcmF0b3Iu", - "R3JvdXAyEi4KBGV4dDEY6AcgAygLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVz", - "dEFsbFR5cGVzEi4KBGV4dDIY6QcgAygLMh8ucHJvdG9idWZfdW5pdHRlc3Qu", - "VGVzdEFsbFR5cGVzGjkKBkdyb3VwMRIvCgZmaWVsZDEYCyABKAsyHy5wcm90", - "b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMaOQoGR3JvdXAyEi8KBmZpZWxk", - "MRgVIAEoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcxpSCg1P", - "cHRpb25hbEdyb3VwEkEKGG9wdGlvbmFsX2dyb3VwX2FsbF90eXBlcxgLIAEo", - "CzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcxpSCg1SZXBlYXRl", - "ZEdyb3VwEkEKGHJlcGVhdGVkX2dyb3VwX2FsbF90eXBlcxgVIAEoCzIfLnBy", - "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcyoJCOgHEICAgIACMlsKDG9w", - "dGlvbmFsX2V4dBIjLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYXJzaW5nTWVy", - "Z2UY6AcgASgLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzMlsK", - "DHJlcGVhdGVkX2V4dBIjLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYXJzaW5n", - "TWVyZ2UY6QcgAygLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVz", - "IkQKG1Rlc3RDb21tZW50SW5qZWN0aW9uTWVzc2FnZRIlCgFhGAEgASgJOhoq", - "LyA8LSBOZWl0aGVyIHNob3VsZCB0aGlzLiIMCgpGb29SZXF1ZXN0Ig0KC0Zv", - "b1Jlc3BvbnNlIhIKEEZvb0NsaWVudE1lc3NhZ2UiEgoQRm9vU2VydmVyTWVz", - "c2FnZSIMCgpCYXJSZXF1ZXN0Ig0KC0JhclJlc3BvbnNlKkAKC0ZvcmVpZ25F", - "bnVtEg8KC0ZPUkVJR05fRk9PEAQSDwoLRk9SRUlHTl9CQVIQBRIPCgtGT1JF", - "SUdOX0JBWhAGKksKFFRlc3RFbnVtV2l0aER1cFZhbHVlEggKBEZPTzEQARII", - "CgRCQVIxEAISBwoDQkFaEAMSCAoERk9PMhABEggKBEJBUjIQAhoCEAEqiQEK", - "DlRlc3RTcGFyc2VFbnVtEgwKCFNQQVJTRV9BEHsSDgoIU1BBUlNFX0IQpucD", - "Eg8KCFNQQVJTRV9DELKxgAYSFQoIU1BBUlNFX0QQ8f//////////ARIVCghT", - "UEFSU0VfRRC03vz///////8BEgwKCFNQQVJTRV9GEAASDAoIU1BBUlNFX0cQ", - "AjKZAQoLVGVzdFNlcnZpY2USRAoDRm9vEh0ucHJvdG9idWZfdW5pdHRlc3Qu", - "Rm9vUmVxdWVzdBoeLnByb3RvYnVmX3VuaXR0ZXN0LkZvb1Jlc3BvbnNlEkQK", - "A0JhchIdLnByb3RvYnVmX3VuaXR0ZXN0LkJhclJlcXVlc3QaHi5wcm90b2J1", - "Zl91bml0dGVzdC5CYXJSZXNwb25zZTpGChhvcHRpb25hbF9pbnQzMl9leHRl", - "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgB", - "IAEoBTpGChhvcHRpb25hbF9pbnQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91", - "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgCIAEoAzpHChlvcHRpb25hbF91", - "aW50MzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4", - "dGVuc2lvbnMYAyABKA06RwoZb3B0aW9uYWxfdWludDY0X2V4dGVuc2lvbhIk", - "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGAQgASgEOkcK", - "GW9wdGlvbmFsX3NpbnQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", - "dC5UZXN0QWxsRXh0ZW5zaW9ucxgFIAEoETpHChlvcHRpb25hbF9zaW50NjRf", - "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv", - "bnMYBiABKBI6SAoab3B0aW9uYWxfZml4ZWQzMl9leHRlbnNpb24SJC5wcm90", - "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgHIAEoBzpIChpvcHRp", - "b25hbF9maXhlZDY0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", - "c3RBbGxFeHRlbnNpb25zGAggASgGOkkKG29wdGlvbmFsX3NmaXhlZDMyX2V4", - "dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25z", - "GAkgASgPOkkKG29wdGlvbmFsX3NmaXhlZDY0X2V4dGVuc2lvbhIkLnByb3Rv", - "YnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGAogASgQOkYKGG9wdGlv", - "bmFsX2Zsb2F0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", - "bGxFeHRlbnNpb25zGAsgASgCOkcKGW9wdGlvbmFsX2RvdWJsZV9leHRlbnNp", - "b24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgMIAEo", - "ATpFChdvcHRpb25hbF9ib29sX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0", - "ZXN0LlRlc3RBbGxFeHRlbnNpb25zGA0gASgIOkcKGW9wdGlvbmFsX3N0cmlu", - "Z19leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5z", - "aW9ucxgOIAEoCTpGChhvcHRpb25hbF9ieXRlc19leHRlbnNpb24SJC5wcm90", - "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgPIAEoDDpxChdvcHRp", - "b25hbGdyb3VwX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", - "bGxFeHRlbnNpb25zGBAgASgKMioucHJvdG9idWZfdW5pdHRlc3QuT3B0aW9u", - "YWxHcm91cF9leHRlbnNpb246fgohb3B0aW9uYWxfbmVzdGVkX21lc3NhZ2Vf", - "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv", - "bnMYEiABKAsyLS5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVz", - "dGVkTWVzc2FnZTpzCiJvcHRpb25hbF9mb3JlaWduX21lc3NhZ2VfZXh0ZW5z", - "aW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYEyAB", - "KAsyIS5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduTWVzc2FnZTp4CiFvcHRp", - "b25hbF9pbXBvcnRfbWVzc2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0", - "dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgUIAEoCzInLnByb3RvYnVmX3VuaXR0", - "ZXN0X2ltcG9ydC5JbXBvcnRNZXNzYWdlOngKHm9wdGlvbmFsX25lc3RlZF9l", - "bnVtX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRl", - "bnNpb25zGBUgASgOMioucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVz", - "Lk5lc3RlZEVudW06bQofb3B0aW9uYWxfZm9yZWlnbl9lbnVtX2V4dGVuc2lv", - "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGBYgASgO", - "Mh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbkVudW06cgoeb3B0aW9uYWxf", - "aW1wb3J0X2VudW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVz", - "dEFsbEV4dGVuc2lvbnMYFyABKA4yJC5wcm90b2J1Zl91bml0dGVzdF9pbXBv", - "cnQuSW1wb3J0RW51bTpRCh9vcHRpb25hbF9zdHJpbmdfcGllY2VfZXh0ZW5z", - "aW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYGCAB", - "KAlCAggCOkkKF29wdGlvbmFsX2NvcmRfZXh0ZW5zaW9uEiQucHJvdG9idWZf", - "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYGSABKAlCAggBOoUBCihvcHRp", - "b25hbF9wdWJsaWNfaW1wb3J0X21lc3NhZ2VfZXh0ZW5zaW9uEiQucHJvdG9i", - "dWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYGiABKAsyLS5wcm90b2J1", - "Zl91bml0dGVzdF9pbXBvcnQuUHVibGljSW1wb3J0TWVzc2FnZTqAAQofb3B0", - "aW9uYWxfbGF6eV9tZXNzYWdlX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0", - "ZXN0LlRlc3RBbGxFeHRlbnNpb25zGBsgASgLMi0ucHJvdG9idWZfdW5pdHRl", - "c3QuVGVzdEFsbFR5cGVzLk5lc3RlZE1lc3NhZ2VCAigBOkYKGHJlcGVhdGVk", - "X2ludDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxF", - "eHRlbnNpb25zGB8gAygFOkYKGHJlcGVhdGVkX2ludDY0X2V4dGVuc2lvbhIk", - "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCAgAygDOkcK", - "GXJlcGVhdGVkX3VpbnQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", - "dC5UZXN0QWxsRXh0ZW5zaW9ucxghIAMoDTpHChlyZXBlYXRlZF91aW50NjRf", - "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv", - "bnMYIiADKAQ6RwoZcmVwZWF0ZWRfc2ludDMyX2V4dGVuc2lvbhIkLnByb3Rv", - "YnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCMgAygROkcKGXJlcGVh", - "dGVkX3NpbnQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", - "QWxsRXh0ZW5zaW9ucxgkIAMoEjpIChpyZXBlYXRlZF9maXhlZDMyX2V4dGVu", - "c2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCUg", - "AygHOkgKGnJlcGVhdGVkX2ZpeGVkNjRfZXh0ZW5zaW9uEiQucHJvdG9idWZf", - "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYJiADKAY6SQobcmVwZWF0ZWRf", - "c2ZpeGVkMzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFs", - "bEV4dGVuc2lvbnMYJyADKA86SQobcmVwZWF0ZWRfc2ZpeGVkNjRfZXh0ZW5z", - "aW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYKCAD", - "KBA6RgoYcmVwZWF0ZWRfZmxvYXRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5p", - "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYKSADKAI6RwoZcmVwZWF0ZWRfZG91", - "YmxlX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRl", - "bnNpb25zGCogAygBOkUKF3JlcGVhdGVkX2Jvb2xfZXh0ZW5zaW9uEiQucHJv", - "dG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYKyADKAg6RwoZcmVw", - "ZWF0ZWRfc3RyaW5nX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", - "c3RBbGxFeHRlbnNpb25zGCwgAygJOkYKGHJlcGVhdGVkX2J5dGVzX2V4dGVu", - "c2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGC0g", - "AygMOnEKF3JlcGVhdGVkZ3JvdXBfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5p", - "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYLiADKAoyKi5wcm90b2J1Zl91bml0", - "dGVzdC5SZXBlYXRlZEdyb3VwX2V4dGVuc2lvbjp+CiFyZXBlYXRlZF9uZXN0", - "ZWRfbWVzc2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", - "QWxsRXh0ZW5zaW9ucxgwIAMoCzItLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", - "bGxUeXBlcy5OZXN0ZWRNZXNzYWdlOnMKInJlcGVhdGVkX2ZvcmVpZ25fbWVz", - "c2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", - "ZW5zaW9ucxgxIAMoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25NZXNz", - "YWdlOngKIXJlcGVhdGVkX2ltcG9ydF9tZXNzYWdlX2V4dGVuc2lvbhIkLnBy", - "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGDIgAygLMicucHJv", - "dG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydE1lc3NhZ2U6eAoecmVwZWF0", - "ZWRfbmVzdGVkX2VudW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3Qu", - "VGVzdEFsbEV4dGVuc2lvbnMYMyADKA4yKi5wcm90b2J1Zl91bml0dGVzdC5U", - "ZXN0QWxsVHlwZXMuTmVzdGVkRW51bTptCh9yZXBlYXRlZF9mb3JlaWduX2Vu", - "dW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVu", - "c2lvbnMYNCADKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bTpy", - "Ch5yZXBlYXRlZF9pbXBvcnRfZW51bV9leHRlbnNpb24SJC5wcm90b2J1Zl91", - "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg1IAMoDjIkLnByb3RvYnVmX3Vu", - "aXR0ZXN0X2ltcG9ydC5JbXBvcnRFbnVtOlEKH3JlcGVhdGVkX3N0cmluZ19w", - "aWVjZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", - "ZW5zaW9ucxg2IAMoCUICCAI6SQoXcmVwZWF0ZWRfY29yZF9leHRlbnNpb24S", - "JC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg3IAMoCUIC", - "CAE6gAEKH3JlcGVhdGVkX2xhenlfbWVzc2FnZV9leHRlbnNpb24SJC5wcm90", - "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg5IAMoCzItLnByb3Rv", - "YnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdlQgIoATpJ", - "ChdkZWZhdWx0X2ludDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0", - "LlRlc3RBbGxFeHRlbnNpb25zGD0gASgFOgI0MTpJChdkZWZhdWx0X2ludDY0", - "X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNp", - "b25zGD4gASgDOgI0MjpKChhkZWZhdWx0X3VpbnQzMl9leHRlbnNpb24SJC5w", - "cm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg/IAEoDToCNDM6", - "SgoYZGVmYXVsdF91aW50NjRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRl", - "c3QuVGVzdEFsbEV4dGVuc2lvbnMYQCABKAQ6AjQ0OksKGGRlZmF1bHRfc2lu", - "dDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRl", - "bnNpb25zGEEgASgROgMtNDU6SgoYZGVmYXVsdF9zaW50NjRfZXh0ZW5zaW9u", - "EiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYQiABKBI6", - "AjQ2OksKGWRlZmF1bHRfZml4ZWQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91", - "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhDIAEoBzoCNDc6SwoZZGVmYXVs", - "dF9maXhlZDY0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", - "bGxFeHRlbnNpb25zGEQgASgGOgI0ODpMChpkZWZhdWx0X3NmaXhlZDMyX2V4", - "dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25z", - "GEUgASgPOgI0OTpNChpkZWZhdWx0X3NmaXhlZDY0X2V4dGVuc2lvbhIkLnBy", - "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEYgASgQOgMtNTA6", - "SwoXZGVmYXVsdF9mbG9hdF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", - "dC5UZXN0QWxsRXh0ZW5zaW9ucxhHIAEoAjoENTEuNTpNChhkZWZhdWx0X2Rv", - "dWJsZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", - "ZW5zaW9ucxhIIAEoAToFNTIwMDA6SgoWZGVmYXVsdF9ib29sX2V4dGVuc2lv", - "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEkgASgI", - "OgR0cnVlOk0KGGRlZmF1bHRfc3RyaW5nX2V4dGVuc2lvbhIkLnByb3RvYnVm", - "X3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEogASgJOgVoZWxsbzpMChdk", - "ZWZhdWx0X2J5dGVzX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", - "c3RBbGxFeHRlbnNpb25zGEsgASgMOgV3b3JsZDp8Ch1kZWZhdWx0X25lc3Rl", - "ZF9lbnVtX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxF", - "eHRlbnNpb25zGFEgASgOMioucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5", - "cGVzLk5lc3RlZEVudW06A0JBUjp5Ch5kZWZhdWx0X2ZvcmVpZ25fZW51bV9l", - "eHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9u", - "cxhSIAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtOgtGT1JF", - "SUdOX0JBUjp9Ch1kZWZhdWx0X2ltcG9ydF9lbnVtX2V4dGVuc2lvbhIkLnBy", - "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGFMgASgOMiQucHJv", - "dG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydEVudW06CklNUE9SVF9CQVI6", - "VQoeZGVmYXVsdF9zdHJpbmdfcGllY2VfZXh0ZW5zaW9uEiQucHJvdG9idWZf", - "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYVCABKAk6A2FiY0ICCAI6TQoW", - "ZGVmYXVsdF9jb3JkX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", - "c3RBbGxFeHRlbnNpb25zGFUgASgJOgMxMjNCAggBOkQKFm9uZW9mX3VpbnQz", - "Ml9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5z", - "aW9ucxhvIAEoDTp7Ch5vbmVvZl9uZXN0ZWRfbWVzc2FnZV9leHRlbnNpb24S", - "JC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhwIAEoCzIt", - "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdl", - "OkQKFm9uZW9mX3N0cmluZ19leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", - "dC5UZXN0QWxsRXh0ZW5zaW9ucxhxIAEoCTpDChVvbmVvZl9ieXRlc19leHRl", - "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhy", - "IAEoDDpCChNteV9leHRlbnNpb25fc3RyaW5nEiUucHJvdG9idWZfdW5pdHRl", - "c3QuVGVzdEZpZWxkT3JkZXJpbmdzGDIgASgJOj8KEG15X2V4dGVuc2lvbl9p", - "bnQSJS5wcm90b2J1Zl91bml0dGVzdC5UZXN0RmllbGRPcmRlcmluZ3MYBSAB", - "KAU6SwoWcGFja2VkX2ludDMyX2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0", - "ZXN0LlRlc3RQYWNrZWRFeHRlbnNpb25zGFogAygFQgIQATpLChZwYWNrZWRf", - "aW50NjRfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tl", - "ZEV4dGVuc2lvbnMYWyADKANCAhABOkwKF3BhY2tlZF91aW50MzJfZXh0ZW5z", - "aW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMY", - "XCADKA1CAhABOkwKF3BhY2tlZF91aW50NjRfZXh0ZW5zaW9uEicucHJvdG9i", - "dWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMYXSADKARCAhABOkwK", - "F3BhY2tlZF9zaW50MzJfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3Qu", - "VGVzdFBhY2tlZEV4dGVuc2lvbnMYXiADKBFCAhABOkwKF3BhY2tlZF9zaW50", - "NjRfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4", - "dGVuc2lvbnMYXyADKBJCAhABOk0KGHBhY2tlZF9maXhlZDMyX2V4dGVuc2lv", - "bhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNpb25zGGAg", - "AygHQgIQATpNChhwYWNrZWRfZml4ZWQ2NF9leHRlbnNpb24SJy5wcm90b2J1", - "Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhhIAMoBkICEAE6TgoZ", - "cGFja2VkX3NmaXhlZDMyX2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0", - "LlRlc3RQYWNrZWRFeHRlbnNpb25zGGIgAygPQgIQATpOChlwYWNrZWRfc2Zp", - "eGVkNjRfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tl", - "ZEV4dGVuc2lvbnMYYyADKBBCAhABOksKFnBhY2tlZF9mbG9hdF9leHRlbnNp", - "b24SJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhk", - "IAMoAkICEAE6TAoXcGFja2VkX2RvdWJsZV9leHRlbnNpb24SJy5wcm90b2J1", - "Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhlIAMoAUICEAE6SgoV", - "cGFja2VkX2Jvb2xfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVz", - "dFBhY2tlZEV4dGVuc2lvbnMYZiADKAhCAhABOmoKFXBhY2tlZF9lbnVtX2V4", - "dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNp", - "b25zGGcgAygOMh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbkVudW1CAhAB", - "Ok8KGHVucGFja2VkX2ludDMyX2V4dGVuc2lvbhIpLnByb3RvYnVmX3VuaXR0", - "ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYWiADKAVCAhAAOk8KGHVucGFj", - "a2VkX2ludDY0X2V4dGVuc2lvbhIpLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RV", - "bnBhY2tlZEV4dGVuc2lvbnMYWyADKANCAhAAOlAKGXVucGFja2VkX3VpbnQz", - "Ml9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVzdC5UZXN0VW5wYWNrZWRF", - "eHRlbnNpb25zGFwgAygNQgIQADpQChl1bnBhY2tlZF91aW50NjRfZXh0ZW5z", - "aW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5zaW9u", - "cxhdIAMoBEICEAA6UAoZdW5wYWNrZWRfc2ludDMyX2V4dGVuc2lvbhIpLnBy", - "b3RvYnVmX3VuaXR0ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYXiADKBFC", - "AhAAOlAKGXVucGFja2VkX3NpbnQ2NF9leHRlbnNpb24SKS5wcm90b2J1Zl91", - "bml0dGVzdC5UZXN0VW5wYWNrZWRFeHRlbnNpb25zGF8gAygSQgIQADpRChp1", - "bnBhY2tlZF9maXhlZDMyX2V4dGVuc2lvbhIpLnByb3RvYnVmX3VuaXR0ZXN0", - "LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYYCADKAdCAhAAOlEKGnVucGFja2Vk", - "X2ZpeGVkNjRfZXh0ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVu", - "cGFja2VkRXh0ZW5zaW9ucxhhIAMoBkICEAA6UgobdW5wYWNrZWRfc2ZpeGVk", - "MzJfZXh0ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2Vk", - "RXh0ZW5zaW9ucxhiIAMoD0ICEAA6UgobdW5wYWNrZWRfc2ZpeGVkNjRfZXh0", - "ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5z", - "aW9ucxhjIAMoEEICEAA6TwoYdW5wYWNrZWRfZmxvYXRfZXh0ZW5zaW9uEiku", - "cHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5zaW9ucxhkIAMo", - "AkICEAA6UAoZdW5wYWNrZWRfZG91YmxlX2V4dGVuc2lvbhIpLnByb3RvYnVm", - "X3VuaXR0ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYZSADKAFCAhAAOk4K", - "F3VucGFja2VkX2Jvb2xfZXh0ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3Qu", - "VGVzdFVucGFja2VkRXh0ZW5zaW9ucxhmIAMoCEICEAA6bgoXdW5wYWNrZWRf", - "ZW51bV9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVzdC5UZXN0VW5wYWNr", - "ZWRFeHRlbnNpb25zGGcgAygOMh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWln", - "bkVudW1CAhAAQkFCDVVuaXR0ZXN0UHJvdG9IAYABAYgBAZABAfgBAaoCIUdv", - "b2dsZS5Qcm90b2NvbEJ1ZmZlcnMuVGVzdFByb3Rvcw==")); - pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { - descriptor = root; - internal__static_protobuf_unittest_TestAllTypes__Descriptor = Descriptor.MessageTypes[0]; - internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes__Descriptor, - new string[] { "OptionalInt32", "OptionalInt64", "OptionalUint32", "OptionalUint64", "OptionalSint32", "OptionalSint64", "OptionalFixed32", "OptionalFixed64", "OptionalSfixed32", "OptionalSfixed64", "OptionalFloat", "OptionalDouble", "OptionalBool", "OptionalString", "OptionalBytes", "OptionalGroup", "OptionalNestedMessage", "OptionalForeignMessage", "OptionalImportMessage", "OptionalNestedEnum", "OptionalForeignEnum", "OptionalImportEnum", "OptionalStringPiece", "OptionalCord", "OptionalPublicImportMessage", "OptionalLazyMessage", "RepeatedInt32", "RepeatedInt64", "RepeatedUint32", "RepeatedUint64", "RepeatedSint32", "RepeatedSint64", "RepeatedFixed32", "RepeatedFixed64", "RepeatedSfixed32", "RepeatedSfixed64", "RepeatedFloat", "RepeatedDouble", "RepeatedBool", "RepeatedString", "RepeatedBytes", "RepeatedGroup", "RepeatedNestedMessage", "RepeatedForeignMessage", "RepeatedImportMessage", "RepeatedNestedEnum", "RepeatedForeignEnum", "RepeatedImportEnum", "RepeatedStringPiece", "RepeatedCord", "RepeatedLazyMessage", "DefaultInt32", "DefaultInt64", "DefaultUint32", "DefaultUint64", "DefaultSint32", "DefaultSint64", "DefaultFixed32", "DefaultFixed64", "DefaultSfixed32", "DefaultSfixed64", "DefaultFloat", "DefaultDouble", "DefaultBool", "DefaultString", "DefaultBytes", "DefaultNestedEnum", "DefaultForeignEnum", "DefaultImportEnum", "DefaultStringPiece", "DefaultCord", "OneofUint32", "OneofNestedMessage", "OneofString", "OneofBytes", }); - internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor, - new string[] { "Bb", }); - internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[1]; - internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[2]; - internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor = Descriptor.MessageTypes[1]; - internal__static_protobuf_unittest_NestedTestAllTypes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor, - new string[] { "Child", "Payload", }); - internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor = Descriptor.MessageTypes[2]; - internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor, - new string[] { "DeprecatedInt32", }); - internal__static_protobuf_unittest_ForeignMessage__Descriptor = Descriptor.MessageTypes[3]; - internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_ForeignMessage__Descriptor, - new string[] { "C", }); - internal__static_protobuf_unittest_TestAllExtensions__Descriptor = Descriptor.MessageTypes[4]; - internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllExtensions__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor = Descriptor.MessageTypes[5]; - internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor = Descriptor.MessageTypes[6]; - internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_TestNestedExtension__Descriptor = Descriptor.MessageTypes[7]; - internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedExtension__Descriptor, - new string[] { }); - global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Test = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor.Extensions[0]); - global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.NestedStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor.Extensions[1]); - internal__static_protobuf_unittest_TestRequired__Descriptor = Descriptor.MessageTypes[8]; - internal__static_protobuf_unittest_TestRequired__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequired__Descriptor, - new string[] { "A", "Dummy2", "B", "Dummy4", "Dummy5", "Dummy6", "Dummy7", "Dummy8", "Dummy9", "Dummy10", "Dummy11", "Dummy12", "Dummy13", "Dummy14", "Dummy15", "Dummy16", "Dummy17", "Dummy18", "Dummy19", "Dummy20", "Dummy21", "Dummy22", "Dummy23", "Dummy24", "Dummy25", "Dummy26", "Dummy27", "Dummy28", "Dummy29", "Dummy30", "Dummy31", "Dummy32", "C", }); - global::Google.ProtocolBuffers.TestProtos.TestRequired.Single = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor.Extensions[0]); - global::Google.ProtocolBuffers.TestProtos.TestRequired.Multi = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor.Extensions[1]); - internal__static_protobuf_unittest_TestRequiredForeign__Descriptor = Descriptor.MessageTypes[9]; - internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequiredForeign__Descriptor, - new string[] { "OptionalMessage", "RepeatedMessage", "Dummy", }); - internal__static_protobuf_unittest_TestForeignNested__Descriptor = Descriptor.MessageTypes[10]; - internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestForeignNested__Descriptor, - new string[] { "ForeignNested", }); - internal__static_protobuf_unittest_TestEmptyMessage__Descriptor = Descriptor.MessageTypes[11]; - internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEmptyMessage__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor = Descriptor.MessageTypes[12]; - internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor = Descriptor.MessageTypes[13]; - internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor = Descriptor.MessageTypes[14]; - internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor, - new string[] { "A", "Bb", }); - internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor = Descriptor.MessageTypes[15]; - internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor, - new string[] { "A", "I", }); - internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor = Descriptor.MessageTypes[16]; - internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor, - new string[] { "Bb", }); - internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor = Descriptor.MessageTypes[17]; - internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor, - new string[] { "A", "OptionalInt32", }); - internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor = Descriptor.MessageTypes[18]; - internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor, - new string[] { "A", "Foo", "Bar", }); - internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor = internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor = internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor.NestedTypes[1]; - internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_TestEagerMessage__Descriptor = Descriptor.MessageTypes[19]; - internal__static_protobuf_unittest_TestEagerMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEagerMessage__Descriptor, - new string[] { "SubMessage", }); - internal__static_protobuf_unittest_TestLazyMessage__Descriptor = Descriptor.MessageTypes[20]; - internal__static_protobuf_unittest_TestLazyMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestLazyMessage__Descriptor, - new string[] { "SubMessage", }); - internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor = Descriptor.MessageTypes[21]; - internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor, - new string[] { "OptionalNestedMessage", }); - internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor, - new string[] { "NestedmessageRepeatedInt32", "NestedmessageRepeatedForeignmessage", }); - internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor = Descriptor.MessageTypes[22]; - internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor, - new string[] { "PrimitiveField", "StringField", "EnumField", "MessageField", "StringPieceField", "CordField", "RepeatedPrimitiveField", "RepeatedStringField", "RepeatedEnumField", "RepeatedMessageField", "RepeatedStringPieceField", "RepeatedCordField", }); - internal__static_protobuf_unittest_TestFieldOrderings__Descriptor = Descriptor.MessageTypes[23]; - internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestFieldOrderings__Descriptor, - new string[] { "MyString", "MyInt", "MyFloat", "OptionalNestedMessage", }); - internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestFieldOrderings__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor, - new string[] { "Oo", "Bb", }); - internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor = Descriptor.MessageTypes[24]; - internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor, - new string[] { "EscapedBytes", "LargeUint32", "LargeUint64", "SmallInt32", "SmallInt64", "ReallySmallInt32", "ReallySmallInt64", "Utf8String", "ZeroFloat", "OneFloat", "SmallFloat", "NegativeOneFloat", "NegativeFloat", "LargeFloat", "SmallNegativeFloat", "InfDouble", "NegInfDouble", "NanDouble", "InfFloat", "NegInfFloat", "NanFloat", "CppTrigraph", "StringWithZero", "BytesWithZero", "StringPieceWithZero", "CordWithZero", "ReplacementString", }); - internal__static_protobuf_unittest_SparseEnumMessage__Descriptor = Descriptor.MessageTypes[25]; - internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_SparseEnumMessage__Descriptor, - new string[] { "SparseEnum", }); - internal__static_protobuf_unittest_OneString__Descriptor = Descriptor.MessageTypes[26]; - internal__static_protobuf_unittest_OneString__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OneString__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_MoreString__Descriptor = Descriptor.MessageTypes[27]; - internal__static_protobuf_unittest_MoreString__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_MoreString__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_OneBytes__Descriptor = Descriptor.MessageTypes[28]; - internal__static_protobuf_unittest_OneBytes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OneBytes__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_MoreBytes__Descriptor = Descriptor.MessageTypes[29]; - internal__static_protobuf_unittest_MoreBytes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_MoreBytes__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_Int32Message__Descriptor = Descriptor.MessageTypes[30]; - internal__static_protobuf_unittest_Int32Message__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Int32Message__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_Uint32Message__Descriptor = Descriptor.MessageTypes[31]; - internal__static_protobuf_unittest_Uint32Message__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Uint32Message__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_Int64Message__Descriptor = Descriptor.MessageTypes[32]; - internal__static_protobuf_unittest_Int64Message__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Int64Message__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_Uint64Message__Descriptor = Descriptor.MessageTypes[33]; - internal__static_protobuf_unittest_Uint64Message__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Uint64Message__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_BoolMessage__Descriptor = Descriptor.MessageTypes[34]; - internal__static_protobuf_unittest_BoolMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BoolMessage__Descriptor, - new string[] { "Data", }); - internal__static_protobuf_unittest_TestOneof__Descriptor = Descriptor.MessageTypes[35]; - internal__static_protobuf_unittest_TestOneof__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof__Descriptor, - new string[] { "FooInt", "FooString", "FooMessage", "FooGroup", }); - internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor = internal__static_protobuf_unittest_TestOneof__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestOneof_FooGroup__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor, - new string[] { "A", "B", }); - internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor = Descriptor.MessageTypes[36]; - internal__static_protobuf_unittest_TestOneofBackwardsCompatible__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor, - new string[] { "FooInt", "FooString", "FooMessage", "FooGroup", }); - internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor = internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor, - new string[] { "A", "B", }); - internal__static_protobuf_unittest_TestOneof2__Descriptor = Descriptor.MessageTypes[37]; - internal__static_protobuf_unittest_TestOneof2__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof2__Descriptor, - new string[] { "FooInt", "FooString", "FooCord", "FooStringPiece", "FooBytes", "FooEnum", "FooMessage", "FooGroup", "FooLazyMessage", "BarInt", "BarString", "BarCord", "BarStringPiece", "BarBytes", "BarEnum", "BazInt", "BazString", }); - internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor = internal__static_protobuf_unittest_TestOneof2__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestOneof2_FooGroup__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor, - new string[] { "A", "B", }); - internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestOneof2__Descriptor.NestedTypes[1]; - internal__static_protobuf_unittest_TestOneof2_NestedMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor, - new string[] { "QuxInt", "CorgeInt", }); - internal__static_protobuf_unittest_TestRequiredOneof__Descriptor = Descriptor.MessageTypes[38]; - internal__static_protobuf_unittest_TestRequiredOneof__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequiredOneof__Descriptor, - new string[] { "FooInt", "FooString", "FooMessage", }); - internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestRequiredOneof__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor, - new string[] { "RequiredDouble", }); - internal__static_protobuf_unittest_TestPackedTypes__Descriptor = Descriptor.MessageTypes[39]; - internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestPackedTypes__Descriptor, - new string[] { "PackedInt32", "PackedInt64", "PackedUint32", "PackedUint64", "PackedSint32", "PackedSint64", "PackedFixed32", "PackedFixed64", "PackedSfixed32", "PackedSfixed64", "PackedFloat", "PackedDouble", "PackedBool", "PackedEnum", }); - internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor = Descriptor.MessageTypes[40]; - internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor, - new string[] { "UnpackedInt32", "UnpackedInt64", "UnpackedUint32", "UnpackedUint64", "UnpackedSint32", "UnpackedSint64", "UnpackedFixed32", "UnpackedFixed64", "UnpackedSfixed32", "UnpackedSfixed64", "UnpackedFloat", "UnpackedDouble", "UnpackedBool", "UnpackedEnum", }); - internal__static_protobuf_unittest_TestPackedExtensions__Descriptor = Descriptor.MessageTypes[41]; - internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestPackedExtensions__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor = Descriptor.MessageTypes[42]; - internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor = Descriptor.MessageTypes[43]; - internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor, - new string[] { "ScalarExtension", "EnumExtension", "DynamicEnumExtension", "MessageExtension", "DynamicMessageExtension", "RepeatedExtension", "PackedExtension", }); - internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor = internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor, - new string[] { "DynamicField", }); - internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor = Descriptor.MessageTypes[44]; - internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor, - new string[] { "RepeatedFixed32", "RepeatedInt32", "RepeatedFixed64", "RepeatedInt64", "RepeatedFloat", "RepeatedUint64", }); - internal__static_protobuf_unittest_TestParsingMerge__Descriptor = Descriptor.MessageTypes[45]; - internal__static_protobuf_unittest_TestParsingMerge__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge__Descriptor, - new string[] { "RequiredAllTypes", "OptionalAllTypes", "RepeatedAllTypes", "OptionalGroup", "RepeatedGroup", }); - internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor = internal__static_protobuf_unittest_TestParsingMerge__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor, - new string[] { "Field1", "Field2", "Field3", "Group1", "Group2", "Ext1", "Ext2", }); - internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor = internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor, - new string[] { "Field1", }); - internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor = internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor.NestedTypes[1]; - internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor, - new string[] { "Field1", }); - internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor = internal__static_protobuf_unittest_TestParsingMerge__Descriptor.NestedTypes[1]; - internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor, - new string[] { "OptionalGroupAllTypes", }); - internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor = internal__static_protobuf_unittest_TestParsingMerge__Descriptor.NestedTypes[2]; - internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor, - new string[] { "RepeatedGroupAllTypes", }); - global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.OptionalExt = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Descriptor.Extensions[0]); - global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.RepeatedExt = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Descriptor.Extensions[1]); - internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor = Descriptor.MessageTypes[46]; - internal__static_protobuf_unittest_TestCommentInjectionMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor, - new string[] { "A", }); - internal__static_protobuf_unittest_FooRequest__Descriptor = Descriptor.MessageTypes[47]; - internal__static_protobuf_unittest_FooRequest__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooRequest__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_FooResponse__Descriptor = Descriptor.MessageTypes[48]; - internal__static_protobuf_unittest_FooResponse__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooResponse__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_FooClientMessage__Descriptor = Descriptor.MessageTypes[49]; - internal__static_protobuf_unittest_FooClientMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooClientMessage__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_FooServerMessage__Descriptor = Descriptor.MessageTypes[50]; - internal__static_protobuf_unittest_FooServerMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooServerMessage__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_BarRequest__Descriptor = Descriptor.MessageTypes[51]; - internal__static_protobuf_unittest_BarRequest__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BarRequest__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_BarResponse__Descriptor = Descriptor.MessageTypes[52]; - internal__static_protobuf_unittest_BarResponse__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BarResponse__Descriptor, - new string[] { }); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[0]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[1]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[2]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[3]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[4]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[5]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[6]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[7]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[8]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[9]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFloatExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[10]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalDoubleExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[11]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBoolExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[12]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[13]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[14]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalGroupExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[15]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[16]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[17]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[18]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[19]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[20]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[21]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringPieceExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[22]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalCordExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[23]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalPublicImportMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[24]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalLazyMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[25]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[26]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[27]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[28]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[29]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[30]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[31]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[32]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[33]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[34]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[35]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[36]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[37]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[38]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[39]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBytesExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[40]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedGroupExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[41]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[42]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[43]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[44]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[45]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[46]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[47]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringPieceExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[48]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedCordExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[49]); - global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedLazyMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[50]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[51]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[52]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[53]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[54]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[55]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[56]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[57]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[58]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[59]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[60]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFloatExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[61]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultDoubleExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[62]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBoolExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[63]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[64]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[65]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultNestedEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[66]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultForeignEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[67]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultImportEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[68]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringPieceExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[69]); - global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultCordExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[70]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OneofUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[71]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OneofNestedMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[72]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OneofStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[73]); - global::Google.ProtocolBuffers.TestProtos.Unittest.OneofBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[74]); - global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionString = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[75]); - global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionInt = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[76]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[77]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[78]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[79]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[80]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[81]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[82]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[83]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[84]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[85]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[86]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[87]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[88]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[89]); - global::Google.ProtocolBuffers.TestProtos.Unittest.PackedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[90]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[91]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[92]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[93]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[94]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[95]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[96]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[97]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[98]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[99]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[100]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[101]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[102]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[103]); - global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[104]); - pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); - RegisterAllExtensions(registry); - global::Google.ProtocolBuffers.TestProtos.UnittestImport.RegisterAllExtensions(registry); - return registry; - }; - pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, - new pbd::FileDescriptor[] { - global::Google.ProtocolBuffers.TestProtos.UnittestImport.Descriptor, - }, assigner); - } - #endregion + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Unittest + { + + #region Extension registration + public static void RegisterAllExtensions(pb::ExtensionRegistry registry) + { + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFloatExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalDoubleExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBoolExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBytesExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalGroupExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringPieceExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalCordExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalPublicImportMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalLazyMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFloatExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedDoubleExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBoolExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBytesExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedGroupExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringPieceExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedCordExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedLazyMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFloatExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultDoubleExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBoolExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBytesExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultNestedEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultForeignEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultImportEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringPieceExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultCordExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofNestedMessageExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofStringExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.OneofBytesExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionString); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionInt); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFloatExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedDoubleExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedBoolExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.PackedEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed32Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed64Extension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFloatExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedDoubleExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedBoolExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedEnumExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Test); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.NestedStringExtension); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestRequired.Single); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestRequired.Multi); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.OptionalExt); + registry.Add(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.RepeatedExt); + } + #endregion + #region Extensions + public const int OptionalInt32ExtensionFieldNumber = 1; + public static pb::GeneratedExtensionBase OptionalInt32Extension; + public const int OptionalInt64ExtensionFieldNumber = 2; + public static pb::GeneratedExtensionBase OptionalInt64Extension; + public const int OptionalUint32ExtensionFieldNumber = 3; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase OptionalUint32Extension; + public const int OptionalUint64ExtensionFieldNumber = 4; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase OptionalUint64Extension; + public const int OptionalSint32ExtensionFieldNumber = 5; + public static pb::GeneratedExtensionBase OptionalSint32Extension; + public const int OptionalSint64ExtensionFieldNumber = 6; + public static pb::GeneratedExtensionBase OptionalSint64Extension; + public const int OptionalFixed32ExtensionFieldNumber = 7; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase OptionalFixed32Extension; + public const int OptionalFixed64ExtensionFieldNumber = 8; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase OptionalFixed64Extension; + public const int OptionalSfixed32ExtensionFieldNumber = 9; + public static pb::GeneratedExtensionBase OptionalSfixed32Extension; + public const int OptionalSfixed64ExtensionFieldNumber = 10; + public static pb::GeneratedExtensionBase OptionalSfixed64Extension; + public const int OptionalFloatExtensionFieldNumber = 11; + public static pb::GeneratedExtensionBase OptionalFloatExtension; + public const int OptionalDoubleExtensionFieldNumber = 12; + public static pb::GeneratedExtensionBase OptionalDoubleExtension; + public const int OptionalBoolExtensionFieldNumber = 13; + public static pb::GeneratedExtensionBase OptionalBoolExtension; + public const int OptionalStringExtensionFieldNumber = 14; + public static pb::GeneratedExtensionBase OptionalStringExtension; + public const int OptionalBytesExtensionFieldNumber = 15; + public static pb::GeneratedExtensionBase OptionalBytesExtension; + public const int OptionalGroupExtensionFieldNumber = 16; + public static pb::GeneratedExtensionBase OptionalGroupExtension; + public const int OptionalNestedMessageExtensionFieldNumber = 18; + public static pb::GeneratedExtensionBase OptionalNestedMessageExtension; + public const int OptionalForeignMessageExtensionFieldNumber = 19; + public static pb::GeneratedExtensionBase OptionalForeignMessageExtension; + public const int OptionalImportMessageExtensionFieldNumber = 20; + public static pb::GeneratedExtensionBase OptionalImportMessageExtension; + public const int OptionalNestedEnumExtensionFieldNumber = 21; + public static pb::GeneratedExtensionBase OptionalNestedEnumExtension; + public const int OptionalForeignEnumExtensionFieldNumber = 22; + public static pb::GeneratedExtensionBase OptionalForeignEnumExtension; + public const int OptionalImportEnumExtensionFieldNumber = 23; + public static pb::GeneratedExtensionBase OptionalImportEnumExtension; + public const int OptionalStringPieceExtensionFieldNumber = 24; + public static pb::GeneratedExtensionBase OptionalStringPieceExtension; + public const int OptionalCordExtensionFieldNumber = 25; + public static pb::GeneratedExtensionBase OptionalCordExtension; + public const int OptionalPublicImportMessageExtensionFieldNumber = 26; + public static pb::GeneratedExtensionBase OptionalPublicImportMessageExtension; + public const int OptionalLazyMessageExtensionFieldNumber = 27; + public static pb::GeneratedExtensionBase OptionalLazyMessageExtension; + public const int RepeatedInt32ExtensionFieldNumber = 31; + public static pb::GeneratedExtensionBase> RepeatedInt32Extension; + public const int RepeatedInt64ExtensionFieldNumber = 32; + public static pb::GeneratedExtensionBase> RepeatedInt64Extension; + public const int RepeatedUint32ExtensionFieldNumber = 33; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> RepeatedUint32Extension; + public const int RepeatedUint64ExtensionFieldNumber = 34; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> RepeatedUint64Extension; + public const int RepeatedSint32ExtensionFieldNumber = 35; + public static pb::GeneratedExtensionBase> RepeatedSint32Extension; + public const int RepeatedSint64ExtensionFieldNumber = 36; + public static pb::GeneratedExtensionBase> RepeatedSint64Extension; + public const int RepeatedFixed32ExtensionFieldNumber = 37; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> RepeatedFixed32Extension; + public const int RepeatedFixed64ExtensionFieldNumber = 38; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> RepeatedFixed64Extension; + public const int RepeatedSfixed32ExtensionFieldNumber = 39; + public static pb::GeneratedExtensionBase> RepeatedSfixed32Extension; + public const int RepeatedSfixed64ExtensionFieldNumber = 40; + public static pb::GeneratedExtensionBase> RepeatedSfixed64Extension; + public const int RepeatedFloatExtensionFieldNumber = 41; + public static pb::GeneratedExtensionBase> RepeatedFloatExtension; + public const int RepeatedDoubleExtensionFieldNumber = 42; + public static pb::GeneratedExtensionBase> RepeatedDoubleExtension; + public const int RepeatedBoolExtensionFieldNumber = 43; + public static pb::GeneratedExtensionBase> RepeatedBoolExtension; + public const int RepeatedStringExtensionFieldNumber = 44; + public static pb::GeneratedExtensionBase> RepeatedStringExtension; + public const int RepeatedBytesExtensionFieldNumber = 45; + public static pb::GeneratedExtensionBase> RepeatedBytesExtension; + public const int RepeatedGroupExtensionFieldNumber = 46; + public static pb::GeneratedExtensionBase> RepeatedGroupExtension; + public const int RepeatedNestedMessageExtensionFieldNumber = 48; + public static pb::GeneratedExtensionBase> RepeatedNestedMessageExtension; + public const int RepeatedForeignMessageExtensionFieldNumber = 49; + public static pb::GeneratedExtensionBase> RepeatedForeignMessageExtension; + public const int RepeatedImportMessageExtensionFieldNumber = 50; + public static pb::GeneratedExtensionBase> RepeatedImportMessageExtension; + public const int RepeatedNestedEnumExtensionFieldNumber = 51; + public static pb::GeneratedExtensionBase> RepeatedNestedEnumExtension; + public const int RepeatedForeignEnumExtensionFieldNumber = 52; + public static pb::GeneratedExtensionBase> RepeatedForeignEnumExtension; + public const int RepeatedImportEnumExtensionFieldNumber = 53; + public static pb::GeneratedExtensionBase> RepeatedImportEnumExtension; + public const int RepeatedStringPieceExtensionFieldNumber = 54; + public static pb::GeneratedExtensionBase> RepeatedStringPieceExtension; + public const int RepeatedCordExtensionFieldNumber = 55; + public static pb::GeneratedExtensionBase> RepeatedCordExtension; + public const int RepeatedLazyMessageExtensionFieldNumber = 57; + public static pb::GeneratedExtensionBase> RepeatedLazyMessageExtension; + public const int DefaultInt32ExtensionFieldNumber = 61; + public static pb::GeneratedExtensionBase DefaultInt32Extension; + public const int DefaultInt64ExtensionFieldNumber = 62; + public static pb::GeneratedExtensionBase DefaultInt64Extension; + public const int DefaultUint32ExtensionFieldNumber = 63; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase DefaultUint32Extension; + public const int DefaultUint64ExtensionFieldNumber = 64; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase DefaultUint64Extension; + public const int DefaultSint32ExtensionFieldNumber = 65; + public static pb::GeneratedExtensionBase DefaultSint32Extension; + public const int DefaultSint64ExtensionFieldNumber = 66; + public static pb::GeneratedExtensionBase DefaultSint64Extension; + public const int DefaultFixed32ExtensionFieldNumber = 67; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase DefaultFixed32Extension; + public const int DefaultFixed64ExtensionFieldNumber = 68; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase DefaultFixed64Extension; + public const int DefaultSfixed32ExtensionFieldNumber = 69; + public static pb::GeneratedExtensionBase DefaultSfixed32Extension; + public const int DefaultSfixed64ExtensionFieldNumber = 70; + public static pb::GeneratedExtensionBase DefaultSfixed64Extension; + public const int DefaultFloatExtensionFieldNumber = 71; + public static pb::GeneratedExtensionBase DefaultFloatExtension; + public const int DefaultDoubleExtensionFieldNumber = 72; + public static pb::GeneratedExtensionBase DefaultDoubleExtension; + public const int DefaultBoolExtensionFieldNumber = 73; + public static pb::GeneratedExtensionBase DefaultBoolExtension; + public const int DefaultStringExtensionFieldNumber = 74; + public static pb::GeneratedExtensionBase DefaultStringExtension; + public const int DefaultBytesExtensionFieldNumber = 75; + public static pb::GeneratedExtensionBase DefaultBytesExtension; + public const int DefaultNestedEnumExtensionFieldNumber = 81; + public static pb::GeneratedExtensionBase DefaultNestedEnumExtension; + public const int DefaultForeignEnumExtensionFieldNumber = 82; + public static pb::GeneratedExtensionBase DefaultForeignEnumExtension; + public const int DefaultImportEnumExtensionFieldNumber = 83; + public static pb::GeneratedExtensionBase DefaultImportEnumExtension; + public const int DefaultStringPieceExtensionFieldNumber = 84; + public static pb::GeneratedExtensionBase DefaultStringPieceExtension; + public const int DefaultCordExtensionFieldNumber = 85; + public static pb::GeneratedExtensionBase DefaultCordExtension; + public const int OneofUint32ExtensionFieldNumber = 111; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase OneofUint32Extension; + public const int OneofNestedMessageExtensionFieldNumber = 112; + public static pb::GeneratedExtensionBase OneofNestedMessageExtension; + public const int OneofStringExtensionFieldNumber = 113; + public static pb::GeneratedExtensionBase OneofStringExtension; + public const int OneofBytesExtensionFieldNumber = 114; + public static pb::GeneratedExtensionBase OneofBytesExtension; + public const int MyExtensionStringFieldNumber = 50; + public static pb::GeneratedExtensionBase MyExtensionString; + public const int MyExtensionIntFieldNumber = 5; + public static pb::GeneratedExtensionBase MyExtensionInt; + public const int PackedInt32ExtensionFieldNumber = 90; + public static pb::GeneratedExtensionBase> PackedInt32Extension; + public const int PackedInt64ExtensionFieldNumber = 91; + public static pb::GeneratedExtensionBase> PackedInt64Extension; + public const int PackedUint32ExtensionFieldNumber = 92; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> PackedUint32Extension; + public const int PackedUint64ExtensionFieldNumber = 93; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> PackedUint64Extension; + public const int PackedSint32ExtensionFieldNumber = 94; + public static pb::GeneratedExtensionBase> PackedSint32Extension; + public const int PackedSint64ExtensionFieldNumber = 95; + public static pb::GeneratedExtensionBase> PackedSint64Extension; + public const int PackedFixed32ExtensionFieldNumber = 96; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> PackedFixed32Extension; + public const int PackedFixed64ExtensionFieldNumber = 97; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> PackedFixed64Extension; + public const int PackedSfixed32ExtensionFieldNumber = 98; + public static pb::GeneratedExtensionBase> PackedSfixed32Extension; + public const int PackedSfixed64ExtensionFieldNumber = 99; + public static pb::GeneratedExtensionBase> PackedSfixed64Extension; + public const int PackedFloatExtensionFieldNumber = 100; + public static pb::GeneratedExtensionBase> PackedFloatExtension; + public const int PackedDoubleExtensionFieldNumber = 101; + public static pb::GeneratedExtensionBase> PackedDoubleExtension; + public const int PackedBoolExtensionFieldNumber = 102; + public static pb::GeneratedExtensionBase> PackedBoolExtension; + public const int PackedEnumExtensionFieldNumber = 103; + public static pb::GeneratedExtensionBase> PackedEnumExtension; + public const int UnpackedInt32ExtensionFieldNumber = 90; + public static pb::GeneratedExtensionBase> UnpackedInt32Extension; + public const int UnpackedInt64ExtensionFieldNumber = 91; + public static pb::GeneratedExtensionBase> UnpackedInt64Extension; + public const int UnpackedUint32ExtensionFieldNumber = 92; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> UnpackedUint32Extension; + public const int UnpackedUint64ExtensionFieldNumber = 93; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> UnpackedUint64Extension; + public const int UnpackedSint32ExtensionFieldNumber = 94; + public static pb::GeneratedExtensionBase> UnpackedSint32Extension; + public const int UnpackedSint64ExtensionFieldNumber = 95; + public static pb::GeneratedExtensionBase> UnpackedSint64Extension; + public const int UnpackedFixed32ExtensionFieldNumber = 96; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> UnpackedFixed32Extension; + public const int UnpackedFixed64ExtensionFieldNumber = 97; + [global::System.CLSCompliant(false)] + public static pb::GeneratedExtensionBase> UnpackedFixed64Extension; + public const int UnpackedSfixed32ExtensionFieldNumber = 98; + public static pb::GeneratedExtensionBase> UnpackedSfixed32Extension; + public const int UnpackedSfixed64ExtensionFieldNumber = 99; + public static pb::GeneratedExtensionBase> UnpackedSfixed64Extension; + public const int UnpackedFloatExtensionFieldNumber = 100; + public static pb::GeneratedExtensionBase> UnpackedFloatExtension; + public const int UnpackedDoubleExtensionFieldNumber = 101; + public static pb::GeneratedExtensionBase> UnpackedDoubleExtension; + public const int UnpackedBoolExtensionFieldNumber = 102; + public static pb::GeneratedExtensionBase> UnpackedBoolExtension; + public const int UnpackedEnumExtensionFieldNumber = 103; + public static pb::GeneratedExtensionBase> UnpackedEnumExtension; + #endregion - } - #region Enums - public enum ForeignEnum { - FOREIGN_FOO = 4, - FOREIGN_BAR = 5, - FOREIGN_BAZ = 6, - } - - public enum TestEnumWithDupValue { - FOO1 = 1, - BAR1 = 2, - BAZ = 3, - FOO2 = 1, - BAR2 = 2, - } - - public enum TestSparseEnum { - SPARSE_A = 123, - SPARSE_B = 62374, - SPARSE_C = 12589234, - SPARSE_D = -15, - SPARSE_E = -53452, - SPARSE_F = 0, - SPARSE_G = 2, - } - - #endregion - - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestAllTypes : pb::GeneratedMessage { - private TestAllTypes() { } - private static readonly TestAllTypes defaultInstance = new TestAllTypes().MakeReadOnly(); - private static readonly string[] _testAllTypesFieldNames = new string[] { "default_bool", "default_bytes", "default_cord", "default_double", "default_fixed32", "default_fixed64", "default_float", "default_foreign_enum", "default_import_enum", "default_int32", "default_int64", "default_nested_enum", "default_sfixed32", "default_sfixed64", "default_sint32", "default_sint64", "default_string", "default_string_piece", "default_uint32", "default_uint64", "oneof_bytes", "oneof_nested_message", "oneof_string", "oneof_uint32", "optional_bool", "optional_bytes", "optional_cord", "optional_double", "optional_fixed32", "optional_fixed64", "optional_float", "optional_foreign_enum", "optional_foreign_message", "optional_import_enum", "optional_import_message", "optional_int32", "optional_int64", "optional_lazy_message", "optional_nested_enum", "optional_nested_message", "optional_public_import_message", "optional_sfixed32", "optional_sfixed64", "optional_sint32", "optional_sint64", "optional_string", "optional_string_piece", "optional_uint32", "optional_uint64", "optionalgroup", "repeated_bool", "repeated_bytes", "repeated_cord", "repeated_double", "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_foreign_enum", "repeated_foreign_message", "repeated_import_enum", "repeated_import_message", "repeated_int32", "repeated_int64", "repeated_lazy_message", "repeated_nested_enum", "repeated_nested_message", "repeated_sfixed32", "repeated_sfixed64", "repeated_sint32", "repeated_sint64", "repeated_string", "repeated_string_piece", "repeated_uint32", "repeated_uint64", "repeatedgroup" }; - private static readonly uint[] _testAllTypesFieldTags = new uint[] { 584, 602, 682, 577, 541, 545, 573, 656, 664, 488, 496, 648, 557, 561, 520, 528, 594, 674, 504, 512, 914, 898, 906, 888, 104, 122, 202, 97, 61, 65, 93, 176, 154, 184, 162, 8, 16, 218, 168, 146, 210, 77, 81, 40, 48, 114, 194, 24, 32, 131, 344, 362, 442, 337, 301, 305, 333, 416, 394, 424, 402, 248, 256, 458, 408, 386, 317, 321, 280, 288, 354, 434, 264, 272, 371 }; - public static TestAllTypes DefaultInstance { - get { return defaultInstance; } - } + #region Static variables + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_NestedTestAllTypes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_ForeignMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllExtensions__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedExtension__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequired__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequired__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredForeign__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestForeignNested__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEmptyMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEagerMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestEagerMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestLazyMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestLazyMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestFieldOrderings__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_SparseEnumMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OneString__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OneString__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_MoreString__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_MoreString__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OneBytes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_OneBytes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_MoreBytes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_MoreBytes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Int32Message__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Int32Message__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Uint32Message__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Uint32Message__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Int64Message__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Int64Message__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_Uint64Message__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_Uint64Message__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BoolMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BoolMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof_FooGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneofBackwardsCompatible__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof2__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof2__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof2_FooGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestOneof2_NestedMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredOneof__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequiredOneof__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestPackedTypes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestPackedExtensions__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_TestCommentInjectionMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooRequest__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooRequest__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooResponse__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooResponse__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooClientMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooClientMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooServerMessage__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_FooServerMessage__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BarRequest__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BarRequest__FieldAccessorTable; + internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BarResponse__Descriptor; + internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_BarResponse__FieldAccessorTable; + #endregion + #region Descriptor + public static pbd::FileDescriptor Descriptor + { + get { return descriptor; } + } + private static pbd::FileDescriptor descriptor; + + static Unittest() + { + byte[] descriptorData = global::System.Convert.FromBase64String( + string.Concat( + "Ch5nb29nbGUvcHJvdG9idWYvdW5pdHRlc3QucHJvdG8SEXByb3RvYnVmX3Vu", + "aXR0ZXN0GiVnb29nbGUvcHJvdG9idWYvdW5pdHRlc3RfaW1wb3J0LnByb3Rv", + "Iu0YCgxUZXN0QWxsVHlwZXMSFgoOb3B0aW9uYWxfaW50MzIYASABKAUSFgoO", + "b3B0aW9uYWxfaW50NjQYAiABKAMSFwoPb3B0aW9uYWxfdWludDMyGAMgASgN", + "EhcKD29wdGlvbmFsX3VpbnQ2NBgEIAEoBBIXCg9vcHRpb25hbF9zaW50MzIY", + "BSABKBESFwoPb3B0aW9uYWxfc2ludDY0GAYgASgSEhgKEG9wdGlvbmFsX2Zp", + "eGVkMzIYByABKAcSGAoQb3B0aW9uYWxfZml4ZWQ2NBgIIAEoBhIZChFvcHRp", + "b25hbF9zZml4ZWQzMhgJIAEoDxIZChFvcHRpb25hbF9zZml4ZWQ2NBgKIAEo", + "EBIWCg5vcHRpb25hbF9mbG9hdBgLIAEoAhIXCg9vcHRpb25hbF9kb3VibGUY", + "DCABKAESFQoNb3B0aW9uYWxfYm9vbBgNIAEoCBIXCg9vcHRpb25hbF9zdHJp", + "bmcYDiABKAkSFgoOb3B0aW9uYWxfYnl0ZXMYDyABKAwSRAoNb3B0aW9uYWxn", + "cm91cBgQIAEoCjItLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5P", + "cHRpb25hbEdyb3VwEk4KF29wdGlvbmFsX25lc3RlZF9tZXNzYWdlGBIgASgL", + "Mi0ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzLk5lc3RlZE1lc3Nh", + "Z2USQwoYb3B0aW9uYWxfZm9yZWlnbl9tZXNzYWdlGBMgASgLMiEucHJvdG9i", + "dWZfdW5pdHRlc3QuRm9yZWlnbk1lc3NhZ2USSAoXb3B0aW9uYWxfaW1wb3J0", + "X21lc3NhZ2UYFCABKAsyJy5wcm90b2J1Zl91bml0dGVzdF9pbXBvcnQuSW1w", + "b3J0TWVzc2FnZRJIChRvcHRpb25hbF9uZXN0ZWRfZW51bRgVIAEoDjIqLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRFbnVtEj0KFW9w", + "dGlvbmFsX2ZvcmVpZ25fZW51bRgWIAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0", + "LkZvcmVpZ25FbnVtEkIKFG9wdGlvbmFsX2ltcG9ydF9lbnVtGBcgASgOMiQu", + "cHJvdG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydEVudW0SIQoVb3B0aW9u", + "YWxfc3RyaW5nX3BpZWNlGBggASgJQgIIAhIZCg1vcHRpb25hbF9jb3JkGBkg", + "ASgJQgIIARJVCh5vcHRpb25hbF9wdWJsaWNfaW1wb3J0X21lc3NhZ2UYGiAB", + "KAsyLS5wcm90b2J1Zl91bml0dGVzdF9pbXBvcnQuUHVibGljSW1wb3J0TWVz", + "c2FnZRJQChVvcHRpb25hbF9sYXp5X21lc3NhZ2UYGyABKAsyLS5wcm90b2J1", + "Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkTWVzc2FnZUICKAESFgoO", + "cmVwZWF0ZWRfaW50MzIYHyADKAUSFgoOcmVwZWF0ZWRfaW50NjQYICADKAMS", + "FwoPcmVwZWF0ZWRfdWludDMyGCEgAygNEhcKD3JlcGVhdGVkX3VpbnQ2NBgi", + "IAMoBBIXCg9yZXBlYXRlZF9zaW50MzIYIyADKBESFwoPcmVwZWF0ZWRfc2lu", + "dDY0GCQgAygSEhgKEHJlcGVhdGVkX2ZpeGVkMzIYJSADKAcSGAoQcmVwZWF0", + "ZWRfZml4ZWQ2NBgmIAMoBhIZChFyZXBlYXRlZF9zZml4ZWQzMhgnIAMoDxIZ", + "ChFyZXBlYXRlZF9zZml4ZWQ2NBgoIAMoEBIWCg5yZXBlYXRlZF9mbG9hdBgp", + "IAMoAhIXCg9yZXBlYXRlZF9kb3VibGUYKiADKAESFQoNcmVwZWF0ZWRfYm9v", + "bBgrIAMoCBIXCg9yZXBlYXRlZF9zdHJpbmcYLCADKAkSFgoOcmVwZWF0ZWRf", + "Ynl0ZXMYLSADKAwSRAoNcmVwZWF0ZWRncm91cBguIAMoCjItLnByb3RvYnVm", + "X3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5SZXBlYXRlZEdyb3VwEk4KF3JlcGVh", + "dGVkX25lc3RlZF9tZXNzYWdlGDAgAygLMi0ucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdEFsbFR5cGVzLk5lc3RlZE1lc3NhZ2USQwoYcmVwZWF0ZWRfZm9yZWln", + "bl9tZXNzYWdlGDEgAygLMiEucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbk1l", + "c3NhZ2USSAoXcmVwZWF0ZWRfaW1wb3J0X21lc3NhZ2UYMiADKAsyJy5wcm90", + "b2J1Zl91bml0dGVzdF9pbXBvcnQuSW1wb3J0TWVzc2FnZRJIChRyZXBlYXRl", + "ZF9uZXN0ZWRfZW51bRgzIAMoDjIqLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", + "bGxUeXBlcy5OZXN0ZWRFbnVtEj0KFXJlcGVhdGVkX2ZvcmVpZ25fZW51bRg0", + "IAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtEkIKFHJlcGVh", + "dGVkX2ltcG9ydF9lbnVtGDUgAygOMiQucHJvdG9idWZfdW5pdHRlc3RfaW1w", + "b3J0LkltcG9ydEVudW0SIQoVcmVwZWF0ZWRfc3RyaW5nX3BpZWNlGDYgAygJ", + "QgIIAhIZCg1yZXBlYXRlZF9jb3JkGDcgAygJQgIIARJQChVyZXBlYXRlZF9s", + "YXp5X21lc3NhZ2UYOSADKAsyLS5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxs", + "VHlwZXMuTmVzdGVkTWVzc2FnZUICKAESGQoNZGVmYXVsdF9pbnQzMhg9IAEo", + "BToCNDESGQoNZGVmYXVsdF9pbnQ2NBg+IAEoAzoCNDISGgoOZGVmYXVsdF91", + "aW50MzIYPyABKA06AjQzEhoKDmRlZmF1bHRfdWludDY0GEAgASgEOgI0NBIb", + "Cg5kZWZhdWx0X3NpbnQzMhhBIAEoEToDLTQ1EhoKDmRlZmF1bHRfc2ludDY0", + "GEIgASgSOgI0NhIbCg9kZWZhdWx0X2ZpeGVkMzIYQyABKAc6AjQ3EhsKD2Rl", + "ZmF1bHRfZml4ZWQ2NBhEIAEoBjoCNDgSHAoQZGVmYXVsdF9zZml4ZWQzMhhF", + "IAEoDzoCNDkSHQoQZGVmYXVsdF9zZml4ZWQ2NBhGIAEoEDoDLTUwEhsKDWRl", + "ZmF1bHRfZmxvYXQYRyABKAI6BDUxLjUSHQoOZGVmYXVsdF9kb3VibGUYSCAB", + "KAE6BTUyMDAwEhoKDGRlZmF1bHRfYm9vbBhJIAEoCDoEdHJ1ZRIdCg5kZWZh", + "dWx0X3N0cmluZxhKIAEoCToFaGVsbG8SHAoNZGVmYXVsdF9ieXRlcxhLIAEo", + "DDoFd29ybGQSTAoTZGVmYXVsdF9uZXN0ZWRfZW51bRhRIAEoDjIqLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRFbnVtOgNCQVISSQoU", + "ZGVmYXVsdF9mb3JlaWduX2VudW0YUiABKA4yHi5wcm90b2J1Zl91bml0dGVz", + "dC5Gb3JlaWduRW51bToLRk9SRUlHTl9CQVISTQoTZGVmYXVsdF9pbXBvcnRf", + "ZW51bRhTIAEoDjIkLnByb3RvYnVmX3VuaXR0ZXN0X2ltcG9ydC5JbXBvcnRF", + "bnVtOgpJTVBPUlRfQkFSEiUKFGRlZmF1bHRfc3RyaW5nX3BpZWNlGFQgASgJ", + "OgNhYmNCAggCEh0KDGRlZmF1bHRfY29yZBhVIAEoCToDMTIzQgIIARIWCgxv", + "bmVvZl91aW50MzIYbyABKA1IABJNChRvbmVvZl9uZXN0ZWRfbWVzc2FnZRhw", + "IAEoCzItLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRN", + "ZXNzYWdlSAASFgoMb25lb2Zfc3RyaW5nGHEgASgJSAASFQoLb25lb2ZfYnl0", + "ZXMYciABKAxIABobCg1OZXN0ZWRNZXNzYWdlEgoKAmJiGAEgASgFGhoKDU9w", + "dGlvbmFsR3JvdXASCQoBYRgRIAEoBRoaCg1SZXBlYXRlZEdyb3VwEgkKAWEY", + "LyABKAUiOQoKTmVzdGVkRW51bRIHCgNGT08QARIHCgNCQVIQAhIHCgNCQVoQ", + "AxIQCgNORUcQ////////////AUINCgtvbmVvZl9maWVsZCJ8ChJOZXN0ZWRU", + "ZXN0QWxsVHlwZXMSNAoFY2hpbGQYASABKAsyJS5wcm90b2J1Zl91bml0dGVz", + "dC5OZXN0ZWRUZXN0QWxsVHlwZXMSMAoHcGF5bG9hZBgCIAEoCzIfLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcyI0ChRUZXN0RGVwcmVjYXRlZEZp", + "ZWxkcxIcChBkZXByZWNhdGVkX2ludDMyGAEgASgFQgIYASIbCg5Gb3JlaWdu", + "TWVzc2FnZRIJCgFjGAEgASgFIh0KEVRlc3RBbGxFeHRlbnNpb25zKggIARCA", + "gICAAiIkChdPcHRpb25hbEdyb3VwX2V4dGVuc2lvbhIJCgFhGBEgASgFIiQK", + "F1JlcGVhdGVkR3JvdXBfZXh0ZW5zaW9uEgkKAWEYLyABKAUimAEKE1Rlc3RO", + "ZXN0ZWRFeHRlbnNpb24yOQoEdGVzdBIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxFeHRlbnNpb25zGOoHIAEoCToEdGVzdDJGChduZXN0ZWRfc3RyaW5n", + "X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNp", + "b25zGOsHIAEoCSLVBQoMVGVzdFJlcXVpcmVkEgkKAWEYASACKAUSDgoGZHVt", + "bXkyGAIgASgFEgkKAWIYAyACKAUSDgoGZHVtbXk0GAQgASgFEg4KBmR1bW15", + "NRgFIAEoBRIOCgZkdW1teTYYBiABKAUSDgoGZHVtbXk3GAcgASgFEg4KBmR1", + "bW15OBgIIAEoBRIOCgZkdW1teTkYCSABKAUSDwoHZHVtbXkxMBgKIAEoBRIP", + "CgdkdW1teTExGAsgASgFEg8KB2R1bW15MTIYDCABKAUSDwoHZHVtbXkxMxgN", + "IAEoBRIPCgdkdW1teTE0GA4gASgFEg8KB2R1bW15MTUYDyABKAUSDwoHZHVt", + "bXkxNhgQIAEoBRIPCgdkdW1teTE3GBEgASgFEg8KB2R1bW15MTgYEiABKAUS", + "DwoHZHVtbXkxORgTIAEoBRIPCgdkdW1teTIwGBQgASgFEg8KB2R1bW15MjEY", + "FSABKAUSDwoHZHVtbXkyMhgWIAEoBRIPCgdkdW1teTIzGBcgASgFEg8KB2R1", + "bW15MjQYGCABKAUSDwoHZHVtbXkyNRgZIAEoBRIPCgdkdW1teTI2GBogASgF", + "Eg8KB2R1bW15MjcYGyABKAUSDwoHZHVtbXkyOBgcIAEoBRIPCgdkdW1teTI5", + "GB0gASgFEg8KB2R1bW15MzAYHiABKAUSDwoHZHVtbXkzMRgfIAEoBRIPCgdk", + "dW1teTMyGCAgASgFEgkKAWMYISACKAUyVgoGc2luZ2xlEiQucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY6AcgASgLMh8ucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdFJlcXVpcmVkMlUKBW11bHRpEiQucHJvdG9idWZfdW5p", + "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY6QcgAygLMh8ucHJvdG9idWZfdW5p", + "dHRlc3QuVGVzdFJlcXVpcmVkIpoBChNUZXN0UmVxdWlyZWRGb3JlaWduEjkK", + "EG9wdGlvbmFsX21lc3NhZ2UYASABKAsyHy5wcm90b2J1Zl91bml0dGVzdC5U", + "ZXN0UmVxdWlyZWQSOQoQcmVwZWF0ZWRfbWVzc2FnZRgCIAMoCzIfLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RSZXF1aXJlZBINCgVkdW1teRgDIAEoBSJaChFU", + "ZXN0Rm9yZWlnbk5lc3RlZBJFCg5mb3JlaWduX25lc3RlZBgBIAEoCzItLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdlIhIK", + "EFRlc3RFbXB0eU1lc3NhZ2UiKgoeVGVzdEVtcHR5TWVzc2FnZVdpdGhFeHRl", + "bnNpb25zKggIARCAgICAAiI3ChtUZXN0TXVsdGlwbGVFeHRlbnNpb25SYW5n", + "ZXMqBAgqECsqBgivIBCUISoKCICABBCAgICAAiI0ChhUZXN0UmVhbGx5TGFy", + "Z2VUYWdOdW1iZXISCQoBYRgBIAEoBRINCgJiYhj///9/IAEoBSJVChRUZXN0", + "UmVjdXJzaXZlTWVzc2FnZRIyCgFhGAEgASgLMicucHJvdG9idWZfdW5pdHRl", + "c3QuVGVzdFJlY3Vyc2l2ZU1lc3NhZ2USCQoBaRgCIAEoBSJLChRUZXN0TXV0", + "dWFsUmVjdXJzaW9uQRIzCgJiYhgBIAEoCzInLnByb3RvYnVmX3VuaXR0ZXN0", + "LlRlc3RNdXR1YWxSZWN1cnNpb25CImIKFFRlc3RNdXR1YWxSZWN1cnNpb25C", + "EjIKAWEYASABKAsyJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0TXV0dWFsUmVj", + "dXJzaW9uQRIWCg5vcHRpb25hbF9pbnQzMhgCIAEoBSKzAQoSVGVzdER1cEZp", + "ZWxkTnVtYmVyEgkKAWEYASABKAUSNgoDZm9vGAIgASgKMikucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdER1cEZpZWxkTnVtYmVyLkZvbxI2CgNiYXIYAyABKAoy", + "KS5wcm90b2J1Zl91bml0dGVzdC5UZXN0RHVwRmllbGROdW1iZXIuQmFyGhAK", + "A0ZvbxIJCgFhGAEgASgFGhAKA0JhchIJCgFhGAEgASgFIkwKEFRlc3RFYWdl", + "ck1lc3NhZ2USOAoLc3ViX21lc3NhZ2UYASABKAsyHy5wcm90b2J1Zl91bml0", + "dGVzdC5UZXN0QWxsVHlwZXNCAigAIksKD1Rlc3RMYXp5TWVzc2FnZRI4Cgtz", + "dWJfbWVzc2FnZRgBIAEoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxU", + "eXBlc0ICKAEigAIKGFRlc3ROZXN0ZWRNZXNzYWdlSGFzQml0cxJaChdvcHRp", + "b25hbF9uZXN0ZWRfbWVzc2FnZRgBIAEoCzI5LnByb3RvYnVmX3VuaXR0ZXN0", + "LlRlc3ROZXN0ZWRNZXNzYWdlSGFzQml0cy5OZXN0ZWRNZXNzYWdlGocBCg1O", + "ZXN0ZWRNZXNzYWdlEiQKHG5lc3RlZG1lc3NhZ2VfcmVwZWF0ZWRfaW50MzIY", + "ASADKAUSUAolbmVzdGVkbWVzc2FnZV9yZXBlYXRlZF9mb3JlaWdubWVzc2Fn", + "ZRgCIAMoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25NZXNzYWdlIuUD", + "ChdUZXN0Q2FtZWxDYXNlRmllbGROYW1lcxIWCg5QcmltaXRpdmVGaWVsZBgB", + "IAEoBRITCgtTdHJpbmdGaWVsZBgCIAEoCRIxCglFbnVtRmllbGQYAyABKA4y", + "Hi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bRI3CgxNZXNzYWdlRmll", + "bGQYBCABKAsyIS5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduTWVzc2FnZRIc", + "ChBTdHJpbmdQaWVjZUZpZWxkGAUgASgJQgIIAhIVCglDb3JkRmllbGQYBiAB", + "KAlCAggBEh4KFlJlcGVhdGVkUHJpbWl0aXZlRmllbGQYByADKAUSGwoTUmVw", + "ZWF0ZWRTdHJpbmdGaWVsZBgIIAMoCRI5ChFSZXBlYXRlZEVudW1GaWVsZBgJ", + "IAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtEj8KFFJlcGVh", + "dGVkTWVzc2FnZUZpZWxkGAogAygLMiEucHJvdG9idWZfdW5pdHRlc3QuRm9y", + "ZWlnbk1lc3NhZ2USJAoYUmVwZWF0ZWRTdHJpbmdQaWVjZUZpZWxkGAsgAygJ", + "QgIIAhIdChFSZXBlYXRlZENvcmRGaWVsZBgMIAMoCUICCAEi1QEKElRlc3RG", + "aWVsZE9yZGVyaW5ncxIRCglteV9zdHJpbmcYCyABKAkSDgoGbXlfaW50GAEg", + "ASgDEhAKCG15X2Zsb2F0GGUgASgCElUKF29wdGlvbmFsX25lc3RlZF9tZXNz", + "YWdlGMgBIAEoCzIzLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RGaWVsZE9yZGVy", + "aW5ncy5OZXN0ZWRNZXNzYWdlGicKDU5lc3RlZE1lc3NhZ2USCgoCb28YAiAB", + "KAMSCgoCYmIYASABKAUqBAgCEAsqBAgMEGUitgcKGFRlc3RFeHRyZW1lRGVm", + "YXVsdFZhbHVlcxI/Cg1lc2NhcGVkX2J5dGVzGAEgASgMOihcMDAwXDAwMVww", + "MDdcMDEwXDAxNFxuXHJcdFwwMTNcXFwnXCJcMzc2EiAKDGxhcmdlX3VpbnQz", + "MhgCIAEoDToKNDI5NDk2NzI5NRIqCgxsYXJnZV91aW50NjQYAyABKAQ6FDE4", + "NDQ2NzQ0MDczNzA5NTUxNjE1EiAKC3NtYWxsX2ludDMyGAQgASgFOgstMjE0", + "NzQ4MzY0NxIpCgtzbWFsbF9pbnQ2NBgFIAEoAzoULTkyMjMzNzIwMzY4NTQ3", + "NzU4MDcSJwoScmVhbGx5X3NtYWxsX2ludDMyGBUgASgFOgstMjE0NzQ4MzY0", + "OBIwChJyZWFsbHlfc21hbGxfaW50NjQYFiABKAM6FC05MjIzMzcyMDM2ODU0", + "Nzc1ODA4EhgKC3V0Zjhfc3RyaW5nGAYgASgJOgPhiLQSFQoKemVyb19mbG9h", + "dBgHIAEoAjoBMBIUCglvbmVfZmxvYXQYCCABKAI6ATESGAoLc21hbGxfZmxv", + "YXQYCSABKAI6AzEuNRIeChJuZWdhdGl2ZV9vbmVfZmxvYXQYCiABKAI6Ai0x", + "EhwKDm5lZ2F0aXZlX2Zsb2F0GAsgASgCOgQtMS41EhoKC2xhcmdlX2Zsb2F0", + "GAwgASgCOgUyZSswOBIkChRzbWFsbF9uZWdhdGl2ZV9mbG9hdBgNIAEoAjoG", + "LThlLTI4EhcKCmluZl9kb3VibGUYDiABKAE6A2luZhIcCg5uZWdfaW5mX2Rv", + "dWJsZRgPIAEoAToELWluZhIXCgpuYW5fZG91YmxlGBAgASgBOgNuYW4SFgoJ", + "aW5mX2Zsb2F0GBEgASgCOgNpbmYSGwoNbmVnX2luZl9mbG9hdBgSIAEoAjoE", + "LWluZhIWCgluYW5fZmxvYXQYEyABKAI6A25hbhIrCgxjcHBfdHJpZ3JhcGgY", + "FCABKAk6FT8gPyA/PyA/PyA/Pz8gPz8vID8/LRIgChBzdHJpbmdfd2l0aF96", + "ZXJvGBcgASgJOgZoZWwAbG8SIgoPYnl0ZXNfd2l0aF96ZXJvGBggASgMOgl3", + "b3JcMDAwbGQSKAoWc3RyaW5nX3BpZWNlX3dpdGhfemVybxgZIAEoCToEYWIA", + "Y0ICCAISIAoOY29yZF93aXRoX3plcm8YGiABKAk6BDEyADNCAggBEiYKEnJl", + "cGxhY2VtZW50X3N0cmluZxgbIAEoCToKJHt1bmtub3dufSJLChFTcGFyc2VF", + "bnVtTWVzc2FnZRI2CgtzcGFyc2VfZW51bRgBIAEoDjIhLnByb3RvYnVmX3Vu", + "aXR0ZXN0LlRlc3RTcGFyc2VFbnVtIhkKCU9uZVN0cmluZxIMCgRkYXRhGAEg", + "ASgJIhoKCk1vcmVTdHJpbmcSDAoEZGF0YRgBIAMoCSIYCghPbmVCeXRlcxIM", + "CgRkYXRhGAEgASgMIhkKCU1vcmVCeXRlcxIMCgRkYXRhGAEgAygMIhwKDElu", + "dDMyTWVzc2FnZRIMCgRkYXRhGAEgASgFIh0KDVVpbnQzMk1lc3NhZ2USDAoE", + "ZGF0YRgBIAEoDSIcCgxJbnQ2NE1lc3NhZ2USDAoEZGF0YRgBIAEoAyIdCg1V", + "aW50NjRNZXNzYWdlEgwKBGRhdGEYASABKAQiGwoLQm9vbE1lc3NhZ2USDAoE", + "ZGF0YRgBIAEoCCLQAQoJVGVzdE9uZW9mEhEKB2Zvb19pbnQYASABKAVIABIU", + "Cgpmb29fc3RyaW5nGAIgASgJSAASNgoLZm9vX21lc3NhZ2UYAyABKAsyHy5w", + "cm90b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXNIABI5Cghmb29ncm91cBgE", + "IAEoCjIlLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RPbmVvZi5Gb29Hcm91cEgA", + "GiAKCEZvb0dyb3VwEgkKAWEYBSABKAUSCQoBYhgGIAEoCUIFCgNmb28i5wEK", + "HFRlc3RPbmVvZkJhY2t3YXJkc0NvbXBhdGlibGUSDwoHZm9vX2ludBgBIAEo", + "BRISCgpmb29fc3RyaW5nGAIgASgJEjQKC2Zvb19tZXNzYWdlGAMgASgLMh8u", + "cHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzEkoKCGZvb2dyb3VwGAQg", + "ASgKMjgucHJvdG9idWZfdW5pdHRlc3QuVGVzdE9uZW9mQmFja3dhcmRzQ29t", + "cGF0aWJsZS5Gb29Hcm91cBogCghGb29Hcm91cBIJCgFhGAUgASgFEgkKAWIY", + "BiABKAkingYKClRlc3RPbmVvZjISEQoHZm9vX2ludBgBIAEoBUgAEhQKCmZv", + "b19zdHJpbmcYAiABKAlIABIWCghmb29fY29yZBgDIAEoCUICCAFIABIeChBm", + "b29fc3RyaW5nX3BpZWNlGAQgASgJQgIIAkgAEhMKCWZvb19ieXRlcxgFIAEo", + "DEgAEjwKCGZvb19lbnVtGAYgASgOMigucHJvdG9idWZfdW5pdHRlc3QuVGVz", + "dE9uZW9mMi5OZXN0ZWRFbnVtSAASQgoLZm9vX21lc3NhZ2UYByABKAsyKy5w", + "cm90b2J1Zl91bml0dGVzdC5UZXN0T25lb2YyLk5lc3RlZE1lc3NhZ2VIABI6", + "Cghmb29ncm91cBgIIAEoCjImLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RPbmVv", + "ZjIuRm9vR3JvdXBIABJLChBmb29fbGF6eV9tZXNzYWdlGAsgASgLMisucHJv", + "dG9idWZfdW5pdHRlc3QuVGVzdE9uZW9mMi5OZXN0ZWRNZXNzYWdlQgIoAUgA", + "EhQKB2Jhcl9pbnQYDCABKAU6ATVIARIcCgpiYXJfc3RyaW5nGA0gASgJOgZT", + "VFJJTkdIARIcCghiYXJfY29yZBgOIAEoCToEQ09SREICCAFIARImChBiYXJf", + "c3RyaW5nX3BpZWNlGA8gASgJOgZTUElFQ0VCAggCSAESGgoJYmFyX2J5dGVz", + "GBAgASgMOgVCWVRFU0gBEkEKCGJhcl9lbnVtGBEgASgOMigucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdE9uZW9mMi5OZXN0ZWRFbnVtOgNCQVJIARIPCgdiYXpf", + "aW50GBIgASgFEhcKCmJhel9zdHJpbmcYEyABKAk6A0JBWhogCghGb29Hcm91", + "cBIJCgFhGAkgASgFEgkKAWIYCiABKAkaMwoNTmVzdGVkTWVzc2FnZRIPCgdx", + "dXhfaW50GAEgASgDEhEKCWNvcmdlX2ludBgCIAMoBSInCgpOZXN0ZWRFbnVt", + "EgcKA0ZPTxABEgcKA0JBUhACEgcKA0JBWhADQgUKA2Zvb0IFCgNiYXIiuAEK", + "EVRlc3RSZXF1aXJlZE9uZW9mEhEKB2Zvb19pbnQYASABKAVIABIUCgpmb29f", + "c3RyaW5nGAIgASgJSAASSQoLZm9vX21lc3NhZ2UYAyABKAsyMi5wcm90b2J1", + "Zl91bml0dGVzdC5UZXN0UmVxdWlyZWRPbmVvZi5OZXN0ZWRNZXNzYWdlSAAa", + "KAoNTmVzdGVkTWVzc2FnZRIXCg9yZXF1aXJlZF9kb3VibGUYASACKAFCBQoD", + "Zm9vIqoDCg9UZXN0UGFja2VkVHlwZXMSGAoMcGFja2VkX2ludDMyGFogAygF", + "QgIQARIYCgxwYWNrZWRfaW50NjQYWyADKANCAhABEhkKDXBhY2tlZF91aW50", + "MzIYXCADKA1CAhABEhkKDXBhY2tlZF91aW50NjQYXSADKARCAhABEhkKDXBh", + "Y2tlZF9zaW50MzIYXiADKBFCAhABEhkKDXBhY2tlZF9zaW50NjQYXyADKBJC", + "AhABEhoKDnBhY2tlZF9maXhlZDMyGGAgAygHQgIQARIaCg5wYWNrZWRfZml4", + "ZWQ2NBhhIAMoBkICEAESGwoPcGFja2VkX3NmaXhlZDMyGGIgAygPQgIQARIb", + "Cg9wYWNrZWRfc2ZpeGVkNjQYYyADKBBCAhABEhgKDHBhY2tlZF9mbG9hdBhk", + "IAMoAkICEAESGQoNcGFja2VkX2RvdWJsZRhlIAMoAUICEAESFwoLcGFja2Vk", + "X2Jvb2wYZiADKAhCAhABEjcKC3BhY2tlZF9lbnVtGGcgAygOMh4ucHJvdG9i", + "dWZfdW5pdHRlc3QuRm9yZWlnbkVudW1CAhABIsgDChFUZXN0VW5wYWNrZWRU", + "eXBlcxIaCg51bnBhY2tlZF9pbnQzMhhaIAMoBUICEAASGgoOdW5wYWNrZWRf", + "aW50NjQYWyADKANCAhAAEhsKD3VucGFja2VkX3VpbnQzMhhcIAMoDUICEAAS", + "GwoPdW5wYWNrZWRfdWludDY0GF0gAygEQgIQABIbCg91bnBhY2tlZF9zaW50", + "MzIYXiADKBFCAhAAEhsKD3VucGFja2VkX3NpbnQ2NBhfIAMoEkICEAASHAoQ", + "dW5wYWNrZWRfZml4ZWQzMhhgIAMoB0ICEAASHAoQdW5wYWNrZWRfZml4ZWQ2", + "NBhhIAMoBkICEAASHQoRdW5wYWNrZWRfc2ZpeGVkMzIYYiADKA9CAhAAEh0K", + "EXVucGFja2VkX3NmaXhlZDY0GGMgAygQQgIQABIaCg51bnBhY2tlZF9mbG9h", + "dBhkIAMoAkICEAASGwoPdW5wYWNrZWRfZG91YmxlGGUgAygBQgIQABIZCg11", + "bnBhY2tlZF9ib29sGGYgAygIQgIQABI5Cg11bnBhY2tlZF9lbnVtGGcgAygO", + "Mh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbkVudW1CAhAAIiAKFFRlc3RQ", + "YWNrZWRFeHRlbnNpb25zKggIARCAgICAAiIiChZUZXN0VW5wYWNrZWRFeHRl", + "bnNpb25zKggIARCAgICAAiKZBAoVVGVzdER5bmFtaWNFeHRlbnNpb25zEhkK", + "EHNjYWxhcl9leHRlbnNpb24Y0A8gASgHEjcKDmVudW1fZXh0ZW5zaW9uGNEP", + "IAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtElkKFmR5bmFt", + "aWNfZW51bV9leHRlbnNpb24Y0g8gASgOMjgucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdER5bmFtaWNFeHRlbnNpb25zLkR5bmFtaWNFbnVtVHlwZRI9ChFtZXNz", + "YWdlX2V4dGVuc2lvbhjTDyABKAsyIS5wcm90b2J1Zl91bml0dGVzdC5Gb3Jl", + "aWduTWVzc2FnZRJfChlkeW5hbWljX21lc3NhZ2VfZXh0ZW5zaW9uGNQPIAEo", + "CzI7LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3REeW5hbWljRXh0ZW5zaW9ucy5E", + "eW5hbWljTWVzc2FnZVR5cGUSGwoScmVwZWF0ZWRfZXh0ZW5zaW9uGNUPIAMo", + "CRIdChBwYWNrZWRfZXh0ZW5zaW9uGNYPIAMoEUICEAEaLAoSRHluYW1pY01l", + "c3NhZ2VUeXBlEhYKDWR5bmFtaWNfZmllbGQYtBAgASgFIkcKD0R5bmFtaWNF", + "bnVtVHlwZRIQCgtEWU5BTUlDX0ZPTxCYERIQCgtEWU5BTUlDX0JBUhCZERIQ", + "CgtEWU5BTUlDX0JBWhCaESLAAQojVGVzdFJlcGVhdGVkU2NhbGFyRGlmZmVy", + "ZW50VGFnU2l6ZXMSGAoQcmVwZWF0ZWRfZml4ZWQzMhgMIAMoBxIWCg5yZXBl", + "YXRlZF9pbnQzMhgNIAMoBRIZChByZXBlYXRlZF9maXhlZDY0GP4PIAMoBhIX", + "Cg5yZXBlYXRlZF9pbnQ2NBj/DyADKAMSGAoOcmVwZWF0ZWRfZmxvYXQY/v8P", + "IAMoAhIZCg9yZXBlYXRlZF91aW50NjQY//8PIAMoBCL3CQoQVGVzdFBhcnNp", + "bmdNZXJnZRI7ChJyZXF1aXJlZF9hbGxfdHlwZXMYASACKAsyHy5wcm90b2J1", + "Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMSOwoSb3B0aW9uYWxfYWxsX3R5cGVz", + "GAIgASgLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzEjsKEnJl", + "cGVhdGVkX2FsbF90eXBlcxgDIAMoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxUeXBlcxJICg1vcHRpb25hbGdyb3VwGAogASgKMjEucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdFBhcnNpbmdNZXJnZS5PcHRpb25hbEdyb3VwEkgKDXJl", + "cGVhdGVkZ3JvdXAYFCADKAoyMS5wcm90b2J1Zl91bml0dGVzdC5UZXN0UGFy", + "c2luZ01lcmdlLlJlcGVhdGVkR3JvdXAaqgQKF1JlcGVhdGVkRmllbGRzR2Vu", + "ZXJhdG9yEi8KBmZpZWxkMRgBIAMoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxUeXBlcxIvCgZmaWVsZDIYAiADKAsyHy5wcm90b2J1Zl91bml0dGVz", + "dC5UZXN0QWxsVHlwZXMSLwoGZmllbGQzGAMgAygLMh8ucHJvdG9idWZfdW5p", + "dHRlc3QuVGVzdEFsbFR5cGVzElIKBmdyb3VwMRgKIAMoCjJCLnByb3RvYnVm", + "X3VuaXR0ZXN0LlRlc3RQYXJzaW5nTWVyZ2UuUmVwZWF0ZWRGaWVsZHNHZW5l", + "cmF0b3IuR3JvdXAxElIKBmdyb3VwMhgUIAMoCjJCLnByb3RvYnVmX3VuaXR0", + "ZXN0LlRlc3RQYXJzaW5nTWVyZ2UuUmVwZWF0ZWRGaWVsZHNHZW5lcmF0b3Iu", + "R3JvdXAyEi4KBGV4dDEY6AcgAygLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVz", + "dEFsbFR5cGVzEi4KBGV4dDIY6QcgAygLMh8ucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdEFsbFR5cGVzGjkKBkdyb3VwMRIvCgZmaWVsZDEYCyABKAsyHy5wcm90", + "b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMaOQoGR3JvdXAyEi8KBmZpZWxk", + "MRgVIAEoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcxpSCg1P", + "cHRpb25hbEdyb3VwEkEKGG9wdGlvbmFsX2dyb3VwX2FsbF90eXBlcxgLIAEo", + "CzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcxpSCg1SZXBlYXRl", + "ZEdyb3VwEkEKGHJlcGVhdGVkX2dyb3VwX2FsbF90eXBlcxgVIAEoCzIfLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcyoJCOgHEICAgIACMlsKDG9w", + "dGlvbmFsX2V4dBIjLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYXJzaW5nTWVy", + "Z2UY6AcgASgLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzMlsK", + "DHJlcGVhdGVkX2V4dBIjLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYXJzaW5n", + "TWVyZ2UY6QcgAygLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVz", + "IkQKG1Rlc3RDb21tZW50SW5qZWN0aW9uTWVzc2FnZRIlCgFhGAEgASgJOhoq", + "LyA8LSBOZWl0aGVyIHNob3VsZCB0aGlzLiIMCgpGb29SZXF1ZXN0Ig0KC0Zv", + "b1Jlc3BvbnNlIhIKEEZvb0NsaWVudE1lc3NhZ2UiEgoQRm9vU2VydmVyTWVz", + "c2FnZSIMCgpCYXJSZXF1ZXN0Ig0KC0JhclJlc3BvbnNlKkAKC0ZvcmVpZ25F", + "bnVtEg8KC0ZPUkVJR05fRk9PEAQSDwoLRk9SRUlHTl9CQVIQBRIPCgtGT1JF", + "SUdOX0JBWhAGKksKFFRlc3RFbnVtV2l0aER1cFZhbHVlEggKBEZPTzEQARII", + "CgRCQVIxEAISBwoDQkFaEAMSCAoERk9PMhABEggKBEJBUjIQAhoCEAEqiQEK", + "DlRlc3RTcGFyc2VFbnVtEgwKCFNQQVJTRV9BEHsSDgoIU1BBUlNFX0IQpucD", + "Eg8KCFNQQVJTRV9DELKxgAYSFQoIU1BBUlNFX0QQ8f//////////ARIVCghT", + "UEFSU0VfRRC03vz///////8BEgwKCFNQQVJTRV9GEAASDAoIU1BBUlNFX0cQ", + "AjKZAQoLVGVzdFNlcnZpY2USRAoDRm9vEh0ucHJvdG9idWZfdW5pdHRlc3Qu", + "Rm9vUmVxdWVzdBoeLnByb3RvYnVmX3VuaXR0ZXN0LkZvb1Jlc3BvbnNlEkQK", + "A0JhchIdLnByb3RvYnVmX3VuaXR0ZXN0LkJhclJlcXVlc3QaHi5wcm90b2J1", + "Zl91bml0dGVzdC5CYXJSZXNwb25zZTpGChhvcHRpb25hbF9pbnQzMl9leHRl", + "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgB", + "IAEoBTpGChhvcHRpb25hbF9pbnQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91", + "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgCIAEoAzpHChlvcHRpb25hbF91", + "aW50MzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4", + "dGVuc2lvbnMYAyABKA06RwoZb3B0aW9uYWxfdWludDY0X2V4dGVuc2lvbhIk", + "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGAQgASgEOkcK", + "GW9wdGlvbmFsX3NpbnQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", + "dC5UZXN0QWxsRXh0ZW5zaW9ucxgFIAEoETpHChlvcHRpb25hbF9zaW50NjRf", + "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv", + "bnMYBiABKBI6SAoab3B0aW9uYWxfZml4ZWQzMl9leHRlbnNpb24SJC5wcm90", + "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgHIAEoBzpIChpvcHRp", + "b25hbF9maXhlZDY0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxFeHRlbnNpb25zGAggASgGOkkKG29wdGlvbmFsX3NmaXhlZDMyX2V4", + "dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25z", + "GAkgASgPOkkKG29wdGlvbmFsX3NmaXhlZDY0X2V4dGVuc2lvbhIkLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGAogASgQOkYKGG9wdGlv", + "bmFsX2Zsb2F0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", + "bGxFeHRlbnNpb25zGAsgASgCOkcKGW9wdGlvbmFsX2RvdWJsZV9leHRlbnNp", + "b24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgMIAEo", + "ATpFChdvcHRpb25hbF9ib29sX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0", + "ZXN0LlRlc3RBbGxFeHRlbnNpb25zGA0gASgIOkcKGW9wdGlvbmFsX3N0cmlu", + "Z19leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5z", + "aW9ucxgOIAEoCTpGChhvcHRpb25hbF9ieXRlc19leHRlbnNpb24SJC5wcm90", + "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgPIAEoDDpxChdvcHRp", + "b25hbGdyb3VwX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", + "bGxFeHRlbnNpb25zGBAgASgKMioucHJvdG9idWZfdW5pdHRlc3QuT3B0aW9u", + "YWxHcm91cF9leHRlbnNpb246fgohb3B0aW9uYWxfbmVzdGVkX21lc3NhZ2Vf", + "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv", + "bnMYEiABKAsyLS5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVz", + "dGVkTWVzc2FnZTpzCiJvcHRpb25hbF9mb3JlaWduX21lc3NhZ2VfZXh0ZW5z", + "aW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYEyAB", + "KAsyIS5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduTWVzc2FnZTp4CiFvcHRp", + "b25hbF9pbXBvcnRfbWVzc2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0", + "dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgUIAEoCzInLnByb3RvYnVmX3VuaXR0", + "ZXN0X2ltcG9ydC5JbXBvcnRNZXNzYWdlOngKHm9wdGlvbmFsX25lc3RlZF9l", + "bnVtX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRl", + "bnNpb25zGBUgASgOMioucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVz", + "Lk5lc3RlZEVudW06bQofb3B0aW9uYWxfZm9yZWlnbl9lbnVtX2V4dGVuc2lv", + "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGBYgASgO", + "Mh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbkVudW06cgoeb3B0aW9uYWxf", + "aW1wb3J0X2VudW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVz", + "dEFsbEV4dGVuc2lvbnMYFyABKA4yJC5wcm90b2J1Zl91bml0dGVzdF9pbXBv", + "cnQuSW1wb3J0RW51bTpRCh9vcHRpb25hbF9zdHJpbmdfcGllY2VfZXh0ZW5z", + "aW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYGCAB", + "KAlCAggCOkkKF29wdGlvbmFsX2NvcmRfZXh0ZW5zaW9uEiQucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYGSABKAlCAggBOoUBCihvcHRp", + "b25hbF9wdWJsaWNfaW1wb3J0X21lc3NhZ2VfZXh0ZW5zaW9uEiQucHJvdG9i", + "dWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYGiABKAsyLS5wcm90b2J1", + "Zl91bml0dGVzdF9pbXBvcnQuUHVibGljSW1wb3J0TWVzc2FnZTqAAQofb3B0", + "aW9uYWxfbGF6eV9tZXNzYWdlX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0", + "ZXN0LlRlc3RBbGxFeHRlbnNpb25zGBsgASgLMi0ucHJvdG9idWZfdW5pdHRl", + "c3QuVGVzdEFsbFR5cGVzLk5lc3RlZE1lc3NhZ2VCAigBOkYKGHJlcGVhdGVk", + "X2ludDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxF", + "eHRlbnNpb25zGB8gAygFOkYKGHJlcGVhdGVkX2ludDY0X2V4dGVuc2lvbhIk", + "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCAgAygDOkcK", + "GXJlcGVhdGVkX3VpbnQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", + "dC5UZXN0QWxsRXh0ZW5zaW9ucxghIAMoDTpHChlyZXBlYXRlZF91aW50NjRf", + "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv", + "bnMYIiADKAQ6RwoZcmVwZWF0ZWRfc2ludDMyX2V4dGVuc2lvbhIkLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCMgAygROkcKGXJlcGVh", + "dGVkX3NpbnQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", + "QWxsRXh0ZW5zaW9ucxgkIAMoEjpIChpyZXBlYXRlZF9maXhlZDMyX2V4dGVu", + "c2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCUg", + "AygHOkgKGnJlcGVhdGVkX2ZpeGVkNjRfZXh0ZW5zaW9uEiQucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYJiADKAY6SQobcmVwZWF0ZWRf", + "c2ZpeGVkMzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFs", + "bEV4dGVuc2lvbnMYJyADKA86SQobcmVwZWF0ZWRfc2ZpeGVkNjRfZXh0ZW5z", + "aW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYKCAD", + "KBA6RgoYcmVwZWF0ZWRfZmxvYXRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5p", + "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYKSADKAI6RwoZcmVwZWF0ZWRfZG91", + "YmxlX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRl", + "bnNpb25zGCogAygBOkUKF3JlcGVhdGVkX2Jvb2xfZXh0ZW5zaW9uEiQucHJv", + "dG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYKyADKAg6RwoZcmVw", + "ZWF0ZWRfc3RyaW5nX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxFeHRlbnNpb25zGCwgAygJOkYKGHJlcGVhdGVkX2J5dGVzX2V4dGVu", + "c2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGC0g", + "AygMOnEKF3JlcGVhdGVkZ3JvdXBfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5p", + "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYLiADKAoyKi5wcm90b2J1Zl91bml0", + "dGVzdC5SZXBlYXRlZEdyb3VwX2V4dGVuc2lvbjp+CiFyZXBlYXRlZF9uZXN0", + "ZWRfbWVzc2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0", + "QWxsRXh0ZW5zaW9ucxgwIAMoCzItLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", + "bGxUeXBlcy5OZXN0ZWRNZXNzYWdlOnMKInJlcGVhdGVkX2ZvcmVpZ25fbWVz", + "c2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", + "ZW5zaW9ucxgxIAMoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25NZXNz", + "YWdlOngKIXJlcGVhdGVkX2ltcG9ydF9tZXNzYWdlX2V4dGVuc2lvbhIkLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGDIgAygLMicucHJv", + "dG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydE1lc3NhZ2U6eAoecmVwZWF0", + "ZWRfbmVzdGVkX2VudW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdEFsbEV4dGVuc2lvbnMYMyADKA4yKi5wcm90b2J1Zl91bml0dGVzdC5U", + "ZXN0QWxsVHlwZXMuTmVzdGVkRW51bTptCh9yZXBlYXRlZF9mb3JlaWduX2Vu", + "dW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVu", + "c2lvbnMYNCADKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bTpy", + "Ch5yZXBlYXRlZF9pbXBvcnRfZW51bV9leHRlbnNpb24SJC5wcm90b2J1Zl91", + "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg1IAMoDjIkLnByb3RvYnVmX3Vu", + "aXR0ZXN0X2ltcG9ydC5JbXBvcnRFbnVtOlEKH3JlcGVhdGVkX3N0cmluZ19w", + "aWVjZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", + "ZW5zaW9ucxg2IAMoCUICCAI6SQoXcmVwZWF0ZWRfY29yZF9leHRlbnNpb24S", + "JC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg3IAMoCUIC", + "CAE6gAEKH3JlcGVhdGVkX2xhenlfbWVzc2FnZV9leHRlbnNpb24SJC5wcm90", + "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg5IAMoCzItLnByb3Rv", + "YnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdlQgIoATpJ", + "ChdkZWZhdWx0X2ludDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0", + "LlRlc3RBbGxFeHRlbnNpb25zGD0gASgFOgI0MTpJChdkZWZhdWx0X2ludDY0", + "X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNp", + "b25zGD4gASgDOgI0MjpKChhkZWZhdWx0X3VpbnQzMl9leHRlbnNpb24SJC5w", + "cm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg/IAEoDToCNDM6", + "SgoYZGVmYXVsdF91aW50NjRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRl", + "c3QuVGVzdEFsbEV4dGVuc2lvbnMYQCABKAQ6AjQ0OksKGGRlZmF1bHRfc2lu", + "dDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRl", + "bnNpb25zGEEgASgROgMtNDU6SgoYZGVmYXVsdF9zaW50NjRfZXh0ZW5zaW9u", + "EiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYQiABKBI6", + "AjQ2OksKGWRlZmF1bHRfZml4ZWQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91", + "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhDIAEoBzoCNDc6SwoZZGVmYXVs", + "dF9maXhlZDY0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB", + "bGxFeHRlbnNpb25zGEQgASgGOgI0ODpMChpkZWZhdWx0X3NmaXhlZDMyX2V4", + "dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25z", + "GEUgASgPOgI0OTpNChpkZWZhdWx0X3NmaXhlZDY0X2V4dGVuc2lvbhIkLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEYgASgQOgMtNTA6", + "SwoXZGVmYXVsdF9mbG9hdF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", + "dC5UZXN0QWxsRXh0ZW5zaW9ucxhHIAEoAjoENTEuNTpNChhkZWZhdWx0X2Rv", + "dWJsZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0", + "ZW5zaW9ucxhIIAEoAToFNTIwMDA6SgoWZGVmYXVsdF9ib29sX2V4dGVuc2lv", + "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEkgASgI", + "OgR0cnVlOk0KGGRlZmF1bHRfc3RyaW5nX2V4dGVuc2lvbhIkLnByb3RvYnVm", + "X3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEogASgJOgVoZWxsbzpMChdk", + "ZWZhdWx0X2J5dGVzX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxFeHRlbnNpb25zGEsgASgMOgV3b3JsZDp8Ch1kZWZhdWx0X25lc3Rl", + "ZF9lbnVtX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxF", + "eHRlbnNpb25zGFEgASgOMioucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5", + "cGVzLk5lc3RlZEVudW06A0JBUjp5Ch5kZWZhdWx0X2ZvcmVpZ25fZW51bV9l", + "eHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9u", + "cxhSIAEoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtOgtGT1JF", + "SUdOX0JBUjp9Ch1kZWZhdWx0X2ltcG9ydF9lbnVtX2V4dGVuc2lvbhIkLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGFMgASgOMiQucHJv", + "dG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydEVudW06CklNUE9SVF9CQVI6", + "VQoeZGVmYXVsdF9zdHJpbmdfcGllY2VfZXh0ZW5zaW9uEiQucHJvdG9idWZf", + "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYVCABKAk6A2FiY0ICCAI6TQoW", + "ZGVmYXVsdF9jb3JkX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl", + "c3RBbGxFeHRlbnNpb25zGFUgASgJOgMxMjNCAggBOkQKFm9uZW9mX3VpbnQz", + "Ml9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5z", + "aW9ucxhvIAEoDTp7Ch5vbmVvZl9uZXN0ZWRfbWVzc2FnZV9leHRlbnNpb24S", + "JC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhwIAEoCzIt", + "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdl", + "OkQKFm9uZW9mX3N0cmluZ19leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz", + "dC5UZXN0QWxsRXh0ZW5zaW9ucxhxIAEoCTpDChVvbmVvZl9ieXRlc19leHRl", + "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhy", + "IAEoDDpCChNteV9leHRlbnNpb25fc3RyaW5nEiUucHJvdG9idWZfdW5pdHRl", + "c3QuVGVzdEZpZWxkT3JkZXJpbmdzGDIgASgJOj8KEG15X2V4dGVuc2lvbl9p", + "bnQSJS5wcm90b2J1Zl91bml0dGVzdC5UZXN0RmllbGRPcmRlcmluZ3MYBSAB", + "KAU6SwoWcGFja2VkX2ludDMyX2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0", + "ZXN0LlRlc3RQYWNrZWRFeHRlbnNpb25zGFogAygFQgIQATpLChZwYWNrZWRf", + "aW50NjRfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tl", + "ZEV4dGVuc2lvbnMYWyADKANCAhABOkwKF3BhY2tlZF91aW50MzJfZXh0ZW5z", + "aW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMY", + "XCADKA1CAhABOkwKF3BhY2tlZF91aW50NjRfZXh0ZW5zaW9uEicucHJvdG9i", + "dWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMYXSADKARCAhABOkwK", + "F3BhY2tlZF9zaW50MzJfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdFBhY2tlZEV4dGVuc2lvbnMYXiADKBFCAhABOkwKF3BhY2tlZF9zaW50", + "NjRfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4", + "dGVuc2lvbnMYXyADKBJCAhABOk0KGHBhY2tlZF9maXhlZDMyX2V4dGVuc2lv", + "bhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNpb25zGGAg", + "AygHQgIQATpNChhwYWNrZWRfZml4ZWQ2NF9leHRlbnNpb24SJy5wcm90b2J1", + "Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhhIAMoBkICEAE6TgoZ", + "cGFja2VkX3NmaXhlZDMyX2V4dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0", + "LlRlc3RQYWNrZWRFeHRlbnNpb25zGGIgAygPQgIQATpOChlwYWNrZWRfc2Zp", + "eGVkNjRfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tl", + "ZEV4dGVuc2lvbnMYYyADKBBCAhABOksKFnBhY2tlZF9mbG9hdF9leHRlbnNp", + "b24SJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhk", + "IAMoAkICEAE6TAoXcGFja2VkX2RvdWJsZV9leHRlbnNpb24SJy5wcm90b2J1", + "Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhlIAMoAUICEAE6SgoV", + "cGFja2VkX2Jvb2xfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVz", + "dFBhY2tlZEV4dGVuc2lvbnMYZiADKAhCAhABOmoKFXBhY2tlZF9lbnVtX2V4", + "dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNp", + "b25zGGcgAygOMh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWlnbkVudW1CAhAB", + "Ok8KGHVucGFja2VkX2ludDMyX2V4dGVuc2lvbhIpLnByb3RvYnVmX3VuaXR0", + "ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYWiADKAVCAhAAOk8KGHVucGFj", + "a2VkX2ludDY0X2V4dGVuc2lvbhIpLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RV", + "bnBhY2tlZEV4dGVuc2lvbnMYWyADKANCAhAAOlAKGXVucGFja2VkX3VpbnQz", + "Ml9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVzdC5UZXN0VW5wYWNrZWRF", + "eHRlbnNpb25zGFwgAygNQgIQADpQChl1bnBhY2tlZF91aW50NjRfZXh0ZW5z", + "aW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5zaW9u", + "cxhdIAMoBEICEAA6UAoZdW5wYWNrZWRfc2ludDMyX2V4dGVuc2lvbhIpLnBy", + "b3RvYnVmX3VuaXR0ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYXiADKBFC", + "AhAAOlAKGXVucGFja2VkX3NpbnQ2NF9leHRlbnNpb24SKS5wcm90b2J1Zl91", + "bml0dGVzdC5UZXN0VW5wYWNrZWRFeHRlbnNpb25zGF8gAygSQgIQADpRChp1", + "bnBhY2tlZF9maXhlZDMyX2V4dGVuc2lvbhIpLnByb3RvYnVmX3VuaXR0ZXN0", + "LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYYCADKAdCAhAAOlEKGnVucGFja2Vk", + "X2ZpeGVkNjRfZXh0ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVu", + "cGFja2VkRXh0ZW5zaW9ucxhhIAMoBkICEAA6UgobdW5wYWNrZWRfc2ZpeGVk", + "MzJfZXh0ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2Vk", + "RXh0ZW5zaW9ucxhiIAMoD0ICEAA6UgobdW5wYWNrZWRfc2ZpeGVkNjRfZXh0", + "ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5z", + "aW9ucxhjIAMoEEICEAA6TwoYdW5wYWNrZWRfZmxvYXRfZXh0ZW5zaW9uEiku", + "cHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5zaW9ucxhkIAMo", + "AkICEAA6UAoZdW5wYWNrZWRfZG91YmxlX2V4dGVuc2lvbhIpLnByb3RvYnVm", + "X3VuaXR0ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYZSADKAFCAhAAOk4K", + "F3VucGFja2VkX2Jvb2xfZXh0ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3Qu", + "VGVzdFVucGFja2VkRXh0ZW5zaW9ucxhmIAMoCEICEAA6bgoXdW5wYWNrZWRf", + "ZW51bV9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVzdC5UZXN0VW5wYWNr", + "ZWRFeHRlbnNpb25zGGcgAygOMh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWln", + "bkVudW1CAhAAQkFCDVVuaXR0ZXN0UHJvdG9IAYABAYgBAZABAfgBAaoCIUdv", + "b2dsZS5Qcm90b2NvbEJ1ZmZlcnMuVGVzdFByb3Rvcw==")); + pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate (pbd::FileDescriptor root) { + descriptor = root; + internal__static_protobuf_unittest_TestAllTypes__Descriptor = Descriptor.MessageTypes[0]; + internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes__Descriptor, + new string[] { "OptionalInt32", "OptionalInt64", "OptionalUint32", "OptionalUint64", "OptionalSint32", "OptionalSint64", "OptionalFixed32", "OptionalFixed64", "OptionalSfixed32", "OptionalSfixed64", "OptionalFloat", "OptionalDouble", "OptionalBool", "OptionalString", "OptionalBytes", "OptionalGroup", "OptionalNestedMessage", "OptionalForeignMessage", "OptionalImportMessage", "OptionalNestedEnum", "OptionalForeignEnum", "OptionalImportEnum", "OptionalStringPiece", "OptionalCord", "OptionalPublicImportMessage", "OptionalLazyMessage", "RepeatedInt32", "RepeatedInt64", "RepeatedUint32", "RepeatedUint64", "RepeatedSint32", "RepeatedSint64", "RepeatedFixed32", "RepeatedFixed64", "RepeatedSfixed32", "RepeatedSfixed64", "RepeatedFloat", "RepeatedDouble", "RepeatedBool", "RepeatedString", "RepeatedBytes", "RepeatedGroup", "RepeatedNestedMessage", "RepeatedForeignMessage", "RepeatedImportMessage", "RepeatedNestedEnum", "RepeatedForeignEnum", "RepeatedImportEnum", "RepeatedStringPiece", "RepeatedCord", "RepeatedLazyMessage", "DefaultInt32", "DefaultInt64", "DefaultUint32", "DefaultUint64", "DefaultSint32", "DefaultSint64", "DefaultFixed32", "DefaultFixed64", "DefaultSfixed32", "DefaultSfixed64", "DefaultFloat", "DefaultDouble", "DefaultBool", "DefaultString", "DefaultBytes", "DefaultNestedEnum", "DefaultForeignEnum", "DefaultImportEnum", "DefaultStringPiece", "DefaultCord", "OneofUint32", "OneofNestedMessage", "OneofString", "OneofBytes", }); + internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor, + new string[] { "Bb", }); + internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[2]; + internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor = Descriptor.MessageTypes[1]; + internal__static_protobuf_unittest_NestedTestAllTypes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor, + new string[] { "Child", "Payload", }); + internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor = Descriptor.MessageTypes[2]; + internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor, + new string[] { "DeprecatedInt32", }); + internal__static_protobuf_unittest_ForeignMessage__Descriptor = Descriptor.MessageTypes[3]; + internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_ForeignMessage__Descriptor, + new string[] { "C", }); + internal__static_protobuf_unittest_TestAllExtensions__Descriptor = Descriptor.MessageTypes[4]; + internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestAllExtensions__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor = Descriptor.MessageTypes[5]; + internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor = Descriptor.MessageTypes[6]; + internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_TestNestedExtension__Descriptor = Descriptor.MessageTypes[7]; + internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedExtension__Descriptor, + new string[] { }); + global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Test = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor.Extensions[0]); + global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.NestedStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor.Extensions[1]); + internal__static_protobuf_unittest_TestRequired__Descriptor = Descriptor.MessageTypes[8]; + internal__static_protobuf_unittest_TestRequired__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequired__Descriptor, + new string[] { "A", "Dummy2", "B", "Dummy4", "Dummy5", "Dummy6", "Dummy7", "Dummy8", "Dummy9", "Dummy10", "Dummy11", "Dummy12", "Dummy13", "Dummy14", "Dummy15", "Dummy16", "Dummy17", "Dummy18", "Dummy19", "Dummy20", "Dummy21", "Dummy22", "Dummy23", "Dummy24", "Dummy25", "Dummy26", "Dummy27", "Dummy28", "Dummy29", "Dummy30", "Dummy31", "Dummy32", "C", }); + global::Google.ProtocolBuffers.TestProtos.TestRequired.Single = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor.Extensions[0]); + global::Google.ProtocolBuffers.TestProtos.TestRequired.Multi = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor.Extensions[1]); + internal__static_protobuf_unittest_TestRequiredForeign__Descriptor = Descriptor.MessageTypes[9]; + internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequiredForeign__Descriptor, + new string[] { "OptionalMessage", "RepeatedMessage", "Dummy", }); + internal__static_protobuf_unittest_TestForeignNested__Descriptor = Descriptor.MessageTypes[10]; + internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestForeignNested__Descriptor, + new string[] { "ForeignNested", }); + internal__static_protobuf_unittest_TestEmptyMessage__Descriptor = Descriptor.MessageTypes[11]; + internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEmptyMessage__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor = Descriptor.MessageTypes[12]; + internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor = Descriptor.MessageTypes[13]; + internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor = Descriptor.MessageTypes[14]; + internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor, + new string[] { "A", "Bb", }); + internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor = Descriptor.MessageTypes[15]; + internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor, + new string[] { "A", "I", }); + internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor = Descriptor.MessageTypes[16]; + internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor, + new string[] { "Bb", }); + internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor = Descriptor.MessageTypes[17]; + internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor, + new string[] { "A", "OptionalInt32", }); + internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor = Descriptor.MessageTypes[18]; + internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor, + new string[] { "A", "Foo", "Bar", }); + internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor = internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor = internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_TestEagerMessage__Descriptor = Descriptor.MessageTypes[19]; + internal__static_protobuf_unittest_TestEagerMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestEagerMessage__Descriptor, + new string[] { "SubMessage", }); + internal__static_protobuf_unittest_TestLazyMessage__Descriptor = Descriptor.MessageTypes[20]; + internal__static_protobuf_unittest_TestLazyMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestLazyMessage__Descriptor, + new string[] { "SubMessage", }); + internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor = Descriptor.MessageTypes[21]; + internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor, + new string[] { "OptionalNestedMessage", }); + internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor, + new string[] { "NestedmessageRepeatedInt32", "NestedmessageRepeatedForeignmessage", }); + internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor = Descriptor.MessageTypes[22]; + internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor, + new string[] { "PrimitiveField", "StringField", "EnumField", "MessageField", "StringPieceField", "CordField", "RepeatedPrimitiveField", "RepeatedStringField", "RepeatedEnumField", "RepeatedMessageField", "RepeatedStringPieceField", "RepeatedCordField", }); + internal__static_protobuf_unittest_TestFieldOrderings__Descriptor = Descriptor.MessageTypes[23]; + internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestFieldOrderings__Descriptor, + new string[] { "MyString", "MyInt", "MyFloat", "OptionalNestedMessage", }); + internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestFieldOrderings__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor, + new string[] { "Oo", "Bb", }); + internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor = Descriptor.MessageTypes[24]; + internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor, + new string[] { "EscapedBytes", "LargeUint32", "LargeUint64", "SmallInt32", "SmallInt64", "ReallySmallInt32", "ReallySmallInt64", "Utf8String", "ZeroFloat", "OneFloat", "SmallFloat", "NegativeOneFloat", "NegativeFloat", "LargeFloat", "SmallNegativeFloat", "InfDouble", "NegInfDouble", "NanDouble", "InfFloat", "NegInfFloat", "NanFloat", "CppTrigraph", "StringWithZero", "BytesWithZero", "StringPieceWithZero", "CordWithZero", "ReplacementString", }); + internal__static_protobuf_unittest_SparseEnumMessage__Descriptor = Descriptor.MessageTypes[25]; + internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_SparseEnumMessage__Descriptor, + new string[] { "SparseEnum", }); + internal__static_protobuf_unittest_OneString__Descriptor = Descriptor.MessageTypes[26]; + internal__static_protobuf_unittest_OneString__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OneString__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_MoreString__Descriptor = Descriptor.MessageTypes[27]; + internal__static_protobuf_unittest_MoreString__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_MoreString__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_OneBytes__Descriptor = Descriptor.MessageTypes[28]; + internal__static_protobuf_unittest_OneBytes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_OneBytes__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_MoreBytes__Descriptor = Descriptor.MessageTypes[29]; + internal__static_protobuf_unittest_MoreBytes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_MoreBytes__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_Int32Message__Descriptor = Descriptor.MessageTypes[30]; + internal__static_protobuf_unittest_Int32Message__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Int32Message__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_Uint32Message__Descriptor = Descriptor.MessageTypes[31]; + internal__static_protobuf_unittest_Uint32Message__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Uint32Message__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_Int64Message__Descriptor = Descriptor.MessageTypes[32]; + internal__static_protobuf_unittest_Int64Message__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Int64Message__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_Uint64Message__Descriptor = Descriptor.MessageTypes[33]; + internal__static_protobuf_unittest_Uint64Message__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_Uint64Message__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_BoolMessage__Descriptor = Descriptor.MessageTypes[34]; + internal__static_protobuf_unittest_BoolMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BoolMessage__Descriptor, + new string[] { "Data", }); + internal__static_protobuf_unittest_TestOneof__Descriptor = Descriptor.MessageTypes[35]; + internal__static_protobuf_unittest_TestOneof__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof__Descriptor, + new string[] { "FooInt", "FooString", "FooMessage", "FooGroup", }); + internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor = internal__static_protobuf_unittest_TestOneof__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestOneof_FooGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor, + new string[] { "A", "B", }); + internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor = Descriptor.MessageTypes[36]; + internal__static_protobuf_unittest_TestOneofBackwardsCompatible__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor, + new string[] { "FooInt", "FooString", "FooMessage", "FooGroup", }); + internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor = internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor, + new string[] { "A", "B", }); + internal__static_protobuf_unittest_TestOneof2__Descriptor = Descriptor.MessageTypes[37]; + internal__static_protobuf_unittest_TestOneof2__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof2__Descriptor, + new string[] { "FooInt", "FooString", "FooCord", "FooStringPiece", "FooBytes", "FooEnum", "FooMessage", "FooGroup", "FooLazyMessage", "BarInt", "BarString", "BarCord", "BarStringPiece", "BarBytes", "BarEnum", "BazInt", "BazString", }); + internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor = internal__static_protobuf_unittest_TestOneof2__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestOneof2_FooGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor, + new string[] { "A", "B", }); + internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestOneof2__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_TestOneof2_NestedMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor, + new string[] { "QuxInt", "CorgeInt", }); + internal__static_protobuf_unittest_TestRequiredOneof__Descriptor = Descriptor.MessageTypes[38]; + internal__static_protobuf_unittest_TestRequiredOneof__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequiredOneof__Descriptor, + new string[] { "FooInt", "FooString", "FooMessage", }); + internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestRequiredOneof__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor, + new string[] { "RequiredDouble", }); + internal__static_protobuf_unittest_TestPackedTypes__Descriptor = Descriptor.MessageTypes[39]; + internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestPackedTypes__Descriptor, + new string[] { "PackedInt32", "PackedInt64", "PackedUint32", "PackedUint64", "PackedSint32", "PackedSint64", "PackedFixed32", "PackedFixed64", "PackedSfixed32", "PackedSfixed64", "PackedFloat", "PackedDouble", "PackedBool", "PackedEnum", }); + internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor = Descriptor.MessageTypes[40]; + internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor, + new string[] { "UnpackedInt32", "UnpackedInt64", "UnpackedUint32", "UnpackedUint64", "UnpackedSint32", "UnpackedSint64", "UnpackedFixed32", "UnpackedFixed64", "UnpackedSfixed32", "UnpackedSfixed64", "UnpackedFloat", "UnpackedDouble", "UnpackedBool", "UnpackedEnum", }); + internal__static_protobuf_unittest_TestPackedExtensions__Descriptor = Descriptor.MessageTypes[41]; + internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestPackedExtensions__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor = Descriptor.MessageTypes[42]; + internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor = Descriptor.MessageTypes[43]; + internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor, + new string[] { "ScalarExtension", "EnumExtension", "DynamicEnumExtension", "MessageExtension", "DynamicMessageExtension", "RepeatedExtension", "PackedExtension", }); + internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor = internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor, + new string[] { "DynamicField", }); + internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor = Descriptor.MessageTypes[44]; + internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor, + new string[] { "RepeatedFixed32", "RepeatedInt32", "RepeatedFixed64", "RepeatedInt64", "RepeatedFloat", "RepeatedUint64", }); + internal__static_protobuf_unittest_TestParsingMerge__Descriptor = Descriptor.MessageTypes[45]; + internal__static_protobuf_unittest_TestParsingMerge__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge__Descriptor, + new string[] { "RequiredAllTypes", "OptionalAllTypes", "RepeatedAllTypes", "OptionalGroup", "RepeatedGroup", }); + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor = internal__static_protobuf_unittest_TestParsingMerge__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor, + new string[] { "Field1", "Field2", "Field3", "Group1", "Group2", "Ext1", "Ext2", }); + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor = internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor.NestedTypes[0]; + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor, + new string[] { "Field1", }); + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor = internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor, + new string[] { "Field1", }); + internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor = internal__static_protobuf_unittest_TestParsingMerge__Descriptor.NestedTypes[1]; + internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor, + new string[] { "OptionalGroupAllTypes", }); + internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor = internal__static_protobuf_unittest_TestParsingMerge__Descriptor.NestedTypes[2]; + internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor, + new string[] { "RepeatedGroupAllTypes", }); + global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.OptionalExt = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Descriptor.Extensions[0]); + global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.RepeatedExt = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Descriptor.Extensions[1]); + internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor = Descriptor.MessageTypes[46]; + internal__static_protobuf_unittest_TestCommentInjectionMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor, + new string[] { "A", }); + internal__static_protobuf_unittest_FooRequest__Descriptor = Descriptor.MessageTypes[47]; + internal__static_protobuf_unittest_FooRequest__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooRequest__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_FooResponse__Descriptor = Descriptor.MessageTypes[48]; + internal__static_protobuf_unittest_FooResponse__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooResponse__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_FooClientMessage__Descriptor = Descriptor.MessageTypes[49]; + internal__static_protobuf_unittest_FooClientMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooClientMessage__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_FooServerMessage__Descriptor = Descriptor.MessageTypes[50]; + internal__static_protobuf_unittest_FooServerMessage__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_FooServerMessage__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_BarRequest__Descriptor = Descriptor.MessageTypes[51]; + internal__static_protobuf_unittest_BarRequest__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BarRequest__Descriptor, + new string[] { }); + internal__static_protobuf_unittest_BarResponse__Descriptor = Descriptor.MessageTypes[52]; + internal__static_protobuf_unittest_BarResponse__FieldAccessorTable = + new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_BarResponse__Descriptor, + new string[] { }); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[0]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalInt64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[1]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[2]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalUint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[3]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[4]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[5]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[6]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[7]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[8]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalSfixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[9]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalFloatExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[10]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalDoubleExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[11]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBoolExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[12]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[13]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[14]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalGroupExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[15]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[16]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[17]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[18]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalNestedEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[19]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalForeignEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[20]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalImportEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[21]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalStringPieceExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[22]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalCordExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[23]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalPublicImportMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[24]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OptionalLazyMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[25]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[26]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[27]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[28]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[29]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[30]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[31]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[32]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[33]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[34]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[35]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[36]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[37]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[38]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[39]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedBytesExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[40]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedGroupExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[41]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[42]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[43]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[44]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedNestedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[45]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedForeignEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[46]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedImportEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[47]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedStringPieceExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[48]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedCordExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[49]); + global::Google.ProtocolBuffers.TestProtos.Unittest.RepeatedLazyMessageExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[50]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[51]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultInt64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[52]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[53]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultUint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[54]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[55]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSint64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[56]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[57]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[58]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[59]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultSfixed64Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[60]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultFloatExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[61]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultDoubleExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[62]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBoolExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[63]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[64]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[65]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultNestedEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[66]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultForeignEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[67]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultImportEnumExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[68]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultStringPieceExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[69]); + global::Google.ProtocolBuffers.TestProtos.Unittest.DefaultCordExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[70]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OneofUint32Extension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[71]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OneofNestedMessageExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[72]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OneofStringExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[73]); + global::Google.ProtocolBuffers.TestProtos.Unittest.OneofBytesExtension = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[74]); + global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionString = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[75]); + global::Google.ProtocolBuffers.TestProtos.Unittest.MyExtensionInt = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[76]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[77]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[78]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[79]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[80]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[81]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[82]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[83]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[84]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[85]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[86]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[87]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[88]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[89]); + global::Google.ProtocolBuffers.TestProtos.Unittest.PackedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[90]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[91]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedInt64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[92]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[93]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedUint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[94]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[95]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSint64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[96]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[97]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[98]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed32Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[99]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedSfixed64Extension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[100]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedFloatExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[101]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedDoubleExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[102]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedBoolExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[103]); + global::Google.ProtocolBuffers.TestProtos.Unittest.UnpackedEnumExtension = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor.Extensions[104]); + pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); + RegisterAllExtensions(registry); + global::Google.ProtocolBuffers.TestProtos.UnittestImport.RegisterAllExtensions(registry); + return registry; + }; + pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, + new pbd::FileDescriptor[] { + global::Google.ProtocolBuffers.TestProtos.UnittestImport.Descriptor, + }, assigner); + } + #endregion - public override TestAllTypes DefaultInstanceForType { - get { return DefaultInstance; } } - - protected override TestAllTypes ThisMessage { - get { return this; } + #region Enums + public enum ForeignEnum + { + FOREIGN_FOO = 4, + FOREIGN_BAR = 5, + FOREIGN_BAZ = 6, } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes__Descriptor; } + public enum TestEnumWithDupValue + { + FOO1 = 1, + BAR1 = 2, + BAZ = 3, + FOO2 = 1, + BAR2 = 2, } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable; } + public enum TestSparseEnum + { + SPARSE_A = 123, + SPARSE_B = 62374, + SPARSE_C = 12589234, + SPARSE_D = -15, + SPARSE_E = -53452, + SPARSE_F = 0, + SPARSE_G = 2, } - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - public enum NestedEnum { - FOO = 1, - BAR = 2, - BAZ = 3, - NEG = -1, - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NestedMessage : pb::GeneratedMessage { - private NestedMessage() { } - private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); - private static readonly string[] _nestedMessageFieldNames = new string[] { "bb" }; - private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8 }; - public static NestedMessage DefaultInstance { - get { return defaultInstance; } - } - - public override NestedMessage DefaultInstanceForType { - get { return DefaultInstance; } - } + #endregion - protected override NestedMessage ThisMessage { - get { return this; } + #region Messages + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestAllTypes : pb::GeneratedMessage + { + private TestAllTypes() { } + private static readonly TestAllTypes defaultInstance = new TestAllTypes().MakeReadOnly(); + private static readonly string[] _testAllTypesFieldNames = new string[] { "default_bool", "default_bytes", "default_cord", "default_double", "default_fixed32", "default_fixed64", "default_float", "default_foreign_enum", "default_import_enum", "default_int32", "default_int64", "default_nested_enum", "default_sfixed32", "default_sfixed64", "default_sint32", "default_sint64", "default_string", "default_string_piece", "default_uint32", "default_uint64", "oneof_bytes", "oneof_nested_message", "oneof_string", "oneof_uint32", "optional_bool", "optional_bytes", "optional_cord", "optional_double", "optional_fixed32", "optional_fixed64", "optional_float", "optional_foreign_enum", "optional_foreign_message", "optional_import_enum", "optional_import_message", "optional_int32", "optional_int64", "optional_lazy_message", "optional_nested_enum", "optional_nested_message", "optional_public_import_message", "optional_sfixed32", "optional_sfixed64", "optional_sint32", "optional_sint64", "optional_string", "optional_string_piece", "optional_uint32", "optional_uint64", "optionalgroup", "repeated_bool", "repeated_bytes", "repeated_cord", "repeated_double", "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_foreign_enum", "repeated_foreign_message", "repeated_import_enum", "repeated_import_message", "repeated_int32", "repeated_int64", "repeated_lazy_message", "repeated_nested_enum", "repeated_nested_message", "repeated_sfixed32", "repeated_sfixed64", "repeated_sint32", "repeated_sint64", "repeated_string", "repeated_string_piece", "repeated_uint32", "repeated_uint64", "repeatedgroup" }; + private static readonly uint[] _testAllTypesFieldTags = new uint[] { 584, 602, 682, 577, 541, 545, 573, 656, 664, 488, 496, 648, 557, 561, 520, 528, 594, 674, 504, 512, 914, 898, 906, 888, 104, 122, 202, 97, 61, 65, 93, 176, 154, 184, 162, 8, 16, 218, 168, 146, 210, 77, 81, 40, 48, 114, 194, 24, 32, 131, 344, 362, 442, 337, 301, 305, 333, 416, 394, 424, 402, 248, 256, 458, 408, 386, 317, 321, 280, 288, 354, 434, 264, 272, 371 }; + public static TestAllTypes DefaultInstance + { + get { return defaultInstance; } } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor; } + public override TestAllTypes DefaultInstanceForType + { + get { return DefaultInstance; } } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; } + protected override TestAllTypes ThisMessage + { + get { return this; } } - public const int BbFieldNumber = 1; - private bool hasBb; - private int bb_; - public bool HasBb { - get { return hasBb; } - } - public int Bb { - get { return bb_; } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes__Descriptor; } } - public override bool IsInitialized { - get { - return true; - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable; } } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _nestedMessageFieldNames; - if (hasBb) { - output.WriteInt32(1, field_names[0], Bb); - } - UnknownFields.WriteTo(output); - } + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + public enum NestedEnum + { + FOO = 1, + BAR = 2, + BAZ = 3, + NEG = -1, + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessage + { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "bb" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8 }; + public static NestedMessage DefaultInstance + { + get { return defaultInstance; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public override NestedMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } - size = 0; - if (hasBb) { - size += pb::CodedOutputStream.ComputeInt32Size(1, Bb); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static NestedMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NestedMessage MakeReadOnly() { - return this; - } + protected override NestedMessage ThisMessage + { + get { return this; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NestedMessage prototype) { - return new Builder(prototype); - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NestedMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NestedMessage result; - - private NestedMessage PrepareBuilder() { - if (resultIsReadOnly) { - NestedMessage original = result; - result = new NestedMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NestedMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; } + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } + public const int BbFieldNumber = 1; + private bool hasBb; + private int bb_; + public bool HasBb + { + get { return hasBb; } + } + public int Bb + { + get { return bb_; } + } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Descriptor; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - public override NestedMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (hasBb) + { + output.WriteInt32(1, field_names[0], Bb); + } + UnknownFields.WriteTo(output); + } - public override NestedMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public override Builder MergeFrom(pb::IMessage other) { - if (other is NestedMessage) { - return MergeFrom((NestedMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public override Builder MergeFrom(NestedMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasBb) { - Bb = other.Bb; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _nestedMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + size = 0; + if (hasBb) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, Bb); } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; } - case 8: { - result.hasBb = input.ReadInt32(ref result.bb_); - break; + public static NestedMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() + { + return this; } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasBb { - get { return result.hasBb; } - } - public int Bb { - get { return result.Bb; } - set { SetBb(value); } - } - public Builder SetBb(int value) { - PrepareBuilder(); - result.hasBb = true; - result.bb_ = value; - return this; - } - public Builder ClearBb() { - PrepareBuilder(); - result.hasBb = false; - result.bb_ = 0; - return this; - } - } - static NestedMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OptionalGroup : pb::GeneratedMessage { - private OptionalGroup() { } - private static readonly OptionalGroup defaultInstance = new OptionalGroup().MakeReadOnly(); - private static readonly string[] _optionalGroupFieldNames = new string[] { "a" }; - private static readonly uint[] _optionalGroupFieldTags = new uint[] { 136 }; - public static OptionalGroup DefaultInstance { - get { return defaultInstance; } - } - - public override OptionalGroup DefaultInstanceForType { - get { return DefaultInstance; } - } - protected override OptionalGroup ThisMessage { - get { return this; } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) + { + return new Builder(prototype); + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable; } - } + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public const int AFieldNumber = 17; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public override bool IsInitialized { - get { - return true; - } - } + protected override NestedMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _optionalGroupFieldNames; - if (hasA) { - output.WriteInt32(17, field_names[0], A); - } - UnknownFields.WriteTo(output); - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Descriptor; } + } - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(17, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static OptionalGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static OptionalGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private OptionalGroup MakeReadOnly() { - return this; - } + public override NestedMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OptionalGroup prototype) { - return new Builder(prototype); - } + public override NestedMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OptionalGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OptionalGroup result; - - private OptionalGroup PrepareBuilder() { - if (resultIsReadOnly) { - OptionalGroup original = result; - result = new OptionalGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OptionalGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is NestedMessage) + { + return MergeFrom((NestedMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } + public override Builder MergeFrom(NestedMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasBb) + { + Bb = other.Bb; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Descriptor; } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public override OptionalGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance; } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasBb = input.ReadInt32(ref result.bb_); + break; + } + } + } - public override OptionalGroup BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public override Builder MergeFrom(pb::IMessage other) { - if (other is OptionalGroup) { - return MergeFrom((OptionalGroup) other); - } else { - base.MergeFrom(other); - return this; - } - } - public override Builder MergeFrom(OptionalGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _optionalGroupFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + public bool HasBb + { + get { return result.hasBb; } + } + public int Bb + { + get { return result.Bb; } + set { SetBb(value); } + } + public Builder SetBb(int value) + { + PrepareBuilder(); + result.hasBb = true; + result.bb_ = value; + return this; + } + public Builder ClearBb() + { + PrepareBuilder(); + result.hasBb = false; + result.bb_ = 0; + return this; } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; } - case 136: { - result.hasA = input.ReadInt32(ref result.a_); - break; + static NestedMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); } - } } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static OptionalGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OptionalGroup : pb::GeneratedMessage + { + private OptionalGroup() { } + private static readonly OptionalGroup defaultInstance = new OptionalGroup().MakeReadOnly(); + private static readonly string[] _optionalGroupFieldNames = new string[] { "a" }; + private static readonly uint[] _optionalGroupFieldTags = new uint[] { 136 }; + public static OptionalGroup DefaultInstance + { + get { return defaultInstance; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class RepeatedGroup : pb::GeneratedMessage { - private RepeatedGroup() { } - private static readonly RepeatedGroup defaultInstance = new RepeatedGroup().MakeReadOnly(); - private static readonly string[] _repeatedGroupFieldNames = new string[] { "a" }; - private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 376 }; - public static RepeatedGroup DefaultInstance { - get { return defaultInstance; } - } + public override OptionalGroup DefaultInstanceForType + { + get { return DefaultInstance; } + } - public override RepeatedGroup DefaultInstanceForType { - get { return DefaultInstance; } - } + protected override OptionalGroup ThisMessage + { + get { return this; } + } - protected override RepeatedGroup ThisMessage { - get { return this; } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable; } - } + public const int AFieldNumber = 17; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } - public const int AFieldNumber = 47; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - public override bool IsInitialized { - get { - return true; - } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _optionalGroupFieldNames; + if (hasA) + { + output.WriteInt32(17, field_names[0], A); + } + UnknownFields.WriteTo(output); + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _repeatedGroupFieldNames; - if (hasA) { - output.WriteInt32(47, field_names[0], A); - } - UnknownFields.WriteTo(output); - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(17, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static OptionalGroup ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OptionalGroup MakeReadOnly() + { + return this; + } - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(47, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static RepeatedGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private RepeatedGroup MakeReadOnly() { - return this; - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OptionalGroup prototype) + { + return new Builder(prototype); + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(RepeatedGroup prototype) { - return new Builder(prototype); - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OptionalGroup cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(RepeatedGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private RepeatedGroup result; - - private RepeatedGroup PrepareBuilder() { - if (resultIsReadOnly) { - RepeatedGroup original = result; - result = new RepeatedGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override RepeatedGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + private bool resultIsReadOnly; + private OptionalGroup result; + + private OptionalGroup PrepareBuilder() + { + if (resultIsReadOnly) + { + OptionalGroup original = result; + result = new OptionalGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Descriptor; } - } + protected override OptionalGroup MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public override RepeatedGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public override RepeatedGroup BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public override Builder MergeFrom(pb::IMessage other) { - if (other is RepeatedGroup) { - return MergeFrom((RepeatedGroup) other); - } else { - base.MergeFrom(other); - return this; - } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Descriptor; } + } - public override Builder MergeFrom(RepeatedGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _repeatedGroupFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + public override OptionalGroup DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance; } } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 376: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static RepeatedGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } + public override OptionalGroup BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - } - #endregion + public override Builder MergeFrom(pb::IMessage other) + { + if (other is OptionalGroup) + { + return MergeFrom((OptionalGroup)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public const int OptionalInt32FieldNumber = 1; - private bool hasOptionalInt32; - private int optionalInt32_; - public bool HasOptionalInt32 { - get { return hasOptionalInt32; } - } - public int OptionalInt32 { - get { return optionalInt32_; } - } + public override Builder MergeFrom(OptionalGroup other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public const int OptionalInt64FieldNumber = 2; - private bool hasOptionalInt64; - private long optionalInt64_; - public bool HasOptionalInt64 { - get { return hasOptionalInt64; } - } - public long OptionalInt64 { - get { return optionalInt64_; } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public const int OptionalUint32FieldNumber = 3; - private bool hasOptionalUint32; - private uint optionalUint32_; - public bool HasOptionalUint32 { - get { return hasOptionalUint32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalUint32 { - get { return optionalUint32_; } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _optionalGroupFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 136: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } - public const int OptionalUint64FieldNumber = 4; - private bool hasOptionalUint64; - private ulong optionalUint64_; - public bool HasOptionalUint64 { - get { return hasOptionalUint64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalUint64 { - get { return optionalUint64_; } - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public const int OptionalSint32FieldNumber = 5; - private bool hasOptionalSint32; - private int optionalSint32_; - public bool HasOptionalSint32 { - get { return hasOptionalSint32; } - } - public int OptionalSint32 { - get { return optionalSint32_; } - } - public const int OptionalSint64FieldNumber = 6; - private bool hasOptionalSint64; - private long optionalSint64_; - public bool HasOptionalSint64 { - get { return hasOptionalSint64; } - } - public long OptionalSint64 { - get { return optionalSint64_; } - } + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static OptionalGroup() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - public const int OptionalFixed32FieldNumber = 7; - private bool hasOptionalFixed32; - private uint optionalFixed32_; - public bool HasOptionalFixed32 { - get { return hasOptionalFixed32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalFixed32 { - get { return optionalFixed32_; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedGroup : pb::GeneratedMessage + { + private RepeatedGroup() { } + private static readonly RepeatedGroup defaultInstance = new RepeatedGroup().MakeReadOnly(); + private static readonly string[] _repeatedGroupFieldNames = new string[] { "a" }; + private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 376 }; + public static RepeatedGroup DefaultInstance + { + get { return defaultInstance; } + } - public const int OptionalFixed64FieldNumber = 8; - private bool hasOptionalFixed64; - private ulong optionalFixed64_; - public bool HasOptionalFixed64 { - get { return hasOptionalFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalFixed64 { - get { return optionalFixed64_; } - } + public override RepeatedGroup DefaultInstanceForType + { + get { return DefaultInstance; } + } - public const int OptionalSfixed32FieldNumber = 9; - private bool hasOptionalSfixed32; - private int optionalSfixed32_; - public bool HasOptionalSfixed32 { - get { return hasOptionalSfixed32; } - } - public int OptionalSfixed32 { - get { return optionalSfixed32_; } - } + protected override RepeatedGroup ThisMessage + { + get { return this; } + } - public const int OptionalSfixed64FieldNumber = 10; - private bool hasOptionalSfixed64; - private long optionalSfixed64_; - public bool HasOptionalSfixed64 { - get { return hasOptionalSfixed64; } - } - public long OptionalSfixed64 { - get { return optionalSfixed64_; } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor; } + } - public const int OptionalFloatFieldNumber = 11; - private bool hasOptionalFloat; - private float optionalFloat_; - public bool HasOptionalFloat { - get { return hasOptionalFloat; } - } - public float OptionalFloat { - get { return optionalFloat_; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable; } + } - public const int OptionalDoubleFieldNumber = 12; - private bool hasOptionalDouble; - private double optionalDouble_; - public bool HasOptionalDouble { - get { return hasOptionalDouble; } - } - public double OptionalDouble { - get { return optionalDouble_; } - } + public const int AFieldNumber = 47; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } - public const int OptionalBoolFieldNumber = 13; - private bool hasOptionalBool; - private bool optionalBool_; - public bool HasOptionalBool { - get { return hasOptionalBool; } - } - public bool OptionalBool { - get { return optionalBool_; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - public const int OptionalStringFieldNumber = 14; - private bool hasOptionalString; - private string optionalString_ = ""; - public bool HasOptionalString { - get { return hasOptionalString; } - } - public string OptionalString { - get { return optionalString_; } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _repeatedGroupFieldNames; + if (hasA) + { + output.WriteInt32(47, field_names[0], A); + } + UnknownFields.WriteTo(output); + } - public const int OptionalBytesFieldNumber = 15; - private bool hasOptionalBytes; - private pb::ByteString optionalBytes_ = pb::ByteString.Empty; - public bool HasOptionalBytes { - get { return hasOptionalBytes; } - } - public pb::ByteString OptionalBytes { - get { return optionalBytes_; } - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public const int OptionalGroupFieldNumber = 16; - private bool hasOptionalGroup; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup optionalGroup_; - public bool HasOptionalGroup { - get { return hasOptionalGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup OptionalGroup { - get { return optionalGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance; } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public const int OptionalNestedMessageFieldNumber = 18; - private bool hasOptionalNestedMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage optionalNestedMessage_; - public bool HasOptionalNestedMessage { - get { return hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage { - get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(47, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static RepeatedGroup ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedGroup MakeReadOnly() + { + return this; + } - public const int OptionalForeignMessageFieldNumber = 19; - private bool hasOptionalForeignMessage; - private global::Google.ProtocolBuffers.TestProtos.ForeignMessage optionalForeignMessage_; - public bool HasOptionalForeignMessage { - get { return hasOptionalForeignMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage { - get { return optionalForeignMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedGroup prototype) + { + return new Builder(prototype); + } - public const int OptionalImportMessageFieldNumber = 20; - private bool hasOptionalImportMessage; - private global::Google.ProtocolBuffers.TestProtos.ImportMessage optionalImportMessage_; - public bool HasOptionalImportMessage { - get { return hasOptionalImportMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessage OptionalImportMessage { - get { return optionalImportMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedGroup cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - public const int OptionalNestedEnumFieldNumber = 21; - private bool hasOptionalNestedEnum; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; - public bool HasOptionalNestedEnum { - get { return hasOptionalNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum { - get { return optionalNestedEnum_; } - } + private bool resultIsReadOnly; + private RepeatedGroup result; + + private RepeatedGroup PrepareBuilder() + { + if (resultIsReadOnly) + { + RepeatedGroup original = result; + result = new RepeatedGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public const int OptionalForeignEnumFieldNumber = 22; - private bool hasOptionalForeignEnum; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnum optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - public bool HasOptionalForeignEnum { - get { return hasOptionalForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum { - get { return optionalForeignEnum_; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public const int OptionalImportEnumFieldNumber = 23; - private bool hasOptionalImportEnum; - private global::Google.ProtocolBuffers.TestProtos.ImportEnum optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_FOO; - public bool HasOptionalImportEnum { - get { return hasOptionalImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum OptionalImportEnum { - get { return optionalImportEnum_; } - } + protected override RepeatedGroup MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public const int OptionalStringPieceFieldNumber = 24; - private bool hasOptionalStringPiece; - private string optionalStringPiece_ = ""; - public bool HasOptionalStringPiece { - get { return hasOptionalStringPiece; } - } - public string OptionalStringPiece { - get { return optionalStringPiece_; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public const int OptionalCordFieldNumber = 25; - private bool hasOptionalCord; - private string optionalCord_ = ""; - public bool HasOptionalCord { - get { return hasOptionalCord; } - } - public string OptionalCord { - get { return optionalCord_; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public const int OptionalPublicImportMessageFieldNumber = 26; - private bool hasOptionalPublicImportMessage; - private global::Google.ProtocolBuffers.TestProtos.PublicImportMessage optionalPublicImportMessage_; - public bool HasOptionalPublicImportMessage { - get { return hasOptionalPublicImportMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.PublicImportMessage OptionalPublicImportMessage { - get { return optionalPublicImportMessage_ ?? global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.DefaultInstance; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Descriptor; } + } - public const int OptionalLazyMessageFieldNumber = 27; - private bool hasOptionalLazyMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage optionalLazyMessage_; - public bool HasOptionalLazyMessage { - get { return hasOptionalLazyMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalLazyMessage { - get { return optionalLazyMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } + public override RepeatedGroup DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance; } + } - public const int RepeatedInt32FieldNumber = 31; - private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt32List { - get { return pbc::Lists.AsReadOnly(repeatedInt32_); } - } - public int RepeatedInt32Count { - get { return repeatedInt32_.Count; } - } - public int GetRepeatedInt32(int index) { - return repeatedInt32_[index]; - } + public override RepeatedGroup BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public const int RepeatedInt64FieldNumber = 32; - private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt64List { - get { return pbc::Lists.AsReadOnly(repeatedInt64_); } - } - public int RepeatedInt64Count { - get { return repeatedInt64_.Count; } - } - public long GetRepeatedInt64(int index) { - return repeatedInt64_[index]; - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is RepeatedGroup) + { + return MergeFrom((RepeatedGroup)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public const int RepeatedUint32FieldNumber = 33; - private pbc::PopsicleList repeatedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedUint32List { - get { return pbc::Lists.AsReadOnly(repeatedUint32_); } - } - public int RepeatedUint32Count { - get { return repeatedUint32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedUint32(int index) { - return repeatedUint32_[index]; - } + public override Builder MergeFrom(RepeatedGroup other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public const int RepeatedUint64FieldNumber = 34; - private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedUint64List { - get { return pbc::Lists.AsReadOnly(repeatedUint64_); } - } - public int RepeatedUint64Count { - get { return repeatedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return repeatedUint64_[index]; - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public const int RepeatedSint32FieldNumber = 35; - private pbc::PopsicleList repeatedSint32_ = new pbc::PopsicleList(); - public scg::IList RepeatedSint32List { - get { return pbc::Lists.AsReadOnly(repeatedSint32_); } - } - public int RepeatedSint32Count { - get { return repeatedSint32_.Count; } - } - public int GetRepeatedSint32(int index) { - return repeatedSint32_[index]; - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _repeatedGroupFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 376: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } - public const int RepeatedSint64FieldNumber = 36; - private pbc::PopsicleList repeatedSint64_ = new pbc::PopsicleList(); - public scg::IList RepeatedSint64List { - get { return pbc::Lists.AsReadOnly(repeatedSint64_); } - } - public int RepeatedSint64Count { - get { return repeatedSint64_.Count; } - } - public long GetRepeatedSint64(int index) { - return repeatedSint64_[index]; - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public const int RepeatedFixed32FieldNumber = 37; - private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed32List { - get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } - } - public int RepeatedFixed32Count { - get { return repeatedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return repeatedFixed32_[index]; - } - public const int RepeatedFixed64FieldNumber = 38; - private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed64List { - get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } - } - public int RepeatedFixed64Count { - get { return repeatedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return repeatedFixed64_[index]; - } + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static RepeatedGroup() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - public const int RepeatedSfixed32FieldNumber = 39; - private pbc::PopsicleList repeatedSfixed32_ = new pbc::PopsicleList(); - public scg::IList RepeatedSfixed32List { - get { return pbc::Lists.AsReadOnly(repeatedSfixed32_); } - } - public int RepeatedSfixed32Count { - get { return repeatedSfixed32_.Count; } - } - public int GetRepeatedSfixed32(int index) { - return repeatedSfixed32_[index]; - } + } + #endregion - public const int RepeatedSfixed64FieldNumber = 40; - private pbc::PopsicleList repeatedSfixed64_ = new pbc::PopsicleList(); - public scg::IList RepeatedSfixed64List { - get { return pbc::Lists.AsReadOnly(repeatedSfixed64_); } - } - public int RepeatedSfixed64Count { - get { return repeatedSfixed64_.Count; } - } - public long GetRepeatedSfixed64(int index) { - return repeatedSfixed64_[index]; - } + public const int OptionalInt32FieldNumber = 1; + private bool hasOptionalInt32; + private int optionalInt32_; + public bool HasOptionalInt32 + { + get { return hasOptionalInt32; } + } + public int OptionalInt32 + { + get { return optionalInt32_; } + } - public const int RepeatedFloatFieldNumber = 41; - private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); - public scg::IList RepeatedFloatList { - get { return pbc::Lists.AsReadOnly(repeatedFloat_); } - } - public int RepeatedFloatCount { - get { return repeatedFloat_.Count; } - } - public float GetRepeatedFloat(int index) { - return repeatedFloat_[index]; - } + public const int OptionalInt64FieldNumber = 2; + private bool hasOptionalInt64; + private long optionalInt64_; + public bool HasOptionalInt64 + { + get { return hasOptionalInt64; } + } + public long OptionalInt64 + { + get { return optionalInt64_; } + } - public const int RepeatedDoubleFieldNumber = 42; - private pbc::PopsicleList repeatedDouble_ = new pbc::PopsicleList(); - public scg::IList RepeatedDoubleList { - get { return pbc::Lists.AsReadOnly(repeatedDouble_); } - } - public int RepeatedDoubleCount { - get { return repeatedDouble_.Count; } - } - public double GetRepeatedDouble(int index) { - return repeatedDouble_[index]; - } + public const int OptionalUint32FieldNumber = 3; + private bool hasOptionalUint32; + private uint optionalUint32_; + public bool HasOptionalUint32 + { + get { return hasOptionalUint32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalUint32 + { + get { return optionalUint32_; } + } - public const int RepeatedBoolFieldNumber = 43; - private pbc::PopsicleList repeatedBool_ = new pbc::PopsicleList(); - public scg::IList RepeatedBoolList { - get { return pbc::Lists.AsReadOnly(repeatedBool_); } - } - public int RepeatedBoolCount { - get { return repeatedBool_.Count; } - } - public bool GetRepeatedBool(int index) { - return repeatedBool_[index]; - } + public const int OptionalUint64FieldNumber = 4; + private bool hasOptionalUint64; + private ulong optionalUint64_; + public bool HasOptionalUint64 + { + get { return hasOptionalUint64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalUint64 + { + get { return optionalUint64_; } + } - public const int RepeatedStringFieldNumber = 44; - private pbc::PopsicleList repeatedString_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringList { - get { return pbc::Lists.AsReadOnly(repeatedString_); } - } - public int RepeatedStringCount { - get { return repeatedString_.Count; } - } - public string GetRepeatedString(int index) { - return repeatedString_[index]; - } + public const int OptionalSint32FieldNumber = 5; + private bool hasOptionalSint32; + private int optionalSint32_; + public bool HasOptionalSint32 + { + get { return hasOptionalSint32; } + } + public int OptionalSint32 + { + get { return optionalSint32_; } + } - public const int RepeatedBytesFieldNumber = 45; - private pbc::PopsicleList repeatedBytes_ = new pbc::PopsicleList(); - public scg::IList RepeatedBytesList { - get { return pbc::Lists.AsReadOnly(repeatedBytes_); } - } - public int RepeatedBytesCount { - get { return repeatedBytes_.Count; } - } - public pb::ByteString GetRepeatedBytes(int index) { - return repeatedBytes_[index]; - } + public const int OptionalSint64FieldNumber = 6; + private bool hasOptionalSint64; + private long optionalSint64_; + public bool HasOptionalSint64 + { + get { return hasOptionalSint64; } + } + public long OptionalSint64 + { + get { return optionalSint64_; } + } - public const int RepeatedGroupFieldNumber = 46; - private pbc::PopsicleList repeatedGroup_ = new pbc::PopsicleList(); - public scg::IList RepeatedGroupList { - get { return repeatedGroup_; } - } - public int RepeatedGroupCount { - get { return repeatedGroup_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup GetRepeatedGroup(int index) { - return repeatedGroup_[index]; - } + public const int OptionalFixed32FieldNumber = 7; + private bool hasOptionalFixed32; + private uint optionalFixed32_; + public bool HasOptionalFixed32 + { + get { return hasOptionalFixed32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalFixed32 + { + get { return optionalFixed32_; } + } + + public const int OptionalFixed64FieldNumber = 8; + private bool hasOptionalFixed64; + private ulong optionalFixed64_; + public bool HasOptionalFixed64 + { + get { return hasOptionalFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalFixed64 + { + get { return optionalFixed64_; } + } + + public const int OptionalSfixed32FieldNumber = 9; + private bool hasOptionalSfixed32; + private int optionalSfixed32_; + public bool HasOptionalSfixed32 + { + get { return hasOptionalSfixed32; } + } + public int OptionalSfixed32 + { + get { return optionalSfixed32_; } + } + + public const int OptionalSfixed64FieldNumber = 10; + private bool hasOptionalSfixed64; + private long optionalSfixed64_; + public bool HasOptionalSfixed64 + { + get { return hasOptionalSfixed64; } + } + public long OptionalSfixed64 + { + get { return optionalSfixed64_; } + } + + public const int OptionalFloatFieldNumber = 11; + private bool hasOptionalFloat; + private float optionalFloat_; + public bool HasOptionalFloat + { + get { return hasOptionalFloat; } + } + public float OptionalFloat + { + get { return optionalFloat_; } + } - public const int RepeatedNestedMessageFieldNumber = 48; - private pbc::PopsicleList repeatedNestedMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedNestedMessageList { - get { return repeatedNestedMessage_; } - } - public int RepeatedNestedMessageCount { - get { return repeatedNestedMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) { - return repeatedNestedMessage_[index]; - } + public const int OptionalDoubleFieldNumber = 12; + private bool hasOptionalDouble; + private double optionalDouble_; + public bool HasOptionalDouble + { + get { return hasOptionalDouble; } + } + public double OptionalDouble + { + get { return optionalDouble_; } + } - public const int RepeatedForeignMessageFieldNumber = 49; - private pbc::PopsicleList repeatedForeignMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedForeignMessageList { - get { return repeatedForeignMessage_; } - } - public int RepeatedForeignMessageCount { - get { return repeatedForeignMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) { - return repeatedForeignMessage_[index]; - } + public const int OptionalBoolFieldNumber = 13; + private bool hasOptionalBool; + private bool optionalBool_; + public bool HasOptionalBool + { + get { return hasOptionalBool; } + } + public bool OptionalBool + { + get { return optionalBool_; } + } - public const int RepeatedImportMessageFieldNumber = 50; - private pbc::PopsicleList repeatedImportMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedImportMessageList { - get { return repeatedImportMessage_; } - } - public int RepeatedImportMessageCount { - get { return repeatedImportMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessage GetRepeatedImportMessage(int index) { - return repeatedImportMessage_[index]; - } + public const int OptionalStringFieldNumber = 14; + private bool hasOptionalString; + private string optionalString_ = ""; + public bool HasOptionalString + { + get { return hasOptionalString; } + } + public string OptionalString + { + get { return optionalString_; } + } - public const int RepeatedNestedEnumFieldNumber = 51; - private pbc::PopsicleList repeatedNestedEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedNestedEnumList { - get { return pbc::Lists.AsReadOnly(repeatedNestedEnum_); } - } - public int RepeatedNestedEnumCount { - get { return repeatedNestedEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) { - return repeatedNestedEnum_[index]; - } + public const int OptionalBytesFieldNumber = 15; + private bool hasOptionalBytes; + private pb::ByteString optionalBytes_ = pb::ByteString.Empty; + public bool HasOptionalBytes + { + get { return hasOptionalBytes; } + } + public pb::ByteString OptionalBytes + { + get { return optionalBytes_; } + } - public const int RepeatedForeignEnumFieldNumber = 52; - private pbc::PopsicleList repeatedForeignEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedForeignEnumList { - get { return pbc::Lists.AsReadOnly(repeatedForeignEnum_); } - } - public int RepeatedForeignEnumCount { - get { return repeatedForeignEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) { - return repeatedForeignEnum_[index]; - } + public const int OptionalGroupFieldNumber = 16; + private bool hasOptionalGroup; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup optionalGroup_; + public bool HasOptionalGroup + { + get { return hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup OptionalGroup + { + get { return optionalGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance; } + } - public const int RepeatedImportEnumFieldNumber = 53; - private pbc::PopsicleList repeatedImportEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedImportEnumList { - get { return pbc::Lists.AsReadOnly(repeatedImportEnum_); } - } - public int RepeatedImportEnumCount { - get { return repeatedImportEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum GetRepeatedImportEnum(int index) { - return repeatedImportEnum_[index]; - } + public const int OptionalNestedMessageFieldNumber = 18; + private bool hasOptionalNestedMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage optionalNestedMessage_; + public bool HasOptionalNestedMessage + { + get { return hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage + { + get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } + } - public const int RepeatedStringPieceFieldNumber = 54; - private pbc::PopsicleList repeatedStringPiece_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringPieceList { - get { return pbc::Lists.AsReadOnly(repeatedStringPiece_); } - } - public int RepeatedStringPieceCount { - get { return repeatedStringPiece_.Count; } - } - public string GetRepeatedStringPiece(int index) { - return repeatedStringPiece_[index]; - } + public const int OptionalForeignMessageFieldNumber = 19; + private bool hasOptionalForeignMessage; + private global::Google.ProtocolBuffers.TestProtos.ForeignMessage optionalForeignMessage_; + public bool HasOptionalForeignMessage + { + get { return hasOptionalForeignMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage + { + get { return optionalForeignMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } + } - public const int RepeatedCordFieldNumber = 55; - private pbc::PopsicleList repeatedCord_ = new pbc::PopsicleList(); - public scg::IList RepeatedCordList { - get { return pbc::Lists.AsReadOnly(repeatedCord_); } - } - public int RepeatedCordCount { - get { return repeatedCord_.Count; } - } - public string GetRepeatedCord(int index) { - return repeatedCord_[index]; - } + public const int OptionalImportMessageFieldNumber = 20; + private bool hasOptionalImportMessage; + private global::Google.ProtocolBuffers.TestProtos.ImportMessage optionalImportMessage_; + public bool HasOptionalImportMessage + { + get { return hasOptionalImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessage OptionalImportMessage + { + get { return optionalImportMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance; } + } - public const int RepeatedLazyMessageFieldNumber = 57; - private pbc::PopsicleList repeatedLazyMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedLazyMessageList { - get { return repeatedLazyMessage_; } - } - public int RepeatedLazyMessageCount { - get { return repeatedLazyMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedLazyMessage(int index) { - return repeatedLazyMessage_[index]; - } - - public const int DefaultInt32FieldNumber = 61; - private bool hasDefaultInt32; - private int defaultInt32_ = 41; - public bool HasDefaultInt32 { - get { return hasDefaultInt32; } - } - public int DefaultInt32 { - get { return defaultInt32_; } - } - - public const int DefaultInt64FieldNumber = 62; - private bool hasDefaultInt64; - private long defaultInt64_ = 42L; - public bool HasDefaultInt64 { - get { return hasDefaultInt64; } - } - public long DefaultInt64 { - get { return defaultInt64_; } - } - - public const int DefaultUint32FieldNumber = 63; - private bool hasDefaultUint32; - private uint defaultUint32_ = 43; - public bool HasDefaultUint32 { - get { return hasDefaultUint32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultUint32 { - get { return defaultUint32_; } - } - - public const int DefaultUint64FieldNumber = 64; - private bool hasDefaultUint64; - private ulong defaultUint64_ = 44UL; - public bool HasDefaultUint64 { - get { return hasDefaultUint64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultUint64 { - get { return defaultUint64_; } - } - - public const int DefaultSint32FieldNumber = 65; - private bool hasDefaultSint32; - private int defaultSint32_ = -45; - public bool HasDefaultSint32 { - get { return hasDefaultSint32; } - } - public int DefaultSint32 { - get { return defaultSint32_; } - } - - public const int DefaultSint64FieldNumber = 66; - private bool hasDefaultSint64; - private long defaultSint64_ = 46L; - public bool HasDefaultSint64 { - get { return hasDefaultSint64; } - } - public long DefaultSint64 { - get { return defaultSint64_; } - } - - public const int DefaultFixed32FieldNumber = 67; - private bool hasDefaultFixed32; - private uint defaultFixed32_ = 47; - public bool HasDefaultFixed32 { - get { return hasDefaultFixed32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultFixed32 { - get { return defaultFixed32_; } - } - - public const int DefaultFixed64FieldNumber = 68; - private bool hasDefaultFixed64; - private ulong defaultFixed64_ = 48UL; - public bool HasDefaultFixed64 { - get { return hasDefaultFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultFixed64 { - get { return defaultFixed64_; } - } - - public const int DefaultSfixed32FieldNumber = 69; - private bool hasDefaultSfixed32; - private int defaultSfixed32_ = 49; - public bool HasDefaultSfixed32 { - get { return hasDefaultSfixed32; } - } - public int DefaultSfixed32 { - get { return defaultSfixed32_; } - } - - public const int DefaultSfixed64FieldNumber = 70; - private bool hasDefaultSfixed64; - private long defaultSfixed64_ = -50L; - public bool HasDefaultSfixed64 { - get { return hasDefaultSfixed64; } - } - public long DefaultSfixed64 { - get { return defaultSfixed64_; } - } - - public const int DefaultFloatFieldNumber = 71; - private bool hasDefaultFloat; - private float defaultFloat_ = 51.5F; - public bool HasDefaultFloat { - get { return hasDefaultFloat; } - } - public float DefaultFloat { - get { return defaultFloat_; } - } - - public const int DefaultDoubleFieldNumber = 72; - private bool hasDefaultDouble; - private double defaultDouble_ = 52000D; - public bool HasDefaultDouble { - get { return hasDefaultDouble; } - } - public double DefaultDouble { - get { return defaultDouble_; } - } - - public const int DefaultBoolFieldNumber = 73; - private bool hasDefaultBool; - private bool defaultBool_ = true; - public bool HasDefaultBool { - get { return hasDefaultBool; } - } - public bool DefaultBool { - get { return defaultBool_; } - } - - public const int DefaultStringFieldNumber = 74; - private bool hasDefaultString; - private string defaultString_ = "hello"; - public bool HasDefaultString { - get { return hasDefaultString; } - } - public string DefaultString { - get { return defaultString_; } - } - - public const int DefaultBytesFieldNumber = 75; - private bool hasDefaultBytes; - private pb::ByteString defaultBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor.Fields[65].DefaultValue; - public bool HasDefaultBytes { - get { return hasDefaultBytes; } - } - public pb::ByteString DefaultBytes { - get { return defaultBytes_; } - } - - public const int DefaultNestedEnumFieldNumber = 81; - private bool hasDefaultNestedEnum; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.BAR; - public bool HasDefaultNestedEnum { - get { return hasDefaultNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum DefaultNestedEnum { - get { return defaultNestedEnum_; } - } - - public const int DefaultForeignEnumFieldNumber = 82; - private bool hasDefaultForeignEnum; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnum defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_BAR; - public bool HasDefaultForeignEnum { - get { return hasDefaultForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum DefaultForeignEnum { - get { return defaultForeignEnum_; } - } - - public const int DefaultImportEnumFieldNumber = 83; - private bool hasDefaultImportEnum; - private global::Google.ProtocolBuffers.TestProtos.ImportEnum defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_BAR; - public bool HasDefaultImportEnum { - get { return hasDefaultImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum DefaultImportEnum { - get { return defaultImportEnum_; } - } - - public const int DefaultStringPieceFieldNumber = 84; - private bool hasDefaultStringPiece; - private string defaultStringPiece_ = "abc"; - public bool HasDefaultStringPiece { - get { return hasDefaultStringPiece; } - } - public string DefaultStringPiece { - get { return defaultStringPiece_; } - } - - public const int DefaultCordFieldNumber = 85; - private bool hasDefaultCord; - private string defaultCord_ = "123"; - public bool HasDefaultCord { - get { return hasDefaultCord; } - } - public string DefaultCord { - get { return defaultCord_; } - } - - public const int OneofUint32FieldNumber = 111; - private bool hasOneofUint32; - private uint oneofUint32_; - public bool HasOneofUint32 { - get { return hasOneofUint32; } - } - [global::System.CLSCompliant(false)] - public uint OneofUint32 { - get { return oneofUint32_; } - } - - public const int OneofNestedMessageFieldNumber = 112; - private bool hasOneofNestedMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage oneofNestedMessage_; - public bool HasOneofNestedMessage { - get { return hasOneofNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OneofNestedMessage { - get { return oneofNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } - - public const int OneofStringFieldNumber = 113; - private bool hasOneofString; - private string oneofString_ = ""; - public bool HasOneofString { - get { return hasOneofString; } - } - public string OneofString { - get { return oneofString_; } - } - - public const int OneofBytesFieldNumber = 114; - private bool hasOneofBytes; - private pb::ByteString oneofBytes_ = pb::ByteString.Empty; - public bool HasOneofBytes { - get { return hasOneofBytes; } - } - public pb::ByteString OneofBytes { - get { return oneofBytes_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testAllTypesFieldNames; - if (hasOptionalInt32) { - output.WriteInt32(1, field_names[35], OptionalInt32); - } - if (hasOptionalInt64) { - output.WriteInt64(2, field_names[36], OptionalInt64); - } - if (hasOptionalUint32) { - output.WriteUInt32(3, field_names[47], OptionalUint32); - } - if (hasOptionalUint64) { - output.WriteUInt64(4, field_names[48], OptionalUint64); - } - if (hasOptionalSint32) { - output.WriteSInt32(5, field_names[43], OptionalSint32); - } - if (hasOptionalSint64) { - output.WriteSInt64(6, field_names[44], OptionalSint64); - } - if (hasOptionalFixed32) { - output.WriteFixed32(7, field_names[28], OptionalFixed32); - } - if (hasOptionalFixed64) { - output.WriteFixed64(8, field_names[29], OptionalFixed64); - } - if (hasOptionalSfixed32) { - output.WriteSFixed32(9, field_names[41], OptionalSfixed32); - } - if (hasOptionalSfixed64) { - output.WriteSFixed64(10, field_names[42], OptionalSfixed64); - } - if (hasOptionalFloat) { - output.WriteFloat(11, field_names[30], OptionalFloat); - } - if (hasOptionalDouble) { - output.WriteDouble(12, field_names[27], OptionalDouble); - } - if (hasOptionalBool) { - output.WriteBool(13, field_names[24], OptionalBool); - } - if (hasOptionalString) { - output.WriteString(14, field_names[45], OptionalString); - } - if (hasOptionalBytes) { - output.WriteBytes(15, field_names[25], OptionalBytes); - } - if (hasOptionalGroup) { - output.WriteGroup(16, field_names[49], OptionalGroup); - } - if (hasOptionalNestedMessage) { - output.WriteMessage(18, field_names[39], OptionalNestedMessage); - } - if (hasOptionalForeignMessage) { - output.WriteMessage(19, field_names[32], OptionalForeignMessage); - } - if (hasOptionalImportMessage) { - output.WriteMessage(20, field_names[34], OptionalImportMessage); - } - if (hasOptionalNestedEnum) { - output.WriteEnum(21, field_names[38], (int) OptionalNestedEnum, OptionalNestedEnum); - } - if (hasOptionalForeignEnum) { - output.WriteEnum(22, field_names[31], (int) OptionalForeignEnum, OptionalForeignEnum); - } - if (hasOptionalImportEnum) { - output.WriteEnum(23, field_names[33], (int) OptionalImportEnum, OptionalImportEnum); - } - if (hasOptionalStringPiece) { - output.WriteString(24, field_names[46], OptionalStringPiece); - } - if (hasOptionalCord) { - output.WriteString(25, field_names[26], OptionalCord); - } - if (hasOptionalPublicImportMessage) { - output.WriteMessage(26, field_names[40], OptionalPublicImportMessage); - } - if (hasOptionalLazyMessage) { - output.WriteMessage(27, field_names[37], OptionalLazyMessage); - } - if (repeatedInt32_.Count > 0) { - output.WriteInt32Array(31, field_names[61], repeatedInt32_); - } - if (repeatedInt64_.Count > 0) { - output.WriteInt64Array(32, field_names[62], repeatedInt64_); - } - if (repeatedUint32_.Count > 0) { - output.WriteUInt32Array(33, field_names[72], repeatedUint32_); - } - if (repeatedUint64_.Count > 0) { - output.WriteUInt64Array(34, field_names[73], repeatedUint64_); - } - if (repeatedSint32_.Count > 0) { - output.WriteSInt32Array(35, field_names[68], repeatedSint32_); - } - if (repeatedSint64_.Count > 0) { - output.WriteSInt64Array(36, field_names[69], repeatedSint64_); - } - if (repeatedFixed32_.Count > 0) { - output.WriteFixed32Array(37, field_names[54], repeatedFixed32_); - } - if (repeatedFixed64_.Count > 0) { - output.WriteFixed64Array(38, field_names[55], repeatedFixed64_); - } - if (repeatedSfixed32_.Count > 0) { - output.WriteSFixed32Array(39, field_names[66], repeatedSfixed32_); - } - if (repeatedSfixed64_.Count > 0) { - output.WriteSFixed64Array(40, field_names[67], repeatedSfixed64_); - } - if (repeatedFloat_.Count > 0) { - output.WriteFloatArray(41, field_names[56], repeatedFloat_); - } - if (repeatedDouble_.Count > 0) { - output.WriteDoubleArray(42, field_names[53], repeatedDouble_); - } - if (repeatedBool_.Count > 0) { - output.WriteBoolArray(43, field_names[50], repeatedBool_); - } - if (repeatedString_.Count > 0) { - output.WriteStringArray(44, field_names[70], repeatedString_); - } - if (repeatedBytes_.Count > 0) { - output.WriteBytesArray(45, field_names[51], repeatedBytes_); - } - if (repeatedGroup_.Count > 0) { - output.WriteGroupArray(46, field_names[74], repeatedGroup_); - } - if (repeatedNestedMessage_.Count > 0) { - output.WriteMessageArray(48, field_names[65], repeatedNestedMessage_); - } - if (repeatedForeignMessage_.Count > 0) { - output.WriteMessageArray(49, field_names[58], repeatedForeignMessage_); - } - if (repeatedImportMessage_.Count > 0) { - output.WriteMessageArray(50, field_names[60], repeatedImportMessage_); - } - if (repeatedNestedEnum_.Count > 0) { - output.WriteEnumArray(51, field_names[64], repeatedNestedEnum_); - } - if (repeatedForeignEnum_.Count > 0) { - output.WriteEnumArray(52, field_names[57], repeatedForeignEnum_); - } - if (repeatedImportEnum_.Count > 0) { - output.WriteEnumArray(53, field_names[59], repeatedImportEnum_); - } - if (repeatedStringPiece_.Count > 0) { - output.WriteStringArray(54, field_names[71], repeatedStringPiece_); - } - if (repeatedCord_.Count > 0) { - output.WriteStringArray(55, field_names[52], repeatedCord_); - } - if (repeatedLazyMessage_.Count > 0) { - output.WriteMessageArray(57, field_names[63], repeatedLazyMessage_); - } - if (hasDefaultInt32) { - output.WriteInt32(61, field_names[9], DefaultInt32); - } - if (hasDefaultInt64) { - output.WriteInt64(62, field_names[10], DefaultInt64); - } - if (hasDefaultUint32) { - output.WriteUInt32(63, field_names[18], DefaultUint32); - } - if (hasDefaultUint64) { - output.WriteUInt64(64, field_names[19], DefaultUint64); - } - if (hasDefaultSint32) { - output.WriteSInt32(65, field_names[14], DefaultSint32); - } - if (hasDefaultSint64) { - output.WriteSInt64(66, field_names[15], DefaultSint64); - } - if (hasDefaultFixed32) { - output.WriteFixed32(67, field_names[4], DefaultFixed32); - } - if (hasDefaultFixed64) { - output.WriteFixed64(68, field_names[5], DefaultFixed64); - } - if (hasDefaultSfixed32) { - output.WriteSFixed32(69, field_names[12], DefaultSfixed32); - } - if (hasDefaultSfixed64) { - output.WriteSFixed64(70, field_names[13], DefaultSfixed64); - } - if (hasDefaultFloat) { - output.WriteFloat(71, field_names[6], DefaultFloat); - } - if (hasDefaultDouble) { - output.WriteDouble(72, field_names[3], DefaultDouble); - } - if (hasDefaultBool) { - output.WriteBool(73, field_names[0], DefaultBool); - } - if (hasDefaultString) { - output.WriteString(74, field_names[16], DefaultString); - } - if (hasDefaultBytes) { - output.WriteBytes(75, field_names[1], DefaultBytes); - } - if (hasDefaultNestedEnum) { - output.WriteEnum(81, field_names[11], (int) DefaultNestedEnum, DefaultNestedEnum); - } - if (hasDefaultForeignEnum) { - output.WriteEnum(82, field_names[7], (int) DefaultForeignEnum, DefaultForeignEnum); - } - if (hasDefaultImportEnum) { - output.WriteEnum(83, field_names[8], (int) DefaultImportEnum, DefaultImportEnum); - } - if (hasDefaultStringPiece) { - output.WriteString(84, field_names[17], DefaultStringPiece); - } - if (hasDefaultCord) { - output.WriteString(85, field_names[2], DefaultCord); - } - if (hasOneofUint32) { - output.WriteUInt32(111, field_names[23], OneofUint32); - } - if (hasOneofNestedMessage) { - output.WriteMessage(112, field_names[21], OneofNestedMessage); - } - if (hasOneofString) { - output.WriteString(113, field_names[22], OneofString); - } - if (hasOneofBytes) { - output.WriteBytes(114, field_names[20], OneofBytes); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasOptionalInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(1, OptionalInt32); - } - if (hasOptionalInt64) { - size += pb::CodedOutputStream.ComputeInt64Size(2, OptionalInt64); - } - if (hasOptionalUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(3, OptionalUint32); - } - if (hasOptionalUint64) { - size += pb::CodedOutputStream.ComputeUInt64Size(4, OptionalUint64); - } - if (hasOptionalSint32) { - size += pb::CodedOutputStream.ComputeSInt32Size(5, OptionalSint32); - } - if (hasOptionalSint64) { - size += pb::CodedOutputStream.ComputeSInt64Size(6, OptionalSint64); - } - if (hasOptionalFixed32) { - size += pb::CodedOutputStream.ComputeFixed32Size(7, OptionalFixed32); - } - if (hasOptionalFixed64) { - size += pb::CodedOutputStream.ComputeFixed64Size(8, OptionalFixed64); - } - if (hasOptionalSfixed32) { - size += pb::CodedOutputStream.ComputeSFixed32Size(9, OptionalSfixed32); - } - if (hasOptionalSfixed64) { - size += pb::CodedOutputStream.ComputeSFixed64Size(10, OptionalSfixed64); - } - if (hasOptionalFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(11, OptionalFloat); - } - if (hasOptionalDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(12, OptionalDouble); - } - if (hasOptionalBool) { - size += pb::CodedOutputStream.ComputeBoolSize(13, OptionalBool); - } - if (hasOptionalString) { - size += pb::CodedOutputStream.ComputeStringSize(14, OptionalString); - } - if (hasOptionalBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(15, OptionalBytes); - } - if (hasOptionalGroup) { - size += pb::CodedOutputStream.ComputeGroupSize(16, OptionalGroup); - } - if (hasOptionalNestedMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(18, OptionalNestedMessage); - } - if (hasOptionalForeignMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(19, OptionalForeignMessage); - } - if (hasOptionalImportMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(20, OptionalImportMessage); - } - if (hasOptionalNestedEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(21, (int) OptionalNestedEnum); - } - if (hasOptionalForeignEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(22, (int) OptionalForeignEnum); - } - if (hasOptionalImportEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(23, (int) OptionalImportEnum); - } - if (hasOptionalStringPiece) { - size += pb::CodedOutputStream.ComputeStringSize(24, OptionalStringPiece); - } - if (hasOptionalCord) { - size += pb::CodedOutputStream.ComputeStringSize(25, OptionalCord); - } - if (hasOptionalPublicImportMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(26, OptionalPublicImportMessage); - } - if (hasOptionalLazyMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(27, OptionalLazyMessage); - } - { - int dataSize = 0; - foreach (int element in RepeatedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedInt32_.Count; - } - { - int dataSize = 0; - foreach (long element in RepeatedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedInt64_.Count; - } - { - int dataSize = 0; - foreach (uint element in RepeatedUint32List) { - dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedUint32_.Count; - } - { - int dataSize = 0; - foreach (ulong element in RepeatedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedUint64_.Count; - } - { - int dataSize = 0; - foreach (int element in RepeatedSint32List) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedSint32_.Count; - } - { - int dataSize = 0; - foreach (long element in RepeatedSint64List) { - dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedSint64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedFixed32_.Count; - size += dataSize; - size += 2 * repeatedFixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedFixed64_.Count; - size += dataSize; - size += 2 * repeatedFixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedSfixed32_.Count; - size += dataSize; - size += 2 * repeatedSfixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedSfixed64_.Count; - size += dataSize; - size += 2 * repeatedSfixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedFloat_.Count; - size += dataSize; - size += 2 * repeatedFloat_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedDouble_.Count; - size += dataSize; - size += 2 * repeatedDouble_.Count; - } - { - int dataSize = 0; - dataSize = 1 * repeatedBool_.Count; - size += dataSize; - size += 2 * repeatedBool_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedStringList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedString_.Count; - } - { - int dataSize = 0; - foreach (pb::ByteString element in RepeatedBytesList) { - dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedBytes_.Count; - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup element in RepeatedGroupList) { - size += pb::CodedOutputStream.ComputeGroupSize(46, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage element in RepeatedNestedMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(48, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedForeignMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(49, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.ImportMessage element in RepeatedImportMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(50, element); - } - { - int dataSize = 0; - if (repeatedNestedEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum element in repeatedNestedEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedNestedEnum_.Count; - } - } - { - int dataSize = 0; - if (repeatedForeignEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedForeignEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedForeignEnum_.Count; - } - } - { - int dataSize = 0; - if (repeatedImportEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ImportEnum element in repeatedImportEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedImportEnum_.Count; - } - } - { - int dataSize = 0; - foreach (string element in RepeatedStringPieceList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedStringPiece_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedCordList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedCord_.Count; - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage element in RepeatedLazyMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(57, element); - } - if (hasDefaultInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(61, DefaultInt32); - } - if (hasDefaultInt64) { - size += pb::CodedOutputStream.ComputeInt64Size(62, DefaultInt64); - } - if (hasDefaultUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(63, DefaultUint32); - } - if (hasDefaultUint64) { - size += pb::CodedOutputStream.ComputeUInt64Size(64, DefaultUint64); - } - if (hasDefaultSint32) { - size += pb::CodedOutputStream.ComputeSInt32Size(65, DefaultSint32); - } - if (hasDefaultSint64) { - size += pb::CodedOutputStream.ComputeSInt64Size(66, DefaultSint64); - } - if (hasDefaultFixed32) { - size += pb::CodedOutputStream.ComputeFixed32Size(67, DefaultFixed32); - } - if (hasDefaultFixed64) { - size += pb::CodedOutputStream.ComputeFixed64Size(68, DefaultFixed64); - } - if (hasDefaultSfixed32) { - size += pb::CodedOutputStream.ComputeSFixed32Size(69, DefaultSfixed32); - } - if (hasDefaultSfixed64) { - size += pb::CodedOutputStream.ComputeSFixed64Size(70, DefaultSfixed64); - } - if (hasDefaultFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(71, DefaultFloat); - } - if (hasDefaultDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(72, DefaultDouble); - } - if (hasDefaultBool) { - size += pb::CodedOutputStream.ComputeBoolSize(73, DefaultBool); - } - if (hasDefaultString) { - size += pb::CodedOutputStream.ComputeStringSize(74, DefaultString); - } - if (hasDefaultBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(75, DefaultBytes); - } - if (hasDefaultNestedEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(81, (int) DefaultNestedEnum); - } - if (hasDefaultForeignEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(82, (int) DefaultForeignEnum); - } - if (hasDefaultImportEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(83, (int) DefaultImportEnum); - } - if (hasDefaultStringPiece) { - size += pb::CodedOutputStream.ComputeStringSize(84, DefaultStringPiece); - } - if (hasDefaultCord) { - size += pb::CodedOutputStream.ComputeStringSize(85, DefaultCord); - } - if (hasOneofUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(111, OneofUint32); - } - if (hasOneofNestedMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(112, OneofNestedMessage); - } - if (hasOneofString) { - size += pb::CodedOutputStream.ComputeStringSize(113, OneofString); - } - if (hasOneofBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(114, OneofBytes); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestAllTypes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllTypes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllTypes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestAllTypes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestAllTypes MakeReadOnly() { - repeatedInt32_.MakeReadOnly(); - repeatedInt64_.MakeReadOnly(); - repeatedUint32_.MakeReadOnly(); - repeatedUint64_.MakeReadOnly(); - repeatedSint32_.MakeReadOnly(); - repeatedSint64_.MakeReadOnly(); - repeatedFixed32_.MakeReadOnly(); - repeatedFixed64_.MakeReadOnly(); - repeatedSfixed32_.MakeReadOnly(); - repeatedSfixed64_.MakeReadOnly(); - repeatedFloat_.MakeReadOnly(); - repeatedDouble_.MakeReadOnly(); - repeatedBool_.MakeReadOnly(); - repeatedString_.MakeReadOnly(); - repeatedBytes_.MakeReadOnly(); - repeatedGroup_.MakeReadOnly(); - repeatedNestedMessage_.MakeReadOnly(); - repeatedForeignMessage_.MakeReadOnly(); - repeatedImportMessage_.MakeReadOnly(); - repeatedNestedEnum_.MakeReadOnly(); - repeatedForeignEnum_.MakeReadOnly(); - repeatedImportEnum_.MakeReadOnly(); - repeatedStringPiece_.MakeReadOnly(); - repeatedCord_.MakeReadOnly(); - repeatedLazyMessage_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestAllTypes prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestAllTypes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestAllTypes result; - - private TestAllTypes PrepareBuilder() { - if (resultIsReadOnly) { - TestAllTypes original = result; - result = new TestAllTypes(); - resultIsReadOnly = false; - MergeFrom(original); + public const int OptionalNestedEnumFieldNumber = 21; + private bool hasOptionalNestedEnum; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; + public bool HasOptionalNestedEnum + { + get { return hasOptionalNestedEnum; } } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestAllTypes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum + { + get { return optionalNestedEnum_; } } - } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor; } - } + public const int OptionalForeignEnumFieldNumber = 22; + private bool hasOptionalForeignEnum; + private global::Google.ProtocolBuffers.TestProtos.ForeignEnum optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + public bool HasOptionalForeignEnum + { + get { return hasOptionalForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum + { + get { return optionalForeignEnum_; } + } - public override TestAllTypes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } + public const int OptionalImportEnumFieldNumber = 23; + private bool hasOptionalImportEnum; + private global::Google.ProtocolBuffers.TestProtos.ImportEnum optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_FOO; + public bool HasOptionalImportEnum + { + get { return hasOptionalImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum OptionalImportEnum + { + get { return optionalImportEnum_; } + } - public override TestAllTypes BuildPartial() { - if (resultIsReadOnly) { - return result; + public const int OptionalStringPieceFieldNumber = 24; + private bool hasOptionalStringPiece; + private string optionalStringPiece_ = ""; + public bool HasOptionalStringPiece + { + get { return hasOptionalStringPiece; } + } + public string OptionalStringPiece + { + get { return optionalStringPiece_; } } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestAllTypes) { - return MergeFrom((TestAllTypes) other); - } else { - base.MergeFrom(other); - return this; + public const int OptionalCordFieldNumber = 25; + private bool hasOptionalCord; + private string optionalCord_ = ""; + public bool HasOptionalCord + { + get { return hasOptionalCord; } + } + public string OptionalCord + { + get { return optionalCord_; } } - } - public override Builder MergeFrom(TestAllTypes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasOptionalInt32) { - OptionalInt32 = other.OptionalInt32; + public const int OptionalPublicImportMessageFieldNumber = 26; + private bool hasOptionalPublicImportMessage; + private global::Google.ProtocolBuffers.TestProtos.PublicImportMessage optionalPublicImportMessage_; + public bool HasOptionalPublicImportMessage + { + get { return hasOptionalPublicImportMessage; } } - if (other.HasOptionalInt64) { - OptionalInt64 = other.OptionalInt64; + public global::Google.ProtocolBuffers.TestProtos.PublicImportMessage OptionalPublicImportMessage + { + get { return optionalPublicImportMessage_ ?? global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.DefaultInstance; } } - if (other.HasOptionalUint32) { - OptionalUint32 = other.OptionalUint32; + + public const int OptionalLazyMessageFieldNumber = 27; + private bool hasOptionalLazyMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage optionalLazyMessage_; + public bool HasOptionalLazyMessage + { + get { return hasOptionalLazyMessage; } } - if (other.HasOptionalUint64) { - OptionalUint64 = other.OptionalUint64; + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalLazyMessage + { + get { return optionalLazyMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } } - if (other.HasOptionalSint32) { - OptionalSint32 = other.OptionalSint32; + + public const int RepeatedInt32FieldNumber = 31; + private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); + public scg::IList RepeatedInt32List + { + get { return pbc::Lists.AsReadOnly(repeatedInt32_); } } - if (other.HasOptionalSint64) { - OptionalSint64 = other.OptionalSint64; + public int RepeatedInt32Count + { + get { return repeatedInt32_.Count; } } - if (other.HasOptionalFixed32) { - OptionalFixed32 = other.OptionalFixed32; + public int GetRepeatedInt32(int index) + { + return repeatedInt32_[index]; } - if (other.HasOptionalFixed64) { - OptionalFixed64 = other.OptionalFixed64; + + public const int RepeatedInt64FieldNumber = 32; + private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); + public scg::IList RepeatedInt64List + { + get { return pbc::Lists.AsReadOnly(repeatedInt64_); } } - if (other.HasOptionalSfixed32) { - OptionalSfixed32 = other.OptionalSfixed32; + public int RepeatedInt64Count + { + get { return repeatedInt64_.Count; } } - if (other.HasOptionalSfixed64) { - OptionalSfixed64 = other.OptionalSfixed64; + public long GetRepeatedInt64(int index) + { + return repeatedInt64_[index]; } - if (other.HasOptionalFloat) { - OptionalFloat = other.OptionalFloat; + + public const int RepeatedUint32FieldNumber = 33; + private pbc::PopsicleList repeatedUint32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedUint32List + { + get { return pbc::Lists.AsReadOnly(repeatedUint32_); } } - if (other.HasOptionalDouble) { - OptionalDouble = other.OptionalDouble; + public int RepeatedUint32Count + { + get { return repeatedUint32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedUint32(int index) + { + return repeatedUint32_[index]; } - if (other.HasOptionalBool) { - OptionalBool = other.OptionalBool; + + public const int RepeatedUint64FieldNumber = 34; + private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedUint64List + { + get { return pbc::Lists.AsReadOnly(repeatedUint64_); } } - if (other.HasOptionalString) { - OptionalString = other.OptionalString; + public int RepeatedUint64Count + { + get { return repeatedUint64_.Count; } } - if (other.HasOptionalBytes) { - OptionalBytes = other.OptionalBytes; + [global::System.CLSCompliant(false)] + public ulong GetRepeatedUint64(int index) + { + return repeatedUint64_[index]; } - if (other.HasOptionalGroup) { - MergeOptionalGroup(other.OptionalGroup); + + public const int RepeatedSint32FieldNumber = 35; + private pbc::PopsicleList repeatedSint32_ = new pbc::PopsicleList(); + public scg::IList RepeatedSint32List + { + get { return pbc::Lists.AsReadOnly(repeatedSint32_); } } - if (other.HasOptionalNestedMessage) { - MergeOptionalNestedMessage(other.OptionalNestedMessage); + public int RepeatedSint32Count + { + get { return repeatedSint32_.Count; } } - if (other.HasOptionalForeignMessage) { - MergeOptionalForeignMessage(other.OptionalForeignMessage); + public int GetRepeatedSint32(int index) + { + return repeatedSint32_[index]; } - if (other.HasOptionalImportMessage) { - MergeOptionalImportMessage(other.OptionalImportMessage); + + public const int RepeatedSint64FieldNumber = 36; + private pbc::PopsicleList repeatedSint64_ = new pbc::PopsicleList(); + public scg::IList RepeatedSint64List + { + get { return pbc::Lists.AsReadOnly(repeatedSint64_); } } - if (other.HasOptionalNestedEnum) { - OptionalNestedEnum = other.OptionalNestedEnum; + public int RepeatedSint64Count + { + get { return repeatedSint64_.Count; } } - if (other.HasOptionalForeignEnum) { - OptionalForeignEnum = other.OptionalForeignEnum; + public long GetRepeatedSint64(int index) + { + return repeatedSint64_[index]; } - if (other.HasOptionalImportEnum) { - OptionalImportEnum = other.OptionalImportEnum; + + public const int RepeatedFixed32FieldNumber = 37; + private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedFixed32List + { + get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } } - if (other.HasOptionalStringPiece) { - OptionalStringPiece = other.OptionalStringPiece; + public int RepeatedFixed32Count + { + get { return repeatedFixed32_.Count; } } - if (other.HasOptionalCord) { - OptionalCord = other.OptionalCord; + [global::System.CLSCompliant(false)] + public uint GetRepeatedFixed32(int index) + { + return repeatedFixed32_[index]; } - if (other.HasOptionalPublicImportMessage) { - MergeOptionalPublicImportMessage(other.OptionalPublicImportMessage); + + public const int RepeatedFixed64FieldNumber = 38; + private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedFixed64List + { + get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } } - if (other.HasOptionalLazyMessage) { - MergeOptionalLazyMessage(other.OptionalLazyMessage); + public int RepeatedFixed64Count + { + get { return repeatedFixed64_.Count; } } - if (other.repeatedInt32_.Count != 0) { - result.repeatedInt32_.Add(other.repeatedInt32_); + [global::System.CLSCompliant(false)] + public ulong GetRepeatedFixed64(int index) + { + return repeatedFixed64_[index]; } - if (other.repeatedInt64_.Count != 0) { - result.repeatedInt64_.Add(other.repeatedInt64_); + + public const int RepeatedSfixed32FieldNumber = 39; + private pbc::PopsicleList repeatedSfixed32_ = new pbc::PopsicleList(); + public scg::IList RepeatedSfixed32List + { + get { return pbc::Lists.AsReadOnly(repeatedSfixed32_); } } - if (other.repeatedUint32_.Count != 0) { - result.repeatedUint32_.Add(other.repeatedUint32_); + public int RepeatedSfixed32Count + { + get { return repeatedSfixed32_.Count; } } - if (other.repeatedUint64_.Count != 0) { - result.repeatedUint64_.Add(other.repeatedUint64_); + public int GetRepeatedSfixed32(int index) + { + return repeatedSfixed32_[index]; } - if (other.repeatedSint32_.Count != 0) { - result.repeatedSint32_.Add(other.repeatedSint32_); + + public const int RepeatedSfixed64FieldNumber = 40; + private pbc::PopsicleList repeatedSfixed64_ = new pbc::PopsicleList(); + public scg::IList RepeatedSfixed64List + { + get { return pbc::Lists.AsReadOnly(repeatedSfixed64_); } } - if (other.repeatedSint64_.Count != 0) { - result.repeatedSint64_.Add(other.repeatedSint64_); + public int RepeatedSfixed64Count + { + get { return repeatedSfixed64_.Count; } } - if (other.repeatedFixed32_.Count != 0) { - result.repeatedFixed32_.Add(other.repeatedFixed32_); + public long GetRepeatedSfixed64(int index) + { + return repeatedSfixed64_[index]; } - if (other.repeatedFixed64_.Count != 0) { - result.repeatedFixed64_.Add(other.repeatedFixed64_); + + public const int RepeatedFloatFieldNumber = 41; + private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); + public scg::IList RepeatedFloatList + { + get { return pbc::Lists.AsReadOnly(repeatedFloat_); } } - if (other.repeatedSfixed32_.Count != 0) { - result.repeatedSfixed32_.Add(other.repeatedSfixed32_); + public int RepeatedFloatCount + { + get { return repeatedFloat_.Count; } } - if (other.repeatedSfixed64_.Count != 0) { - result.repeatedSfixed64_.Add(other.repeatedSfixed64_); + public float GetRepeatedFloat(int index) + { + return repeatedFloat_[index]; } - if (other.repeatedFloat_.Count != 0) { - result.repeatedFloat_.Add(other.repeatedFloat_); + + public const int RepeatedDoubleFieldNumber = 42; + private pbc::PopsicleList repeatedDouble_ = new pbc::PopsicleList(); + public scg::IList RepeatedDoubleList + { + get { return pbc::Lists.AsReadOnly(repeatedDouble_); } } - if (other.repeatedDouble_.Count != 0) { - result.repeatedDouble_.Add(other.repeatedDouble_); + public int RepeatedDoubleCount + { + get { return repeatedDouble_.Count; } } - if (other.repeatedBool_.Count != 0) { - result.repeatedBool_.Add(other.repeatedBool_); + public double GetRepeatedDouble(int index) + { + return repeatedDouble_[index]; } - if (other.repeatedString_.Count != 0) { - result.repeatedString_.Add(other.repeatedString_); + + public const int RepeatedBoolFieldNumber = 43; + private pbc::PopsicleList repeatedBool_ = new pbc::PopsicleList(); + public scg::IList RepeatedBoolList + { + get { return pbc::Lists.AsReadOnly(repeatedBool_); } } - if (other.repeatedBytes_.Count != 0) { - result.repeatedBytes_.Add(other.repeatedBytes_); + public int RepeatedBoolCount + { + get { return repeatedBool_.Count; } } - if (other.repeatedGroup_.Count != 0) { - result.repeatedGroup_.Add(other.repeatedGroup_); + public bool GetRepeatedBool(int index) + { + return repeatedBool_[index]; } - if (other.repeatedNestedMessage_.Count != 0) { - result.repeatedNestedMessage_.Add(other.repeatedNestedMessage_); + + public const int RepeatedStringFieldNumber = 44; + private pbc::PopsicleList repeatedString_ = new pbc::PopsicleList(); + public scg::IList RepeatedStringList + { + get { return pbc::Lists.AsReadOnly(repeatedString_); } } - if (other.repeatedForeignMessage_.Count != 0) { - result.repeatedForeignMessage_.Add(other.repeatedForeignMessage_); + public int RepeatedStringCount + { + get { return repeatedString_.Count; } } - if (other.repeatedImportMessage_.Count != 0) { - result.repeatedImportMessage_.Add(other.repeatedImportMessage_); + public string GetRepeatedString(int index) + { + return repeatedString_[index]; } - if (other.repeatedNestedEnum_.Count != 0) { - result.repeatedNestedEnum_.Add(other.repeatedNestedEnum_); + + public const int RepeatedBytesFieldNumber = 45; + private pbc::PopsicleList repeatedBytes_ = new pbc::PopsicleList(); + public scg::IList RepeatedBytesList + { + get { return pbc::Lists.AsReadOnly(repeatedBytes_); } } - if (other.repeatedForeignEnum_.Count != 0) { - result.repeatedForeignEnum_.Add(other.repeatedForeignEnum_); + public int RepeatedBytesCount + { + get { return repeatedBytes_.Count; } } - if (other.repeatedImportEnum_.Count != 0) { - result.repeatedImportEnum_.Add(other.repeatedImportEnum_); + public pb::ByteString GetRepeatedBytes(int index) + { + return repeatedBytes_[index]; } - if (other.repeatedStringPiece_.Count != 0) { - result.repeatedStringPiece_.Add(other.repeatedStringPiece_); + + public const int RepeatedGroupFieldNumber = 46; + private pbc::PopsicleList repeatedGroup_ = new pbc::PopsicleList(); + public scg::IList RepeatedGroupList + { + get { return repeatedGroup_; } } - if (other.repeatedCord_.Count != 0) { - result.repeatedCord_.Add(other.repeatedCord_); + public int RepeatedGroupCount + { + get { return repeatedGroup_.Count; } } - if (other.repeatedLazyMessage_.Count != 0) { - result.repeatedLazyMessage_.Add(other.repeatedLazyMessage_); + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup GetRepeatedGroup(int index) + { + return repeatedGroup_[index]; } - if (other.HasDefaultInt32) { - DefaultInt32 = other.DefaultInt32; + + public const int RepeatedNestedMessageFieldNumber = 48; + private pbc::PopsicleList repeatedNestedMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedNestedMessageList + { + get { return repeatedNestedMessage_; } } - if (other.HasDefaultInt64) { - DefaultInt64 = other.DefaultInt64; + public int RepeatedNestedMessageCount + { + get { return repeatedNestedMessage_.Count; } } - if (other.HasDefaultUint32) { - DefaultUint32 = other.DefaultUint32; + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) + { + return repeatedNestedMessage_[index]; } - if (other.HasDefaultUint64) { - DefaultUint64 = other.DefaultUint64; + + public const int RepeatedForeignMessageFieldNumber = 49; + private pbc::PopsicleList repeatedForeignMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedForeignMessageList + { + get { return repeatedForeignMessage_; } } - if (other.HasDefaultSint32) { - DefaultSint32 = other.DefaultSint32; + public int RepeatedForeignMessageCount + { + get { return repeatedForeignMessage_.Count; } } - if (other.HasDefaultSint64) { - DefaultSint64 = other.DefaultSint64; + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) + { + return repeatedForeignMessage_[index]; } - if (other.HasDefaultFixed32) { - DefaultFixed32 = other.DefaultFixed32; + + public const int RepeatedImportMessageFieldNumber = 50; + private pbc::PopsicleList repeatedImportMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedImportMessageList + { + get { return repeatedImportMessage_; } } - if (other.HasDefaultFixed64) { - DefaultFixed64 = other.DefaultFixed64; + public int RepeatedImportMessageCount + { + get { return repeatedImportMessage_.Count; } } - if (other.HasDefaultSfixed32) { - DefaultSfixed32 = other.DefaultSfixed32; + public global::Google.ProtocolBuffers.TestProtos.ImportMessage GetRepeatedImportMessage(int index) + { + return repeatedImportMessage_[index]; } - if (other.HasDefaultSfixed64) { - DefaultSfixed64 = other.DefaultSfixed64; + + public const int RepeatedNestedEnumFieldNumber = 51; + private pbc::PopsicleList repeatedNestedEnum_ = new pbc::PopsicleList(); + public scg::IList RepeatedNestedEnumList + { + get { return pbc::Lists.AsReadOnly(repeatedNestedEnum_); } } - if (other.HasDefaultFloat) { - DefaultFloat = other.DefaultFloat; + public int RepeatedNestedEnumCount + { + get { return repeatedNestedEnum_.Count; } } - if (other.HasDefaultDouble) { - DefaultDouble = other.DefaultDouble; + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) + { + return repeatedNestedEnum_[index]; } - if (other.HasDefaultBool) { - DefaultBool = other.DefaultBool; + + public const int RepeatedForeignEnumFieldNumber = 52; + private pbc::PopsicleList repeatedForeignEnum_ = new pbc::PopsicleList(); + public scg::IList RepeatedForeignEnumList + { + get { return pbc::Lists.AsReadOnly(repeatedForeignEnum_); } } - if (other.HasDefaultString) { - DefaultString = other.DefaultString; + public int RepeatedForeignEnumCount + { + get { return repeatedForeignEnum_.Count; } } - if (other.HasDefaultBytes) { - DefaultBytes = other.DefaultBytes; + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) + { + return repeatedForeignEnum_[index]; } - if (other.HasDefaultNestedEnum) { - DefaultNestedEnum = other.DefaultNestedEnum; + + public const int RepeatedImportEnumFieldNumber = 53; + private pbc::PopsicleList repeatedImportEnum_ = new pbc::PopsicleList(); + public scg::IList RepeatedImportEnumList + { + get { return pbc::Lists.AsReadOnly(repeatedImportEnum_); } } - if (other.HasDefaultForeignEnum) { - DefaultForeignEnum = other.DefaultForeignEnum; + public int RepeatedImportEnumCount + { + get { return repeatedImportEnum_.Count; } } - if (other.HasDefaultImportEnum) { - DefaultImportEnum = other.DefaultImportEnum; + public global::Google.ProtocolBuffers.TestProtos.ImportEnum GetRepeatedImportEnum(int index) + { + return repeatedImportEnum_[index]; } - if (other.HasDefaultStringPiece) { - DefaultStringPiece = other.DefaultStringPiece; + + public const int RepeatedStringPieceFieldNumber = 54; + private pbc::PopsicleList repeatedStringPiece_ = new pbc::PopsicleList(); + public scg::IList RepeatedStringPieceList + { + get { return pbc::Lists.AsReadOnly(repeatedStringPiece_); } } - if (other.HasDefaultCord) { - DefaultCord = other.DefaultCord; + public int RepeatedStringPieceCount + { + get { return repeatedStringPiece_.Count; } } - if (other.HasOneofUint32) { - OneofUint32 = other.OneofUint32; + public string GetRepeatedStringPiece(int index) + { + return repeatedStringPiece_[index]; } - if (other.HasOneofNestedMessage) { - MergeOneofNestedMessage(other.OneofNestedMessage); + + public const int RepeatedCordFieldNumber = 55; + private pbc::PopsicleList repeatedCord_ = new pbc::PopsicleList(); + public scg::IList RepeatedCordList + { + get { return pbc::Lists.AsReadOnly(repeatedCord_); } } - if (other.HasOneofString) { - OneofString = other.OneofString; + public int RepeatedCordCount + { + get { return repeatedCord_.Count; } } - if (other.HasOneofBytes) { - OneofBytes = other.OneofBytes; + public string GetRepeatedCord(int index) + { + return repeatedCord_[index]; } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testAllTypesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testAllTypesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); - break; - } - case 16: { - result.hasOptionalInt64 = input.ReadInt64(ref result.optionalInt64_); - break; - } - case 24: { - result.hasOptionalUint32 = input.ReadUInt32(ref result.optionalUint32_); - break; - } - case 32: { - result.hasOptionalUint64 = input.ReadUInt64(ref result.optionalUint64_); - break; - } - case 40: { - result.hasOptionalSint32 = input.ReadSInt32(ref result.optionalSint32_); - break; - } - case 48: { - result.hasOptionalSint64 = input.ReadSInt64(ref result.optionalSint64_); - break; - } - case 61: { - result.hasOptionalFixed32 = input.ReadFixed32(ref result.optionalFixed32_); - break; - } - case 65: { - result.hasOptionalFixed64 = input.ReadFixed64(ref result.optionalFixed64_); - break; - } - case 77: { - result.hasOptionalSfixed32 = input.ReadSFixed32(ref result.optionalSfixed32_); - break; - } - case 81: { - result.hasOptionalSfixed64 = input.ReadSFixed64(ref result.optionalSfixed64_); - break; - } - case 93: { - result.hasOptionalFloat = input.ReadFloat(ref result.optionalFloat_); - break; - } - case 97: { - result.hasOptionalDouble = input.ReadDouble(ref result.optionalDouble_); - break; - } - case 104: { - result.hasOptionalBool = input.ReadBool(ref result.optionalBool_); - break; - } - case 114: { - result.hasOptionalString = input.ReadString(ref result.optionalString_); - break; - } - case 122: { - result.hasOptionalBytes = input.ReadBytes(ref result.optionalBytes_); - break; - } - case 131: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.CreateBuilder(); - if (result.hasOptionalGroup) { - subBuilder.MergeFrom(OptionalGroup); - } - input.ReadGroup(16, subBuilder, extensionRegistry); - OptionalGroup = subBuilder.BuildPartial(); - break; - } - case 146: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); - if (result.hasOptionalNestedMessage) { - subBuilder.MergeFrom(OptionalNestedMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalNestedMessage = subBuilder.BuildPartial(); - break; - } - case 154: { - global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); - if (result.hasOptionalForeignMessage) { - subBuilder.MergeFrom(OptionalForeignMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalForeignMessage = subBuilder.BuildPartial(); - break; - } - case 162: { - global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder(); - if (result.hasOptionalImportMessage) { - subBuilder.MergeFrom(OptionalImportMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalImportMessage = subBuilder.BuildPartial(); - break; - } - case 168: { - object unknown; - if(input.ReadEnum(ref result.optionalNestedEnum_, out unknown)) { - result.hasOptionalNestedEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(21, (ulong)(int)unknown); - } - break; - } - case 176: { - object unknown; - if(input.ReadEnum(ref result.optionalForeignEnum_, out unknown)) { - result.hasOptionalForeignEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(22, (ulong)(int)unknown); - } - break; - } - case 184: { - object unknown; - if(input.ReadEnum(ref result.optionalImportEnum_, out unknown)) { - result.hasOptionalImportEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(23, (ulong)(int)unknown); - } - break; - } - case 194: { - result.hasOptionalStringPiece = input.ReadString(ref result.optionalStringPiece_); - break; - } - case 202: { - result.hasOptionalCord = input.ReadString(ref result.optionalCord_); - break; - } - case 210: { - global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.CreateBuilder(); - if (result.hasOptionalPublicImportMessage) { - subBuilder.MergeFrom(OptionalPublicImportMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalPublicImportMessage = subBuilder.BuildPartial(); - break; - } - case 218: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); - if (result.hasOptionalLazyMessage) { - subBuilder.MergeFrom(OptionalLazyMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalLazyMessage = subBuilder.BuildPartial(); - break; - } - case 250: - case 248: { - input.ReadInt32Array(tag, field_name, result.repeatedInt32_); - break; - } - case 258: - case 256: { - input.ReadInt64Array(tag, field_name, result.repeatedInt64_); - break; - } - case 266: - case 264: { - input.ReadUInt32Array(tag, field_name, result.repeatedUint32_); - break; - } - case 274: - case 272: { - input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); - break; - } - case 282: - case 280: { - input.ReadSInt32Array(tag, field_name, result.repeatedSint32_); - break; - } - case 290: - case 288: { - input.ReadSInt64Array(tag, field_name, result.repeatedSint64_); - break; - } - case 298: - case 301: { - input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); - break; - } - case 306: - case 305: { - input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); - break; - } - case 314: - case 317: { - input.ReadSFixed32Array(tag, field_name, result.repeatedSfixed32_); - break; - } - case 322: - case 321: { - input.ReadSFixed64Array(tag, field_name, result.repeatedSfixed64_); - break; - } - case 330: - case 333: { - input.ReadFloatArray(tag, field_name, result.repeatedFloat_); - break; - } - case 338: - case 337: { - input.ReadDoubleArray(tag, field_name, result.repeatedDouble_); - break; - } - case 346: - case 344: { - input.ReadBoolArray(tag, field_name, result.repeatedBool_); - break; - } - case 354: { - input.ReadStringArray(tag, field_name, result.repeatedString_); - break; - } - case 362: { - input.ReadBytesArray(tag, field_name, result.repeatedBytes_); - break; - } - case 371: { - input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance, extensionRegistry); - break; - } - case 386: { - input.ReadMessageArray(tag, field_name, result.repeatedNestedMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance, extensionRegistry); - break; - } - case 394: { - input.ReadMessageArray(tag, field_name, result.repeatedForeignMessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); - break; - } - case 402: { - input.ReadMessageArray(tag, field_name, result.repeatedImportMessage_, global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance, extensionRegistry); - break; - } - case 410: - case 408: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedNestedEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(51, (ulong)(int)rawValue); - } - break; - } - case 418: - case 416: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedForeignEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(52, (ulong)(int)rawValue); - } - break; - } - case 426: - case 424: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedImportEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(53, (ulong)(int)rawValue); - } - break; - } - case 434: { - input.ReadStringArray(tag, field_name, result.repeatedStringPiece_); - break; - } - case 442: { - input.ReadStringArray(tag, field_name, result.repeatedCord_); - break; - } - case 458: { - input.ReadMessageArray(tag, field_name, result.repeatedLazyMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance, extensionRegistry); - break; - } - case 488: { - result.hasDefaultInt32 = input.ReadInt32(ref result.defaultInt32_); - break; - } - case 496: { - result.hasDefaultInt64 = input.ReadInt64(ref result.defaultInt64_); - break; - } - case 504: { - result.hasDefaultUint32 = input.ReadUInt32(ref result.defaultUint32_); - break; - } - case 512: { - result.hasDefaultUint64 = input.ReadUInt64(ref result.defaultUint64_); - break; - } - case 520: { - result.hasDefaultSint32 = input.ReadSInt32(ref result.defaultSint32_); - break; - } - case 528: { - result.hasDefaultSint64 = input.ReadSInt64(ref result.defaultSint64_); - break; - } - case 541: { - result.hasDefaultFixed32 = input.ReadFixed32(ref result.defaultFixed32_); - break; - } - case 545: { - result.hasDefaultFixed64 = input.ReadFixed64(ref result.defaultFixed64_); - break; - } - case 557: { - result.hasDefaultSfixed32 = input.ReadSFixed32(ref result.defaultSfixed32_); - break; - } - case 561: { - result.hasDefaultSfixed64 = input.ReadSFixed64(ref result.defaultSfixed64_); - break; - } - case 573: { - result.hasDefaultFloat = input.ReadFloat(ref result.defaultFloat_); - break; - } - case 577: { - result.hasDefaultDouble = input.ReadDouble(ref result.defaultDouble_); - break; - } - case 584: { - result.hasDefaultBool = input.ReadBool(ref result.defaultBool_); - break; - } - case 594: { - result.hasDefaultString = input.ReadString(ref result.defaultString_); - break; - } - case 602: { - result.hasDefaultBytes = input.ReadBytes(ref result.defaultBytes_); - break; - } - case 648: { - object unknown; - if(input.ReadEnum(ref result.defaultNestedEnum_, out unknown)) { - result.hasDefaultNestedEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(81, (ulong)(int)unknown); - } - break; - } - case 656: { - object unknown; - if(input.ReadEnum(ref result.defaultForeignEnum_, out unknown)) { - result.hasDefaultForeignEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(82, (ulong)(int)unknown); - } - break; - } - case 664: { - object unknown; - if(input.ReadEnum(ref result.defaultImportEnum_, out unknown)) { - result.hasDefaultImportEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(83, (ulong)(int)unknown); - } - break; - } - case 674: { - result.hasDefaultStringPiece = input.ReadString(ref result.defaultStringPiece_); - break; - } - case 682: { - result.hasDefaultCord = input.ReadString(ref result.defaultCord_); - break; - } - case 888: { - result.hasOneofUint32 = input.ReadUInt32(ref result.oneofUint32_); - break; - } - case 898: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); - if (result.hasOneofNestedMessage) { - subBuilder.MergeFrom(OneofNestedMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OneofNestedMessage = subBuilder.BuildPartial(); - break; - } - case 906: { - result.hasOneofString = input.ReadString(ref result.oneofString_); - break; - } - case 914: { - result.hasOneofBytes = input.ReadBytes(ref result.oneofBytes_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasOptionalInt32 { - get { return result.hasOptionalInt32; } - } - public int OptionalInt32 { - get { return result.OptionalInt32; } - set { SetOptionalInt32(value); } - } - public Builder SetOptionalInt32(int value) { - PrepareBuilder(); - result.hasOptionalInt32 = true; - result.optionalInt32_ = value; - return this; - } - public Builder ClearOptionalInt32() { - PrepareBuilder(); - result.hasOptionalInt32 = false; - result.optionalInt32_ = 0; - return this; - } - - public bool HasOptionalInt64 { - get { return result.hasOptionalInt64; } - } - public long OptionalInt64 { - get { return result.OptionalInt64; } - set { SetOptionalInt64(value); } - } - public Builder SetOptionalInt64(long value) { - PrepareBuilder(); - result.hasOptionalInt64 = true; - result.optionalInt64_ = value; - return this; - } - public Builder ClearOptionalInt64() { - PrepareBuilder(); - result.hasOptionalInt64 = false; - result.optionalInt64_ = 0L; - return this; - } - - public bool HasOptionalUint32 { - get { return result.hasOptionalUint32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalUint32 { - get { return result.OptionalUint32; } - set { SetOptionalUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalUint32(uint value) { - PrepareBuilder(); - result.hasOptionalUint32 = true; - result.optionalUint32_ = value; - return this; - } - public Builder ClearOptionalUint32() { - PrepareBuilder(); - result.hasOptionalUint32 = false; - result.optionalUint32_ = 0; - return this; - } - - public bool HasOptionalUint64 { - get { return result.hasOptionalUint64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalUint64 { - get { return result.OptionalUint64; } - set { SetOptionalUint64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalUint64(ulong value) { - PrepareBuilder(); - result.hasOptionalUint64 = true; - result.optionalUint64_ = value; - return this; - } - public Builder ClearOptionalUint64() { - PrepareBuilder(); - result.hasOptionalUint64 = false; - result.optionalUint64_ = 0UL; - return this; - } - - public bool HasOptionalSint32 { - get { return result.hasOptionalSint32; } - } - public int OptionalSint32 { - get { return result.OptionalSint32; } - set { SetOptionalSint32(value); } - } - public Builder SetOptionalSint32(int value) { - PrepareBuilder(); - result.hasOptionalSint32 = true; - result.optionalSint32_ = value; - return this; - } - public Builder ClearOptionalSint32() { - PrepareBuilder(); - result.hasOptionalSint32 = false; - result.optionalSint32_ = 0; - return this; - } - - public bool HasOptionalSint64 { - get { return result.hasOptionalSint64; } - } - public long OptionalSint64 { - get { return result.OptionalSint64; } - set { SetOptionalSint64(value); } - } - public Builder SetOptionalSint64(long value) { - PrepareBuilder(); - result.hasOptionalSint64 = true; - result.optionalSint64_ = value; - return this; - } - public Builder ClearOptionalSint64() { - PrepareBuilder(); - result.hasOptionalSint64 = false; - result.optionalSint64_ = 0L; - return this; - } - - public bool HasOptionalFixed32 { - get { return result.hasOptionalFixed32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalFixed32 { - get { return result.OptionalFixed32; } - set { SetOptionalFixed32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalFixed32(uint value) { - PrepareBuilder(); - result.hasOptionalFixed32 = true; - result.optionalFixed32_ = value; - return this; - } - public Builder ClearOptionalFixed32() { - PrepareBuilder(); - result.hasOptionalFixed32 = false; - result.optionalFixed32_ = 0; - return this; - } - - public bool HasOptionalFixed64 { - get { return result.hasOptionalFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalFixed64 { - get { return result.OptionalFixed64; } - set { SetOptionalFixed64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalFixed64(ulong value) { - PrepareBuilder(); - result.hasOptionalFixed64 = true; - result.optionalFixed64_ = value; - return this; - } - public Builder ClearOptionalFixed64() { - PrepareBuilder(); - result.hasOptionalFixed64 = false; - result.optionalFixed64_ = 0UL; - return this; - } - - public bool HasOptionalSfixed32 { - get { return result.hasOptionalSfixed32; } - } - public int OptionalSfixed32 { - get { return result.OptionalSfixed32; } - set { SetOptionalSfixed32(value); } - } - public Builder SetOptionalSfixed32(int value) { - PrepareBuilder(); - result.hasOptionalSfixed32 = true; - result.optionalSfixed32_ = value; - return this; - } - public Builder ClearOptionalSfixed32() { - PrepareBuilder(); - result.hasOptionalSfixed32 = false; - result.optionalSfixed32_ = 0; - return this; - } - - public bool HasOptionalSfixed64 { - get { return result.hasOptionalSfixed64; } - } - public long OptionalSfixed64 { - get { return result.OptionalSfixed64; } - set { SetOptionalSfixed64(value); } - } - public Builder SetOptionalSfixed64(long value) { - PrepareBuilder(); - result.hasOptionalSfixed64 = true; - result.optionalSfixed64_ = value; - return this; - } - public Builder ClearOptionalSfixed64() { - PrepareBuilder(); - result.hasOptionalSfixed64 = false; - result.optionalSfixed64_ = 0L; - return this; - } - - public bool HasOptionalFloat { - get { return result.hasOptionalFloat; } - } - public float OptionalFloat { - get { return result.OptionalFloat; } - set { SetOptionalFloat(value); } - } - public Builder SetOptionalFloat(float value) { - PrepareBuilder(); - result.hasOptionalFloat = true; - result.optionalFloat_ = value; - return this; - } - public Builder ClearOptionalFloat() { - PrepareBuilder(); - result.hasOptionalFloat = false; - result.optionalFloat_ = 0F; - return this; - } - - public bool HasOptionalDouble { - get { return result.hasOptionalDouble; } - } - public double OptionalDouble { - get { return result.OptionalDouble; } - set { SetOptionalDouble(value); } - } - public Builder SetOptionalDouble(double value) { - PrepareBuilder(); - result.hasOptionalDouble = true; - result.optionalDouble_ = value; - return this; - } - public Builder ClearOptionalDouble() { - PrepareBuilder(); - result.hasOptionalDouble = false; - result.optionalDouble_ = 0D; - return this; - } - - public bool HasOptionalBool { - get { return result.hasOptionalBool; } - } - public bool OptionalBool { - get { return result.OptionalBool; } - set { SetOptionalBool(value); } - } - public Builder SetOptionalBool(bool value) { - PrepareBuilder(); - result.hasOptionalBool = true; - result.optionalBool_ = value; - return this; - } - public Builder ClearOptionalBool() { - PrepareBuilder(); - result.hasOptionalBool = false; - result.optionalBool_ = false; - return this; - } - - public bool HasOptionalString { - get { return result.hasOptionalString; } - } - public string OptionalString { - get { return result.OptionalString; } - set { SetOptionalString(value); } - } - public Builder SetOptionalString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalString = true; - result.optionalString_ = value; - return this; - } - public Builder ClearOptionalString() { - PrepareBuilder(); - result.hasOptionalString = false; - result.optionalString_ = ""; - return this; - } - - public bool HasOptionalBytes { - get { return result.hasOptionalBytes; } - } - public pb::ByteString OptionalBytes { - get { return result.OptionalBytes; } - set { SetOptionalBytes(value); } - } - public Builder SetOptionalBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalBytes = true; - result.optionalBytes_ = value; - return this; - } - public Builder ClearOptionalBytes() { - PrepareBuilder(); - result.hasOptionalBytes = false; - result.optionalBytes_ = pb::ByteString.Empty; - return this; - } - - public bool HasOptionalGroup { - get { return result.hasOptionalGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup OptionalGroup { - get { return result.OptionalGroup; } - set { SetOptionalGroup(value); } - } - public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalGroup = true; - result.optionalGroup_ = value; - return this; - } - public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalGroup = true; - result.optionalGroup_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalGroup && - result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance) { - result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial(); - } else { - result.optionalGroup_ = value; - } - result.hasOptionalGroup = true; - return this; - } - public Builder ClearOptionalGroup() { - PrepareBuilder(); - result.hasOptionalGroup = false; - result.optionalGroup_ = null; - return this; - } - - public bool HasOptionalNestedMessage { - get { return result.hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage { - get { return result.OptionalNestedMessage; } - set { SetOptionalNestedMessage(value); } - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = value; - return this; - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalNestedMessage && - result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { - result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalNestedMessage_ = value; - } - result.hasOptionalNestedMessage = true; - return this; - } - public Builder ClearOptionalNestedMessage() { - PrepareBuilder(); - result.hasOptionalNestedMessage = false; - result.optionalNestedMessage_ = null; - return this; - } - - public bool HasOptionalForeignMessage { - get { return result.hasOptionalForeignMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage { - get { return result.OptionalForeignMessage; } - set { SetOptionalForeignMessage(value); } - } - public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalForeignMessage = true; - result.optionalForeignMessage_ = value; - return this; - } - public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalForeignMessage = true; - result.optionalForeignMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalForeignMessage && - result.optionalForeignMessage_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) { - result.optionalForeignMessage_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.optionalForeignMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalForeignMessage_ = value; - } - result.hasOptionalForeignMessage = true; - return this; - } - public Builder ClearOptionalForeignMessage() { - PrepareBuilder(); - result.hasOptionalForeignMessage = false; - result.optionalForeignMessage_ = null; - return this; - } - - public bool HasOptionalImportMessage { - get { return result.hasOptionalImportMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessage OptionalImportMessage { - get { return result.OptionalImportMessage; } - set { SetOptionalImportMessage(value); } - } - public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalImportMessage = true; - result.optionalImportMessage_ = value; - return this; - } - public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalImportMessage = true; - result.optionalImportMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalImportMessage && - result.optionalImportMessage_ != global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance) { - result.optionalImportMessage_ = global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder(result.optionalImportMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalImportMessage_ = value; - } - result.hasOptionalImportMessage = true; - return this; - } - public Builder ClearOptionalImportMessage() { - PrepareBuilder(); - result.hasOptionalImportMessage = false; - result.optionalImportMessage_ = null; - return this; - } - - public bool HasOptionalNestedEnum { - get { return result.hasOptionalNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum { - get { return result.OptionalNestedEnum; } - set { SetOptionalNestedEnum(value); } - } - public Builder SetOptionalNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.hasOptionalNestedEnum = true; - result.optionalNestedEnum_ = value; - return this; - } - public Builder ClearOptionalNestedEnum() { - PrepareBuilder(); - result.hasOptionalNestedEnum = false; - result.optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; - return this; - } - - public bool HasOptionalForeignEnum { - get { return result.hasOptionalForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum { - get { return result.OptionalForeignEnum; } - set { SetOptionalForeignEnum(value); } - } - public Builder SetOptionalForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.hasOptionalForeignEnum = true; - result.optionalForeignEnum_ = value; - return this; - } - public Builder ClearOptionalForeignEnum() { - PrepareBuilder(); - result.hasOptionalForeignEnum = false; - result.optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - return this; - } - - public bool HasOptionalImportEnum { - get { return result.hasOptionalImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum OptionalImportEnum { - get { return result.OptionalImportEnum; } - set { SetOptionalImportEnum(value); } - } - public Builder SetOptionalImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { - PrepareBuilder(); - result.hasOptionalImportEnum = true; - result.optionalImportEnum_ = value; - return this; - } - public Builder ClearOptionalImportEnum() { - PrepareBuilder(); - result.hasOptionalImportEnum = false; - result.optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_FOO; - return this; - } - - public bool HasOptionalStringPiece { - get { return result.hasOptionalStringPiece; } - } - public string OptionalStringPiece { - get { return result.OptionalStringPiece; } - set { SetOptionalStringPiece(value); } - } - public Builder SetOptionalStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalStringPiece = true; - result.optionalStringPiece_ = value; - return this; - } - public Builder ClearOptionalStringPiece() { - PrepareBuilder(); - result.hasOptionalStringPiece = false; - result.optionalStringPiece_ = ""; - return this; - } - - public bool HasOptionalCord { - get { return result.hasOptionalCord; } - } - public string OptionalCord { - get { return result.OptionalCord; } - set { SetOptionalCord(value); } - } - public Builder SetOptionalCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalCord = true; - result.optionalCord_ = value; - return this; - } - public Builder ClearOptionalCord() { - PrepareBuilder(); - result.hasOptionalCord = false; - result.optionalCord_ = ""; - return this; - } - - public bool HasOptionalPublicImportMessage { - get { return result.hasOptionalPublicImportMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.PublicImportMessage OptionalPublicImportMessage { - get { return result.OptionalPublicImportMessage; } - set { SetOptionalPublicImportMessage(value); } - } - public Builder SetOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalPublicImportMessage = true; - result.optionalPublicImportMessage_ = value; - return this; - } - public Builder SetOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalPublicImportMessage = true; - result.optionalPublicImportMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalPublicImportMessage && - result.optionalPublicImportMessage_ != global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.DefaultInstance) { - result.optionalPublicImportMessage_ = global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.CreateBuilder(result.optionalPublicImportMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalPublicImportMessage_ = value; - } - result.hasOptionalPublicImportMessage = true; - return this; - } - public Builder ClearOptionalPublicImportMessage() { - PrepareBuilder(); - result.hasOptionalPublicImportMessage = false; - result.optionalPublicImportMessage_ = null; - return this; - } - - public bool HasOptionalLazyMessage { - get { return result.hasOptionalLazyMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalLazyMessage { - get { return result.OptionalLazyMessage; } - set { SetOptionalLazyMessage(value); } - } - public Builder SetOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalLazyMessage = true; - result.optionalLazyMessage_ = value; - return this; - } - public Builder SetOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalLazyMessage = true; - result.optionalLazyMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalLazyMessage && - result.optionalLazyMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { - result.optionalLazyMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.optionalLazyMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalLazyMessage_ = value; - } - result.hasOptionalLazyMessage = true; - return this; - } - public Builder ClearOptionalLazyMessage() { - PrepareBuilder(); - result.hasOptionalLazyMessage = false; - result.optionalLazyMessage_ = null; - return this; - } - - public pbc::IPopsicleList RepeatedInt32List { - get { return PrepareBuilder().repeatedInt32_; } - } - public int RepeatedInt32Count { - get { return result.RepeatedInt32Count; } - } - public int GetRepeatedInt32(int index) { - return result.GetRepeatedInt32(index); - } - public Builder SetRepeatedInt32(int index, int value) { - PrepareBuilder(); - result.repeatedInt32_[index] = value; - return this; - } - public Builder AddRepeatedInt32(int value) { - PrepareBuilder(); - result.repeatedInt32_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt32_.Add(values); - return this; - } - public Builder ClearRepeatedInt32() { - PrepareBuilder(); - result.repeatedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedInt64List { - get { return PrepareBuilder().repeatedInt64_; } - } - public int RepeatedInt64Count { - get { return result.RepeatedInt64Count; } - } - public long GetRepeatedInt64(int index) { - return result.GetRepeatedInt64(index); - } - public Builder SetRepeatedInt64(int index, long value) { - PrepareBuilder(); - result.repeatedInt64_[index] = value; - return this; - } - public Builder AddRepeatedInt64(long value) { - PrepareBuilder(); - result.repeatedInt64_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt64_.Add(values); - return this; - } - public Builder ClearRepeatedInt64() { - PrepareBuilder(); - result.repeatedInt64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedUint32List { - get { return PrepareBuilder().repeatedUint32_; } - } - public int RepeatedUint32Count { - get { return result.RepeatedUint32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedUint32(int index) { - return result.GetRepeatedUint32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedUint32(int index, uint value) { - PrepareBuilder(); - result.repeatedUint32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedUint32(uint value) { - PrepareBuilder(); - result.repeatedUint32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedUint32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedUint32_.Add(values); - return this; - } - public Builder ClearRepeatedUint32() { - PrepareBuilder(); - result.repeatedUint32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedUint64List { - get { return PrepareBuilder().repeatedUint64_; } - } - public int RepeatedUint64Count { - get { return result.RepeatedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return result.GetRepeatedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedUint64(int index, ulong value) { - PrepareBuilder(); - result.repeatedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedUint64(ulong value) { - PrepareBuilder(); - result.repeatedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedUint64_.Add(values); - return this; - } - public Builder ClearRepeatedUint64() { - PrepareBuilder(); - result.repeatedUint64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSint32List { - get { return PrepareBuilder().repeatedSint32_; } - } - public int RepeatedSint32Count { - get { return result.RepeatedSint32Count; } - } - public int GetRepeatedSint32(int index) { - return result.GetRepeatedSint32(index); - } - public Builder SetRepeatedSint32(int index, int value) { - PrepareBuilder(); - result.repeatedSint32_[index] = value; - return this; - } - public Builder AddRepeatedSint32(int value) { - PrepareBuilder(); - result.repeatedSint32_.Add(value); - return this; - } - public Builder AddRangeRepeatedSint32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSint32_.Add(values); - return this; - } - public Builder ClearRepeatedSint32() { - PrepareBuilder(); - result.repeatedSint32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSint64List { - get { return PrepareBuilder().repeatedSint64_; } - } - public int RepeatedSint64Count { - get { return result.RepeatedSint64Count; } - } - public long GetRepeatedSint64(int index) { - return result.GetRepeatedSint64(index); - } - public Builder SetRepeatedSint64(int index, long value) { - PrepareBuilder(); - result.repeatedSint64_[index] = value; - return this; - } - public Builder AddRepeatedSint64(long value) { - PrepareBuilder(); - result.repeatedSint64_.Add(value); - return this; - } - public Builder AddRangeRepeatedSint64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSint64_.Add(values); - return this; - } - public Builder ClearRepeatedSint64() { - PrepareBuilder(); - result.repeatedSint64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed32List { - get { return PrepareBuilder().repeatedFixed32_; } - } - public int RepeatedFixed32Count { - get { return result.RepeatedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return result.GetRepeatedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed32(int index, uint value) { - PrepareBuilder(); - result.repeatedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed32(uint value) { - PrepareBuilder(); - result.repeatedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed32_.Add(values); - return this; - } - public Builder ClearRepeatedFixed32() { - PrepareBuilder(); - result.repeatedFixed32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed64List { - get { return PrepareBuilder().repeatedFixed64_; } - } - public int RepeatedFixed64Count { - get { return result.RepeatedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return result.GetRepeatedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed64(int index, ulong value) { - PrepareBuilder(); - result.repeatedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed64(ulong value) { - PrepareBuilder(); - result.repeatedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed64_.Add(values); - return this; - } - public Builder ClearRepeatedFixed64() { - PrepareBuilder(); - result.repeatedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSfixed32List { - get { return PrepareBuilder().repeatedSfixed32_; } - } - public int RepeatedSfixed32Count { - get { return result.RepeatedSfixed32Count; } - } - public int GetRepeatedSfixed32(int index) { - return result.GetRepeatedSfixed32(index); - } - public Builder SetRepeatedSfixed32(int index, int value) { - PrepareBuilder(); - result.repeatedSfixed32_[index] = value; - return this; - } - public Builder AddRepeatedSfixed32(int value) { - PrepareBuilder(); - result.repeatedSfixed32_.Add(value); - return this; - } - public Builder AddRangeRepeatedSfixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSfixed32_.Add(values); - return this; - } - public Builder ClearRepeatedSfixed32() { - PrepareBuilder(); - result.repeatedSfixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSfixed64List { - get { return PrepareBuilder().repeatedSfixed64_; } - } - public int RepeatedSfixed64Count { - get { return result.RepeatedSfixed64Count; } - } - public long GetRepeatedSfixed64(int index) { - return result.GetRepeatedSfixed64(index); - } - public Builder SetRepeatedSfixed64(int index, long value) { - PrepareBuilder(); - result.repeatedSfixed64_[index] = value; - return this; - } - public Builder AddRepeatedSfixed64(long value) { - PrepareBuilder(); - result.repeatedSfixed64_.Add(value); - return this; - } - public Builder AddRangeRepeatedSfixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSfixed64_.Add(values); - return this; - } - public Builder ClearRepeatedSfixed64() { - PrepareBuilder(); - result.repeatedSfixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedFloatList { - get { return PrepareBuilder().repeatedFloat_; } - } - public int RepeatedFloatCount { - get { return result.RepeatedFloatCount; } - } - public float GetRepeatedFloat(int index) { - return result.GetRepeatedFloat(index); - } - public Builder SetRepeatedFloat(int index, float value) { - PrepareBuilder(); - result.repeatedFloat_[index] = value; - return this; - } - public Builder AddRepeatedFloat(float value) { - PrepareBuilder(); - result.repeatedFloat_.Add(value); - return this; - } - public Builder AddRangeRepeatedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFloat_.Add(values); - return this; - } - public Builder ClearRepeatedFloat() { - PrepareBuilder(); - result.repeatedFloat_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedDoubleList { - get { return PrepareBuilder().repeatedDouble_; } - } - public int RepeatedDoubleCount { - get { return result.RepeatedDoubleCount; } - } - public double GetRepeatedDouble(int index) { - return result.GetRepeatedDouble(index); - } - public Builder SetRepeatedDouble(int index, double value) { - PrepareBuilder(); - result.repeatedDouble_[index] = value; - return this; - } - public Builder AddRepeatedDouble(double value) { - PrepareBuilder(); - result.repeatedDouble_.Add(value); - return this; - } - public Builder AddRangeRepeatedDouble(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedDouble_.Add(values); - return this; - } - public Builder ClearRepeatedDouble() { - PrepareBuilder(); - result.repeatedDouble_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedBoolList { - get { return PrepareBuilder().repeatedBool_; } - } - public int RepeatedBoolCount { - get { return result.RepeatedBoolCount; } - } - public bool GetRepeatedBool(int index) { - return result.GetRepeatedBool(index); - } - public Builder SetRepeatedBool(int index, bool value) { - PrepareBuilder(); - result.repeatedBool_[index] = value; - return this; - } - public Builder AddRepeatedBool(bool value) { - PrepareBuilder(); - result.repeatedBool_.Add(value); - return this; - } - public Builder AddRangeRepeatedBool(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedBool_.Add(values); - return this; - } - public Builder ClearRepeatedBool() { - PrepareBuilder(); - result.repeatedBool_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringList { - get { return PrepareBuilder().repeatedString_; } - } - public int RepeatedStringCount { - get { return result.RepeatedStringCount; } - } - public string GetRepeatedString(int index) { - return result.GetRepeatedString(index); - } - public Builder SetRepeatedString(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedString_[index] = value; - return this; - } - public Builder AddRepeatedString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedString_.Add(value); - return this; - } - public Builder AddRangeRepeatedString(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedString_.Add(values); - return this; - } - public Builder ClearRepeatedString() { - PrepareBuilder(); - result.repeatedString_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedBytesList { - get { return PrepareBuilder().repeatedBytes_; } - } - public int RepeatedBytesCount { - get { return result.RepeatedBytesCount; } - } - public pb::ByteString GetRepeatedBytes(int index) { - return result.GetRepeatedBytes(index); - } - public Builder SetRepeatedBytes(int index, pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedBytes_[index] = value; - return this; - } - public Builder AddRepeatedBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedBytes_.Add(value); - return this; - } - public Builder AddRangeRepeatedBytes(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedBytes_.Add(values); - return this; - } - public Builder ClearRepeatedBytes() { - PrepareBuilder(); - result.repeatedBytes_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedGroupList { - get { return PrepareBuilder().repeatedGroup_; } - } - public int RepeatedGroupCount { - get { return result.RepeatedGroupCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup GetRepeatedGroup(int index) { - return result.GetRepeatedGroup(index); - } - public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedGroup_[index] = value; - return this; - } - public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedGroup_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedGroup_.Add(value); - return this; - } - public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedGroup_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedGroup(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedGroup_.Add(values); - return this; - } - public Builder ClearRepeatedGroup() { - PrepareBuilder(); - result.repeatedGroup_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedNestedMessageList { - get { return PrepareBuilder().repeatedNestedMessage_; } - } - public int RepeatedNestedMessageCount { - get { return result.RepeatedNestedMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) { - return result.GetRepeatedNestedMessage(index); - } - public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedNestedMessage_[index] = value; - return this; - } - public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedNestedMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedNestedMessage_.Add(value); - return this; - } - public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedNestedMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedNestedMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedNestedMessage_.Add(values); - return this; - } - public Builder ClearRepeatedNestedMessage() { - PrepareBuilder(); - result.repeatedNestedMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedForeignMessageList { - get { return PrepareBuilder().repeatedForeignMessage_; } - } - public int RepeatedForeignMessageCount { - get { return result.RepeatedForeignMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) { - return result.GetRepeatedForeignMessage(index); - } - public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedForeignMessage_[index] = value; - return this; - } - public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedForeignMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedForeignMessage_.Add(value); - return this; - } - public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedForeignMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedForeignMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedForeignMessage_.Add(values); - return this; - } - public Builder ClearRepeatedForeignMessage() { - PrepareBuilder(); - result.repeatedForeignMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedImportMessageList { - get { return PrepareBuilder().repeatedImportMessage_; } - } - public int RepeatedImportMessageCount { - get { return result.RepeatedImportMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportMessage GetRepeatedImportMessage(int index) { - return result.GetRepeatedImportMessage(index); - } - public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedImportMessage_[index] = value; - return this; - } - public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedImportMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedImportMessage_.Add(value); - return this; - } - public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedImportMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedImportMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedImportMessage_.Add(values); - return this; - } - public Builder ClearRepeatedImportMessage() { - PrepareBuilder(); - result.repeatedImportMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedNestedEnumList { - get { return PrepareBuilder().repeatedNestedEnum_; } - } - public int RepeatedNestedEnumCount { - get { return result.RepeatedNestedEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) { - return result.GetRepeatedNestedEnum(index); - } - public Builder SetRepeatedNestedEnum(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.repeatedNestedEnum_[index] = value; - return this; - } - public Builder AddRepeatedNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.repeatedNestedEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedNestedEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedNestedEnum_.Add(values); - return this; - } - public Builder ClearRepeatedNestedEnum() { - PrepareBuilder(); - result.repeatedNestedEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedForeignEnumList { - get { return PrepareBuilder().repeatedForeignEnum_; } - } - public int RepeatedForeignEnumCount { - get { return result.RepeatedForeignEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) { - return result.GetRepeatedForeignEnum(index); - } - public Builder SetRepeatedForeignEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.repeatedForeignEnum_[index] = value; - return this; - } - public Builder AddRepeatedForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.repeatedForeignEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedForeignEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedForeignEnum_.Add(values); - return this; - } - public Builder ClearRepeatedForeignEnum() { - PrepareBuilder(); - result.repeatedForeignEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedImportEnumList { - get { return PrepareBuilder().repeatedImportEnum_; } - } - public int RepeatedImportEnumCount { - get { return result.RepeatedImportEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum GetRepeatedImportEnum(int index) { - return result.GetRepeatedImportEnum(index); - } - public Builder SetRepeatedImportEnum(int index, global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { - PrepareBuilder(); - result.repeatedImportEnum_[index] = value; - return this; - } - public Builder AddRepeatedImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { - PrepareBuilder(); - result.repeatedImportEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedImportEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedImportEnum_.Add(values); - return this; - } - public Builder ClearRepeatedImportEnum() { - PrepareBuilder(); - result.repeatedImportEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringPieceList { - get { return PrepareBuilder().repeatedStringPiece_; } - } - public int RepeatedStringPieceCount { - get { return result.RepeatedStringPieceCount; } - } - public string GetRepeatedStringPiece(int index) { - return result.GetRepeatedStringPiece(index); - } - public Builder SetRepeatedStringPiece(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPiece_[index] = value; - return this; - } - public Builder AddRepeatedStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPiece_.Add(value); - return this; - } - public Builder AddRangeRepeatedStringPiece(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedStringPiece_.Add(values); - return this; - } - public Builder ClearRepeatedStringPiece() { - PrepareBuilder(); - result.repeatedStringPiece_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedCordList { - get { return PrepareBuilder().repeatedCord_; } - } - public int RepeatedCordCount { - get { return result.RepeatedCordCount; } - } - public string GetRepeatedCord(int index) { - return result.GetRepeatedCord(index); - } - public Builder SetRepeatedCord(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCord_[index] = value; - return this; - } - public Builder AddRepeatedCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCord_.Add(value); - return this; - } - public Builder AddRangeRepeatedCord(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedCord_.Add(values); - return this; - } - public Builder ClearRepeatedCord() { - PrepareBuilder(); - result.repeatedCord_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedLazyMessageList { - get { return PrepareBuilder().repeatedLazyMessage_; } - } - public int RepeatedLazyMessageCount { - get { return result.RepeatedLazyMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedLazyMessage(int index) { - return result.GetRepeatedLazyMessage(index); - } - public Builder SetRepeatedLazyMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedLazyMessage_[index] = value; - return this; - } - public Builder SetRepeatedLazyMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedLazyMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedLazyMessage_.Add(value); - return this; - } - public Builder AddRepeatedLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedLazyMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedLazyMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedLazyMessage_.Add(values); - return this; - } - public Builder ClearRepeatedLazyMessage() { - PrepareBuilder(); - result.repeatedLazyMessage_.Clear(); - return this; - } - - public bool HasDefaultInt32 { - get { return result.hasDefaultInt32; } - } - public int DefaultInt32 { - get { return result.DefaultInt32; } - set { SetDefaultInt32(value); } - } - public Builder SetDefaultInt32(int value) { - PrepareBuilder(); - result.hasDefaultInt32 = true; - result.defaultInt32_ = value; - return this; - } - public Builder ClearDefaultInt32() { - PrepareBuilder(); - result.hasDefaultInt32 = false; - result.defaultInt32_ = 41; - return this; - } - - public bool HasDefaultInt64 { - get { return result.hasDefaultInt64; } - } - public long DefaultInt64 { - get { return result.DefaultInt64; } - set { SetDefaultInt64(value); } - } - public Builder SetDefaultInt64(long value) { - PrepareBuilder(); - result.hasDefaultInt64 = true; - result.defaultInt64_ = value; - return this; - } - public Builder ClearDefaultInt64() { - PrepareBuilder(); - result.hasDefaultInt64 = false; - result.defaultInt64_ = 42L; - return this; - } - - public bool HasDefaultUint32 { - get { return result.hasDefaultUint32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultUint32 { - get { return result.DefaultUint32; } - set { SetDefaultUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultUint32(uint value) { - PrepareBuilder(); - result.hasDefaultUint32 = true; - result.defaultUint32_ = value; - return this; - } - public Builder ClearDefaultUint32() { - PrepareBuilder(); - result.hasDefaultUint32 = false; - result.defaultUint32_ = 43; - return this; - } - - public bool HasDefaultUint64 { - get { return result.hasDefaultUint64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultUint64 { - get { return result.DefaultUint64; } - set { SetDefaultUint64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultUint64(ulong value) { - PrepareBuilder(); - result.hasDefaultUint64 = true; - result.defaultUint64_ = value; - return this; - } - public Builder ClearDefaultUint64() { - PrepareBuilder(); - result.hasDefaultUint64 = false; - result.defaultUint64_ = 44UL; - return this; - } - - public bool HasDefaultSint32 { - get { return result.hasDefaultSint32; } - } - public int DefaultSint32 { - get { return result.DefaultSint32; } - set { SetDefaultSint32(value); } - } - public Builder SetDefaultSint32(int value) { - PrepareBuilder(); - result.hasDefaultSint32 = true; - result.defaultSint32_ = value; - return this; - } - public Builder ClearDefaultSint32() { - PrepareBuilder(); - result.hasDefaultSint32 = false; - result.defaultSint32_ = -45; - return this; - } - - public bool HasDefaultSint64 { - get { return result.hasDefaultSint64; } - } - public long DefaultSint64 { - get { return result.DefaultSint64; } - set { SetDefaultSint64(value); } - } - public Builder SetDefaultSint64(long value) { - PrepareBuilder(); - result.hasDefaultSint64 = true; - result.defaultSint64_ = value; - return this; - } - public Builder ClearDefaultSint64() { - PrepareBuilder(); - result.hasDefaultSint64 = false; - result.defaultSint64_ = 46L; - return this; - } - - public bool HasDefaultFixed32 { - get { return result.hasDefaultFixed32; } - } - [global::System.CLSCompliant(false)] - public uint DefaultFixed32 { - get { return result.DefaultFixed32; } - set { SetDefaultFixed32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultFixed32(uint value) { - PrepareBuilder(); - result.hasDefaultFixed32 = true; - result.defaultFixed32_ = value; - return this; - } - public Builder ClearDefaultFixed32() { - PrepareBuilder(); - result.hasDefaultFixed32 = false; - result.defaultFixed32_ = 47; - return this; - } - - public bool HasDefaultFixed64 { - get { return result.hasDefaultFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong DefaultFixed64 { - get { return result.DefaultFixed64; } - set { SetDefaultFixed64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetDefaultFixed64(ulong value) { - PrepareBuilder(); - result.hasDefaultFixed64 = true; - result.defaultFixed64_ = value; - return this; - } - public Builder ClearDefaultFixed64() { - PrepareBuilder(); - result.hasDefaultFixed64 = false; - result.defaultFixed64_ = 48UL; - return this; - } - - public bool HasDefaultSfixed32 { - get { return result.hasDefaultSfixed32; } - } - public int DefaultSfixed32 { - get { return result.DefaultSfixed32; } - set { SetDefaultSfixed32(value); } - } - public Builder SetDefaultSfixed32(int value) { - PrepareBuilder(); - result.hasDefaultSfixed32 = true; - result.defaultSfixed32_ = value; - return this; - } - public Builder ClearDefaultSfixed32() { - PrepareBuilder(); - result.hasDefaultSfixed32 = false; - result.defaultSfixed32_ = 49; - return this; - } - - public bool HasDefaultSfixed64 { - get { return result.hasDefaultSfixed64; } - } - public long DefaultSfixed64 { - get { return result.DefaultSfixed64; } - set { SetDefaultSfixed64(value); } - } - public Builder SetDefaultSfixed64(long value) { - PrepareBuilder(); - result.hasDefaultSfixed64 = true; - result.defaultSfixed64_ = value; - return this; - } - public Builder ClearDefaultSfixed64() { - PrepareBuilder(); - result.hasDefaultSfixed64 = false; - result.defaultSfixed64_ = -50L; - return this; - } - - public bool HasDefaultFloat { - get { return result.hasDefaultFloat; } - } - public float DefaultFloat { - get { return result.DefaultFloat; } - set { SetDefaultFloat(value); } - } - public Builder SetDefaultFloat(float value) { - PrepareBuilder(); - result.hasDefaultFloat = true; - result.defaultFloat_ = value; - return this; - } - public Builder ClearDefaultFloat() { - PrepareBuilder(); - result.hasDefaultFloat = false; - result.defaultFloat_ = 51.5F; - return this; - } - - public bool HasDefaultDouble { - get { return result.hasDefaultDouble; } - } - public double DefaultDouble { - get { return result.DefaultDouble; } - set { SetDefaultDouble(value); } - } - public Builder SetDefaultDouble(double value) { - PrepareBuilder(); - result.hasDefaultDouble = true; - result.defaultDouble_ = value; - return this; - } - public Builder ClearDefaultDouble() { - PrepareBuilder(); - result.hasDefaultDouble = false; - result.defaultDouble_ = 52000D; - return this; - } - - public bool HasDefaultBool { - get { return result.hasDefaultBool; } - } - public bool DefaultBool { - get { return result.DefaultBool; } - set { SetDefaultBool(value); } - } - public Builder SetDefaultBool(bool value) { - PrepareBuilder(); - result.hasDefaultBool = true; - result.defaultBool_ = value; - return this; - } - public Builder ClearDefaultBool() { - PrepareBuilder(); - result.hasDefaultBool = false; - result.defaultBool_ = true; - return this; - } - - public bool HasDefaultString { - get { return result.hasDefaultString; } - } - public string DefaultString { - get { return result.DefaultString; } - set { SetDefaultString(value); } - } - public Builder SetDefaultString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultString = true; - result.defaultString_ = value; - return this; - } - public Builder ClearDefaultString() { - PrepareBuilder(); - result.hasDefaultString = false; - result.defaultString_ = "hello"; - return this; - } - - public bool HasDefaultBytes { - get { return result.hasDefaultBytes; } - } - public pb::ByteString DefaultBytes { - get { return result.DefaultBytes; } - set { SetDefaultBytes(value); } - } - public Builder SetDefaultBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultBytes = true; - result.defaultBytes_ = value; - return this; - } - public Builder ClearDefaultBytes() { - PrepareBuilder(); - result.hasDefaultBytes = false; - result.defaultBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor.Fields[65].DefaultValue; - return this; - } - - public bool HasDefaultNestedEnum { - get { return result.hasDefaultNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum DefaultNestedEnum { - get { return result.DefaultNestedEnum; } - set { SetDefaultNestedEnum(value); } - } - public Builder SetDefaultNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.hasDefaultNestedEnum = true; - result.defaultNestedEnum_ = value; - return this; - } - public Builder ClearDefaultNestedEnum() { - PrepareBuilder(); - result.hasDefaultNestedEnum = false; - result.defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.BAR; - return this; - } - - public bool HasDefaultForeignEnum { - get { return result.hasDefaultForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum DefaultForeignEnum { - get { return result.DefaultForeignEnum; } - set { SetDefaultForeignEnum(value); } - } - public Builder SetDefaultForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.hasDefaultForeignEnum = true; - result.defaultForeignEnum_ = value; - return this; - } - public Builder ClearDefaultForeignEnum() { - PrepareBuilder(); - result.hasDefaultForeignEnum = false; - result.defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_BAR; - return this; - } - - public bool HasDefaultImportEnum { - get { return result.hasDefaultImportEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ImportEnum DefaultImportEnum { - get { return result.DefaultImportEnum; } - set { SetDefaultImportEnum(value); } - } - public Builder SetDefaultImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) { - PrepareBuilder(); - result.hasDefaultImportEnum = true; - result.defaultImportEnum_ = value; - return this; - } - public Builder ClearDefaultImportEnum() { - PrepareBuilder(); - result.hasDefaultImportEnum = false; - result.defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_BAR; - return this; - } - - public bool HasDefaultStringPiece { - get { return result.hasDefaultStringPiece; } - } - public string DefaultStringPiece { - get { return result.DefaultStringPiece; } - set { SetDefaultStringPiece(value); } - } - public Builder SetDefaultStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultStringPiece = true; - result.defaultStringPiece_ = value; - return this; - } - public Builder ClearDefaultStringPiece() { - PrepareBuilder(); - result.hasDefaultStringPiece = false; - result.defaultStringPiece_ = "abc"; - return this; - } - - public bool HasDefaultCord { - get { return result.hasDefaultCord; } - } - public string DefaultCord { - get { return result.DefaultCord; } - set { SetDefaultCord(value); } - } - public Builder SetDefaultCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDefaultCord = true; - result.defaultCord_ = value; - return this; - } - public Builder ClearDefaultCord() { - PrepareBuilder(); - result.hasDefaultCord = false; - result.defaultCord_ = "123"; - return this; - } - - public bool HasOneofUint32 { - get { return result.hasOneofUint32; } - } - [global::System.CLSCompliant(false)] - public uint OneofUint32 { - get { return result.OneofUint32; } - set { SetOneofUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOneofUint32(uint value) { - PrepareBuilder(); - result.hasOneofUint32 = true; - result.oneofUint32_ = value; - return this; - } - public Builder ClearOneofUint32() { - PrepareBuilder(); - result.hasOneofUint32 = false; - result.oneofUint32_ = 0; - return this; - } - - public bool HasOneofNestedMessage { - get { return result.hasOneofNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OneofNestedMessage { - get { return result.OneofNestedMessage; } - set { SetOneofNestedMessage(value); } - } - public Builder SetOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOneofNestedMessage = true; - result.oneofNestedMessage_ = value; - return this; - } - public Builder SetOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOneofNestedMessage = true; - result.oneofNestedMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOneofNestedMessage && - result.oneofNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { - result.oneofNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.oneofNestedMessage_).MergeFrom(value).BuildPartial(); - } else { - result.oneofNestedMessage_ = value; - } - result.hasOneofNestedMessage = true; - return this; - } - public Builder ClearOneofNestedMessage() { - PrepareBuilder(); - result.hasOneofNestedMessage = false; - result.oneofNestedMessage_ = null; - return this; - } - - public bool HasOneofString { - get { return result.hasOneofString; } - } - public string OneofString { - get { return result.OneofString; } - set { SetOneofString(value); } - } - public Builder SetOneofString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOneofString = true; - result.oneofString_ = value; - return this; - } - public Builder ClearOneofString() { - PrepareBuilder(); - result.hasOneofString = false; - result.oneofString_ = ""; - return this; - } - - public bool HasOneofBytes { - get { return result.hasOneofBytes; } - } - public pb::ByteString OneofBytes { - get { return result.OneofBytes; } - set { SetOneofBytes(value); } - } - public Builder SetOneofBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOneofBytes = true; - result.oneofBytes_ = value; - return this; - } - public Builder ClearOneofBytes() { - PrepareBuilder(); - result.hasOneofBytes = false; - result.oneofBytes_ = pb::ByteString.Empty; - return this; - } - } - static TestAllTypes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NestedTestAllTypes : pb::GeneratedMessage { - private NestedTestAllTypes() { } - private static readonly NestedTestAllTypes defaultInstance = new NestedTestAllTypes().MakeReadOnly(); - private static readonly string[] _nestedTestAllTypesFieldNames = new string[] { "child", "payload" }; - private static readonly uint[] _nestedTestAllTypesFieldTags = new uint[] { 10, 18 }; - public static NestedTestAllTypes DefaultInstance { - get { return defaultInstance; } - } - - public override NestedTestAllTypes DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override NestedTestAllTypes ThisMessage { - get { return this; } - } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor; } - } + public const int RepeatedLazyMessageFieldNumber = 57; + private pbc::PopsicleList repeatedLazyMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedLazyMessageList + { + get { return repeatedLazyMessage_; } + } + public int RepeatedLazyMessageCount + { + get { return repeatedLazyMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedLazyMessage(int index) + { + return repeatedLazyMessage_[index]; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_NestedTestAllTypes__FieldAccessorTable; } - } + public const int DefaultInt32FieldNumber = 61; + private bool hasDefaultInt32; + private int defaultInt32_ = 41; + public bool HasDefaultInt32 + { + get { return hasDefaultInt32; } + } + public int DefaultInt32 + { + get { return defaultInt32_; } + } - public const int ChildFieldNumber = 1; - private bool hasChild; - private global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes child_; - public bool HasChild { - get { return hasChild; } - } - public global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes Child { - get { return child_ ?? global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance; } - } + public const int DefaultInt64FieldNumber = 62; + private bool hasDefaultInt64; + private long defaultInt64_ = 42L; + public bool HasDefaultInt64 + { + get { return hasDefaultInt64; } + } + public long DefaultInt64 + { + get { return defaultInt64_; } + } - public const int PayloadFieldNumber = 2; - private bool hasPayload; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes payload_; - public bool HasPayload { - get { return hasPayload; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Payload { - get { return payload_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } + public const int DefaultUint32FieldNumber = 63; + private bool hasDefaultUint32; + private uint defaultUint32_ = 43; + public bool HasDefaultUint32 + { + get { return hasDefaultUint32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultUint32 + { + get { return defaultUint32_; } + } - public override bool IsInitialized { - get { - return true; - } - } + public const int DefaultUint64FieldNumber = 64; + private bool hasDefaultUint64; + private ulong defaultUint64_ = 44UL; + public bool HasDefaultUint64 + { + get { return hasDefaultUint64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultUint64 + { + get { return defaultUint64_; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _nestedTestAllTypesFieldNames; - if (hasChild) { - output.WriteMessage(1, field_names[0], Child); - } - if (hasPayload) { - output.WriteMessage(2, field_names[1], Payload); - } - UnknownFields.WriteTo(output); - } + public const int DefaultSint32FieldNumber = 65; + private bool hasDefaultSint32; + private int defaultSint32_ = -45; + public bool HasDefaultSint32 + { + get { return hasDefaultSint32; } + } + public int DefaultSint32 + { + get { return defaultSint32_; } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public const int DefaultSint64FieldNumber = 66; + private bool hasDefaultSint64; + private long defaultSint64_ = 46L; + public bool HasDefaultSint64 + { + get { return hasDefaultSint64; } + } + public long DefaultSint64 + { + get { return defaultSint64_; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasChild) { - size += pb::CodedOutputStream.ComputeMessageSize(1, Child); - } - if (hasPayload) { - size += pb::CodedOutputStream.ComputeMessageSize(2, Payload); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static NestedTestAllTypes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedTestAllTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedTestAllTypes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedTestAllTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedTestAllTypes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedTestAllTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NestedTestAllTypes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NestedTestAllTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NestedTestAllTypes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedTestAllTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NestedTestAllTypes MakeReadOnly() { - return this; - } + public const int DefaultFixed32FieldNumber = 67; + private bool hasDefaultFixed32; + private uint defaultFixed32_ = 47; + public bool HasDefaultFixed32 + { + get { return hasDefaultFixed32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultFixed32 + { + get { return defaultFixed32_; } + } + + public const int DefaultFixed64FieldNumber = 68; + private bool hasDefaultFixed64; + private ulong defaultFixed64_ = 48UL; + public bool HasDefaultFixed64 + { + get { return hasDefaultFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultFixed64 + { + get { return defaultFixed64_; } + } + + public const int DefaultSfixed32FieldNumber = 69; + private bool hasDefaultSfixed32; + private int defaultSfixed32_ = 49; + public bool HasDefaultSfixed32 + { + get { return hasDefaultSfixed32; } + } + public int DefaultSfixed32 + { + get { return defaultSfixed32_; } + } + + public const int DefaultSfixed64FieldNumber = 70; + private bool hasDefaultSfixed64; + private long defaultSfixed64_ = -50L; + public bool HasDefaultSfixed64 + { + get { return hasDefaultSfixed64; } + } + public long DefaultSfixed64 + { + get { return defaultSfixed64_; } + } + + public const int DefaultFloatFieldNumber = 71; + private bool hasDefaultFloat; + private float defaultFloat_ = 51.5F; + public bool HasDefaultFloat + { + get { return hasDefaultFloat; } + } + public float DefaultFloat + { + get { return defaultFloat_; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NestedTestAllTypes prototype) { - return new Builder(prototype); - } + public const int DefaultDoubleFieldNumber = 72; + private bool hasDefaultDouble; + private double defaultDouble_ = 52000D; + public bool HasDefaultDouble + { + get { return hasDefaultDouble; } + } + public double DefaultDouble + { + get { return defaultDouble_; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NestedTestAllTypes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NestedTestAllTypes result; - - private NestedTestAllTypes PrepareBuilder() { - if (resultIsReadOnly) { - NestedTestAllTypes original = result; - result = new NestedTestAllTypes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NestedTestAllTypes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.Descriptor; } - } - - public override NestedTestAllTypes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance; } - } - - public override NestedTestAllTypes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is NestedTestAllTypes) { - return MergeFrom((NestedTestAllTypes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(NestedTestAllTypes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasChild) { - MergeChild(other.Child); - } - if (other.HasPayload) { - MergePayload(other.Payload); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_nestedTestAllTypesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _nestedTestAllTypesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.CreateBuilder(); - if (result.hasChild) { - subBuilder.MergeFrom(Child); - } - input.ReadMessage(subBuilder, extensionRegistry); - Child = subBuilder.BuildPartial(); - break; - } - case 18: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasPayload) { - subBuilder.MergeFrom(Payload); - } - input.ReadMessage(subBuilder, extensionRegistry); - Payload = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasChild { - get { return result.hasChild; } - } - public global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes Child { - get { return result.Child; } - set { SetChild(value); } - } - public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasChild = true; - result.child_ = value; - return this; - } - public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasChild = true; - result.child_ = builderForValue.Build(); - return this; - } - public Builder MergeChild(global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasChild && - result.child_ != global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance) { - result.child_ = global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.CreateBuilder(result.child_).MergeFrom(value).BuildPartial(); - } else { - result.child_ = value; - } - result.hasChild = true; - return this; - } - public Builder ClearChild() { - PrepareBuilder(); - result.hasChild = false; - result.child_ = null; - return this; - } - - public bool HasPayload { - get { return result.hasPayload; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Payload { - get { return result.Payload; } - set { SetPayload(value); } - } - public Builder SetPayload(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasPayload = true; - result.payload_ = value; - return this; - } - public Builder SetPayload(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasPayload = true; - result.payload_ = builderForValue.Build(); - return this; - } - public Builder MergePayload(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasPayload && - result.payload_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.payload_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.payload_).MergeFrom(value).BuildPartial(); - } else { - result.payload_ = value; - } - result.hasPayload = true; - return this; - } - public Builder ClearPayload() { - PrepareBuilder(); - result.hasPayload = false; - result.payload_ = null; - return this; - } - } - static NestedTestAllTypes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestDeprecatedFields : pb::GeneratedMessage { - private TestDeprecatedFields() { } - private static readonly TestDeprecatedFields defaultInstance = new TestDeprecatedFields().MakeReadOnly(); - private static readonly string[] _testDeprecatedFieldsFieldNames = new string[] { "deprecated_int32" }; - private static readonly uint[] _testDeprecatedFieldsFieldTags = new uint[] { 8 }; - public static TestDeprecatedFields DefaultInstance { - get { return defaultInstance; } - } + public const int DefaultBoolFieldNumber = 73; + private bool hasDefaultBool; + private bool defaultBool_ = true; + public bool HasDefaultBool + { + get { return hasDefaultBool; } + } + public bool DefaultBool + { + get { return defaultBool_; } + } - public override TestDeprecatedFields DefaultInstanceForType { - get { return DefaultInstance; } - } + public const int DefaultStringFieldNumber = 74; + private bool hasDefaultString; + private string defaultString_ = "hello"; + public bool HasDefaultString + { + get { return hasDefaultString; } + } + public string DefaultString + { + get { return defaultString_; } + } - protected override TestDeprecatedFields ThisMessage { - get { return this; } - } + public const int DefaultBytesFieldNumber = 75; + private bool hasDefaultBytes; + private pb::ByteString defaultBytes_ = (pb::ByteString)global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor.Fields[65].DefaultValue; + public bool HasDefaultBytes + { + get { return hasDefaultBytes; } + } + public pb::ByteString DefaultBytes + { + get { return defaultBytes_; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor; } - } + public const int DefaultNestedEnumFieldNumber = 81; + private bool hasDefaultNestedEnum; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.BAR; + public bool HasDefaultNestedEnum + { + get { return hasDefaultNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum DefaultNestedEnum + { + get { return defaultNestedEnum_; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable; } - } + public const int DefaultForeignEnumFieldNumber = 82; + private bool hasDefaultForeignEnum; + private global::Google.ProtocolBuffers.TestProtos.ForeignEnum defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_BAR; + public bool HasDefaultForeignEnum + { + get { return hasDefaultForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum DefaultForeignEnum + { + get { return defaultForeignEnum_; } + } - public const int DeprecatedInt32FieldNumber = 1; - private bool hasDeprecatedInt32; - private int deprecatedInt32_; - [global::System.ObsoleteAttribute()] - public bool HasDeprecatedInt32 { - get { return hasDeprecatedInt32; } - } - [global::System.ObsoleteAttribute()] - public int DeprecatedInt32 { - get { return deprecatedInt32_; } - } + public const int DefaultImportEnumFieldNumber = 83; + private bool hasDefaultImportEnum; + private global::Google.ProtocolBuffers.TestProtos.ImportEnum defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_BAR; + public bool HasDefaultImportEnum + { + get { return hasDefaultImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum DefaultImportEnum + { + get { return defaultImportEnum_; } + } - public override bool IsInitialized { - get { - return true; - } - } + public const int DefaultStringPieceFieldNumber = 84; + private bool hasDefaultStringPiece; + private string defaultStringPiece_ = "abc"; + public bool HasDefaultStringPiece + { + get { return hasDefaultStringPiece; } + } + public string DefaultStringPiece + { + get { return defaultStringPiece_; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testDeprecatedFieldsFieldNames; - if (hasDeprecatedInt32) { - output.WriteInt32(1, field_names[0], DeprecatedInt32); - } - UnknownFields.WriteTo(output); - } + public const int DefaultCordFieldNumber = 85; + private bool hasDefaultCord; + private string defaultCord_ = "123"; + public bool HasDefaultCord + { + get { return hasDefaultCord; } + } + public string DefaultCord + { + get { return defaultCord_; } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public const int OneofUint32FieldNumber = 111; + private bool hasOneofUint32; + private uint oneofUint32_; + public bool HasOneofUint32 + { + get { return hasOneofUint32; } + } + [global::System.CLSCompliant(false)] + public uint OneofUint32 + { + get { return oneofUint32_; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasDeprecatedInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(1, DeprecatedInt32); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestDeprecatedFields ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestDeprecatedFields ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestDeprecatedFields ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDeprecatedFields ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestDeprecatedFields MakeReadOnly() { - return this; - } + public const int OneofNestedMessageFieldNumber = 112; + private bool hasOneofNestedMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage oneofNestedMessage_; + public bool HasOneofNestedMessage + { + get { return hasOneofNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OneofNestedMessage + { + get { return oneofNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestDeprecatedFields prototype) { - return new Builder(prototype); - } + public const int OneofStringFieldNumber = 113; + private bool hasOneofString; + private string oneofString_ = ""; + public bool HasOneofString + { + get { return hasOneofString; } + } + public string OneofString + { + get { return oneofString_; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestDeprecatedFields cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestDeprecatedFields result; - - private TestDeprecatedFields PrepareBuilder() { - if (resultIsReadOnly) { - TestDeprecatedFields original = result; - result = new TestDeprecatedFields(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestDeprecatedFields MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.Descriptor; } - } - - public override TestDeprecatedFields DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.DefaultInstance; } - } - - public override TestDeprecatedFields BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestDeprecatedFields) { - return MergeFrom((TestDeprecatedFields) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestDeprecatedFields other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasDeprecatedInt32) { - DeprecatedInt32 = other.DeprecatedInt32; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testDeprecatedFieldsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testDeprecatedFieldsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasDeprecatedInt32 = input.ReadInt32(ref result.deprecatedInt32_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - [global::System.ObsoleteAttribute()] - public bool HasDeprecatedInt32 { - get { return result.hasDeprecatedInt32; } - } - [global::System.ObsoleteAttribute()] - public int DeprecatedInt32 { - get { return result.DeprecatedInt32; } - set { SetDeprecatedInt32(value); } - } - [global::System.ObsoleteAttribute()] - public Builder SetDeprecatedInt32(int value) { - PrepareBuilder(); - result.hasDeprecatedInt32 = true; - result.deprecatedInt32_ = value; - return this; - } - [global::System.ObsoleteAttribute()] - public Builder ClearDeprecatedInt32() { - PrepareBuilder(); - result.hasDeprecatedInt32 = false; - result.deprecatedInt32_ = 0; - return this; - } - } - static TestDeprecatedFields() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class ForeignMessage : pb::GeneratedMessage { - private ForeignMessage() { } - private static readonly ForeignMessage defaultInstance = new ForeignMessage().MakeReadOnly(); - private static readonly string[] _foreignMessageFieldNames = new string[] { "c" }; - private static readonly uint[] _foreignMessageFieldTags = new uint[] { 8 }; - public static ForeignMessage DefaultInstance { - get { return defaultInstance; } - } + public const int OneofBytesFieldNumber = 114; + private bool hasOneofBytes; + private pb::ByteString oneofBytes_ = pb::ByteString.Empty; + public bool HasOneofBytes + { + get { return hasOneofBytes; } + } + public pb::ByteString OneofBytes + { + get { return oneofBytes_; } + } - public override ForeignMessage DefaultInstanceForType { - get { return DefaultInstance; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - protected override ForeignMessage ThisMessage { - get { return this; } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testAllTypesFieldNames; + if (hasOptionalInt32) + { + output.WriteInt32(1, field_names[35], OptionalInt32); + } + if (hasOptionalInt64) + { + output.WriteInt64(2, field_names[36], OptionalInt64); + } + if (hasOptionalUint32) + { + output.WriteUInt32(3, field_names[47], OptionalUint32); + } + if (hasOptionalUint64) + { + output.WriteUInt64(4, field_names[48], OptionalUint64); + } + if (hasOptionalSint32) + { + output.WriteSInt32(5, field_names[43], OptionalSint32); + } + if (hasOptionalSint64) + { + output.WriteSInt64(6, field_names[44], OptionalSint64); + } + if (hasOptionalFixed32) + { + output.WriteFixed32(7, field_names[28], OptionalFixed32); + } + if (hasOptionalFixed64) + { + output.WriteFixed64(8, field_names[29], OptionalFixed64); + } + if (hasOptionalSfixed32) + { + output.WriteSFixed32(9, field_names[41], OptionalSfixed32); + } + if (hasOptionalSfixed64) + { + output.WriteSFixed64(10, field_names[42], OptionalSfixed64); + } + if (hasOptionalFloat) + { + output.WriteFloat(11, field_names[30], OptionalFloat); + } + if (hasOptionalDouble) + { + output.WriteDouble(12, field_names[27], OptionalDouble); + } + if (hasOptionalBool) + { + output.WriteBool(13, field_names[24], OptionalBool); + } + if (hasOptionalString) + { + output.WriteString(14, field_names[45], OptionalString); + } + if (hasOptionalBytes) + { + output.WriteBytes(15, field_names[25], OptionalBytes); + } + if (hasOptionalGroup) + { + output.WriteGroup(16, field_names[49], OptionalGroup); + } + if (hasOptionalNestedMessage) + { + output.WriteMessage(18, field_names[39], OptionalNestedMessage); + } + if (hasOptionalForeignMessage) + { + output.WriteMessage(19, field_names[32], OptionalForeignMessage); + } + if (hasOptionalImportMessage) + { + output.WriteMessage(20, field_names[34], OptionalImportMessage); + } + if (hasOptionalNestedEnum) + { + output.WriteEnum(21, field_names[38], (int)OptionalNestedEnum, OptionalNestedEnum); + } + if (hasOptionalForeignEnum) + { + output.WriteEnum(22, field_names[31], (int)OptionalForeignEnum, OptionalForeignEnum); + } + if (hasOptionalImportEnum) + { + output.WriteEnum(23, field_names[33], (int)OptionalImportEnum, OptionalImportEnum); + } + if (hasOptionalStringPiece) + { + output.WriteString(24, field_names[46], OptionalStringPiece); + } + if (hasOptionalCord) + { + output.WriteString(25, field_names[26], OptionalCord); + } + if (hasOptionalPublicImportMessage) + { + output.WriteMessage(26, field_names[40], OptionalPublicImportMessage); + } + if (hasOptionalLazyMessage) + { + output.WriteMessage(27, field_names[37], OptionalLazyMessage); + } + if (repeatedInt32_.Count > 0) + { + output.WriteInt32Array(31, field_names[61], repeatedInt32_); + } + if (repeatedInt64_.Count > 0) + { + output.WriteInt64Array(32, field_names[62], repeatedInt64_); + } + if (repeatedUint32_.Count > 0) + { + output.WriteUInt32Array(33, field_names[72], repeatedUint32_); + } + if (repeatedUint64_.Count > 0) + { + output.WriteUInt64Array(34, field_names[73], repeatedUint64_); + } + if (repeatedSint32_.Count > 0) + { + output.WriteSInt32Array(35, field_names[68], repeatedSint32_); + } + if (repeatedSint64_.Count > 0) + { + output.WriteSInt64Array(36, field_names[69], repeatedSint64_); + } + if (repeatedFixed32_.Count > 0) + { + output.WriteFixed32Array(37, field_names[54], repeatedFixed32_); + } + if (repeatedFixed64_.Count > 0) + { + output.WriteFixed64Array(38, field_names[55], repeatedFixed64_); + } + if (repeatedSfixed32_.Count > 0) + { + output.WriteSFixed32Array(39, field_names[66], repeatedSfixed32_); + } + if (repeatedSfixed64_.Count > 0) + { + output.WriteSFixed64Array(40, field_names[67], repeatedSfixed64_); + } + if (repeatedFloat_.Count > 0) + { + output.WriteFloatArray(41, field_names[56], repeatedFloat_); + } + if (repeatedDouble_.Count > 0) + { + output.WriteDoubleArray(42, field_names[53], repeatedDouble_); + } + if (repeatedBool_.Count > 0) + { + output.WriteBoolArray(43, field_names[50], repeatedBool_); + } + if (repeatedString_.Count > 0) + { + output.WriteStringArray(44, field_names[70], repeatedString_); + } + if (repeatedBytes_.Count > 0) + { + output.WriteBytesArray(45, field_names[51], repeatedBytes_); + } + if (repeatedGroup_.Count > 0) + { + output.WriteGroupArray(46, field_names[74], repeatedGroup_); + } + if (repeatedNestedMessage_.Count > 0) + { + output.WriteMessageArray(48, field_names[65], repeatedNestedMessage_); + } + if (repeatedForeignMessage_.Count > 0) + { + output.WriteMessageArray(49, field_names[58], repeatedForeignMessage_); + } + if (repeatedImportMessage_.Count > 0) + { + output.WriteMessageArray(50, field_names[60], repeatedImportMessage_); + } + if (repeatedNestedEnum_.Count > 0) + { + output.WriteEnumArray(51, field_names[64], repeatedNestedEnum_); + } + if (repeatedForeignEnum_.Count > 0) + { + output.WriteEnumArray(52, field_names[57], repeatedForeignEnum_); + } + if (repeatedImportEnum_.Count > 0) + { + output.WriteEnumArray(53, field_names[59], repeatedImportEnum_); + } + if (repeatedStringPiece_.Count > 0) + { + output.WriteStringArray(54, field_names[71], repeatedStringPiece_); + } + if (repeatedCord_.Count > 0) + { + output.WriteStringArray(55, field_names[52], repeatedCord_); + } + if (repeatedLazyMessage_.Count > 0) + { + output.WriteMessageArray(57, field_names[63], repeatedLazyMessage_); + } + if (hasDefaultInt32) + { + output.WriteInt32(61, field_names[9], DefaultInt32); + } + if (hasDefaultInt64) + { + output.WriteInt64(62, field_names[10], DefaultInt64); + } + if (hasDefaultUint32) + { + output.WriteUInt32(63, field_names[18], DefaultUint32); + } + if (hasDefaultUint64) + { + output.WriteUInt64(64, field_names[19], DefaultUint64); + } + if (hasDefaultSint32) + { + output.WriteSInt32(65, field_names[14], DefaultSint32); + } + if (hasDefaultSint64) + { + output.WriteSInt64(66, field_names[15], DefaultSint64); + } + if (hasDefaultFixed32) + { + output.WriteFixed32(67, field_names[4], DefaultFixed32); + } + if (hasDefaultFixed64) + { + output.WriteFixed64(68, field_names[5], DefaultFixed64); + } + if (hasDefaultSfixed32) + { + output.WriteSFixed32(69, field_names[12], DefaultSfixed32); + } + if (hasDefaultSfixed64) + { + output.WriteSFixed64(70, field_names[13], DefaultSfixed64); + } + if (hasDefaultFloat) + { + output.WriteFloat(71, field_names[6], DefaultFloat); + } + if (hasDefaultDouble) + { + output.WriteDouble(72, field_names[3], DefaultDouble); + } + if (hasDefaultBool) + { + output.WriteBool(73, field_names[0], DefaultBool); + } + if (hasDefaultString) + { + output.WriteString(74, field_names[16], DefaultString); + } + if (hasDefaultBytes) + { + output.WriteBytes(75, field_names[1], DefaultBytes); + } + if (hasDefaultNestedEnum) + { + output.WriteEnum(81, field_names[11], (int)DefaultNestedEnum, DefaultNestedEnum); + } + if (hasDefaultForeignEnum) + { + output.WriteEnum(82, field_names[7], (int)DefaultForeignEnum, DefaultForeignEnum); + } + if (hasDefaultImportEnum) + { + output.WriteEnum(83, field_names[8], (int)DefaultImportEnum, DefaultImportEnum); + } + if (hasDefaultStringPiece) + { + output.WriteString(84, field_names[17], DefaultStringPiece); + } + if (hasDefaultCord) + { + output.WriteString(85, field_names[2], DefaultCord); + } + if (hasOneofUint32) + { + output.WriteUInt32(111, field_names[23], OneofUint32); + } + if (hasOneofNestedMessage) + { + output.WriteMessage(112, field_names[21], OneofNestedMessage); + } + if (hasOneofString) + { + output.WriteString(113, field_names[22], OneofString); + } + if (hasOneofBytes) + { + output.WriteBytes(114, field_names[20], OneofBytes); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOptionalInt32) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, OptionalInt32); + } + if (hasOptionalInt64) + { + size += pb::CodedOutputStream.ComputeInt64Size(2, OptionalInt64); + } + if (hasOptionalUint32) + { + size += pb::CodedOutputStream.ComputeUInt32Size(3, OptionalUint32); + } + if (hasOptionalUint64) + { + size += pb::CodedOutputStream.ComputeUInt64Size(4, OptionalUint64); + } + if (hasOptionalSint32) + { + size += pb::CodedOutputStream.ComputeSInt32Size(5, OptionalSint32); + } + if (hasOptionalSint64) + { + size += pb::CodedOutputStream.ComputeSInt64Size(6, OptionalSint64); + } + if (hasOptionalFixed32) + { + size += pb::CodedOutputStream.ComputeFixed32Size(7, OptionalFixed32); + } + if (hasOptionalFixed64) + { + size += pb::CodedOutputStream.ComputeFixed64Size(8, OptionalFixed64); + } + if (hasOptionalSfixed32) + { + size += pb::CodedOutputStream.ComputeSFixed32Size(9, OptionalSfixed32); + } + if (hasOptionalSfixed64) + { + size += pb::CodedOutputStream.ComputeSFixed64Size(10, OptionalSfixed64); + } + if (hasOptionalFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(11, OptionalFloat); + } + if (hasOptionalDouble) + { + size += pb::CodedOutputStream.ComputeDoubleSize(12, OptionalDouble); + } + if (hasOptionalBool) + { + size += pb::CodedOutputStream.ComputeBoolSize(13, OptionalBool); + } + if (hasOptionalString) + { + size += pb::CodedOutputStream.ComputeStringSize(14, OptionalString); + } + if (hasOptionalBytes) + { + size += pb::CodedOutputStream.ComputeBytesSize(15, OptionalBytes); + } + if (hasOptionalGroup) + { + size += pb::CodedOutputStream.ComputeGroupSize(16, OptionalGroup); + } + if (hasOptionalNestedMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(18, OptionalNestedMessage); + } + if (hasOptionalForeignMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(19, OptionalForeignMessage); + } + if (hasOptionalImportMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(20, OptionalImportMessage); + } + if (hasOptionalNestedEnum) + { + size += pb::CodedOutputStream.ComputeEnumSize(21, (int)OptionalNestedEnum); + } + if (hasOptionalForeignEnum) + { + size += pb::CodedOutputStream.ComputeEnumSize(22, (int)OptionalForeignEnum); + } + if (hasOptionalImportEnum) + { + size += pb::CodedOutputStream.ComputeEnumSize(23, (int)OptionalImportEnum); + } + if (hasOptionalStringPiece) + { + size += pb::CodedOutputStream.ComputeStringSize(24, OptionalStringPiece); + } + if (hasOptionalCord) + { + size += pb::CodedOutputStream.ComputeStringSize(25, OptionalCord); + } + if (hasOptionalPublicImportMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(26, OptionalPublicImportMessage); + } + if (hasOptionalLazyMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(27, OptionalLazyMessage); + } + { + int dataSize = 0; + foreach (int element in RepeatedInt32List) + { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedInt32_.Count; + } + { + int dataSize = 0; + foreach (long element in RepeatedInt64List) + { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedInt64_.Count; + } + { + int dataSize = 0; + foreach (uint element in RepeatedUint32List) + { + dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedUint32_.Count; + } + { + int dataSize = 0; + foreach (ulong element in RepeatedUint64List) + { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedUint64_.Count; + } + { + int dataSize = 0; + foreach (int element in RepeatedSint32List) + { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedSint32_.Count; + } + { + int dataSize = 0; + foreach (long element in RepeatedSint64List) + { + dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedSint64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedFixed32_.Count; + size += dataSize; + size += 2 * repeatedFixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedFixed64_.Count; + size += dataSize; + size += 2 * repeatedFixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedSfixed32_.Count; + size += dataSize; + size += 2 * repeatedSfixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedSfixed64_.Count; + size += dataSize; + size += 2 * repeatedSfixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedFloat_.Count; + size += dataSize; + size += 2 * repeatedFloat_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedDouble_.Count; + size += dataSize; + size += 2 * repeatedDouble_.Count; + } + { + int dataSize = 0; + dataSize = 1 * repeatedBool_.Count; + size += dataSize; + size += 2 * repeatedBool_.Count; + } + { + int dataSize = 0; + foreach (string element in RepeatedStringList) + { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedString_.Count; + } + { + int dataSize = 0; + foreach (pb::ByteString element in RepeatedBytesList) + { + dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedBytes_.Count; + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup element in RepeatedGroupList) + { + size += pb::CodedOutputStream.ComputeGroupSize(46, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage element in RepeatedNestedMessageList) + { + size += pb::CodedOutputStream.ComputeMessageSize(48, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedForeignMessageList) + { + size += pb::CodedOutputStream.ComputeMessageSize(49, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.ImportMessage element in RepeatedImportMessageList) + { + size += pb::CodedOutputStream.ComputeMessageSize(50, element); + } + { + int dataSize = 0; + if (repeatedNestedEnum_.Count > 0) + { + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum element in repeatedNestedEnum_) + { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int)element); + } + size += dataSize; + size += 2 * repeatedNestedEnum_.Count; + } + } + { + int dataSize = 0; + if (repeatedForeignEnum_.Count > 0) + { + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedForeignEnum_) + { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int)element); + } + size += dataSize; + size += 2 * repeatedForeignEnum_.Count; + } + } + { + int dataSize = 0; + if (repeatedImportEnum_.Count > 0) + { + foreach (global::Google.ProtocolBuffers.TestProtos.ImportEnum element in repeatedImportEnum_) + { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int)element); + } + size += dataSize; + size += 2 * repeatedImportEnum_.Count; + } + } + { + int dataSize = 0; + foreach (string element in RepeatedStringPieceList) + { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedStringPiece_.Count; + } + { + int dataSize = 0; + foreach (string element in RepeatedCordList) + { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedCord_.Count; + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage element in RepeatedLazyMessageList) + { + size += pb::CodedOutputStream.ComputeMessageSize(57, element); + } + if (hasDefaultInt32) + { + size += pb::CodedOutputStream.ComputeInt32Size(61, DefaultInt32); + } + if (hasDefaultInt64) + { + size += pb::CodedOutputStream.ComputeInt64Size(62, DefaultInt64); + } + if (hasDefaultUint32) + { + size += pb::CodedOutputStream.ComputeUInt32Size(63, DefaultUint32); + } + if (hasDefaultUint64) + { + size += pb::CodedOutputStream.ComputeUInt64Size(64, DefaultUint64); + } + if (hasDefaultSint32) + { + size += pb::CodedOutputStream.ComputeSInt32Size(65, DefaultSint32); + } + if (hasDefaultSint64) + { + size += pb::CodedOutputStream.ComputeSInt64Size(66, DefaultSint64); + } + if (hasDefaultFixed32) + { + size += pb::CodedOutputStream.ComputeFixed32Size(67, DefaultFixed32); + } + if (hasDefaultFixed64) + { + size += pb::CodedOutputStream.ComputeFixed64Size(68, DefaultFixed64); + } + if (hasDefaultSfixed32) + { + size += pb::CodedOutputStream.ComputeSFixed32Size(69, DefaultSfixed32); + } + if (hasDefaultSfixed64) + { + size += pb::CodedOutputStream.ComputeSFixed64Size(70, DefaultSfixed64); + } + if (hasDefaultFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(71, DefaultFloat); + } + if (hasDefaultDouble) + { + size += pb::CodedOutputStream.ComputeDoubleSize(72, DefaultDouble); + } + if (hasDefaultBool) + { + size += pb::CodedOutputStream.ComputeBoolSize(73, DefaultBool); + } + if (hasDefaultString) + { + size += pb::CodedOutputStream.ComputeStringSize(74, DefaultString); + } + if (hasDefaultBytes) + { + size += pb::CodedOutputStream.ComputeBytesSize(75, DefaultBytes); + } + if (hasDefaultNestedEnum) + { + size += pb::CodedOutputStream.ComputeEnumSize(81, (int)DefaultNestedEnum); + } + if (hasDefaultForeignEnum) + { + size += pb::CodedOutputStream.ComputeEnumSize(82, (int)DefaultForeignEnum); + } + if (hasDefaultImportEnum) + { + size += pb::CodedOutputStream.ComputeEnumSize(83, (int)DefaultImportEnum); + } + if (hasDefaultStringPiece) + { + size += pb::CodedOutputStream.ComputeStringSize(84, DefaultStringPiece); + } + if (hasDefaultCord) + { + size += pb::CodedOutputStream.ComputeStringSize(85, DefaultCord); + } + if (hasOneofUint32) + { + size += pb::CodedOutputStream.ComputeUInt32Size(111, OneofUint32); + } + if (hasOneofNestedMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(112, OneofNestedMessage); + } + if (hasOneofString) + { + size += pb::CodedOutputStream.ComputeStringSize(113, OneofString); + } + if (hasOneofBytes) + { + size += pb::CodedOutputStream.ComputeBytesSize(114, OneofBytes); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestAllTypes ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllTypes ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllTypes ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestAllTypes ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestAllTypes MakeReadOnly() + { + repeatedInt32_.MakeReadOnly(); + repeatedInt64_.MakeReadOnly(); + repeatedUint32_.MakeReadOnly(); + repeatedUint64_.MakeReadOnly(); + repeatedSint32_.MakeReadOnly(); + repeatedSint64_.MakeReadOnly(); + repeatedFixed32_.MakeReadOnly(); + repeatedFixed64_.MakeReadOnly(); + repeatedSfixed32_.MakeReadOnly(); + repeatedSfixed64_.MakeReadOnly(); + repeatedFloat_.MakeReadOnly(); + repeatedDouble_.MakeReadOnly(); + repeatedBool_.MakeReadOnly(); + repeatedString_.MakeReadOnly(); + repeatedBytes_.MakeReadOnly(); + repeatedGroup_.MakeReadOnly(); + repeatedNestedMessage_.MakeReadOnly(); + repeatedForeignMessage_.MakeReadOnly(); + repeatedImportMessage_.MakeReadOnly(); + repeatedNestedEnum_.MakeReadOnly(); + repeatedForeignEnum_.MakeReadOnly(); + repeatedImportEnum_.MakeReadOnly(); + repeatedStringPiece_.MakeReadOnly(); + repeatedCord_.MakeReadOnly(); + repeatedLazyMessage_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestAllTypes prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestAllTypes cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestAllTypes result; + + private TestAllTypes PrepareBuilder() + { + if (resultIsReadOnly) + { + TestAllTypes original = result; + result = new TestAllTypes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestAllTypes MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor; } + } + + public override TestAllTypes DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override TestAllTypes BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestAllTypes) + { + return MergeFrom((TestAllTypes)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestAllTypes other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOptionalInt32) + { + OptionalInt32 = other.OptionalInt32; + } + if (other.HasOptionalInt64) + { + OptionalInt64 = other.OptionalInt64; + } + if (other.HasOptionalUint32) + { + OptionalUint32 = other.OptionalUint32; + } + if (other.HasOptionalUint64) + { + OptionalUint64 = other.OptionalUint64; + } + if (other.HasOptionalSint32) + { + OptionalSint32 = other.OptionalSint32; + } + if (other.HasOptionalSint64) + { + OptionalSint64 = other.OptionalSint64; + } + if (other.HasOptionalFixed32) + { + OptionalFixed32 = other.OptionalFixed32; + } + if (other.HasOptionalFixed64) + { + OptionalFixed64 = other.OptionalFixed64; + } + if (other.HasOptionalSfixed32) + { + OptionalSfixed32 = other.OptionalSfixed32; + } + if (other.HasOptionalSfixed64) + { + OptionalSfixed64 = other.OptionalSfixed64; + } + if (other.HasOptionalFloat) + { + OptionalFloat = other.OptionalFloat; + } + if (other.HasOptionalDouble) + { + OptionalDouble = other.OptionalDouble; + } + if (other.HasOptionalBool) + { + OptionalBool = other.OptionalBool; + } + if (other.HasOptionalString) + { + OptionalString = other.OptionalString; + } + if (other.HasOptionalBytes) + { + OptionalBytes = other.OptionalBytes; + } + if (other.HasOptionalGroup) + { + MergeOptionalGroup(other.OptionalGroup); + } + if (other.HasOptionalNestedMessage) + { + MergeOptionalNestedMessage(other.OptionalNestedMessage); + } + if (other.HasOptionalForeignMessage) + { + MergeOptionalForeignMessage(other.OptionalForeignMessage); + } + if (other.HasOptionalImportMessage) + { + MergeOptionalImportMessage(other.OptionalImportMessage); + } + if (other.HasOptionalNestedEnum) + { + OptionalNestedEnum = other.OptionalNestedEnum; + } + if (other.HasOptionalForeignEnum) + { + OptionalForeignEnum = other.OptionalForeignEnum; + } + if (other.HasOptionalImportEnum) + { + OptionalImportEnum = other.OptionalImportEnum; + } + if (other.HasOptionalStringPiece) + { + OptionalStringPiece = other.OptionalStringPiece; + } + if (other.HasOptionalCord) + { + OptionalCord = other.OptionalCord; + } + if (other.HasOptionalPublicImportMessage) + { + MergeOptionalPublicImportMessage(other.OptionalPublicImportMessage); + } + if (other.HasOptionalLazyMessage) + { + MergeOptionalLazyMessage(other.OptionalLazyMessage); + } + if (other.repeatedInt32_.Count != 0) + { + result.repeatedInt32_.Add(other.repeatedInt32_); + } + if (other.repeatedInt64_.Count != 0) + { + result.repeatedInt64_.Add(other.repeatedInt64_); + } + if (other.repeatedUint32_.Count != 0) + { + result.repeatedUint32_.Add(other.repeatedUint32_); + } + if (other.repeatedUint64_.Count != 0) + { + result.repeatedUint64_.Add(other.repeatedUint64_); + } + if (other.repeatedSint32_.Count != 0) + { + result.repeatedSint32_.Add(other.repeatedSint32_); + } + if (other.repeatedSint64_.Count != 0) + { + result.repeatedSint64_.Add(other.repeatedSint64_); + } + if (other.repeatedFixed32_.Count != 0) + { + result.repeatedFixed32_.Add(other.repeatedFixed32_); + } + if (other.repeatedFixed64_.Count != 0) + { + result.repeatedFixed64_.Add(other.repeatedFixed64_); + } + if (other.repeatedSfixed32_.Count != 0) + { + result.repeatedSfixed32_.Add(other.repeatedSfixed32_); + } + if (other.repeatedSfixed64_.Count != 0) + { + result.repeatedSfixed64_.Add(other.repeatedSfixed64_); + } + if (other.repeatedFloat_.Count != 0) + { + result.repeatedFloat_.Add(other.repeatedFloat_); + } + if (other.repeatedDouble_.Count != 0) + { + result.repeatedDouble_.Add(other.repeatedDouble_); + } + if (other.repeatedBool_.Count != 0) + { + result.repeatedBool_.Add(other.repeatedBool_); + } + if (other.repeatedString_.Count != 0) + { + result.repeatedString_.Add(other.repeatedString_); + } + if (other.repeatedBytes_.Count != 0) + { + result.repeatedBytes_.Add(other.repeatedBytes_); + } + if (other.repeatedGroup_.Count != 0) + { + result.repeatedGroup_.Add(other.repeatedGroup_); + } + if (other.repeatedNestedMessage_.Count != 0) + { + result.repeatedNestedMessage_.Add(other.repeatedNestedMessage_); + } + if (other.repeatedForeignMessage_.Count != 0) + { + result.repeatedForeignMessage_.Add(other.repeatedForeignMessage_); + } + if (other.repeatedImportMessage_.Count != 0) + { + result.repeatedImportMessage_.Add(other.repeatedImportMessage_); + } + if (other.repeatedNestedEnum_.Count != 0) + { + result.repeatedNestedEnum_.Add(other.repeatedNestedEnum_); + } + if (other.repeatedForeignEnum_.Count != 0) + { + result.repeatedForeignEnum_.Add(other.repeatedForeignEnum_); + } + if (other.repeatedImportEnum_.Count != 0) + { + result.repeatedImportEnum_.Add(other.repeatedImportEnum_); + } + if (other.repeatedStringPiece_.Count != 0) + { + result.repeatedStringPiece_.Add(other.repeatedStringPiece_); + } + if (other.repeatedCord_.Count != 0) + { + result.repeatedCord_.Add(other.repeatedCord_); + } + if (other.repeatedLazyMessage_.Count != 0) + { + result.repeatedLazyMessage_.Add(other.repeatedLazyMessage_); + } + if (other.HasDefaultInt32) + { + DefaultInt32 = other.DefaultInt32; + } + if (other.HasDefaultInt64) + { + DefaultInt64 = other.DefaultInt64; + } + if (other.HasDefaultUint32) + { + DefaultUint32 = other.DefaultUint32; + } + if (other.HasDefaultUint64) + { + DefaultUint64 = other.DefaultUint64; + } + if (other.HasDefaultSint32) + { + DefaultSint32 = other.DefaultSint32; + } + if (other.HasDefaultSint64) + { + DefaultSint64 = other.DefaultSint64; + } + if (other.HasDefaultFixed32) + { + DefaultFixed32 = other.DefaultFixed32; + } + if (other.HasDefaultFixed64) + { + DefaultFixed64 = other.DefaultFixed64; + } + if (other.HasDefaultSfixed32) + { + DefaultSfixed32 = other.DefaultSfixed32; + } + if (other.HasDefaultSfixed64) + { + DefaultSfixed64 = other.DefaultSfixed64; + } + if (other.HasDefaultFloat) + { + DefaultFloat = other.DefaultFloat; + } + if (other.HasDefaultDouble) + { + DefaultDouble = other.DefaultDouble; + } + if (other.HasDefaultBool) + { + DefaultBool = other.DefaultBool; + } + if (other.HasDefaultString) + { + DefaultString = other.DefaultString; + } + if (other.HasDefaultBytes) + { + DefaultBytes = other.DefaultBytes; + } + if (other.HasDefaultNestedEnum) + { + DefaultNestedEnum = other.DefaultNestedEnum; + } + if (other.HasDefaultForeignEnum) + { + DefaultForeignEnum = other.DefaultForeignEnum; + } + if (other.HasDefaultImportEnum) + { + DefaultImportEnum = other.DefaultImportEnum; + } + if (other.HasDefaultStringPiece) + { + DefaultStringPiece = other.DefaultStringPiece; + } + if (other.HasDefaultCord) + { + DefaultCord = other.DefaultCord; + } + if (other.HasOneofUint32) + { + OneofUint32 = other.OneofUint32; + } + if (other.HasOneofNestedMessage) + { + MergeOneofNestedMessage(other.OneofNestedMessage); + } + if (other.HasOneofString) + { + OneofString = other.OneofString; + } + if (other.HasOneofBytes) + { + OneofBytes = other.OneofBytes; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testAllTypesFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testAllTypesFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); + break; + } + case 16: + { + result.hasOptionalInt64 = input.ReadInt64(ref result.optionalInt64_); + break; + } + case 24: + { + result.hasOptionalUint32 = input.ReadUInt32(ref result.optionalUint32_); + break; + } + case 32: + { + result.hasOptionalUint64 = input.ReadUInt64(ref result.optionalUint64_); + break; + } + case 40: + { + result.hasOptionalSint32 = input.ReadSInt32(ref result.optionalSint32_); + break; + } + case 48: + { + result.hasOptionalSint64 = input.ReadSInt64(ref result.optionalSint64_); + break; + } + case 61: + { + result.hasOptionalFixed32 = input.ReadFixed32(ref result.optionalFixed32_); + break; + } + case 65: + { + result.hasOptionalFixed64 = input.ReadFixed64(ref result.optionalFixed64_); + break; + } + case 77: + { + result.hasOptionalSfixed32 = input.ReadSFixed32(ref result.optionalSfixed32_); + break; + } + case 81: + { + result.hasOptionalSfixed64 = input.ReadSFixed64(ref result.optionalSfixed64_); + break; + } + case 93: + { + result.hasOptionalFloat = input.ReadFloat(ref result.optionalFloat_); + break; + } + case 97: + { + result.hasOptionalDouble = input.ReadDouble(ref result.optionalDouble_); + break; + } + case 104: + { + result.hasOptionalBool = input.ReadBool(ref result.optionalBool_); + break; + } + case 114: + { + result.hasOptionalString = input.ReadString(ref result.optionalString_); + break; + } + case 122: + { + result.hasOptionalBytes = input.ReadBytes(ref result.optionalBytes_); + break; + } + case 131: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.CreateBuilder(); + if (result.hasOptionalGroup) + { + subBuilder.MergeFrom(OptionalGroup); + } + input.ReadGroup(16, subBuilder, extensionRegistry); + OptionalGroup = subBuilder.BuildPartial(); + break; + } + case 146: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); + if (result.hasOptionalNestedMessage) + { + subBuilder.MergeFrom(OptionalNestedMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalNestedMessage = subBuilder.BuildPartial(); + break; + } + case 154: + { + global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); + if (result.hasOptionalForeignMessage) + { + subBuilder.MergeFrom(OptionalForeignMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalForeignMessage = subBuilder.BuildPartial(); + break; + } + case 162: + { + global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder(); + if (result.hasOptionalImportMessage) + { + subBuilder.MergeFrom(OptionalImportMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalImportMessage = subBuilder.BuildPartial(); + break; + } + case 168: + { + object unknown; + if (input.ReadEnum(ref result.optionalNestedEnum_, out unknown)) + { + result.hasOptionalNestedEnum = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(21, (ulong)(int)unknown); + } + break; + } + case 176: + { + object unknown; + if (input.ReadEnum(ref result.optionalForeignEnum_, out unknown)) + { + result.hasOptionalForeignEnum = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(22, (ulong)(int)unknown); + } + break; + } + case 184: + { + object unknown; + if (input.ReadEnum(ref result.optionalImportEnum_, out unknown)) + { + result.hasOptionalImportEnum = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(23, (ulong)(int)unknown); + } + break; + } + case 194: + { + result.hasOptionalStringPiece = input.ReadString(ref result.optionalStringPiece_); + break; + } + case 202: + { + result.hasOptionalCord = input.ReadString(ref result.optionalCord_); + break; + } + case 210: + { + global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.CreateBuilder(); + if (result.hasOptionalPublicImportMessage) + { + subBuilder.MergeFrom(OptionalPublicImportMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalPublicImportMessage = subBuilder.BuildPartial(); + break; + } + case 218: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); + if (result.hasOptionalLazyMessage) + { + subBuilder.MergeFrom(OptionalLazyMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalLazyMessage = subBuilder.BuildPartial(); + break; + } + case 250: + case 248: + { + input.ReadInt32Array(tag, field_name, result.repeatedInt32_); + break; + } + case 258: + case 256: + { + input.ReadInt64Array(tag, field_name, result.repeatedInt64_); + break; + } + case 266: + case 264: + { + input.ReadUInt32Array(tag, field_name, result.repeatedUint32_); + break; + } + case 274: + case 272: + { + input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); + break; + } + case 282: + case 280: + { + input.ReadSInt32Array(tag, field_name, result.repeatedSint32_); + break; + } + case 290: + case 288: + { + input.ReadSInt64Array(tag, field_name, result.repeatedSint64_); + break; + } + case 298: + case 301: + { + input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); + break; + } + case 306: + case 305: + { + input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); + break; + } + case 314: + case 317: + { + input.ReadSFixed32Array(tag, field_name, result.repeatedSfixed32_); + break; + } + case 322: + case 321: + { + input.ReadSFixed64Array(tag, field_name, result.repeatedSfixed64_); + break; + } + case 330: + case 333: + { + input.ReadFloatArray(tag, field_name, result.repeatedFloat_); + break; + } + case 338: + case 337: + { + input.ReadDoubleArray(tag, field_name, result.repeatedDouble_); + break; + } + case 346: + case 344: + { + input.ReadBoolArray(tag, field_name, result.repeatedBool_); + break; + } + case 354: + { + input.ReadStringArray(tag, field_name, result.repeatedString_); + break; + } + case 362: + { + input.ReadBytesArray(tag, field_name, result.repeatedBytes_); + break; + } + case 371: + { + input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance, extensionRegistry); + break; + } + case 386: + { + input.ReadMessageArray(tag, field_name, result.repeatedNestedMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance, extensionRegistry); + break; + } + case 394: + { + input.ReadMessageArray(tag, field_name, result.repeatedForeignMessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); + break; + } + case 402: + { + input.ReadMessageArray(tag, field_name, result.repeatedImportMessage_, global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance, extensionRegistry); + break; + } + case 410: + case 408: + { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedNestedEnum_, out unknownItems); + if (unknownItems != null) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(51, (ulong)(int)rawValue); + } + break; + } + case 418: + case 416: + { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedForeignEnum_, out unknownItems); + if (unknownItems != null) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(52, (ulong)(int)rawValue); + } + break; + } + case 426: + case 424: + { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedImportEnum_, out unknownItems); + if (unknownItems != null) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(53, (ulong)(int)rawValue); + } + break; + } + case 434: + { + input.ReadStringArray(tag, field_name, result.repeatedStringPiece_); + break; + } + case 442: + { + input.ReadStringArray(tag, field_name, result.repeatedCord_); + break; + } + case 458: + { + input.ReadMessageArray(tag, field_name, result.repeatedLazyMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance, extensionRegistry); + break; + } + case 488: + { + result.hasDefaultInt32 = input.ReadInt32(ref result.defaultInt32_); + break; + } + case 496: + { + result.hasDefaultInt64 = input.ReadInt64(ref result.defaultInt64_); + break; + } + case 504: + { + result.hasDefaultUint32 = input.ReadUInt32(ref result.defaultUint32_); + break; + } + case 512: + { + result.hasDefaultUint64 = input.ReadUInt64(ref result.defaultUint64_); + break; + } + case 520: + { + result.hasDefaultSint32 = input.ReadSInt32(ref result.defaultSint32_); + break; + } + case 528: + { + result.hasDefaultSint64 = input.ReadSInt64(ref result.defaultSint64_); + break; + } + case 541: + { + result.hasDefaultFixed32 = input.ReadFixed32(ref result.defaultFixed32_); + break; + } + case 545: + { + result.hasDefaultFixed64 = input.ReadFixed64(ref result.defaultFixed64_); + break; + } + case 557: + { + result.hasDefaultSfixed32 = input.ReadSFixed32(ref result.defaultSfixed32_); + break; + } + case 561: + { + result.hasDefaultSfixed64 = input.ReadSFixed64(ref result.defaultSfixed64_); + break; + } + case 573: + { + result.hasDefaultFloat = input.ReadFloat(ref result.defaultFloat_); + break; + } + case 577: + { + result.hasDefaultDouble = input.ReadDouble(ref result.defaultDouble_); + break; + } + case 584: + { + result.hasDefaultBool = input.ReadBool(ref result.defaultBool_); + break; + } + case 594: + { + result.hasDefaultString = input.ReadString(ref result.defaultString_); + break; + } + case 602: + { + result.hasDefaultBytes = input.ReadBytes(ref result.defaultBytes_); + break; + } + case 648: + { + object unknown; + if (input.ReadEnum(ref result.defaultNestedEnum_, out unknown)) + { + result.hasDefaultNestedEnum = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(81, (ulong)(int)unknown); + } + break; + } + case 656: + { + object unknown; + if (input.ReadEnum(ref result.defaultForeignEnum_, out unknown)) + { + result.hasDefaultForeignEnum = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(82, (ulong)(int)unknown); + } + break; + } + case 664: + { + object unknown; + if (input.ReadEnum(ref result.defaultImportEnum_, out unknown)) + { + result.hasDefaultImportEnum = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(83, (ulong)(int)unknown); + } + break; + } + case 674: + { + result.hasDefaultStringPiece = input.ReadString(ref result.defaultStringPiece_); + break; + } + case 682: + { + result.hasDefaultCord = input.ReadString(ref result.defaultCord_); + break; + } + case 888: + { + result.hasOneofUint32 = input.ReadUInt32(ref result.oneofUint32_); + break; + } + case 898: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); + if (result.hasOneofNestedMessage) + { + subBuilder.MergeFrom(OneofNestedMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OneofNestedMessage = subBuilder.BuildPartial(); + break; + } + case 906: + { + result.hasOneofString = input.ReadString(ref result.oneofString_); + break; + } + case 914: + { + result.hasOneofBytes = input.ReadBytes(ref result.oneofBytes_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasOptionalInt32 + { + get { return result.hasOptionalInt32; } + } + public int OptionalInt32 + { + get { return result.OptionalInt32; } + set { SetOptionalInt32(value); } + } + public Builder SetOptionalInt32(int value) + { + PrepareBuilder(); + result.hasOptionalInt32 = true; + result.optionalInt32_ = value; + return this; + } + public Builder ClearOptionalInt32() + { + PrepareBuilder(); + result.hasOptionalInt32 = false; + result.optionalInt32_ = 0; + return this; + } + + public bool HasOptionalInt64 + { + get { return result.hasOptionalInt64; } + } + public long OptionalInt64 + { + get { return result.OptionalInt64; } + set { SetOptionalInt64(value); } + } + public Builder SetOptionalInt64(long value) + { + PrepareBuilder(); + result.hasOptionalInt64 = true; + result.optionalInt64_ = value; + return this; + } + public Builder ClearOptionalInt64() + { + PrepareBuilder(); + result.hasOptionalInt64 = false; + result.optionalInt64_ = 0L; + return this; + } + + public bool HasOptionalUint32 + { + get { return result.hasOptionalUint32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalUint32 + { + get { return result.OptionalUint32; } + set { SetOptionalUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalUint32(uint value) + { + PrepareBuilder(); + result.hasOptionalUint32 = true; + result.optionalUint32_ = value; + return this; + } + public Builder ClearOptionalUint32() + { + PrepareBuilder(); + result.hasOptionalUint32 = false; + result.optionalUint32_ = 0; + return this; + } + + public bool HasOptionalUint64 + { + get { return result.hasOptionalUint64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalUint64 + { + get { return result.OptionalUint64; } + set { SetOptionalUint64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalUint64(ulong value) + { + PrepareBuilder(); + result.hasOptionalUint64 = true; + result.optionalUint64_ = value; + return this; + } + public Builder ClearOptionalUint64() + { + PrepareBuilder(); + result.hasOptionalUint64 = false; + result.optionalUint64_ = 0UL; + return this; + } + + public bool HasOptionalSint32 + { + get { return result.hasOptionalSint32; } + } + public int OptionalSint32 + { + get { return result.OptionalSint32; } + set { SetOptionalSint32(value); } + } + public Builder SetOptionalSint32(int value) + { + PrepareBuilder(); + result.hasOptionalSint32 = true; + result.optionalSint32_ = value; + return this; + } + public Builder ClearOptionalSint32() + { + PrepareBuilder(); + result.hasOptionalSint32 = false; + result.optionalSint32_ = 0; + return this; + } + + public bool HasOptionalSint64 + { + get { return result.hasOptionalSint64; } + } + public long OptionalSint64 + { + get { return result.OptionalSint64; } + set { SetOptionalSint64(value); } + } + public Builder SetOptionalSint64(long value) + { + PrepareBuilder(); + result.hasOptionalSint64 = true; + result.optionalSint64_ = value; + return this; + } + public Builder ClearOptionalSint64() + { + PrepareBuilder(); + result.hasOptionalSint64 = false; + result.optionalSint64_ = 0L; + return this; + } + + public bool HasOptionalFixed32 + { + get { return result.hasOptionalFixed32; } + } + [global::System.CLSCompliant(false)] + public uint OptionalFixed32 + { + get { return result.OptionalFixed32; } + set { SetOptionalFixed32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalFixed32(uint value) + { + PrepareBuilder(); + result.hasOptionalFixed32 = true; + result.optionalFixed32_ = value; + return this; + } + public Builder ClearOptionalFixed32() + { + PrepareBuilder(); + result.hasOptionalFixed32 = false; + result.optionalFixed32_ = 0; + return this; + } + + public bool HasOptionalFixed64 + { + get { return result.hasOptionalFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong OptionalFixed64 + { + get { return result.OptionalFixed64; } + set { SetOptionalFixed64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOptionalFixed64(ulong value) + { + PrepareBuilder(); + result.hasOptionalFixed64 = true; + result.optionalFixed64_ = value; + return this; + } + public Builder ClearOptionalFixed64() + { + PrepareBuilder(); + result.hasOptionalFixed64 = false; + result.optionalFixed64_ = 0UL; + return this; + } + + public bool HasOptionalSfixed32 + { + get { return result.hasOptionalSfixed32; } + } + public int OptionalSfixed32 + { + get { return result.OptionalSfixed32; } + set { SetOptionalSfixed32(value); } + } + public Builder SetOptionalSfixed32(int value) + { + PrepareBuilder(); + result.hasOptionalSfixed32 = true; + result.optionalSfixed32_ = value; + return this; + } + public Builder ClearOptionalSfixed32() + { + PrepareBuilder(); + result.hasOptionalSfixed32 = false; + result.optionalSfixed32_ = 0; + return this; + } + + public bool HasOptionalSfixed64 + { + get { return result.hasOptionalSfixed64; } + } + public long OptionalSfixed64 + { + get { return result.OptionalSfixed64; } + set { SetOptionalSfixed64(value); } + } + public Builder SetOptionalSfixed64(long value) + { + PrepareBuilder(); + result.hasOptionalSfixed64 = true; + result.optionalSfixed64_ = value; + return this; + } + public Builder ClearOptionalSfixed64() + { + PrepareBuilder(); + result.hasOptionalSfixed64 = false; + result.optionalSfixed64_ = 0L; + return this; + } + + public bool HasOptionalFloat + { + get { return result.hasOptionalFloat; } + } + public float OptionalFloat + { + get { return result.OptionalFloat; } + set { SetOptionalFloat(value); } + } + public Builder SetOptionalFloat(float value) + { + PrepareBuilder(); + result.hasOptionalFloat = true; + result.optionalFloat_ = value; + return this; + } + public Builder ClearOptionalFloat() + { + PrepareBuilder(); + result.hasOptionalFloat = false; + result.optionalFloat_ = 0F; + return this; + } + + public bool HasOptionalDouble + { + get { return result.hasOptionalDouble; } + } + public double OptionalDouble + { + get { return result.OptionalDouble; } + set { SetOptionalDouble(value); } + } + public Builder SetOptionalDouble(double value) + { + PrepareBuilder(); + result.hasOptionalDouble = true; + result.optionalDouble_ = value; + return this; + } + public Builder ClearOptionalDouble() + { + PrepareBuilder(); + result.hasOptionalDouble = false; + result.optionalDouble_ = 0D; + return this; + } + + public bool HasOptionalBool + { + get { return result.hasOptionalBool; } + } + public bool OptionalBool + { + get { return result.OptionalBool; } + set { SetOptionalBool(value); } + } + public Builder SetOptionalBool(bool value) + { + PrepareBuilder(); + result.hasOptionalBool = true; + result.optionalBool_ = value; + return this; + } + public Builder ClearOptionalBool() + { + PrepareBuilder(); + result.hasOptionalBool = false; + result.optionalBool_ = false; + return this; + } + + public bool HasOptionalString + { + get { return result.hasOptionalString; } + } + public string OptionalString + { + get { return result.OptionalString; } + set { SetOptionalString(value); } + } + public Builder SetOptionalString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalString = true; + result.optionalString_ = value; + return this; + } + public Builder ClearOptionalString() + { + PrepareBuilder(); + result.hasOptionalString = false; + result.optionalString_ = ""; + return this; + } + + public bool HasOptionalBytes + { + get { return result.hasOptionalBytes; } + } + public pb::ByteString OptionalBytes + { + get { return result.OptionalBytes; } + set { SetOptionalBytes(value); } + } + public Builder SetOptionalBytes(pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalBytes = true; + result.optionalBytes_ = value; + return this; + } + public Builder ClearOptionalBytes() + { + PrepareBuilder(); + result.hasOptionalBytes = false; + result.optionalBytes_ = pb::ByteString.Empty; + return this; + } + + public bool HasOptionalGroup + { + get { return result.hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup OptionalGroup + { + get { return result.OptionalGroup; } + set { SetOptionalGroup(value); } + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = value; + return this; + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalGroup && + result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance) + { + result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalGroup_ = value; + } + result.hasOptionalGroup = true; + return this; + } + public Builder ClearOptionalGroup() + { + PrepareBuilder(); + result.hasOptionalGroup = false; + result.optionalGroup_ = null; + return this; + } + + public bool HasOptionalNestedMessage + { + get { return result.hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage + { + get { return result.OptionalNestedMessage; } + set { SetOptionalNestedMessage(value); } + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = value; + return this; + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalNestedMessage && + result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) + { + result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalNestedMessage_ = value; + } + result.hasOptionalNestedMessage = true; + return this; + } + public Builder ClearOptionalNestedMessage() + { + PrepareBuilder(); + result.hasOptionalNestedMessage = false; + result.optionalNestedMessage_ = null; + return this; + } + + public bool HasOptionalForeignMessage + { + get { return result.hasOptionalForeignMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage + { + get { return result.OptionalForeignMessage; } + set { SetOptionalForeignMessage(value); } + } + public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalForeignMessage = true; + result.optionalForeignMessage_ = value; + return this; + } + public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalForeignMessage = true; + result.optionalForeignMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalForeignMessage && + result.optionalForeignMessage_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) + { + result.optionalForeignMessage_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.optionalForeignMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalForeignMessage_ = value; + } + result.hasOptionalForeignMessage = true; + return this; + } + public Builder ClearOptionalForeignMessage() + { + PrepareBuilder(); + result.hasOptionalForeignMessage = false; + result.optionalForeignMessage_ = null; + return this; + } + + public bool HasOptionalImportMessage + { + get { return result.hasOptionalImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessage OptionalImportMessage + { + get { return result.OptionalImportMessage; } + set { SetOptionalImportMessage(value); } + } + public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalImportMessage = true; + result.optionalImportMessage_ = value; + return this; + } + public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalImportMessage = true; + result.optionalImportMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalImportMessage && + result.optionalImportMessage_ != global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance) + { + result.optionalImportMessage_ = global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder(result.optionalImportMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalImportMessage_ = value; + } + result.hasOptionalImportMessage = true; + return this; + } + public Builder ClearOptionalImportMessage() + { + PrepareBuilder(); + result.hasOptionalImportMessage = false; + result.optionalImportMessage_ = null; + return this; + } + + public bool HasOptionalNestedEnum + { + get { return result.hasOptionalNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum + { + get { return result.OptionalNestedEnum; } + set { SetOptionalNestedEnum(value); } + } + public Builder SetOptionalNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) + { + PrepareBuilder(); + result.hasOptionalNestedEnum = true; + result.optionalNestedEnum_ = value; + return this; + } + public Builder ClearOptionalNestedEnum() + { + PrepareBuilder(); + result.hasOptionalNestedEnum = false; + result.optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; + return this; + } + + public bool HasOptionalForeignEnum + { + get { return result.hasOptionalForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum + { + get { return result.OptionalForeignEnum; } + set { SetOptionalForeignEnum(value); } + } + public Builder SetOptionalForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.hasOptionalForeignEnum = true; + result.optionalForeignEnum_ = value; + return this; + } + public Builder ClearOptionalForeignEnum() + { + PrepareBuilder(); + result.hasOptionalForeignEnum = false; + result.optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + return this; + } + + public bool HasOptionalImportEnum + { + get { return result.hasOptionalImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum OptionalImportEnum + { + get { return result.OptionalImportEnum; } + set { SetOptionalImportEnum(value); } + } + public Builder SetOptionalImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) + { + PrepareBuilder(); + result.hasOptionalImportEnum = true; + result.optionalImportEnum_ = value; + return this; + } + public Builder ClearOptionalImportEnum() + { + PrepareBuilder(); + result.hasOptionalImportEnum = false; + result.optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_FOO; + return this; + } + + public bool HasOptionalStringPiece + { + get { return result.hasOptionalStringPiece; } + } + public string OptionalStringPiece + { + get { return result.OptionalStringPiece; } + set { SetOptionalStringPiece(value); } + } + public Builder SetOptionalStringPiece(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalStringPiece = true; + result.optionalStringPiece_ = value; + return this; + } + public Builder ClearOptionalStringPiece() + { + PrepareBuilder(); + result.hasOptionalStringPiece = false; + result.optionalStringPiece_ = ""; + return this; + } + + public bool HasOptionalCord + { + get { return result.hasOptionalCord; } + } + public string OptionalCord + { + get { return result.OptionalCord; } + set { SetOptionalCord(value); } + } + public Builder SetOptionalCord(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalCord = true; + result.optionalCord_ = value; + return this; + } + public Builder ClearOptionalCord() + { + PrepareBuilder(); + result.hasOptionalCord = false; + result.optionalCord_ = ""; + return this; + } + + public bool HasOptionalPublicImportMessage + { + get { return result.hasOptionalPublicImportMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.PublicImportMessage OptionalPublicImportMessage + { + get { return result.OptionalPublicImportMessage; } + set { SetOptionalPublicImportMessage(value); } + } + public Builder SetOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalPublicImportMessage = true; + result.optionalPublicImportMessage_ = value; + return this; + } + public Builder SetOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalPublicImportMessage = true; + result.optionalPublicImportMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalPublicImportMessage(global::Google.ProtocolBuffers.TestProtos.PublicImportMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalPublicImportMessage && + result.optionalPublicImportMessage_ != global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.DefaultInstance) + { + result.optionalPublicImportMessage_ = global::Google.ProtocolBuffers.TestProtos.PublicImportMessage.CreateBuilder(result.optionalPublicImportMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalPublicImportMessage_ = value; + } + result.hasOptionalPublicImportMessage = true; + return this; + } + public Builder ClearOptionalPublicImportMessage() + { + PrepareBuilder(); + result.hasOptionalPublicImportMessage = false; + result.optionalPublicImportMessage_ = null; + return this; + } + + public bool HasOptionalLazyMessage + { + get { return result.hasOptionalLazyMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalLazyMessage + { + get { return result.OptionalLazyMessage; } + set { SetOptionalLazyMessage(value); } + } + public Builder SetOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalLazyMessage = true; + result.optionalLazyMessage_ = value; + return this; + } + public Builder SetOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalLazyMessage = true; + result.optionalLazyMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalLazyMessage && + result.optionalLazyMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) + { + result.optionalLazyMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.optionalLazyMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalLazyMessage_ = value; + } + result.hasOptionalLazyMessage = true; + return this; + } + public Builder ClearOptionalLazyMessage() + { + PrepareBuilder(); + result.hasOptionalLazyMessage = false; + result.optionalLazyMessage_ = null; + return this; + } + + public pbc::IPopsicleList RepeatedInt32List + { + get { return PrepareBuilder().repeatedInt32_; } + } + public int RepeatedInt32Count + { + get { return result.RepeatedInt32Count; } + } + public int GetRepeatedInt32(int index) + { + return result.GetRepeatedInt32(index); + } + public Builder SetRepeatedInt32(int index, int value) + { + PrepareBuilder(); + result.repeatedInt32_[index] = value; + return this; + } + public Builder AddRepeatedInt32(int value) + { + PrepareBuilder(); + result.repeatedInt32_.Add(value); + return this; + } + public Builder AddRangeRepeatedInt32(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedInt32_.Add(values); + return this; + } + public Builder ClearRepeatedInt32() + { + PrepareBuilder(); + result.repeatedInt32_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedInt64List + { + get { return PrepareBuilder().repeatedInt64_; } + } + public int RepeatedInt64Count + { + get { return result.RepeatedInt64Count; } + } + public long GetRepeatedInt64(int index) + { + return result.GetRepeatedInt64(index); + } + public Builder SetRepeatedInt64(int index, long value) + { + PrepareBuilder(); + result.repeatedInt64_[index] = value; + return this; + } + public Builder AddRepeatedInt64(long value) + { + PrepareBuilder(); + result.repeatedInt64_.Add(value); + return this; + } + public Builder AddRangeRepeatedInt64(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedInt64_.Add(values); + return this; + } + public Builder ClearRepeatedInt64() + { + PrepareBuilder(); + result.repeatedInt64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedUint32List + { + get { return PrepareBuilder().repeatedUint32_; } + } + public int RepeatedUint32Count + { + get { return result.RepeatedUint32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedUint32(int index) + { + return result.GetRepeatedUint32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedUint32(int index, uint value) + { + PrepareBuilder(); + result.repeatedUint32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedUint32(uint value) + { + PrepareBuilder(); + result.repeatedUint32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedUint32(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedUint32_.Add(values); + return this; + } + public Builder ClearRepeatedUint32() + { + PrepareBuilder(); + result.repeatedUint32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedUint64List + { + get { return PrepareBuilder().repeatedUint64_; } + } + public int RepeatedUint64Count + { + get { return result.RepeatedUint64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedUint64(int index) + { + return result.GetRepeatedUint64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedUint64(int index, ulong value) + { + PrepareBuilder(); + result.repeatedUint64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedUint64(ulong value) + { + PrepareBuilder(); + result.repeatedUint64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedUint64(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedUint64_.Add(values); + return this; + } + public Builder ClearRepeatedUint64() + { + PrepareBuilder(); + result.repeatedUint64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSint32List + { + get { return PrepareBuilder().repeatedSint32_; } + } + public int RepeatedSint32Count + { + get { return result.RepeatedSint32Count; } + } + public int GetRepeatedSint32(int index) + { + return result.GetRepeatedSint32(index); + } + public Builder SetRepeatedSint32(int index, int value) + { + PrepareBuilder(); + result.repeatedSint32_[index] = value; + return this; + } + public Builder AddRepeatedSint32(int value) + { + PrepareBuilder(); + result.repeatedSint32_.Add(value); + return this; + } + public Builder AddRangeRepeatedSint32(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedSint32_.Add(values); + return this; + } + public Builder ClearRepeatedSint32() + { + PrepareBuilder(); + result.repeatedSint32_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSint64List + { + get { return PrepareBuilder().repeatedSint64_; } + } + public int RepeatedSint64Count + { + get { return result.RepeatedSint64Count; } + } + public long GetRepeatedSint64(int index) + { + return result.GetRepeatedSint64(index); + } + public Builder SetRepeatedSint64(int index, long value) + { + PrepareBuilder(); + result.repeatedSint64_[index] = value; + return this; + } + public Builder AddRepeatedSint64(long value) + { + PrepareBuilder(); + result.repeatedSint64_.Add(value); + return this; + } + public Builder AddRangeRepeatedSint64(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedSint64_.Add(values); + return this; + } + public Builder ClearRepeatedSint64() + { + PrepareBuilder(); + result.repeatedSint64_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedFixed32List + { + get { return PrepareBuilder().repeatedFixed32_; } + } + public int RepeatedFixed32Count + { + get { return result.RepeatedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedFixed32(int index) + { + return result.GetRepeatedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedFixed32(int index, uint value) + { + PrepareBuilder(); + result.repeatedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedFixed32(uint value) + { + PrepareBuilder(); + result.repeatedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedFixed32_.Add(values); + return this; + } + public Builder ClearRepeatedFixed32() + { + PrepareBuilder(); + result.repeatedFixed32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedFixed64List + { + get { return PrepareBuilder().repeatedFixed64_; } + } + public int RepeatedFixed64Count + { + get { return result.RepeatedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedFixed64(int index) + { + return result.GetRepeatedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedFixed64(int index, ulong value) + { + PrepareBuilder(); + result.repeatedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedFixed64(ulong value) + { + PrepareBuilder(); + result.repeatedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedFixed64_.Add(values); + return this; + } + public Builder ClearRepeatedFixed64() + { + PrepareBuilder(); + result.repeatedFixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSfixed32List + { + get { return PrepareBuilder().repeatedSfixed32_; } + } + public int RepeatedSfixed32Count + { + get { return result.RepeatedSfixed32Count; } + } + public int GetRepeatedSfixed32(int index) + { + return result.GetRepeatedSfixed32(index); + } + public Builder SetRepeatedSfixed32(int index, int value) + { + PrepareBuilder(); + result.repeatedSfixed32_[index] = value; + return this; + } + public Builder AddRepeatedSfixed32(int value) + { + PrepareBuilder(); + result.repeatedSfixed32_.Add(value); + return this; + } + public Builder AddRangeRepeatedSfixed32(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedSfixed32_.Add(values); + return this; + } + public Builder ClearRepeatedSfixed32() + { + PrepareBuilder(); + result.repeatedSfixed32_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedSfixed64List + { + get { return PrepareBuilder().repeatedSfixed64_; } + } + public int RepeatedSfixed64Count + { + get { return result.RepeatedSfixed64Count; } + } + public long GetRepeatedSfixed64(int index) + { + return result.GetRepeatedSfixed64(index); + } + public Builder SetRepeatedSfixed64(int index, long value) + { + PrepareBuilder(); + result.repeatedSfixed64_[index] = value; + return this; + } + public Builder AddRepeatedSfixed64(long value) + { + PrepareBuilder(); + result.repeatedSfixed64_.Add(value); + return this; + } + public Builder AddRangeRepeatedSfixed64(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedSfixed64_.Add(values); + return this; + } + public Builder ClearRepeatedSfixed64() + { + PrepareBuilder(); + result.repeatedSfixed64_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedFloatList + { + get { return PrepareBuilder().repeatedFloat_; } + } + public int RepeatedFloatCount + { + get { return result.RepeatedFloatCount; } + } + public float GetRepeatedFloat(int index) + { + return result.GetRepeatedFloat(index); + } + public Builder SetRepeatedFloat(int index, float value) + { + PrepareBuilder(); + result.repeatedFloat_[index] = value; + return this; + } + public Builder AddRepeatedFloat(float value) + { + PrepareBuilder(); + result.repeatedFloat_.Add(value); + return this; + } + public Builder AddRangeRepeatedFloat(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedFloat_.Add(values); + return this; + } + public Builder ClearRepeatedFloat() + { + PrepareBuilder(); + result.repeatedFloat_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedDoubleList + { + get { return PrepareBuilder().repeatedDouble_; } + } + public int RepeatedDoubleCount + { + get { return result.RepeatedDoubleCount; } + } + public double GetRepeatedDouble(int index) + { + return result.GetRepeatedDouble(index); + } + public Builder SetRepeatedDouble(int index, double value) + { + PrepareBuilder(); + result.repeatedDouble_[index] = value; + return this; + } + public Builder AddRepeatedDouble(double value) + { + PrepareBuilder(); + result.repeatedDouble_.Add(value); + return this; + } + public Builder AddRangeRepeatedDouble(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedDouble_.Add(values); + return this; + } + public Builder ClearRepeatedDouble() + { + PrepareBuilder(); + result.repeatedDouble_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedBoolList + { + get { return PrepareBuilder().repeatedBool_; } + } + public int RepeatedBoolCount + { + get { return result.RepeatedBoolCount; } + } + public bool GetRepeatedBool(int index) + { + return result.GetRepeatedBool(index); + } + public Builder SetRepeatedBool(int index, bool value) + { + PrepareBuilder(); + result.repeatedBool_[index] = value; + return this; + } + public Builder AddRepeatedBool(bool value) + { + PrepareBuilder(); + result.repeatedBool_.Add(value); + return this; + } + public Builder AddRangeRepeatedBool(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedBool_.Add(values); + return this; + } + public Builder ClearRepeatedBool() + { + PrepareBuilder(); + result.repeatedBool_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedStringList + { + get { return PrepareBuilder().repeatedString_; } + } + public int RepeatedStringCount + { + get { return result.RepeatedStringCount; } + } + public string GetRepeatedString(int index) + { + return result.GetRepeatedString(index); + } + public Builder SetRepeatedString(int index, string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedString_[index] = value; + return this; + } + public Builder AddRepeatedString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedString_.Add(value); + return this; + } + public Builder AddRangeRepeatedString(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedString_.Add(values); + return this; + } + public Builder ClearRepeatedString() + { + PrepareBuilder(); + result.repeatedString_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedBytesList + { + get { return PrepareBuilder().repeatedBytes_; } + } + public int RepeatedBytesCount + { + get { return result.RepeatedBytesCount; } + } + public pb::ByteString GetRepeatedBytes(int index) + { + return result.GetRepeatedBytes(index); + } + public Builder SetRepeatedBytes(int index, pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedBytes_[index] = value; + return this; + } + public Builder AddRepeatedBytes(pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedBytes_.Add(value); + return this; + } + public Builder AddRangeRepeatedBytes(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedBytes_.Add(values); + return this; + } + public Builder ClearRepeatedBytes() + { + PrepareBuilder(); + result.repeatedBytes_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedGroupList + { + get { return PrepareBuilder().repeatedGroup_; } + } + public int RepeatedGroupCount + { + get { return result.RepeatedGroupCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup GetRepeatedGroup(int index) + { + return result.GetRepeatedGroup(index); + } + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_[index] = value; + return this; + } + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_.Add(value); + return this; + } + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedGroup(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedGroup_.Add(values); + return this; + } + public Builder ClearRepeatedGroup() + { + PrepareBuilder(); + result.repeatedGroup_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedNestedMessageList + { + get { return PrepareBuilder().repeatedNestedMessage_; } + } + public int RepeatedNestedMessageCount + { + get { return result.RepeatedNestedMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) + { + return result.GetRepeatedNestedMessage(index); + } + public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedNestedMessage_[index] = value; + return this; + } + public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedNestedMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedNestedMessage_.Add(value); + return this; + } + public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedNestedMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedNestedMessage(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedNestedMessage_.Add(values); + return this; + } + public Builder ClearRepeatedNestedMessage() + { + PrepareBuilder(); + result.repeatedNestedMessage_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedForeignMessageList + { + get { return PrepareBuilder().repeatedForeignMessage_; } + } + public int RepeatedForeignMessageCount + { + get { return result.RepeatedForeignMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) + { + return result.GetRepeatedForeignMessage(index); + } + public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedForeignMessage_[index] = value; + return this; + } + public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedForeignMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedForeignMessage_.Add(value); + return this; + } + public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedForeignMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedForeignMessage(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedForeignMessage_.Add(values); + return this; + } + public Builder ClearRepeatedForeignMessage() + { + PrepareBuilder(); + result.repeatedForeignMessage_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedImportMessageList + { + get { return PrepareBuilder().repeatedImportMessage_; } + } + public int RepeatedImportMessageCount + { + get { return result.RepeatedImportMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportMessage GetRepeatedImportMessage(int index) + { + return result.GetRepeatedImportMessage(index); + } + public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedImportMessage_[index] = value; + return this; + } + public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedImportMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedImportMessage_.Add(value); + return this; + } + public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedImportMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedImportMessage(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedImportMessage_.Add(values); + return this; + } + public Builder ClearRepeatedImportMessage() + { + PrepareBuilder(); + result.repeatedImportMessage_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedNestedEnumList + { + get { return PrepareBuilder().repeatedNestedEnum_; } + } + public int RepeatedNestedEnumCount + { + get { return result.RepeatedNestedEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) + { + return result.GetRepeatedNestedEnum(index); + } + public Builder SetRepeatedNestedEnum(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) + { + PrepareBuilder(); + result.repeatedNestedEnum_[index] = value; + return this; + } + public Builder AddRepeatedNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) + { + PrepareBuilder(); + result.repeatedNestedEnum_.Add(value); + return this; + } + public Builder AddRangeRepeatedNestedEnum(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedNestedEnum_.Add(values); + return this; + } + public Builder ClearRepeatedNestedEnum() + { + PrepareBuilder(); + result.repeatedNestedEnum_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedForeignEnumList + { + get { return PrepareBuilder().repeatedForeignEnum_; } + } + public int RepeatedForeignEnumCount + { + get { return result.RepeatedForeignEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) + { + return result.GetRepeatedForeignEnum(index); + } + public Builder SetRepeatedForeignEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.repeatedForeignEnum_[index] = value; + return this; + } + public Builder AddRepeatedForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.repeatedForeignEnum_.Add(value); + return this; + } + public Builder AddRangeRepeatedForeignEnum(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedForeignEnum_.Add(values); + return this; + } + public Builder ClearRepeatedForeignEnum() + { + PrepareBuilder(); + result.repeatedForeignEnum_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedImportEnumList + { + get { return PrepareBuilder().repeatedImportEnum_; } + } + public int RepeatedImportEnumCount + { + get { return result.RepeatedImportEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum GetRepeatedImportEnum(int index) + { + return result.GetRepeatedImportEnum(index); + } + public Builder SetRepeatedImportEnum(int index, global::Google.ProtocolBuffers.TestProtos.ImportEnum value) + { + PrepareBuilder(); + result.repeatedImportEnum_[index] = value; + return this; + } + public Builder AddRepeatedImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) + { + PrepareBuilder(); + result.repeatedImportEnum_.Add(value); + return this; + } + public Builder AddRangeRepeatedImportEnum(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedImportEnum_.Add(values); + return this; + } + public Builder ClearRepeatedImportEnum() + { + PrepareBuilder(); + result.repeatedImportEnum_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedStringPieceList + { + get { return PrepareBuilder().repeatedStringPiece_; } + } + public int RepeatedStringPieceCount + { + get { return result.RepeatedStringPieceCount; } + } + public string GetRepeatedStringPiece(int index) + { + return result.GetRepeatedStringPiece(index); + } + public Builder SetRepeatedStringPiece(int index, string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringPiece_[index] = value; + return this; + } + public Builder AddRepeatedStringPiece(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringPiece_.Add(value); + return this; + } + public Builder AddRangeRepeatedStringPiece(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedStringPiece_.Add(values); + return this; + } + public Builder ClearRepeatedStringPiece() + { + PrepareBuilder(); + result.repeatedStringPiece_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedCordList + { + get { return PrepareBuilder().repeatedCord_; } + } + public int RepeatedCordCount + { + get { return result.RepeatedCordCount; } + } + public string GetRepeatedCord(int index) + { + return result.GetRepeatedCord(index); + } + public Builder SetRepeatedCord(int index, string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedCord_[index] = value; + return this; + } + public Builder AddRepeatedCord(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedCord_.Add(value); + return this; + } + public Builder AddRangeRepeatedCord(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedCord_.Add(values); + return this; + } + public Builder ClearRepeatedCord() + { + PrepareBuilder(); + result.repeatedCord_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedLazyMessageList + { + get { return PrepareBuilder().repeatedLazyMessage_; } + } + public int RepeatedLazyMessageCount + { + get { return result.RepeatedLazyMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedLazyMessage(int index) + { + return result.GetRepeatedLazyMessage(index); + } + public Builder SetRepeatedLazyMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedLazyMessage_[index] = value; + return this; + } + public Builder SetRepeatedLazyMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedLazyMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedLazyMessage_.Add(value); + return this; + } + public Builder AddRepeatedLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedLazyMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedLazyMessage(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedLazyMessage_.Add(values); + return this; + } + public Builder ClearRepeatedLazyMessage() + { + PrepareBuilder(); + result.repeatedLazyMessage_.Clear(); + return this; + } + + public bool HasDefaultInt32 + { + get { return result.hasDefaultInt32; } + } + public int DefaultInt32 + { + get { return result.DefaultInt32; } + set { SetDefaultInt32(value); } + } + public Builder SetDefaultInt32(int value) + { + PrepareBuilder(); + result.hasDefaultInt32 = true; + result.defaultInt32_ = value; + return this; + } + public Builder ClearDefaultInt32() + { + PrepareBuilder(); + result.hasDefaultInt32 = false; + result.defaultInt32_ = 41; + return this; + } + + public bool HasDefaultInt64 + { + get { return result.hasDefaultInt64; } + } + public long DefaultInt64 + { + get { return result.DefaultInt64; } + set { SetDefaultInt64(value); } + } + public Builder SetDefaultInt64(long value) + { + PrepareBuilder(); + result.hasDefaultInt64 = true; + result.defaultInt64_ = value; + return this; + } + public Builder ClearDefaultInt64() + { + PrepareBuilder(); + result.hasDefaultInt64 = false; + result.defaultInt64_ = 42L; + return this; + } + + public bool HasDefaultUint32 + { + get { return result.hasDefaultUint32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultUint32 + { + get { return result.DefaultUint32; } + set { SetDefaultUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultUint32(uint value) + { + PrepareBuilder(); + result.hasDefaultUint32 = true; + result.defaultUint32_ = value; + return this; + } + public Builder ClearDefaultUint32() + { + PrepareBuilder(); + result.hasDefaultUint32 = false; + result.defaultUint32_ = 43; + return this; + } + + public bool HasDefaultUint64 + { + get { return result.hasDefaultUint64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultUint64 + { + get { return result.DefaultUint64; } + set { SetDefaultUint64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultUint64(ulong value) + { + PrepareBuilder(); + result.hasDefaultUint64 = true; + result.defaultUint64_ = value; + return this; + } + public Builder ClearDefaultUint64() + { + PrepareBuilder(); + result.hasDefaultUint64 = false; + result.defaultUint64_ = 44UL; + return this; + } + + public bool HasDefaultSint32 + { + get { return result.hasDefaultSint32; } + } + public int DefaultSint32 + { + get { return result.DefaultSint32; } + set { SetDefaultSint32(value); } + } + public Builder SetDefaultSint32(int value) + { + PrepareBuilder(); + result.hasDefaultSint32 = true; + result.defaultSint32_ = value; + return this; + } + public Builder ClearDefaultSint32() + { + PrepareBuilder(); + result.hasDefaultSint32 = false; + result.defaultSint32_ = -45; + return this; + } + + public bool HasDefaultSint64 + { + get { return result.hasDefaultSint64; } + } + public long DefaultSint64 + { + get { return result.DefaultSint64; } + set { SetDefaultSint64(value); } + } + public Builder SetDefaultSint64(long value) + { + PrepareBuilder(); + result.hasDefaultSint64 = true; + result.defaultSint64_ = value; + return this; + } + public Builder ClearDefaultSint64() + { + PrepareBuilder(); + result.hasDefaultSint64 = false; + result.defaultSint64_ = 46L; + return this; + } + + public bool HasDefaultFixed32 + { + get { return result.hasDefaultFixed32; } + } + [global::System.CLSCompliant(false)] + public uint DefaultFixed32 + { + get { return result.DefaultFixed32; } + set { SetDefaultFixed32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultFixed32(uint value) + { + PrepareBuilder(); + result.hasDefaultFixed32 = true; + result.defaultFixed32_ = value; + return this; + } + public Builder ClearDefaultFixed32() + { + PrepareBuilder(); + result.hasDefaultFixed32 = false; + result.defaultFixed32_ = 47; + return this; + } + + public bool HasDefaultFixed64 + { + get { return result.hasDefaultFixed64; } + } + [global::System.CLSCompliant(false)] + public ulong DefaultFixed64 + { + get { return result.DefaultFixed64; } + set { SetDefaultFixed64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetDefaultFixed64(ulong value) + { + PrepareBuilder(); + result.hasDefaultFixed64 = true; + result.defaultFixed64_ = value; + return this; + } + public Builder ClearDefaultFixed64() + { + PrepareBuilder(); + result.hasDefaultFixed64 = false; + result.defaultFixed64_ = 48UL; + return this; + } + + public bool HasDefaultSfixed32 + { + get { return result.hasDefaultSfixed32; } + } + public int DefaultSfixed32 + { + get { return result.DefaultSfixed32; } + set { SetDefaultSfixed32(value); } + } + public Builder SetDefaultSfixed32(int value) + { + PrepareBuilder(); + result.hasDefaultSfixed32 = true; + result.defaultSfixed32_ = value; + return this; + } + public Builder ClearDefaultSfixed32() + { + PrepareBuilder(); + result.hasDefaultSfixed32 = false; + result.defaultSfixed32_ = 49; + return this; + } + + public bool HasDefaultSfixed64 + { + get { return result.hasDefaultSfixed64; } + } + public long DefaultSfixed64 + { + get { return result.DefaultSfixed64; } + set { SetDefaultSfixed64(value); } + } + public Builder SetDefaultSfixed64(long value) + { + PrepareBuilder(); + result.hasDefaultSfixed64 = true; + result.defaultSfixed64_ = value; + return this; + } + public Builder ClearDefaultSfixed64() + { + PrepareBuilder(); + result.hasDefaultSfixed64 = false; + result.defaultSfixed64_ = -50L; + return this; + } + + public bool HasDefaultFloat + { + get { return result.hasDefaultFloat; } + } + public float DefaultFloat + { + get { return result.DefaultFloat; } + set { SetDefaultFloat(value); } + } + public Builder SetDefaultFloat(float value) + { + PrepareBuilder(); + result.hasDefaultFloat = true; + result.defaultFloat_ = value; + return this; + } + public Builder ClearDefaultFloat() + { + PrepareBuilder(); + result.hasDefaultFloat = false; + result.defaultFloat_ = 51.5F; + return this; + } + + public bool HasDefaultDouble + { + get { return result.hasDefaultDouble; } + } + public double DefaultDouble + { + get { return result.DefaultDouble; } + set { SetDefaultDouble(value); } + } + public Builder SetDefaultDouble(double value) + { + PrepareBuilder(); + result.hasDefaultDouble = true; + result.defaultDouble_ = value; + return this; + } + public Builder ClearDefaultDouble() + { + PrepareBuilder(); + result.hasDefaultDouble = false; + result.defaultDouble_ = 52000D; + return this; + } + + public bool HasDefaultBool + { + get { return result.hasDefaultBool; } + } + public bool DefaultBool + { + get { return result.DefaultBool; } + set { SetDefaultBool(value); } + } + public Builder SetDefaultBool(bool value) + { + PrepareBuilder(); + result.hasDefaultBool = true; + result.defaultBool_ = value; + return this; + } + public Builder ClearDefaultBool() + { + PrepareBuilder(); + result.hasDefaultBool = false; + result.defaultBool_ = true; + return this; + } + + public bool HasDefaultString + { + get { return result.hasDefaultString; } + } + public string DefaultString + { + get { return result.DefaultString; } + set { SetDefaultString(value); } + } + public Builder SetDefaultString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultString = true; + result.defaultString_ = value; + return this; + } + public Builder ClearDefaultString() + { + PrepareBuilder(); + result.hasDefaultString = false; + result.defaultString_ = "hello"; + return this; + } + + public bool HasDefaultBytes + { + get { return result.hasDefaultBytes; } + } + public pb::ByteString DefaultBytes + { + get { return result.DefaultBytes; } + set { SetDefaultBytes(value); } + } + public Builder SetDefaultBytes(pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultBytes = true; + result.defaultBytes_ = value; + return this; + } + public Builder ClearDefaultBytes() + { + PrepareBuilder(); + result.hasDefaultBytes = false; + result.defaultBytes_ = (pb::ByteString)global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor.Fields[65].DefaultValue; + return this; + } + + public bool HasDefaultNestedEnum + { + get { return result.hasDefaultNestedEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum DefaultNestedEnum + { + get { return result.DefaultNestedEnum; } + set { SetDefaultNestedEnum(value); } + } + public Builder SetDefaultNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) + { + PrepareBuilder(); + result.hasDefaultNestedEnum = true; + result.defaultNestedEnum_ = value; + return this; + } + public Builder ClearDefaultNestedEnum() + { + PrepareBuilder(); + result.hasDefaultNestedEnum = false; + result.defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.BAR; + return this; + } + + public bool HasDefaultForeignEnum + { + get { return result.hasDefaultForeignEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum DefaultForeignEnum + { + get { return result.DefaultForeignEnum; } + set { SetDefaultForeignEnum(value); } + } + public Builder SetDefaultForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.hasDefaultForeignEnum = true; + result.defaultForeignEnum_ = value; + return this; + } + public Builder ClearDefaultForeignEnum() + { + PrepareBuilder(); + result.hasDefaultForeignEnum = false; + result.defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_BAR; + return this; + } + + public bool HasDefaultImportEnum + { + get { return result.hasDefaultImportEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.ImportEnum DefaultImportEnum + { + get { return result.DefaultImportEnum; } + set { SetDefaultImportEnum(value); } + } + public Builder SetDefaultImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) + { + PrepareBuilder(); + result.hasDefaultImportEnum = true; + result.defaultImportEnum_ = value; + return this; + } + public Builder ClearDefaultImportEnum() + { + PrepareBuilder(); + result.hasDefaultImportEnum = false; + result.defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_BAR; + return this; + } + + public bool HasDefaultStringPiece + { + get { return result.hasDefaultStringPiece; } + } + public string DefaultStringPiece + { + get { return result.DefaultStringPiece; } + set { SetDefaultStringPiece(value); } + } + public Builder SetDefaultStringPiece(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultStringPiece = true; + result.defaultStringPiece_ = value; + return this; + } + public Builder ClearDefaultStringPiece() + { + PrepareBuilder(); + result.hasDefaultStringPiece = false; + result.defaultStringPiece_ = "abc"; + return this; + } + + public bool HasDefaultCord + { + get { return result.hasDefaultCord; } + } + public string DefaultCord + { + get { return result.DefaultCord; } + set { SetDefaultCord(value); } + } + public Builder SetDefaultCord(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDefaultCord = true; + result.defaultCord_ = value; + return this; + } + public Builder ClearDefaultCord() + { + PrepareBuilder(); + result.hasDefaultCord = false; + result.defaultCord_ = "123"; + return this; + } + + public bool HasOneofUint32 + { + get { return result.hasOneofUint32; } + } + [global::System.CLSCompliant(false)] + public uint OneofUint32 + { + get { return result.OneofUint32; } + set { SetOneofUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetOneofUint32(uint value) + { + PrepareBuilder(); + result.hasOneofUint32 = true; + result.oneofUint32_ = value; + return this; + } + public Builder ClearOneofUint32() + { + PrepareBuilder(); + result.hasOneofUint32 = false; + result.oneofUint32_ = 0; + return this; + } + + public bool HasOneofNestedMessage + { + get { return result.hasOneofNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OneofNestedMessage + { + get { return result.OneofNestedMessage; } + set { SetOneofNestedMessage(value); } + } + public Builder SetOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOneofNestedMessage = true; + result.oneofNestedMessage_ = value; + return this; + } + public Builder SetOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOneofNestedMessage = true; + result.oneofNestedMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOneofNestedMessage && + result.oneofNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) + { + result.oneofNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.oneofNestedMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.oneofNestedMessage_ = value; + } + result.hasOneofNestedMessage = true; + return this; + } + public Builder ClearOneofNestedMessage() + { + PrepareBuilder(); + result.hasOneofNestedMessage = false; + result.oneofNestedMessage_ = null; + return this; + } + + public bool HasOneofString + { + get { return result.hasOneofString; } + } + public string OneofString + { + get { return result.OneofString; } + set { SetOneofString(value); } + } + public Builder SetOneofString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOneofString = true; + result.oneofString_ = value; + return this; + } + public Builder ClearOneofString() + { + PrepareBuilder(); + result.hasOneofString = false; + result.oneofString_ = ""; + return this; + } + + public bool HasOneofBytes + { + get { return result.hasOneofBytes; } + } + public pb::ByteString OneofBytes + { + get { return result.OneofBytes; } + set { SetOneofBytes(value); } + } + public Builder SetOneofBytes(pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOneofBytes = true; + result.oneofBytes_ = value; + return this; + } + public Builder ClearOneofBytes() + { + PrepareBuilder(); + result.hasOneofBytes = false; + result.oneofBytes_ = pb::ByteString.Empty; + return this; + } + } + static TestAllTypes() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedTestAllTypes : pb::GeneratedMessage + { + private NestedTestAllTypes() { } + private static readonly NestedTestAllTypes defaultInstance = new NestedTestAllTypes().MakeReadOnly(); + private static readonly string[] _nestedTestAllTypesFieldNames = new string[] { "child", "payload" }; + private static readonly uint[] _nestedTestAllTypesFieldTags = new uint[] { 10, 18 }; + public static NestedTestAllTypes DefaultInstance + { + get { return defaultInstance; } + } + + public override NestedTestAllTypes DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override NestedTestAllTypes ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_NestedTestAllTypes__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_NestedTestAllTypes__FieldAccessorTable; } + } + + public const int ChildFieldNumber = 1; + private bool hasChild; + private global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes child_; + public bool HasChild + { + get { return hasChild; } + } + public global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes Child + { + get { return child_ ?? global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance; } + } + + public const int PayloadFieldNumber = 2; + private bool hasPayload; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes payload_; + public bool HasPayload + { + get { return hasPayload; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Payload + { + get { return payload_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _nestedTestAllTypesFieldNames; + if (hasChild) + { + output.WriteMessage(1, field_names[0], Child); + } + if (hasPayload) + { + output.WriteMessage(2, field_names[1], Payload); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasChild) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, Child); + } + if (hasPayload) + { + size += pb::CodedOutputStream.ComputeMessageSize(2, Payload); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedTestAllTypes ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedTestAllTypes ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedTestAllTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedTestAllTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedTestAllTypes MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedTestAllTypes prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedTestAllTypes cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NestedTestAllTypes result; + + private NestedTestAllTypes PrepareBuilder() + { + if (resultIsReadOnly) + { + NestedTestAllTypes original = result; + result = new NestedTestAllTypes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override NestedTestAllTypes MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.Descriptor; } + } + + public override NestedTestAllTypes DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance; } + } + + public override NestedTestAllTypes BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is NestedTestAllTypes) + { + return MergeFrom((NestedTestAllTypes)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NestedTestAllTypes other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasChild) + { + MergeChild(other.Child); + } + if (other.HasPayload) + { + MergePayload(other.Payload); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_nestedTestAllTypesFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _nestedTestAllTypesFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.CreateBuilder(); + if (result.hasChild) + { + subBuilder.MergeFrom(Child); + } + input.ReadMessage(subBuilder, extensionRegistry); + Child = subBuilder.BuildPartial(); + break; + } + case 18: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasPayload) + { + subBuilder.MergeFrom(Payload); + } + input.ReadMessage(subBuilder, extensionRegistry); + Payload = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasChild + { + get { return result.hasChild; } + } + public global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes Child + { + get { return result.Child; } + set { SetChild(value); } + } + public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasChild = true; + result.child_ = value; + return this; + } + public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasChild = true; + result.child_ = builderForValue.Build(); + return this; + } + public Builder MergeChild(global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasChild && + result.child_ != global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.DefaultInstance) + { + result.child_ = global::Google.ProtocolBuffers.TestProtos.NestedTestAllTypes.CreateBuilder(result.child_).MergeFrom(value).BuildPartial(); + } + else + { + result.child_ = value; + } + result.hasChild = true; + return this; + } + public Builder ClearChild() + { + PrepareBuilder(); + result.hasChild = false; + result.child_ = null; + return this; + } + + public bool HasPayload + { + get { return result.hasPayload; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Payload + { + get { return result.Payload; } + set { SetPayload(value); } + } + public Builder SetPayload(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasPayload = true; + result.payload_ = value; + return this; + } + public Builder SetPayload(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasPayload = true; + result.payload_ = builderForValue.Build(); + return this; + } + public Builder MergePayload(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasPayload && + result.payload_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.payload_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.payload_).MergeFrom(value).BuildPartial(); + } + else + { + result.payload_ = value; + } + result.hasPayload = true; + return this; + } + public Builder ClearPayload() + { + PrepareBuilder(); + result.hasPayload = false; + result.payload_ = null; + return this; + } + } + static NestedTestAllTypes() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestDeprecatedFields : pb::GeneratedMessage + { + private TestDeprecatedFields() { } + private static readonly TestDeprecatedFields defaultInstance = new TestDeprecatedFields().MakeReadOnly(); + private static readonly string[] _testDeprecatedFieldsFieldNames = new string[] { "deprecated_int32" }; + private static readonly uint[] _testDeprecatedFieldsFieldTags = new uint[] { 8 }; + public static TestDeprecatedFields DefaultInstance + { + get { return defaultInstance; } + } + + public override TestDeprecatedFields DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestDeprecatedFields ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable; } + } + + public const int DeprecatedInt32FieldNumber = 1; + private bool hasDeprecatedInt32; + private int deprecatedInt32_; + [global::System.ObsoleteAttribute()] + public bool HasDeprecatedInt32 + { + get { return hasDeprecatedInt32; } + } + [global::System.ObsoleteAttribute()] + public int DeprecatedInt32 + { + get { return deprecatedInt32_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testDeprecatedFieldsFieldNames; + if (hasDeprecatedInt32) + { + output.WriteInt32(1, field_names[0], DeprecatedInt32); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasDeprecatedInt32) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, DeprecatedInt32); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestDeprecatedFields ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestDeprecatedFields ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestDeprecatedFields ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDeprecatedFields ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestDeprecatedFields MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestDeprecatedFields prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestDeprecatedFields cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestDeprecatedFields result; + + private TestDeprecatedFields PrepareBuilder() + { + if (resultIsReadOnly) + { + TestDeprecatedFields original = result; + result = new TestDeprecatedFields(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestDeprecatedFields MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.Descriptor; } + } + + public override TestDeprecatedFields DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.DefaultInstance; } + } + + public override TestDeprecatedFields BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestDeprecatedFields) + { + return MergeFrom((TestDeprecatedFields)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestDeprecatedFields other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasDeprecatedInt32) + { + DeprecatedInt32 = other.DeprecatedInt32; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testDeprecatedFieldsFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testDeprecatedFieldsFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasDeprecatedInt32 = input.ReadInt32(ref result.deprecatedInt32_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + [global::System.ObsoleteAttribute()] + public bool HasDeprecatedInt32 + { + get { return result.hasDeprecatedInt32; } + } + [global::System.ObsoleteAttribute()] + public int DeprecatedInt32 + { + get { return result.DeprecatedInt32; } + set { SetDeprecatedInt32(value); } + } + [global::System.ObsoleteAttribute()] + public Builder SetDeprecatedInt32(int value) + { + PrepareBuilder(); + result.hasDeprecatedInt32 = true; + result.deprecatedInt32_ = value; + return this; + } + [global::System.ObsoleteAttribute()] + public Builder ClearDeprecatedInt32() + { + PrepareBuilder(); + result.hasDeprecatedInt32 = false; + result.deprecatedInt32_ = 0; + return this; + } + } + static TestDeprecatedFields() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class ForeignMessage : pb::GeneratedMessage + { + private ForeignMessage() { } + private static readonly ForeignMessage defaultInstance = new ForeignMessage().MakeReadOnly(); + private static readonly string[] _foreignMessageFieldNames = new string[] { "c" }; + private static readonly uint[] _foreignMessageFieldTags = new uint[] { 8 }; + public static ForeignMessage DefaultInstance + { + get { return defaultInstance; } + } + + public override ForeignMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override ForeignMessage ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_ForeignMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable; } + } + + public const int CFieldNumber = 1; + private bool hasC; + private int c_; + public bool HasC + { + get { return hasC; } + } + public int C + { + get { return c_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _foreignMessageFieldNames; + if (hasC) + { + output.WriteInt32(1, field_names[0], C); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasC) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, C); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static ForeignMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ForeignMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ForeignMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static ForeignMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static ForeignMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ForeignMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static ForeignMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static ForeignMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private ForeignMessage MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(ForeignMessage prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(ForeignMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private ForeignMessage result; + + private ForeignMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + ForeignMessage original = result; + result = new ForeignMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override ForeignMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Descriptor; } + } + + public override ForeignMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } + } + + public override ForeignMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is ForeignMessage) + { + return MergeFrom((ForeignMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(ForeignMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasC) + { + C = other.C; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_foreignMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _foreignMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasC = input.ReadInt32(ref result.c_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasC + { + get { return result.hasC; } + } + public int C + { + get { return result.C; } + set { SetC(value); } + } + public Builder SetC(int value) + { + PrepareBuilder(); + result.hasC = true; + result.c_ = value; + return this; + } + public Builder ClearC() + { + PrepareBuilder(); + result.hasC = false; + result.c_ = 0; + return this; + } + } + static ForeignMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestAllExtensions : pb::ExtendableMessage + { + private TestAllExtensions() { } + private static readonly TestAllExtensions defaultInstance = new TestAllExtensions().MakeReadOnly(); + private static readonly string[] _testAllExtensionsFieldNames = new string[] { }; + private static readonly uint[] _testAllExtensionsFieldTags = new uint[] { }; + public static TestAllExtensions DefaultInstance + { + get { return defaultInstance; } + } + + public override TestAllExtensions DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestAllExtensions ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllExtensions__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable; } + } + + public override bool IsInitialized + { + get + { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testAllExtensionsFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestAllExtensions ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestAllExtensions ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestAllExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestAllExtensions ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestAllExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestAllExtensions MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestAllExtensions prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestAllExtensions cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestAllExtensions result; + + private TestAllExtensions PrepareBuilder() + { + if (resultIsReadOnly) + { + TestAllExtensions original = result; + result = new TestAllExtensions(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestAllExtensions MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.Descriptor; } + } + + public override TestAllExtensions DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.DefaultInstance; } + } + + public override TestAllExtensions BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestAllExtensions) + { + return MergeFrom((TestAllExtensions)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestAllExtensions other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testAllExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testAllExtensionsFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestAllExtensions() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OptionalGroup_extension : pb::GeneratedMessage + { + private OptionalGroup_extension() { } + private static readonly OptionalGroup_extension defaultInstance = new OptionalGroup_extension().MakeReadOnly(); + private static readonly string[] _optionalGroupExtensionFieldNames = new string[] { "a" }; + private static readonly uint[] _optionalGroupExtensionFieldTags = new uint[] { 136 }; + public static OptionalGroup_extension DefaultInstance + { + get { return defaultInstance; } + } + + public override OptionalGroup_extension DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override OptionalGroup_extension ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable; } + } + + public const int AFieldNumber = 17; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _optionalGroupExtensionFieldNames; + if (hasA) + { + output.WriteInt32(17, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(17, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static OptionalGroup_extension ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup_extension ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OptionalGroup_extension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup_extension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OptionalGroup_extension MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OptionalGroup_extension prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OptionalGroup_extension cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OptionalGroup_extension result; + + private OptionalGroup_extension PrepareBuilder() + { + if (resultIsReadOnly) + { + OptionalGroup_extension original = result; + result = new OptionalGroup_extension(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override OptionalGroup_extension MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.Descriptor; } + } + + public override OptionalGroup_extension DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.DefaultInstance; } + } + + public override OptionalGroup_extension BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is OptionalGroup_extension) + { + return MergeFrom((OptionalGroup_extension)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OptionalGroup_extension other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_optionalGroupExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _optionalGroupExtensionFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 136: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static OptionalGroup_extension() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedGroup_extension : pb::GeneratedMessage + { + private RepeatedGroup_extension() { } + private static readonly RepeatedGroup_extension defaultInstance = new RepeatedGroup_extension().MakeReadOnly(); + private static readonly string[] _repeatedGroupExtensionFieldNames = new string[] { "a" }; + private static readonly uint[] _repeatedGroupExtensionFieldTags = new uint[] { 376 }; + public static RepeatedGroup_extension DefaultInstance + { + get { return defaultInstance; } + } + + public override RepeatedGroup_extension DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override RepeatedGroup_extension ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable; } + } + + public const int AFieldNumber = 47; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _repeatedGroupExtensionFieldNames; + if (hasA) + { + output.WriteInt32(47, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(47, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static RepeatedGroup_extension ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup_extension ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedGroup_extension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup_extension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedGroup_extension MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedGroup_extension prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedGroup_extension cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private RepeatedGroup_extension result; + + private RepeatedGroup_extension PrepareBuilder() + { + if (resultIsReadOnly) + { + RepeatedGroup_extension original = result; + result = new RepeatedGroup_extension(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override RepeatedGroup_extension MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.Descriptor; } + } + + public override RepeatedGroup_extension DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.DefaultInstance; } + } + + public override RepeatedGroup_extension BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is RepeatedGroup_extension) + { + return MergeFrom((RepeatedGroup_extension)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(RepeatedGroup_extension other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _repeatedGroupExtensionFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 376: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static RepeatedGroup_extension() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestNestedExtension : pb::GeneratedMessage + { + private TestNestedExtension() { } + private static readonly TestNestedExtension defaultInstance = new TestNestedExtension().MakeReadOnly(); + private static readonly string[] _testNestedExtensionFieldNames = new string[] { }; + private static readonly uint[] _testNestedExtensionFieldTags = new uint[] { }; + public static TestNestedExtension DefaultInstance + { + get { return defaultInstance; } + } + + public override TestNestedExtension DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestNestedExtension ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedExtension__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable; } + } + + public const int TestFieldNumber = 1002; + public static pb::GeneratedExtensionBase Test; + public const int NestedStringExtensionFieldNumber = 1003; + public static pb::GeneratedExtensionBase NestedStringExtension; + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testNestedExtensionFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestNestedExtension ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestNestedExtension ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestNestedExtension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestNestedExtension ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestNestedExtension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestNestedExtension MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestNestedExtension prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestNestedExtension cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestNestedExtension result; + + private TestNestedExtension PrepareBuilder() + { + if (resultIsReadOnly) + { + TestNestedExtension original = result; + result = new TestNestedExtension(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestNestedExtension MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor; } + } + + public override TestNestedExtension DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.DefaultInstance; } + } + + public override TestNestedExtension BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestNestedExtension) + { + return MergeFrom((TestNestedExtension)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestNestedExtension other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testNestedExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testNestedExtensionFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestNestedExtension() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestRequired : pb::GeneratedMessage + { + private TestRequired() { } + private static readonly TestRequired defaultInstance = new TestRequired().MakeReadOnly(); + private static readonly string[] _testRequiredFieldNames = new string[] { "a", "b", "c", "dummy10", "dummy11", "dummy12", "dummy13", "dummy14", "dummy15", "dummy16", "dummy17", "dummy18", "dummy19", "dummy2", "dummy20", "dummy21", "dummy22", "dummy23", "dummy24", "dummy25", "dummy26", "dummy27", "dummy28", "dummy29", "dummy30", "dummy31", "dummy32", "dummy4", "dummy5", "dummy6", "dummy7", "dummy8", "dummy9" }; + private static readonly uint[] _testRequiredFieldTags = new uint[] { 8, 24, 264, 80, 88, 96, 104, 112, 120, 128, 136, 144, 152, 16, 160, 168, 176, 184, 192, 200, 208, 216, 224, 232, 240, 248, 256, 32, 40, 48, 56, 64, 72 }; + public static TestRequired DefaultInstance + { + get { return defaultInstance; } + } + + public override TestRequired DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestRequired ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequired__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequired__FieldAccessorTable; } + } + + public const int SingleFieldNumber = 1000; + public static pb::GeneratedExtensionBase Single; + public const int MultiFieldNumber = 1001; + public static pb::GeneratedExtensionBase> Multi; + public const int AFieldNumber = 1; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } + + public const int Dummy2FieldNumber = 2; + private bool hasDummy2; + private int dummy2_; + public bool HasDummy2 + { + get { return hasDummy2; } + } + public int Dummy2 + { + get { return dummy2_; } + } + + public const int BFieldNumber = 3; + private bool hasB; + private int b_; + public bool HasB + { + get { return hasB; } + } + public int B + { + get { return b_; } + } + + public const int Dummy4FieldNumber = 4; + private bool hasDummy4; + private int dummy4_; + public bool HasDummy4 + { + get { return hasDummy4; } + } + public int Dummy4 + { + get { return dummy4_; } + } + + public const int Dummy5FieldNumber = 5; + private bool hasDummy5; + private int dummy5_; + public bool HasDummy5 + { + get { return hasDummy5; } + } + public int Dummy5 + { + get { return dummy5_; } + } + + public const int Dummy6FieldNumber = 6; + private bool hasDummy6; + private int dummy6_; + public bool HasDummy6 + { + get { return hasDummy6; } + } + public int Dummy6 + { + get { return dummy6_; } + } + + public const int Dummy7FieldNumber = 7; + private bool hasDummy7; + private int dummy7_; + public bool HasDummy7 + { + get { return hasDummy7; } + } + public int Dummy7 + { + get { return dummy7_; } + } + + public const int Dummy8FieldNumber = 8; + private bool hasDummy8; + private int dummy8_; + public bool HasDummy8 + { + get { return hasDummy8; } + } + public int Dummy8 + { + get { return dummy8_; } + } + + public const int Dummy9FieldNumber = 9; + private bool hasDummy9; + private int dummy9_; + public bool HasDummy9 + { + get { return hasDummy9; } + } + public int Dummy9 + { + get { return dummy9_; } + } + + public const int Dummy10FieldNumber = 10; + private bool hasDummy10; + private int dummy10_; + public bool HasDummy10 + { + get { return hasDummy10; } + } + public int Dummy10 + { + get { return dummy10_; } + } + + public const int Dummy11FieldNumber = 11; + private bool hasDummy11; + private int dummy11_; + public bool HasDummy11 + { + get { return hasDummy11; } + } + public int Dummy11 + { + get { return dummy11_; } + } + + public const int Dummy12FieldNumber = 12; + private bool hasDummy12; + private int dummy12_; + public bool HasDummy12 + { + get { return hasDummy12; } + } + public int Dummy12 + { + get { return dummy12_; } + } + + public const int Dummy13FieldNumber = 13; + private bool hasDummy13; + private int dummy13_; + public bool HasDummy13 + { + get { return hasDummy13; } + } + public int Dummy13 + { + get { return dummy13_; } + } + + public const int Dummy14FieldNumber = 14; + private bool hasDummy14; + private int dummy14_; + public bool HasDummy14 + { + get { return hasDummy14; } + } + public int Dummy14 + { + get { return dummy14_; } + } + + public const int Dummy15FieldNumber = 15; + private bool hasDummy15; + private int dummy15_; + public bool HasDummy15 + { + get { return hasDummy15; } + } + public int Dummy15 + { + get { return dummy15_; } + } + + public const int Dummy16FieldNumber = 16; + private bool hasDummy16; + private int dummy16_; + public bool HasDummy16 + { + get { return hasDummy16; } + } + public int Dummy16 + { + get { return dummy16_; } + } + + public const int Dummy17FieldNumber = 17; + private bool hasDummy17; + private int dummy17_; + public bool HasDummy17 + { + get { return hasDummy17; } + } + public int Dummy17 + { + get { return dummy17_; } + } + + public const int Dummy18FieldNumber = 18; + private bool hasDummy18; + private int dummy18_; + public bool HasDummy18 + { + get { return hasDummy18; } + } + public int Dummy18 + { + get { return dummy18_; } + } + + public const int Dummy19FieldNumber = 19; + private bool hasDummy19; + private int dummy19_; + public bool HasDummy19 + { + get { return hasDummy19; } + } + public int Dummy19 + { + get { return dummy19_; } + } + + public const int Dummy20FieldNumber = 20; + private bool hasDummy20; + private int dummy20_; + public bool HasDummy20 + { + get { return hasDummy20; } + } + public int Dummy20 + { + get { return dummy20_; } + } + + public const int Dummy21FieldNumber = 21; + private bool hasDummy21; + private int dummy21_; + public bool HasDummy21 + { + get { return hasDummy21; } + } + public int Dummy21 + { + get { return dummy21_; } + } + + public const int Dummy22FieldNumber = 22; + private bool hasDummy22; + private int dummy22_; + public bool HasDummy22 + { + get { return hasDummy22; } + } + public int Dummy22 + { + get { return dummy22_; } + } + + public const int Dummy23FieldNumber = 23; + private bool hasDummy23; + private int dummy23_; + public bool HasDummy23 + { + get { return hasDummy23; } + } + public int Dummy23 + { + get { return dummy23_; } + } + + public const int Dummy24FieldNumber = 24; + private bool hasDummy24; + private int dummy24_; + public bool HasDummy24 + { + get { return hasDummy24; } + } + public int Dummy24 + { + get { return dummy24_; } + } + + public const int Dummy25FieldNumber = 25; + private bool hasDummy25; + private int dummy25_; + public bool HasDummy25 + { + get { return hasDummy25; } + } + public int Dummy25 + { + get { return dummy25_; } + } + + public const int Dummy26FieldNumber = 26; + private bool hasDummy26; + private int dummy26_; + public bool HasDummy26 + { + get { return hasDummy26; } + } + public int Dummy26 + { + get { return dummy26_; } + } + + public const int Dummy27FieldNumber = 27; + private bool hasDummy27; + private int dummy27_; + public bool HasDummy27 + { + get { return hasDummy27; } + } + public int Dummy27 + { + get { return dummy27_; } + } + + public const int Dummy28FieldNumber = 28; + private bool hasDummy28; + private int dummy28_; + public bool HasDummy28 + { + get { return hasDummy28; } + } + public int Dummy28 + { + get { return dummy28_; } + } + + public const int Dummy29FieldNumber = 29; + private bool hasDummy29; + private int dummy29_; + public bool HasDummy29 + { + get { return hasDummy29; } + } + public int Dummy29 + { + get { return dummy29_; } + } + + public const int Dummy30FieldNumber = 30; + private bool hasDummy30; + private int dummy30_; + public bool HasDummy30 + { + get { return hasDummy30; } + } + public int Dummy30 + { + get { return dummy30_; } + } + + public const int Dummy31FieldNumber = 31; + private bool hasDummy31; + private int dummy31_; + public bool HasDummy31 + { + get { return hasDummy31; } + } + public int Dummy31 + { + get { return dummy31_; } + } + + public const int Dummy32FieldNumber = 32; + private bool hasDummy32; + private int dummy32_; + public bool HasDummy32 + { + get { return hasDummy32; } + } + public int Dummy32 + { + get { return dummy32_; } + } + + public const int CFieldNumber = 33; + private bool hasC; + private int c_; + public bool HasC + { + get { return hasC; } + } + public int C + { + get { return c_; } + } + + public override bool IsInitialized + { + get + { + if (!hasA) return false; + if (!hasB) return false; + if (!hasC) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testRequiredFieldNames; + if (hasA) + { + output.WriteInt32(1, field_names[0], A); + } + if (hasDummy2) + { + output.WriteInt32(2, field_names[13], Dummy2); + } + if (hasB) + { + output.WriteInt32(3, field_names[1], B); + } + if (hasDummy4) + { + output.WriteInt32(4, field_names[27], Dummy4); + } + if (hasDummy5) + { + output.WriteInt32(5, field_names[28], Dummy5); + } + if (hasDummy6) + { + output.WriteInt32(6, field_names[29], Dummy6); + } + if (hasDummy7) + { + output.WriteInt32(7, field_names[30], Dummy7); + } + if (hasDummy8) + { + output.WriteInt32(8, field_names[31], Dummy8); + } + if (hasDummy9) + { + output.WriteInt32(9, field_names[32], Dummy9); + } + if (hasDummy10) + { + output.WriteInt32(10, field_names[3], Dummy10); + } + if (hasDummy11) + { + output.WriteInt32(11, field_names[4], Dummy11); + } + if (hasDummy12) + { + output.WriteInt32(12, field_names[5], Dummy12); + } + if (hasDummy13) + { + output.WriteInt32(13, field_names[6], Dummy13); + } + if (hasDummy14) + { + output.WriteInt32(14, field_names[7], Dummy14); + } + if (hasDummy15) + { + output.WriteInt32(15, field_names[8], Dummy15); + } + if (hasDummy16) + { + output.WriteInt32(16, field_names[9], Dummy16); + } + if (hasDummy17) + { + output.WriteInt32(17, field_names[10], Dummy17); + } + if (hasDummy18) + { + output.WriteInt32(18, field_names[11], Dummy18); + } + if (hasDummy19) + { + output.WriteInt32(19, field_names[12], Dummy19); + } + if (hasDummy20) + { + output.WriteInt32(20, field_names[14], Dummy20); + } + if (hasDummy21) + { + output.WriteInt32(21, field_names[15], Dummy21); + } + if (hasDummy22) + { + output.WriteInt32(22, field_names[16], Dummy22); + } + if (hasDummy23) + { + output.WriteInt32(23, field_names[17], Dummy23); + } + if (hasDummy24) + { + output.WriteInt32(24, field_names[18], Dummy24); + } + if (hasDummy25) + { + output.WriteInt32(25, field_names[19], Dummy25); + } + if (hasDummy26) + { + output.WriteInt32(26, field_names[20], Dummy26); + } + if (hasDummy27) + { + output.WriteInt32(27, field_names[21], Dummy27); + } + if (hasDummy28) + { + output.WriteInt32(28, field_names[22], Dummy28); + } + if (hasDummy29) + { + output.WriteInt32(29, field_names[23], Dummy29); + } + if (hasDummy30) + { + output.WriteInt32(30, field_names[24], Dummy30); + } + if (hasDummy31) + { + output.WriteInt32(31, field_names[25], Dummy31); + } + if (hasDummy32) + { + output.WriteInt32(32, field_names[26], Dummy32); + } + if (hasC) + { + output.WriteInt32(33, field_names[2], C); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, A); + } + if (hasDummy2) + { + size += pb::CodedOutputStream.ComputeInt32Size(2, Dummy2); + } + if (hasB) + { + size += pb::CodedOutputStream.ComputeInt32Size(3, B); + } + if (hasDummy4) + { + size += pb::CodedOutputStream.ComputeInt32Size(4, Dummy4); + } + if (hasDummy5) + { + size += pb::CodedOutputStream.ComputeInt32Size(5, Dummy5); + } + if (hasDummy6) + { + size += pb::CodedOutputStream.ComputeInt32Size(6, Dummy6); + } + if (hasDummy7) + { + size += pb::CodedOutputStream.ComputeInt32Size(7, Dummy7); + } + if (hasDummy8) + { + size += pb::CodedOutputStream.ComputeInt32Size(8, Dummy8); + } + if (hasDummy9) + { + size += pb::CodedOutputStream.ComputeInt32Size(9, Dummy9); + } + if (hasDummy10) + { + size += pb::CodedOutputStream.ComputeInt32Size(10, Dummy10); + } + if (hasDummy11) + { + size += pb::CodedOutputStream.ComputeInt32Size(11, Dummy11); + } + if (hasDummy12) + { + size += pb::CodedOutputStream.ComputeInt32Size(12, Dummy12); + } + if (hasDummy13) + { + size += pb::CodedOutputStream.ComputeInt32Size(13, Dummy13); + } + if (hasDummy14) + { + size += pb::CodedOutputStream.ComputeInt32Size(14, Dummy14); + } + if (hasDummy15) + { + size += pb::CodedOutputStream.ComputeInt32Size(15, Dummy15); + } + if (hasDummy16) + { + size += pb::CodedOutputStream.ComputeInt32Size(16, Dummy16); + } + if (hasDummy17) + { + size += pb::CodedOutputStream.ComputeInt32Size(17, Dummy17); + } + if (hasDummy18) + { + size += pb::CodedOutputStream.ComputeInt32Size(18, Dummy18); + } + if (hasDummy19) + { + size += pb::CodedOutputStream.ComputeInt32Size(19, Dummy19); + } + if (hasDummy20) + { + size += pb::CodedOutputStream.ComputeInt32Size(20, Dummy20); + } + if (hasDummy21) + { + size += pb::CodedOutputStream.ComputeInt32Size(21, Dummy21); + } + if (hasDummy22) + { + size += pb::CodedOutputStream.ComputeInt32Size(22, Dummy22); + } + if (hasDummy23) + { + size += pb::CodedOutputStream.ComputeInt32Size(23, Dummy23); + } + if (hasDummy24) + { + size += pb::CodedOutputStream.ComputeInt32Size(24, Dummy24); + } + if (hasDummy25) + { + size += pb::CodedOutputStream.ComputeInt32Size(25, Dummy25); + } + if (hasDummy26) + { + size += pb::CodedOutputStream.ComputeInt32Size(26, Dummy26); + } + if (hasDummy27) + { + size += pb::CodedOutputStream.ComputeInt32Size(27, Dummy27); + } + if (hasDummy28) + { + size += pb::CodedOutputStream.ComputeInt32Size(28, Dummy28); + } + if (hasDummy29) + { + size += pb::CodedOutputStream.ComputeInt32Size(29, Dummy29); + } + if (hasDummy30) + { + size += pb::CodedOutputStream.ComputeInt32Size(30, Dummy30); + } + if (hasDummy31) + { + size += pb::CodedOutputStream.ComputeInt32Size(31, Dummy31); + } + if (hasDummy32) + { + size += pb::CodedOutputStream.ComputeInt32Size(32, Dummy32); + } + if (hasC) + { + size += pb::CodedOutputStream.ComputeInt32Size(33, C); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestRequired ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequired ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequired ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequired ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequired ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequired ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestRequired ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestRequired ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestRequired ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequired ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestRequired MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestRequired prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRequired cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestRequired result; + + private TestRequired PrepareBuilder() + { + if (resultIsReadOnly) + { + TestRequired original = result; + result = new TestRequired(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestRequired MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor; } + } + + public override TestRequired DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance; } + } + + public override TestRequired BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestRequired) + { + return MergeFrom((TestRequired)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestRequired other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + if (other.HasDummy2) + { + Dummy2 = other.Dummy2; + } + if (other.HasB) + { + B = other.B; + } + if (other.HasDummy4) + { + Dummy4 = other.Dummy4; + } + if (other.HasDummy5) + { + Dummy5 = other.Dummy5; + } + if (other.HasDummy6) + { + Dummy6 = other.Dummy6; + } + if (other.HasDummy7) + { + Dummy7 = other.Dummy7; + } + if (other.HasDummy8) + { + Dummy8 = other.Dummy8; + } + if (other.HasDummy9) + { + Dummy9 = other.Dummy9; + } + if (other.HasDummy10) + { + Dummy10 = other.Dummy10; + } + if (other.HasDummy11) + { + Dummy11 = other.Dummy11; + } + if (other.HasDummy12) + { + Dummy12 = other.Dummy12; + } + if (other.HasDummy13) + { + Dummy13 = other.Dummy13; + } + if (other.HasDummy14) + { + Dummy14 = other.Dummy14; + } + if (other.HasDummy15) + { + Dummy15 = other.Dummy15; + } + if (other.HasDummy16) + { + Dummy16 = other.Dummy16; + } + if (other.HasDummy17) + { + Dummy17 = other.Dummy17; + } + if (other.HasDummy18) + { + Dummy18 = other.Dummy18; + } + if (other.HasDummy19) + { + Dummy19 = other.Dummy19; + } + if (other.HasDummy20) + { + Dummy20 = other.Dummy20; + } + if (other.HasDummy21) + { + Dummy21 = other.Dummy21; + } + if (other.HasDummy22) + { + Dummy22 = other.Dummy22; + } + if (other.HasDummy23) + { + Dummy23 = other.Dummy23; + } + if (other.HasDummy24) + { + Dummy24 = other.Dummy24; + } + if (other.HasDummy25) + { + Dummy25 = other.Dummy25; + } + if (other.HasDummy26) + { + Dummy26 = other.Dummy26; + } + if (other.HasDummy27) + { + Dummy27 = other.Dummy27; + } + if (other.HasDummy28) + { + Dummy28 = other.Dummy28; + } + if (other.HasDummy29) + { + Dummy29 = other.Dummy29; + } + if (other.HasDummy30) + { + Dummy30 = other.Dummy30; + } + if (other.HasDummy31) + { + Dummy31 = other.Dummy31; + } + if (other.HasDummy32) + { + Dummy32 = other.Dummy32; + } + if (other.HasC) + { + C = other.C; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testRequiredFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testRequiredFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 16: + { + result.hasDummy2 = input.ReadInt32(ref result.dummy2_); + break; + } + case 24: + { + result.hasB = input.ReadInt32(ref result.b_); + break; + } + case 32: + { + result.hasDummy4 = input.ReadInt32(ref result.dummy4_); + break; + } + case 40: + { + result.hasDummy5 = input.ReadInt32(ref result.dummy5_); + break; + } + case 48: + { + result.hasDummy6 = input.ReadInt32(ref result.dummy6_); + break; + } + case 56: + { + result.hasDummy7 = input.ReadInt32(ref result.dummy7_); + break; + } + case 64: + { + result.hasDummy8 = input.ReadInt32(ref result.dummy8_); + break; + } + case 72: + { + result.hasDummy9 = input.ReadInt32(ref result.dummy9_); + break; + } + case 80: + { + result.hasDummy10 = input.ReadInt32(ref result.dummy10_); + break; + } + case 88: + { + result.hasDummy11 = input.ReadInt32(ref result.dummy11_); + break; + } + case 96: + { + result.hasDummy12 = input.ReadInt32(ref result.dummy12_); + break; + } + case 104: + { + result.hasDummy13 = input.ReadInt32(ref result.dummy13_); + break; + } + case 112: + { + result.hasDummy14 = input.ReadInt32(ref result.dummy14_); + break; + } + case 120: + { + result.hasDummy15 = input.ReadInt32(ref result.dummy15_); + break; + } + case 128: + { + result.hasDummy16 = input.ReadInt32(ref result.dummy16_); + break; + } + case 136: + { + result.hasDummy17 = input.ReadInt32(ref result.dummy17_); + break; + } + case 144: + { + result.hasDummy18 = input.ReadInt32(ref result.dummy18_); + break; + } + case 152: + { + result.hasDummy19 = input.ReadInt32(ref result.dummy19_); + break; + } + case 160: + { + result.hasDummy20 = input.ReadInt32(ref result.dummy20_); + break; + } + case 168: + { + result.hasDummy21 = input.ReadInt32(ref result.dummy21_); + break; + } + case 176: + { + result.hasDummy22 = input.ReadInt32(ref result.dummy22_); + break; + } + case 184: + { + result.hasDummy23 = input.ReadInt32(ref result.dummy23_); + break; + } + case 192: + { + result.hasDummy24 = input.ReadInt32(ref result.dummy24_); + break; + } + case 200: + { + result.hasDummy25 = input.ReadInt32(ref result.dummy25_); + break; + } + case 208: + { + result.hasDummy26 = input.ReadInt32(ref result.dummy26_); + break; + } + case 216: + { + result.hasDummy27 = input.ReadInt32(ref result.dummy27_); + break; + } + case 224: + { + result.hasDummy28 = input.ReadInt32(ref result.dummy28_); + break; + } + case 232: + { + result.hasDummy29 = input.ReadInt32(ref result.dummy29_); + break; + } + case 240: + { + result.hasDummy30 = input.ReadInt32(ref result.dummy30_); + break; + } + case 248: + { + result.hasDummy31 = input.ReadInt32(ref result.dummy31_); + break; + } + case 256: + { + result.hasDummy32 = input.ReadInt32(ref result.dummy32_); + break; + } + case 264: + { + result.hasC = input.ReadInt32(ref result.c_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + + public bool HasDummy2 + { + get { return result.hasDummy2; } + } + public int Dummy2 + { + get { return result.Dummy2; } + set { SetDummy2(value); } + } + public Builder SetDummy2(int value) + { + PrepareBuilder(); + result.hasDummy2 = true; + result.dummy2_ = value; + return this; + } + public Builder ClearDummy2() + { + PrepareBuilder(); + result.hasDummy2 = false; + result.dummy2_ = 0; + return this; + } + + public bool HasB + { + get { return result.hasB; } + } + public int B + { + get { return result.B; } + set { SetB(value); } + } + public Builder SetB(int value) + { + PrepareBuilder(); + result.hasB = true; + result.b_ = value; + return this; + } + public Builder ClearB() + { + PrepareBuilder(); + result.hasB = false; + result.b_ = 0; + return this; + } + + public bool HasDummy4 + { + get { return result.hasDummy4; } + } + public int Dummy4 + { + get { return result.Dummy4; } + set { SetDummy4(value); } + } + public Builder SetDummy4(int value) + { + PrepareBuilder(); + result.hasDummy4 = true; + result.dummy4_ = value; + return this; + } + public Builder ClearDummy4() + { + PrepareBuilder(); + result.hasDummy4 = false; + result.dummy4_ = 0; + return this; + } + + public bool HasDummy5 + { + get { return result.hasDummy5; } + } + public int Dummy5 + { + get { return result.Dummy5; } + set { SetDummy5(value); } + } + public Builder SetDummy5(int value) + { + PrepareBuilder(); + result.hasDummy5 = true; + result.dummy5_ = value; + return this; + } + public Builder ClearDummy5() + { + PrepareBuilder(); + result.hasDummy5 = false; + result.dummy5_ = 0; + return this; + } + + public bool HasDummy6 + { + get { return result.hasDummy6; } + } + public int Dummy6 + { + get { return result.Dummy6; } + set { SetDummy6(value); } + } + public Builder SetDummy6(int value) + { + PrepareBuilder(); + result.hasDummy6 = true; + result.dummy6_ = value; + return this; + } + public Builder ClearDummy6() + { + PrepareBuilder(); + result.hasDummy6 = false; + result.dummy6_ = 0; + return this; + } + + public bool HasDummy7 + { + get { return result.hasDummy7; } + } + public int Dummy7 + { + get { return result.Dummy7; } + set { SetDummy7(value); } + } + public Builder SetDummy7(int value) + { + PrepareBuilder(); + result.hasDummy7 = true; + result.dummy7_ = value; + return this; + } + public Builder ClearDummy7() + { + PrepareBuilder(); + result.hasDummy7 = false; + result.dummy7_ = 0; + return this; + } + + public bool HasDummy8 + { + get { return result.hasDummy8; } + } + public int Dummy8 + { + get { return result.Dummy8; } + set { SetDummy8(value); } + } + public Builder SetDummy8(int value) + { + PrepareBuilder(); + result.hasDummy8 = true; + result.dummy8_ = value; + return this; + } + public Builder ClearDummy8() + { + PrepareBuilder(); + result.hasDummy8 = false; + result.dummy8_ = 0; + return this; + } + + public bool HasDummy9 + { + get { return result.hasDummy9; } + } + public int Dummy9 + { + get { return result.Dummy9; } + set { SetDummy9(value); } + } + public Builder SetDummy9(int value) + { + PrepareBuilder(); + result.hasDummy9 = true; + result.dummy9_ = value; + return this; + } + public Builder ClearDummy9() + { + PrepareBuilder(); + result.hasDummy9 = false; + result.dummy9_ = 0; + return this; + } + + public bool HasDummy10 + { + get { return result.hasDummy10; } + } + public int Dummy10 + { + get { return result.Dummy10; } + set { SetDummy10(value); } + } + public Builder SetDummy10(int value) + { + PrepareBuilder(); + result.hasDummy10 = true; + result.dummy10_ = value; + return this; + } + public Builder ClearDummy10() + { + PrepareBuilder(); + result.hasDummy10 = false; + result.dummy10_ = 0; + return this; + } + + public bool HasDummy11 + { + get { return result.hasDummy11; } + } + public int Dummy11 + { + get { return result.Dummy11; } + set { SetDummy11(value); } + } + public Builder SetDummy11(int value) + { + PrepareBuilder(); + result.hasDummy11 = true; + result.dummy11_ = value; + return this; + } + public Builder ClearDummy11() + { + PrepareBuilder(); + result.hasDummy11 = false; + result.dummy11_ = 0; + return this; + } + + public bool HasDummy12 + { + get { return result.hasDummy12; } + } + public int Dummy12 + { + get { return result.Dummy12; } + set { SetDummy12(value); } + } + public Builder SetDummy12(int value) + { + PrepareBuilder(); + result.hasDummy12 = true; + result.dummy12_ = value; + return this; + } + public Builder ClearDummy12() + { + PrepareBuilder(); + result.hasDummy12 = false; + result.dummy12_ = 0; + return this; + } + + public bool HasDummy13 + { + get { return result.hasDummy13; } + } + public int Dummy13 + { + get { return result.Dummy13; } + set { SetDummy13(value); } + } + public Builder SetDummy13(int value) + { + PrepareBuilder(); + result.hasDummy13 = true; + result.dummy13_ = value; + return this; + } + public Builder ClearDummy13() + { + PrepareBuilder(); + result.hasDummy13 = false; + result.dummy13_ = 0; + return this; + } + + public bool HasDummy14 + { + get { return result.hasDummy14; } + } + public int Dummy14 + { + get { return result.Dummy14; } + set { SetDummy14(value); } + } + public Builder SetDummy14(int value) + { + PrepareBuilder(); + result.hasDummy14 = true; + result.dummy14_ = value; + return this; + } + public Builder ClearDummy14() + { + PrepareBuilder(); + result.hasDummy14 = false; + result.dummy14_ = 0; + return this; + } + + public bool HasDummy15 + { + get { return result.hasDummy15; } + } + public int Dummy15 + { + get { return result.Dummy15; } + set { SetDummy15(value); } + } + public Builder SetDummy15(int value) + { + PrepareBuilder(); + result.hasDummy15 = true; + result.dummy15_ = value; + return this; + } + public Builder ClearDummy15() + { + PrepareBuilder(); + result.hasDummy15 = false; + result.dummy15_ = 0; + return this; + } + + public bool HasDummy16 + { + get { return result.hasDummy16; } + } + public int Dummy16 + { + get { return result.Dummy16; } + set { SetDummy16(value); } + } + public Builder SetDummy16(int value) + { + PrepareBuilder(); + result.hasDummy16 = true; + result.dummy16_ = value; + return this; + } + public Builder ClearDummy16() + { + PrepareBuilder(); + result.hasDummy16 = false; + result.dummy16_ = 0; + return this; + } + + public bool HasDummy17 + { + get { return result.hasDummy17; } + } + public int Dummy17 + { + get { return result.Dummy17; } + set { SetDummy17(value); } + } + public Builder SetDummy17(int value) + { + PrepareBuilder(); + result.hasDummy17 = true; + result.dummy17_ = value; + return this; + } + public Builder ClearDummy17() + { + PrepareBuilder(); + result.hasDummy17 = false; + result.dummy17_ = 0; + return this; + } + + public bool HasDummy18 + { + get { return result.hasDummy18; } + } + public int Dummy18 + { + get { return result.Dummy18; } + set { SetDummy18(value); } + } + public Builder SetDummy18(int value) + { + PrepareBuilder(); + result.hasDummy18 = true; + result.dummy18_ = value; + return this; + } + public Builder ClearDummy18() + { + PrepareBuilder(); + result.hasDummy18 = false; + result.dummy18_ = 0; + return this; + } + + public bool HasDummy19 + { + get { return result.hasDummy19; } + } + public int Dummy19 + { + get { return result.Dummy19; } + set { SetDummy19(value); } + } + public Builder SetDummy19(int value) + { + PrepareBuilder(); + result.hasDummy19 = true; + result.dummy19_ = value; + return this; + } + public Builder ClearDummy19() + { + PrepareBuilder(); + result.hasDummy19 = false; + result.dummy19_ = 0; + return this; + } + + public bool HasDummy20 + { + get { return result.hasDummy20; } + } + public int Dummy20 + { + get { return result.Dummy20; } + set { SetDummy20(value); } + } + public Builder SetDummy20(int value) + { + PrepareBuilder(); + result.hasDummy20 = true; + result.dummy20_ = value; + return this; + } + public Builder ClearDummy20() + { + PrepareBuilder(); + result.hasDummy20 = false; + result.dummy20_ = 0; + return this; + } + + public bool HasDummy21 + { + get { return result.hasDummy21; } + } + public int Dummy21 + { + get { return result.Dummy21; } + set { SetDummy21(value); } + } + public Builder SetDummy21(int value) + { + PrepareBuilder(); + result.hasDummy21 = true; + result.dummy21_ = value; + return this; + } + public Builder ClearDummy21() + { + PrepareBuilder(); + result.hasDummy21 = false; + result.dummy21_ = 0; + return this; + } + + public bool HasDummy22 + { + get { return result.hasDummy22; } + } + public int Dummy22 + { + get { return result.Dummy22; } + set { SetDummy22(value); } + } + public Builder SetDummy22(int value) + { + PrepareBuilder(); + result.hasDummy22 = true; + result.dummy22_ = value; + return this; + } + public Builder ClearDummy22() + { + PrepareBuilder(); + result.hasDummy22 = false; + result.dummy22_ = 0; + return this; + } + + public bool HasDummy23 + { + get { return result.hasDummy23; } + } + public int Dummy23 + { + get { return result.Dummy23; } + set { SetDummy23(value); } + } + public Builder SetDummy23(int value) + { + PrepareBuilder(); + result.hasDummy23 = true; + result.dummy23_ = value; + return this; + } + public Builder ClearDummy23() + { + PrepareBuilder(); + result.hasDummy23 = false; + result.dummy23_ = 0; + return this; + } + + public bool HasDummy24 + { + get { return result.hasDummy24; } + } + public int Dummy24 + { + get { return result.Dummy24; } + set { SetDummy24(value); } + } + public Builder SetDummy24(int value) + { + PrepareBuilder(); + result.hasDummy24 = true; + result.dummy24_ = value; + return this; + } + public Builder ClearDummy24() + { + PrepareBuilder(); + result.hasDummy24 = false; + result.dummy24_ = 0; + return this; + } + + public bool HasDummy25 + { + get { return result.hasDummy25; } + } + public int Dummy25 + { + get { return result.Dummy25; } + set { SetDummy25(value); } + } + public Builder SetDummy25(int value) + { + PrepareBuilder(); + result.hasDummy25 = true; + result.dummy25_ = value; + return this; + } + public Builder ClearDummy25() + { + PrepareBuilder(); + result.hasDummy25 = false; + result.dummy25_ = 0; + return this; + } + + public bool HasDummy26 + { + get { return result.hasDummy26; } + } + public int Dummy26 + { + get { return result.Dummy26; } + set { SetDummy26(value); } + } + public Builder SetDummy26(int value) + { + PrepareBuilder(); + result.hasDummy26 = true; + result.dummy26_ = value; + return this; + } + public Builder ClearDummy26() + { + PrepareBuilder(); + result.hasDummy26 = false; + result.dummy26_ = 0; + return this; + } + + public bool HasDummy27 + { + get { return result.hasDummy27; } + } + public int Dummy27 + { + get { return result.Dummy27; } + set { SetDummy27(value); } + } + public Builder SetDummy27(int value) + { + PrepareBuilder(); + result.hasDummy27 = true; + result.dummy27_ = value; + return this; + } + public Builder ClearDummy27() + { + PrepareBuilder(); + result.hasDummy27 = false; + result.dummy27_ = 0; + return this; + } + + public bool HasDummy28 + { + get { return result.hasDummy28; } + } + public int Dummy28 + { + get { return result.Dummy28; } + set { SetDummy28(value); } + } + public Builder SetDummy28(int value) + { + PrepareBuilder(); + result.hasDummy28 = true; + result.dummy28_ = value; + return this; + } + public Builder ClearDummy28() + { + PrepareBuilder(); + result.hasDummy28 = false; + result.dummy28_ = 0; + return this; + } + + public bool HasDummy29 + { + get { return result.hasDummy29; } + } + public int Dummy29 + { + get { return result.Dummy29; } + set { SetDummy29(value); } + } + public Builder SetDummy29(int value) + { + PrepareBuilder(); + result.hasDummy29 = true; + result.dummy29_ = value; + return this; + } + public Builder ClearDummy29() + { + PrepareBuilder(); + result.hasDummy29 = false; + result.dummy29_ = 0; + return this; + } + + public bool HasDummy30 + { + get { return result.hasDummy30; } + } + public int Dummy30 + { + get { return result.Dummy30; } + set { SetDummy30(value); } + } + public Builder SetDummy30(int value) + { + PrepareBuilder(); + result.hasDummy30 = true; + result.dummy30_ = value; + return this; + } + public Builder ClearDummy30() + { + PrepareBuilder(); + result.hasDummy30 = false; + result.dummy30_ = 0; + return this; + } + + public bool HasDummy31 + { + get { return result.hasDummy31; } + } + public int Dummy31 + { + get { return result.Dummy31; } + set { SetDummy31(value); } + } + public Builder SetDummy31(int value) + { + PrepareBuilder(); + result.hasDummy31 = true; + result.dummy31_ = value; + return this; + } + public Builder ClearDummy31() + { + PrepareBuilder(); + result.hasDummy31 = false; + result.dummy31_ = 0; + return this; + } + + public bool HasDummy32 + { + get { return result.hasDummy32; } + } + public int Dummy32 + { + get { return result.Dummy32; } + set { SetDummy32(value); } + } + public Builder SetDummy32(int value) + { + PrepareBuilder(); + result.hasDummy32 = true; + result.dummy32_ = value; + return this; + } + public Builder ClearDummy32() + { + PrepareBuilder(); + result.hasDummy32 = false; + result.dummy32_ = 0; + return this; + } + + public bool HasC + { + get { return result.hasC; } + } + public int C + { + get { return result.C; } + set { SetC(value); } + } + public Builder SetC(int value) + { + PrepareBuilder(); + result.hasC = true; + result.c_ = value; + return this; + } + public Builder ClearC() + { + PrepareBuilder(); + result.hasC = false; + result.c_ = 0; + return this; + } + } + static TestRequired() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestRequiredForeign : pb::GeneratedMessage + { + private TestRequiredForeign() { } + private static readonly TestRequiredForeign defaultInstance = new TestRequiredForeign().MakeReadOnly(); + private static readonly string[] _testRequiredForeignFieldNames = new string[] { "dummy", "optional_message", "repeated_message" }; + private static readonly uint[] _testRequiredForeignFieldTags = new uint[] { 24, 10, 18 }; + public static TestRequiredForeign DefaultInstance + { + get { return defaultInstance; } + } + + public override TestRequiredForeign DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestRequiredForeign ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredForeign__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable; } + } + + public const int OptionalMessageFieldNumber = 1; + private bool hasOptionalMessage; + private global::Google.ProtocolBuffers.TestProtos.TestRequired optionalMessage_; + public bool HasOptionalMessage + { + get { return hasOptionalMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequired OptionalMessage + { + get { return optionalMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance; } + } + + public const int RepeatedMessageFieldNumber = 2; + private pbc::PopsicleList repeatedMessage_ = new pbc::PopsicleList(); + public scg::IList RepeatedMessageList + { + get { return repeatedMessage_; } + } + public int RepeatedMessageCount + { + get { return repeatedMessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequired GetRepeatedMessage(int index) + { + return repeatedMessage_[index]; + } + + public const int DummyFieldNumber = 3; + private bool hasDummy; + private int dummy_; + public bool HasDummy + { + get { return hasDummy; } + } + public int Dummy + { + get { return dummy_; } + } + + public override bool IsInitialized + { + get + { + if (HasOptionalMessage) + { + if (!OptionalMessage.IsInitialized) return false; + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestRequired element in RepeatedMessageList) + { + if (!element.IsInitialized) return false; + } + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testRequiredForeignFieldNames; + if (hasOptionalMessage) + { + output.WriteMessage(1, field_names[1], OptionalMessage); + } + if (repeatedMessage_.Count > 0) + { + output.WriteMessageArray(2, field_names[2], repeatedMessage_); + } + if (hasDummy) + { + output.WriteInt32(3, field_names[0], Dummy); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOptionalMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, OptionalMessage); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestRequired element in RepeatedMessageList) + { + size += pb::CodedOutputStream.ComputeMessageSize(2, element); + } + if (hasDummy) + { + size += pb::CodedOutputStream.ComputeInt32Size(3, Dummy); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestRequiredForeign ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestRequiredForeign ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestRequiredForeign ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRequiredForeign ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestRequiredForeign MakeReadOnly() + { + repeatedMessage_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestRequiredForeign prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRequiredForeign cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestRequiredForeign result; + + private TestRequiredForeign PrepareBuilder() + { + if (resultIsReadOnly) + { + TestRequiredForeign original = result; + result = new TestRequiredForeign(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestRequiredForeign MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.Descriptor; } + } + + public override TestRequiredForeign DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.DefaultInstance; } + } + + public override TestRequiredForeign BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestRequiredForeign) + { + return MergeFrom((TestRequiredForeign)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestRequiredForeign other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOptionalMessage) + { + MergeOptionalMessage(other.OptionalMessage); + } + if (other.repeatedMessage_.Count != 0) + { + result.repeatedMessage_.Add(other.repeatedMessage_); + } + if (other.HasDummy) + { + Dummy = other.Dummy; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testRequiredForeignFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testRequiredForeignFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(); + if (result.hasOptionalMessage) + { + subBuilder.MergeFrom(OptionalMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalMessage = subBuilder.BuildPartial(); + break; + } + case 18: + { + input.ReadMessageArray(tag, field_name, result.repeatedMessage_, global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance, extensionRegistry); + break; + } + case 24: + { + result.hasDummy = input.ReadInt32(ref result.dummy_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasOptionalMessage + { + get { return result.hasOptionalMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequired OptionalMessage + { + get { return result.OptionalMessage; } + set { SetOptionalMessage(value); } + } + public Builder SetOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalMessage = true; + result.optionalMessage_ = value; + return this; + } + public Builder SetOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalMessage = true; + result.optionalMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalMessage && + result.optionalMessage_ != global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) + { + result.optionalMessage_ = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(result.optionalMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalMessage_ = value; + } + result.hasOptionalMessage = true; + return this; + } + public Builder ClearOptionalMessage() + { + PrepareBuilder(); + result.hasOptionalMessage = false; + result.optionalMessage_ = null; + return this; + } + + public pbc::IPopsicleList RepeatedMessageList + { + get { return PrepareBuilder().repeatedMessage_; } + } + public int RepeatedMessageCount + { + get { return result.RepeatedMessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequired GetRepeatedMessage(int index) + { + return result.GetRepeatedMessage(index); + } + public Builder SetRepeatedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestRequired value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedMessage_[index] = value; + return this; + } + public Builder SetRepeatedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedMessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedMessage_.Add(value); + return this; + } + public Builder AddRepeatedMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedMessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedMessage(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedMessage_.Add(values); + return this; + } + public Builder ClearRepeatedMessage() + { + PrepareBuilder(); + result.repeatedMessage_.Clear(); + return this; + } + + public bool HasDummy + { + get { return result.hasDummy; } + } + public int Dummy + { + get { return result.Dummy; } + set { SetDummy(value); } + } + public Builder SetDummy(int value) + { + PrepareBuilder(); + result.hasDummy = true; + result.dummy_ = value; + return this; + } + public Builder ClearDummy() + { + PrepareBuilder(); + result.hasDummy = false; + result.dummy_ = 0; + return this; + } + } + static TestRequiredForeign() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestForeignNested : pb::GeneratedMessage + { + private TestForeignNested() { } + private static readonly TestForeignNested defaultInstance = new TestForeignNested().MakeReadOnly(); + private static readonly string[] _testForeignNestedFieldNames = new string[] { "foreign_nested" }; + private static readonly uint[] _testForeignNestedFieldTags = new uint[] { 10 }; + public static TestForeignNested DefaultInstance + { + get { return defaultInstance; } + } + + public override TestForeignNested DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestForeignNested ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestForeignNested__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable; } + } + + public const int ForeignNestedFieldNumber = 1; + private bool hasForeignNested; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage foreignNested_; + public bool HasForeignNested + { + get { return hasForeignNested; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage ForeignNested + { + get { return foreignNested_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testForeignNestedFieldNames; + if (hasForeignNested) + { + output.WriteMessage(1, field_names[0], ForeignNested); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasForeignNested) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, ForeignNested); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestForeignNested ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestForeignNested ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestForeignNested ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestForeignNested ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestForeignNested ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestForeignNested ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestForeignNested ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestForeignNested ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestForeignNested ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestForeignNested ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestForeignNested MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestForeignNested prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestForeignNested cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestForeignNested result; + + private TestForeignNested PrepareBuilder() + { + if (resultIsReadOnly) + { + TestForeignNested original = result; + result = new TestForeignNested(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestForeignNested MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestForeignNested.Descriptor; } + } + + public override TestForeignNested DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestForeignNested.DefaultInstance; } + } + + public override TestForeignNested BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestForeignNested) + { + return MergeFrom((TestForeignNested)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestForeignNested other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestForeignNested.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasForeignNested) + { + MergeForeignNested(other.ForeignNested); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testForeignNestedFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testForeignNestedFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); + if (result.hasForeignNested) + { + subBuilder.MergeFrom(ForeignNested); + } + input.ReadMessage(subBuilder, extensionRegistry); + ForeignNested = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasForeignNested + { + get { return result.hasForeignNested; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage ForeignNested + { + get { return result.ForeignNested; } + set { SetForeignNested(value); } + } + public Builder SetForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasForeignNested = true; + result.foreignNested_ = value; + return this; + } + public Builder SetForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasForeignNested = true; + result.foreignNested_ = builderForValue.Build(); + return this; + } + public Builder MergeForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasForeignNested && + result.foreignNested_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) + { + result.foreignNested_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.foreignNested_).MergeFrom(value).BuildPartial(); + } + else + { + result.foreignNested_ = value; + } + result.hasForeignNested = true; + return this; + } + public Builder ClearForeignNested() + { + PrepareBuilder(); + result.hasForeignNested = false; + result.foreignNested_ = null; + return this; + } + } + static TestForeignNested() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestEmptyMessage : pb::GeneratedMessage + { + private TestEmptyMessage() { } + private static readonly TestEmptyMessage defaultInstance = new TestEmptyMessage().MakeReadOnly(); + private static readonly string[] _testEmptyMessageFieldNames = new string[] { }; + private static readonly uint[] _testEmptyMessageFieldTags = new uint[] { }; + public static TestEmptyMessage DefaultInstance + { + get { return defaultInstance; } + } + + public override TestEmptyMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestEmptyMessage ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testEmptyMessageFieldNames; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestEmptyMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestEmptyMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestEmptyMessage MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestEmptyMessage prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestEmptyMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestEmptyMessage result; + + private TestEmptyMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + TestEmptyMessage original = result; + result = new TestEmptyMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestEmptyMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.Descriptor; } + } + + public override TestEmptyMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.DefaultInstance; } + } + + public override TestEmptyMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestEmptyMessage) + { + return MergeFrom((TestEmptyMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestEmptyMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testEmptyMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestEmptyMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestEmptyMessageWithExtensions : pb::ExtendableMessage + { + private TestEmptyMessageWithExtensions() { } + private static readonly TestEmptyMessageWithExtensions defaultInstance = new TestEmptyMessageWithExtensions().MakeReadOnly(); + private static readonly string[] _testEmptyMessageWithExtensionsFieldNames = new string[] { }; + private static readonly uint[] _testEmptyMessageWithExtensionsFieldTags = new uint[] { }; + public static TestEmptyMessageWithExtensions DefaultInstance + { + get { return defaultInstance; } + } + + public override TestEmptyMessageWithExtensions DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestEmptyMessageWithExtensions ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable; } + } + + public override bool IsInitialized + { + get + { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testEmptyMessageWithExtensionsFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestEmptyMessageWithExtensions ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEmptyMessageWithExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestEmptyMessageWithExtensions MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestEmptyMessageWithExtensions prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestEmptyMessageWithExtensions cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestEmptyMessageWithExtensions result; + + private TestEmptyMessageWithExtensions PrepareBuilder() + { + if (resultIsReadOnly) + { + TestEmptyMessageWithExtensions original = result; + result = new TestEmptyMessageWithExtensions(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestEmptyMessageWithExtensions MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.Descriptor; } + } + + public override TestEmptyMessageWithExtensions DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.DefaultInstance; } + } + + public override TestEmptyMessageWithExtensions BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestEmptyMessageWithExtensions) + { + return MergeFrom((TestEmptyMessageWithExtensions)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestEmptyMessageWithExtensions other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageWithExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testEmptyMessageWithExtensionsFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestEmptyMessageWithExtensions() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestMultipleExtensionRanges : pb::ExtendableMessage + { + private TestMultipleExtensionRanges() { } + private static readonly TestMultipleExtensionRanges defaultInstance = new TestMultipleExtensionRanges().MakeReadOnly(); + private static readonly string[] _testMultipleExtensionRangesFieldNames = new string[] { }; + private static readonly uint[] _testMultipleExtensionRangesFieldTags = new uint[] { }; + public static TestMultipleExtensionRanges DefaultInstance + { + get { return defaultInstance; } + } + + public override TestMultipleExtensionRanges DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestMultipleExtensionRanges ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable; } + } + + public override bool IsInitialized + { + get + { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testMultipleExtensionRangesFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(43, output); + extensionWriter.WriteUntil(4244, output); + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestMultipleExtensionRanges ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMultipleExtensionRanges ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestMultipleExtensionRanges MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestMultipleExtensionRanges prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestMultipleExtensionRanges cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestMultipleExtensionRanges result; + + private TestMultipleExtensionRanges PrepareBuilder() + { + if (resultIsReadOnly) + { + TestMultipleExtensionRanges original = result; + result = new TestMultipleExtensionRanges(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestMultipleExtensionRanges MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.Descriptor; } + } + + public override TestMultipleExtensionRanges DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.DefaultInstance; } + } + + public override TestMultipleExtensionRanges BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestMultipleExtensionRanges) + { + return MergeFrom((TestMultipleExtensionRanges)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestMultipleExtensionRanges other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testMultipleExtensionRangesFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testMultipleExtensionRangesFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static TestMultipleExtensionRanges() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestReallyLargeTagNumber : pb::GeneratedMessage + { + private TestReallyLargeTagNumber() { } + private static readonly TestReallyLargeTagNumber defaultInstance = new TestReallyLargeTagNumber().MakeReadOnly(); + private static readonly string[] _testReallyLargeTagNumberFieldNames = new string[] { "a", "bb" }; + private static readonly uint[] _testReallyLargeTagNumberFieldTags = new uint[] { 8, 2147483640 }; + public static TestReallyLargeTagNumber DefaultInstance + { + get { return defaultInstance; } + } + + public override TestReallyLargeTagNumber DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestReallyLargeTagNumber ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } + + public const int BbFieldNumber = 268435455; + private bool hasBb; + private int bb_; + public bool HasBb + { + get { return hasBb; } + } + public int Bb + { + get { return bb_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testReallyLargeTagNumberFieldNames; + if (hasA) + { + output.WriteInt32(1, field_names[0], A); + } + if (hasBb) + { + output.WriteInt32(268435455, field_names[1], Bb); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, A); + } + if (hasBb) + { + size += pb::CodedOutputStream.ComputeInt32Size(268435455, Bb); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestReallyLargeTagNumber ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestReallyLargeTagNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestReallyLargeTagNumber MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestReallyLargeTagNumber prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestReallyLargeTagNumber cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestReallyLargeTagNumber result; + + private TestReallyLargeTagNumber PrepareBuilder() + { + if (resultIsReadOnly) + { + TestReallyLargeTagNumber original = result; + result = new TestReallyLargeTagNumber(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestReallyLargeTagNumber MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.Descriptor; } + } + + public override TestReallyLargeTagNumber DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.DefaultInstance; } + } + + public override TestReallyLargeTagNumber BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestReallyLargeTagNumber) + { + return MergeFrom((TestReallyLargeTagNumber)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestReallyLargeTagNumber other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + if (other.HasBb) + { + Bb = other.Bb; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testReallyLargeTagNumberFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testReallyLargeTagNumberFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 2147483640: + { + result.hasBb = input.ReadInt32(ref result.bb_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + + public bool HasBb + { + get { return result.hasBb; } + } + public int Bb + { + get { return result.Bb; } + set { SetBb(value); } + } + public Builder SetBb(int value) + { + PrepareBuilder(); + result.hasBb = true; + result.bb_ = value; + return this; + } + public Builder ClearBb() + { + PrepareBuilder(); + result.hasBb = false; + result.bb_ = 0; + return this; + } + } + static TestReallyLargeTagNumber() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestRecursiveMessage : pb::GeneratedMessage + { + private TestRecursiveMessage() { } + private static readonly TestRecursiveMessage defaultInstance = new TestRecursiveMessage().MakeReadOnly(); + private static readonly string[] _testRecursiveMessageFieldNames = new string[] { "a", "i" }; + private static readonly uint[] _testRecursiveMessageFieldTags = new uint[] { 10, 16 }; + public static TestRecursiveMessage DefaultInstance + { + get { return defaultInstance; } + } + + public override TestRecursiveMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestRecursiveMessage ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage a_; + public bool HasA + { + get { return hasA; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage A + { + get { return a_ ?? global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance; } + } + + public const int IFieldNumber = 2; + private bool hasI; + private int i_; + public bool HasI + { + get { return hasI; } + } + public int I + { + get { return i_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testRecursiveMessageFieldNames; + if (hasA) + { + output.WriteMessage(1, field_names[0], A); + } + if (hasI) + { + output.WriteInt32(2, field_names[1], I); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, A); + } + if (hasI) + { + size += pb::CodedOutputStream.ComputeInt32Size(2, I); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestRecursiveMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestRecursiveMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestRecursiveMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRecursiveMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestRecursiveMessage MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestRecursiveMessage prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRecursiveMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestRecursiveMessage result; + + private TestRecursiveMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + TestRecursiveMessage original = result; + result = new TestRecursiveMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestRecursiveMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Descriptor; } + } + + public override TestRecursiveMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance; } + } + + public override TestRecursiveMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestRecursiveMessage) + { + return MergeFrom((TestRecursiveMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestRecursiveMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + MergeA(other.A); + } + if (other.HasI) + { + I = other.I; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testRecursiveMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testRecursiveMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.CreateBuilder(); + if (result.hasA) + { + subBuilder.MergeFrom(A); + } + input.ReadMessage(subBuilder, extensionRegistry); + A = subBuilder.BuildPartial(); + break; + } + case 16: + { + result.hasI = input.ReadInt32(ref result.i_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA + { + get { return result.hasA; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasA = true; + result.a_ = builderForValue.Build(); + return this; + } + public Builder MergeA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasA && + result.a_ != global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance) + { + result.a_ = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.CreateBuilder(result.a_).MergeFrom(value).BuildPartial(); + } + else + { + result.a_ = value; + } + result.hasA = true; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = null; + return this; + } + + public bool HasI + { + get { return result.hasI; } + } + public int I + { + get { return result.I; } + set { SetI(value); } + } + public Builder SetI(int value) + { + PrepareBuilder(); + result.hasI = true; + result.i_ = value; + return this; + } + public Builder ClearI() + { + PrepareBuilder(); + result.hasI = false; + result.i_ = 0; + return this; + } + } + static TestRecursiveMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestMutualRecursionA : pb::GeneratedMessage + { + private TestMutualRecursionA() { } + private static readonly TestMutualRecursionA defaultInstance = new TestMutualRecursionA().MakeReadOnly(); + private static readonly string[] _testMutualRecursionAFieldNames = new string[] { "bb" }; + private static readonly uint[] _testMutualRecursionAFieldTags = new uint[] { 10 }; + public static TestMutualRecursionA DefaultInstance + { + get { return defaultInstance; } + } + + public override TestMutualRecursionA DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestMutualRecursionA ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable; } + } + + public const int BbFieldNumber = 1; + private bool hasBb; + private global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB bb_; + public bool HasBb + { + get { return hasBb; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB Bb + { + get { return bb_ ?? global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testMutualRecursionAFieldNames; + if (hasBb) + { + output.WriteMessage(1, field_names[0], Bb); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasBb) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, Bb); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestMutualRecursionA ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionA ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestMutualRecursionA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMutualRecursionA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestMutualRecursionA MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestMutualRecursionA prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestMutualRecursionA cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestMutualRecursionA result; + + private TestMutualRecursionA PrepareBuilder() + { + if (resultIsReadOnly) + { + TestMutualRecursionA original = result; + result = new TestMutualRecursionA(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestMutualRecursionA MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Descriptor; } + } + + public override TestMutualRecursionA DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance; } + } + + public override TestMutualRecursionA BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestMutualRecursionA) + { + return MergeFrom((TestMutualRecursionA)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestMutualRecursionA other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasBb) + { + MergeBb(other.Bb); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testMutualRecursionAFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testMutualRecursionAFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.CreateBuilder(); + if (result.hasBb) + { + subBuilder.MergeFrom(Bb); + } + input.ReadMessage(subBuilder, extensionRegistry); + Bb = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasBb + { + get { return result.hasBb; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB Bb + { + get { return result.Bb; } + set { SetBb(value); } + } + public Builder SetBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBb = true; + result.bb_ = value; + return this; + } + public Builder SetBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasBb = true; + result.bb_ = builderForValue.Build(); + return this; + } + public Builder MergeBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasBb && + result.bb_ != global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance) + { + result.bb_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.CreateBuilder(result.bb_).MergeFrom(value).BuildPartial(); + } + else + { + result.bb_ = value; + } + result.hasBb = true; + return this; + } + public Builder ClearBb() + { + PrepareBuilder(); + result.hasBb = false; + result.bb_ = null; + return this; + } + } + static TestMutualRecursionA() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestMutualRecursionB : pb::GeneratedMessage + { + private TestMutualRecursionB() { } + private static readonly TestMutualRecursionB defaultInstance = new TestMutualRecursionB().MakeReadOnly(); + private static readonly string[] _testMutualRecursionBFieldNames = new string[] { "a", "optional_int32" }; + private static readonly uint[] _testMutualRecursionBFieldTags = new uint[] { 10, 16 }; + public static TestMutualRecursionB DefaultInstance + { + get { return defaultInstance; } + } + + public override TestMutualRecursionB DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestMutualRecursionB ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA a_; + public bool HasA + { + get { return hasA; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA A + { + get { return a_ ?? global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance; } + } + + public const int OptionalInt32FieldNumber = 2; + private bool hasOptionalInt32; + private int optionalInt32_; + public bool HasOptionalInt32 + { + get { return hasOptionalInt32; } + } + public int OptionalInt32 + { + get { return optionalInt32_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testMutualRecursionBFieldNames; + if (hasA) + { + output.WriteMessage(1, field_names[0], A); + } + if (hasOptionalInt32) + { + output.WriteInt32(2, field_names[1], OptionalInt32); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, A); + } + if (hasOptionalInt32) + { + size += pb::CodedOutputStream.ComputeInt32Size(2, OptionalInt32); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestMutualRecursionB ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestMutualRecursionB ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestMutualRecursionB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestMutualRecursionB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestMutualRecursionB MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestMutualRecursionB prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestMutualRecursionB cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestMutualRecursionB result; + + private TestMutualRecursionB PrepareBuilder() + { + if (resultIsReadOnly) + { + TestMutualRecursionB original = result; + result = new TestMutualRecursionB(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestMutualRecursionB MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Descriptor; } + } + + public override TestMutualRecursionB DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance; } + } + + public override TestMutualRecursionB BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestMutualRecursionB) + { + return MergeFrom((TestMutualRecursionB)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestMutualRecursionB other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + MergeA(other.A); + } + if (other.HasOptionalInt32) + { + OptionalInt32 = other.OptionalInt32; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testMutualRecursionBFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testMutualRecursionBFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.CreateBuilder(); + if (result.hasA) + { + subBuilder.MergeFrom(A); + } + input.ReadMessage(subBuilder, extensionRegistry); + A = subBuilder.BuildPartial(); + break; + } + case 16: + { + result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA + { + get { return result.hasA; } + } + public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasA = true; + result.a_ = builderForValue.Build(); + return this; + } + public Builder MergeA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasA && + result.a_ != global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance) + { + result.a_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.CreateBuilder(result.a_).MergeFrom(value).BuildPartial(); + } + else + { + result.a_ = value; + } + result.hasA = true; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = null; + return this; + } + + public bool HasOptionalInt32 + { + get { return result.hasOptionalInt32; } + } + public int OptionalInt32 + { + get { return result.OptionalInt32; } + set { SetOptionalInt32(value); } + } + public Builder SetOptionalInt32(int value) + { + PrepareBuilder(); + result.hasOptionalInt32 = true; + result.optionalInt32_ = value; + return this; + } + public Builder ClearOptionalInt32() + { + PrepareBuilder(); + result.hasOptionalInt32 = false; + result.optionalInt32_ = 0; + return this; + } + } + static TestMutualRecursionB() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestDupFieldNumber : pb::GeneratedMessage + { + private TestDupFieldNumber() { } + private static readonly TestDupFieldNumber defaultInstance = new TestDupFieldNumber().MakeReadOnly(); + private static readonly string[] _testDupFieldNumberFieldNames = new string[] { "a", "bar", "foo" }; + private static readonly uint[] _testDupFieldNumberFieldTags = new uint[] { 8, 27, 19 }; + public static TestDupFieldNumber DefaultInstance + { + get { return defaultInstance; } + } + + public override TestDupFieldNumber DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestDupFieldNumber ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Foo : pb::GeneratedMessage + { + private Foo() { } + private static readonly Foo defaultInstance = new Foo().MakeReadOnly(); + private static readonly string[] _fooFieldNames = new string[] { "a" }; + private static readonly uint[] _fooFieldTags = new uint[] { 8 }; + public static Foo DefaultInstance + { + get { return defaultInstance; } + } + + public override Foo DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override Foo ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _fooFieldNames; + if (hasA) + { + output.WriteInt32(1, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Foo ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Foo ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Foo ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Foo ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Foo ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Foo ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Foo ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Foo ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Foo ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Foo ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Foo MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Foo prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Foo cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Foo result; + + private Foo PrepareBuilder() + { + if (resultIsReadOnly) + { + Foo original = result; + result = new Foo(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override Foo MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Descriptor; } + } + + public override Foo DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance; } + } + + public override Foo BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is Foo) + { + return MergeFrom((Foo)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Foo other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_fooFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _fooFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static Foo() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Bar : pb::GeneratedMessage + { + private Bar() { } + private static readonly Bar defaultInstance = new Bar().MakeReadOnly(); + private static readonly string[] _barFieldNames = new string[] { "a" }; + private static readonly uint[] _barFieldTags = new uint[] { 8 }; + public static Bar DefaultInstance + { + get { return defaultInstance; } + } + + public override Bar DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override Bar ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _barFieldNames; + if (hasA) + { + output.WriteInt32(1, field_names[0], A); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, A); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Bar ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Bar ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Bar ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Bar ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Bar ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Bar ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Bar ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Bar ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Bar ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Bar ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Bar MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Bar prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Bar cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Bar result; + + private Bar PrepareBuilder() + { + if (resultIsReadOnly) + { + Bar original = result; + result = new Bar(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override Bar MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Descriptor; } + } + + public override Bar DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance; } + } + + public override Bar BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is Bar) + { + return MergeFrom((Bar)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Bar other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_barFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _barFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + } + static Bar() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int AFieldNumber = 1; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } + + public const int FooFieldNumber = 2; + private bool hasFoo; + private global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo foo_; + public bool HasFoo + { + get { return hasFoo; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo Foo + { + get { return foo_ ?? global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance; } + } + + public const int BarFieldNumber = 3; + private bool hasBar; + private global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar bar_; + public bool HasBar + { + get { return hasBar; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar Bar + { + get { return bar_ ?? global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testDupFieldNumberFieldNames; + if (hasA) + { + output.WriteInt32(1, field_names[0], A); + } + if (hasFoo) + { + output.WriteGroup(2, field_names[2], Foo); + } + if (hasBar) + { + output.WriteGroup(3, field_names[1], Bar); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, A); + } + if (hasFoo) + { + size += pb::CodedOutputStream.ComputeGroupSize(2, Foo); + } + if (hasBar) + { + size += pb::CodedOutputStream.ComputeGroupSize(3, Bar); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestDupFieldNumber ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestDupFieldNumber ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestDupFieldNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestDupFieldNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestDupFieldNumber MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestDupFieldNumber prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestDupFieldNumber cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestDupFieldNumber result; + + private TestDupFieldNumber PrepareBuilder() + { + if (resultIsReadOnly) + { + TestDupFieldNumber original = result; + result = new TestDupFieldNumber(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestDupFieldNumber MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Descriptor; } + } + + public override TestDupFieldNumber DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.DefaultInstance; } + } + + public override TestDupFieldNumber BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestDupFieldNumber) + { + return MergeFrom((TestDupFieldNumber)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestDupFieldNumber other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + if (other.HasFoo) + { + MergeFoo(other.Foo); + } + if (other.HasBar) + { + MergeBar(other.Bar); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testDupFieldNumberFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testDupFieldNumberFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 19: + { + global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.CreateBuilder(); + if (result.hasFoo) + { + subBuilder.MergeFrom(Foo); + } + input.ReadGroup(2, subBuilder, extensionRegistry); + Foo = subBuilder.BuildPartial(); + break; + } + case 27: + { + global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.CreateBuilder(); + if (result.hasBar) + { + subBuilder.MergeFrom(Bar); + } + input.ReadGroup(3, subBuilder, extensionRegistry); + Bar = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + + public bool HasFoo + { + get { return result.hasFoo; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo Foo + { + get { return result.Foo; } + set { SetFoo(value); } + } + public Builder SetFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFoo = true; + result.foo_ = value; + return this; + } + public Builder SetFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFoo = true; + result.foo_ = builderForValue.Build(); + return this; + } + public Builder MergeFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFoo && + result.foo_ != global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance) + { + result.foo_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.CreateBuilder(result.foo_).MergeFrom(value).BuildPartial(); + } + else + { + result.foo_ = value; + } + result.hasFoo = true; + return this; + } + public Builder ClearFoo() + { + PrepareBuilder(); + result.hasFoo = false; + result.foo_ = null; + return this; + } + + public bool HasBar + { + get { return result.hasBar; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar Bar + { + get { return result.Bar; } + set { SetBar(value); } + } + public Builder SetBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBar = true; + result.bar_ = value; + return this; + } + public Builder SetBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasBar = true; + result.bar_ = builderForValue.Build(); + return this; + } + public Builder MergeBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasBar && + result.bar_ != global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance) + { + result.bar_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.CreateBuilder(result.bar_).MergeFrom(value).BuildPartial(); + } + else + { + result.bar_ = value; + } + result.hasBar = true; + return this; + } + public Builder ClearBar() + { + PrepareBuilder(); + result.hasBar = false; + result.bar_ = null; + return this; + } + } + static TestDupFieldNumber() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestEagerMessage : pb::GeneratedMessage + { + private TestEagerMessage() { } + private static readonly TestEagerMessage defaultInstance = new TestEagerMessage().MakeReadOnly(); + private static readonly string[] _testEagerMessageFieldNames = new string[] { "sub_message" }; + private static readonly uint[] _testEagerMessageFieldTags = new uint[] { 10 }; + public static TestEagerMessage DefaultInstance + { + get { return defaultInstance; } + } + + public override TestEagerMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestEagerMessage ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEagerMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEagerMessage__FieldAccessorTable; } + } + + public const int SubMessageFieldNumber = 1; + private bool hasSubMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes subMessage_; + public bool HasSubMessage + { + get { return hasSubMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage + { + get { return subMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testEagerMessageFieldNames; + if (hasSubMessage) + { + output.WriteMessage(1, field_names[0], SubMessage); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasSubMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, SubMessage); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestEagerMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestEagerMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestEagerMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestEagerMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestEagerMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestEagerMessage MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestEagerMessage prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestEagerMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestEagerMessage result; + + private TestEagerMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + TestEagerMessage original = result; + result = new TestEagerMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestEagerMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestEagerMessage.Descriptor; } + } + + public override TestEagerMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestEagerMessage.DefaultInstance; } + } + + public override TestEagerMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestEagerMessage) + { + return MergeFrom((TestEagerMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestEagerMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestEagerMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasSubMessage) + { + MergeSubMessage(other.SubMessage); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testEagerMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testEagerMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasSubMessage) + { + subBuilder.MergeFrom(SubMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + SubMessage = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasSubMessage + { + get { return result.hasSubMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage + { + get { return result.SubMessage; } + set { SetSubMessage(value); } + } + public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasSubMessage = true; + result.subMessage_ = value; + return this; + } + public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasSubMessage = true; + result.subMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasSubMessage && + result.subMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.subMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.subMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.subMessage_ = value; + } + result.hasSubMessage = true; + return this; + } + public Builder ClearSubMessage() + { + PrepareBuilder(); + result.hasSubMessage = false; + result.subMessage_ = null; + return this; + } + } + static TestEagerMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestLazyMessage : pb::GeneratedMessage + { + private TestLazyMessage() { } + private static readonly TestLazyMessage defaultInstance = new TestLazyMessage().MakeReadOnly(); + private static readonly string[] _testLazyMessageFieldNames = new string[] { "sub_message" }; + private static readonly uint[] _testLazyMessageFieldTags = new uint[] { 10 }; + public static TestLazyMessage DefaultInstance + { + get { return defaultInstance; } + } + + public override TestLazyMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestLazyMessage ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestLazyMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestLazyMessage__FieldAccessorTable; } + } + + public const int SubMessageFieldNumber = 1; + private bool hasSubMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes subMessage_; + public bool HasSubMessage + { + get { return hasSubMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage + { + get { return subMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testLazyMessageFieldNames; + if (hasSubMessage) + { + output.WriteMessage(1, field_names[0], SubMessage); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasSubMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, SubMessage); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestLazyMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestLazyMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestLazyMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestLazyMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestLazyMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestLazyMessage MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestLazyMessage prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestLazyMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestLazyMessage result; + + private TestLazyMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + TestLazyMessage original = result; + result = new TestLazyMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestLazyMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestLazyMessage.Descriptor; } + } + + public override TestLazyMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestLazyMessage.DefaultInstance; } + } + + public override TestLazyMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestLazyMessage) + { + return MergeFrom((TestLazyMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestLazyMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestLazyMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasSubMessage) + { + MergeSubMessage(other.SubMessage); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testLazyMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testLazyMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasSubMessage) + { + subBuilder.MergeFrom(SubMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + SubMessage = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasSubMessage + { + get { return result.hasSubMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage + { + get { return result.SubMessage; } + set { SetSubMessage(value); } + } + public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasSubMessage = true; + result.subMessage_ = value; + return this; + } + public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasSubMessage = true; + result.subMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasSubMessage && + result.subMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.subMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.subMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.subMessage_ = value; + } + result.hasSubMessage = true; + return this; + } + public Builder ClearSubMessage() + { + PrepareBuilder(); + result.hasSubMessage = false; + result.subMessage_ = null; + return this; + } + } + static TestLazyMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestNestedMessageHasBits : pb::GeneratedMessage + { + private TestNestedMessageHasBits() { } + private static readonly TestNestedMessageHasBits defaultInstance = new TestNestedMessageHasBits().MakeReadOnly(); + private static readonly string[] _testNestedMessageHasBitsFieldNames = new string[] { "optional_nested_message" }; + private static readonly uint[] _testNestedMessageHasBitsFieldTags = new uint[] { 10 }; + public static TestNestedMessageHasBits DefaultInstance + { + get { return defaultInstance; } + } + + public override TestNestedMessageHasBits DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestNestedMessageHasBits ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessage + { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "nestedmessage_repeated_foreignmessage", "nestedmessage_repeated_int32" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 18, 8 }; + public static NestedMessage DefaultInstance + { + get { return defaultInstance; } + } + + public override NestedMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override NestedMessage ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable; } + } + + public const int NestedmessageRepeatedInt32FieldNumber = 1; + private pbc::PopsicleList nestedmessageRepeatedInt32_ = new pbc::PopsicleList(); + public scg::IList NestedmessageRepeatedInt32List + { + get { return pbc::Lists.AsReadOnly(nestedmessageRepeatedInt32_); } + } + public int NestedmessageRepeatedInt32Count + { + get { return nestedmessageRepeatedInt32_.Count; } + } + public int GetNestedmessageRepeatedInt32(int index) + { + return nestedmessageRepeatedInt32_[index]; + } + + public const int NestedmessageRepeatedForeignmessageFieldNumber = 2; + private pbc::PopsicleList nestedmessageRepeatedForeignmessage_ = new pbc::PopsicleList(); + public scg::IList NestedmessageRepeatedForeignmessageList + { + get { return nestedmessageRepeatedForeignmessage_; } + } + public int NestedmessageRepeatedForeignmessageCount + { + get { return nestedmessageRepeatedForeignmessage_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetNestedmessageRepeatedForeignmessage(int index) + { + return nestedmessageRepeatedForeignmessage_[index]; + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (nestedmessageRepeatedInt32_.Count > 0) + { + output.WriteInt32Array(1, field_names[1], nestedmessageRepeatedInt32_); + } + if (nestedmessageRepeatedForeignmessage_.Count > 0) + { + output.WriteMessageArray(2, field_names[0], nestedmessageRepeatedForeignmessage_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + foreach (int element in NestedmessageRepeatedInt32List) + { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 1 * nestedmessageRepeatedInt32_.Count; + } + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in NestedmessageRepeatedForeignmessageList) + { + size += pb::CodedOutputStream.ComputeMessageSize(2, element); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() + { + nestedmessageRepeatedInt32_.MakeReadOnly(); + nestedmessageRepeatedForeignmessage_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override NestedMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Descriptor; } + } + + public override NestedMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance; } + } + + public override NestedMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is NestedMessage) + { + return MergeFrom((NestedMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NestedMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.nestedmessageRepeatedInt32_.Count != 0) + { + result.nestedmessageRepeatedInt32_.Add(other.nestedmessageRepeatedInt32_); + } + if (other.nestedmessageRepeatedForeignmessage_.Count != 0) + { + result.nestedmessageRepeatedForeignmessage_.Add(other.nestedmessageRepeatedForeignmessage_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + case 8: + { + input.ReadInt32Array(tag, field_name, result.nestedmessageRepeatedInt32_); + break; + } + case 18: + { + input.ReadMessageArray(tag, field_name, result.nestedmessageRepeatedForeignmessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList NestedmessageRepeatedInt32List + { + get { return PrepareBuilder().nestedmessageRepeatedInt32_; } + } + public int NestedmessageRepeatedInt32Count + { + get { return result.NestedmessageRepeatedInt32Count; } + } + public int GetNestedmessageRepeatedInt32(int index) + { + return result.GetNestedmessageRepeatedInt32(index); + } + public Builder SetNestedmessageRepeatedInt32(int index, int value) + { + PrepareBuilder(); + result.nestedmessageRepeatedInt32_[index] = value; + return this; + } + public Builder AddNestedmessageRepeatedInt32(int value) + { + PrepareBuilder(); + result.nestedmessageRepeatedInt32_.Add(value); + return this; + } + public Builder AddRangeNestedmessageRepeatedInt32(scg::IEnumerable values) + { + PrepareBuilder(); + result.nestedmessageRepeatedInt32_.Add(values); + return this; + } + public Builder ClearNestedmessageRepeatedInt32() + { + PrepareBuilder(); + result.nestedmessageRepeatedInt32_.Clear(); + return this; + } + + public pbc::IPopsicleList NestedmessageRepeatedForeignmessageList + { + get { return PrepareBuilder().nestedmessageRepeatedForeignmessage_; } + } + public int NestedmessageRepeatedForeignmessageCount + { + get { return result.NestedmessageRepeatedForeignmessageCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetNestedmessageRepeatedForeignmessage(int index) + { + return result.GetNestedmessageRepeatedForeignmessage(index); + } + public Builder SetNestedmessageRepeatedForeignmessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_[index] = value; + return this; + } + public Builder SetNestedmessageRepeatedForeignmessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_[index] = builderForValue.Build(); + return this; + } + public Builder AddNestedmessageRepeatedForeignmessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_.Add(value); + return this; + } + public Builder AddNestedmessageRepeatedForeignmessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeNestedmessageRepeatedForeignmessage(scg::IEnumerable values) + { + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_.Add(values); + return this; + } + public Builder ClearNestedmessageRepeatedForeignmessage() + { + PrepareBuilder(); + result.nestedmessageRepeatedForeignmessage_.Clear(); + return this; + } + } + static NestedMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int OptionalNestedMessageFieldNumber = 1; + private bool hasOptionalNestedMessage; + private global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage optionalNestedMessage_; + public bool HasOptionalNestedMessage + { + get { return hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage OptionalNestedMessage + { + get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testNestedMessageHasBitsFieldNames; + if (hasOptionalNestedMessage) + { + output.WriteMessage(1, field_names[0], OptionalNestedMessage); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOptionalNestedMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, OptionalNestedMessage); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestNestedMessageHasBits ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestNestedMessageHasBits ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestNestedMessageHasBits ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestNestedMessageHasBits MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestNestedMessageHasBits prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestNestedMessageHasBits cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestNestedMessageHasBits result; + + private TestNestedMessageHasBits PrepareBuilder() + { + if (resultIsReadOnly) + { + TestNestedMessageHasBits original = result; + result = new TestNestedMessageHasBits(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestNestedMessageHasBits MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Descriptor; } + } + + public override TestNestedMessageHasBits DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.DefaultInstance; } + } + + public override TestNestedMessageHasBits BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestNestedMessageHasBits) + { + return MergeFrom((TestNestedMessageHasBits)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestNestedMessageHasBits other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOptionalNestedMessage) + { + MergeOptionalNestedMessage(other.OptionalNestedMessage); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testNestedMessageHasBitsFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testNestedMessageHasBitsFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.CreateBuilder(); + if (result.hasOptionalNestedMessage) + { + subBuilder.MergeFrom(OptionalNestedMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalNestedMessage = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasOptionalNestedMessage + { + get { return result.hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage OptionalNestedMessage + { + get { return result.OptionalNestedMessage; } + set { SetOptionalNestedMessage(value); } + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = value; + return this; + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalNestedMessage && + result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance) + { + result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalNestedMessage_ = value; + } + result.hasOptionalNestedMessage = true; + return this; + } + public Builder ClearOptionalNestedMessage() + { + PrepareBuilder(); + result.hasOptionalNestedMessage = false; + result.optionalNestedMessage_ = null; + return this; + } + } + static TestNestedMessageHasBits() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestCamelCaseFieldNames : pb::GeneratedMessage + { + private TestCamelCaseFieldNames() { } + private static readonly TestCamelCaseFieldNames defaultInstance = new TestCamelCaseFieldNames().MakeReadOnly(); + private static readonly string[] _testCamelCaseFieldNamesFieldNames = new string[] { "CordField", "EnumField", "MessageField", "PrimitiveField", "RepeatedCordField", "RepeatedEnumField", "RepeatedMessageField", "RepeatedPrimitiveField", "RepeatedStringField", "RepeatedStringPieceField", "StringField", "StringPieceField" }; + private static readonly uint[] _testCamelCaseFieldNamesFieldTags = new uint[] { 50, 24, 34, 8, 98, 72, 82, 56, 66, 90, 18, 42 }; + public static TestCamelCaseFieldNames DefaultInstance + { + get { return defaultInstance; } + } + + public override TestCamelCaseFieldNames DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestCamelCaseFieldNames ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable; } + } + + public const int PrimitiveFieldFieldNumber = 1; + private bool hasPrimitiveField; + private int primitiveField_; + public bool HasPrimitiveField + { + get { return hasPrimitiveField; } + } + public int PrimitiveField + { + get { return primitiveField_; } + } + + public const int StringFieldFieldNumber = 2; + private bool hasStringField; + private string stringField_ = ""; + public bool HasStringField + { + get { return hasStringField; } + } + public string StringField + { + get { return stringField_; } + } + + public const int EnumFieldFieldNumber = 3; + private bool hasEnumField; + private global::Google.ProtocolBuffers.TestProtos.ForeignEnum enumField_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + public bool HasEnumField + { + get { return hasEnumField; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumField + { + get { return enumField_; } + } + + public const int MessageFieldFieldNumber = 4; + private bool hasMessageField; + private global::Google.ProtocolBuffers.TestProtos.ForeignMessage messageField_; + public bool HasMessageField + { + get { return hasMessageField; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageField + { + get { return messageField_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } + } + + public const int StringPieceFieldFieldNumber = 5; + private bool hasStringPieceField; + private string stringPieceField_ = ""; + public bool HasStringPieceField + { + get { return hasStringPieceField; } + } + public string StringPieceField + { + get { return stringPieceField_; } + } + + public const int CordFieldFieldNumber = 6; + private bool hasCordField; + private string cordField_ = ""; + public bool HasCordField + { + get { return hasCordField; } + } + public string CordField + { + get { return cordField_; } + } + + public const int RepeatedPrimitiveFieldFieldNumber = 7; + private pbc::PopsicleList repeatedPrimitiveField_ = new pbc::PopsicleList(); + public scg::IList RepeatedPrimitiveFieldList + { + get { return pbc::Lists.AsReadOnly(repeatedPrimitiveField_); } + } + public int RepeatedPrimitiveFieldCount + { + get { return repeatedPrimitiveField_.Count; } + } + public int GetRepeatedPrimitiveField(int index) + { + return repeatedPrimitiveField_[index]; + } + + public const int RepeatedStringFieldFieldNumber = 8; + private pbc::PopsicleList repeatedStringField_ = new pbc::PopsicleList(); + public scg::IList RepeatedStringFieldList + { + get { return pbc::Lists.AsReadOnly(repeatedStringField_); } + } + public int RepeatedStringFieldCount + { + get { return repeatedStringField_.Count; } + } + public string GetRepeatedStringField(int index) + { + return repeatedStringField_[index]; + } + + public const int RepeatedEnumFieldFieldNumber = 9; + private pbc::PopsicleList repeatedEnumField_ = new pbc::PopsicleList(); + public scg::IList RepeatedEnumFieldList + { + get { return pbc::Lists.AsReadOnly(repeatedEnumField_); } + } + public int RepeatedEnumFieldCount + { + get { return repeatedEnumField_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedEnumField(int index) + { + return repeatedEnumField_[index]; + } + + public const int RepeatedMessageFieldFieldNumber = 10; + private pbc::PopsicleList repeatedMessageField_ = new pbc::PopsicleList(); + public scg::IList RepeatedMessageFieldList + { + get { return repeatedMessageField_; } + } + public int RepeatedMessageFieldCount + { + get { return repeatedMessageField_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedMessageField(int index) + { + return repeatedMessageField_[index]; + } + + public const int RepeatedStringPieceFieldFieldNumber = 11; + private pbc::PopsicleList repeatedStringPieceField_ = new pbc::PopsicleList(); + public scg::IList RepeatedStringPieceFieldList + { + get { return pbc::Lists.AsReadOnly(repeatedStringPieceField_); } + } + public int RepeatedStringPieceFieldCount + { + get { return repeatedStringPieceField_.Count; } + } + public string GetRepeatedStringPieceField(int index) + { + return repeatedStringPieceField_[index]; + } + + public const int RepeatedCordFieldFieldNumber = 12; + private pbc::PopsicleList repeatedCordField_ = new pbc::PopsicleList(); + public scg::IList RepeatedCordFieldList + { + get { return pbc::Lists.AsReadOnly(repeatedCordField_); } + } + public int RepeatedCordFieldCount + { + get { return repeatedCordField_.Count; } + } + public string GetRepeatedCordField(int index) + { + return repeatedCordField_[index]; + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testCamelCaseFieldNamesFieldNames; + if (hasPrimitiveField) + { + output.WriteInt32(1, field_names[3], PrimitiveField); + } + if (hasStringField) + { + output.WriteString(2, field_names[10], StringField); + } + if (hasEnumField) + { + output.WriteEnum(3, field_names[1], (int)EnumField, EnumField); + } + if (hasMessageField) + { + output.WriteMessage(4, field_names[2], MessageField); + } + if (hasStringPieceField) + { + output.WriteString(5, field_names[11], StringPieceField); + } + if (hasCordField) + { + output.WriteString(6, field_names[0], CordField); + } + if (repeatedPrimitiveField_.Count > 0) + { + output.WriteInt32Array(7, field_names[7], repeatedPrimitiveField_); + } + if (repeatedStringField_.Count > 0) + { + output.WriteStringArray(8, field_names[8], repeatedStringField_); + } + if (repeatedEnumField_.Count > 0) + { + output.WriteEnumArray(9, field_names[5], repeatedEnumField_); + } + if (repeatedMessageField_.Count > 0) + { + output.WriteMessageArray(10, field_names[6], repeatedMessageField_); + } + if (repeatedStringPieceField_.Count > 0) + { + output.WriteStringArray(11, field_names[9], repeatedStringPieceField_); + } + if (repeatedCordField_.Count > 0) + { + output.WriteStringArray(12, field_names[4], repeatedCordField_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasPrimitiveField) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, PrimitiveField); + } + if (hasStringField) + { + size += pb::CodedOutputStream.ComputeStringSize(2, StringField); + } + if (hasEnumField) + { + size += pb::CodedOutputStream.ComputeEnumSize(3, (int)EnumField); + } + if (hasMessageField) + { + size += pb::CodedOutputStream.ComputeMessageSize(4, MessageField); + } + if (hasStringPieceField) + { + size += pb::CodedOutputStream.ComputeStringSize(5, StringPieceField); + } + if (hasCordField) + { + size += pb::CodedOutputStream.ComputeStringSize(6, CordField); + } + { + int dataSize = 0; + foreach (int element in RepeatedPrimitiveFieldList) + { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 1 * repeatedPrimitiveField_.Count; + } + { + int dataSize = 0; + foreach (string element in RepeatedStringFieldList) + { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 1 * repeatedStringField_.Count; + } + { + int dataSize = 0; + if (repeatedEnumField_.Count > 0) + { + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedEnumField_) + { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int)element); + } + size += dataSize; + size += 1 * repeatedEnumField_.Count; + } + } + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedMessageFieldList) + { + size += pb::CodedOutputStream.ComputeMessageSize(10, element); + } + { + int dataSize = 0; + foreach (string element in RepeatedStringPieceFieldList) + { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 1 * repeatedStringPieceField_.Count; + } + { + int dataSize = 0; + foreach (string element in RepeatedCordFieldList) + { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 1 * repeatedCordField_.Count; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestCamelCaseFieldNames ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestCamelCaseFieldNames ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestCamelCaseFieldNames MakeReadOnly() + { + repeatedPrimitiveField_.MakeReadOnly(); + repeatedStringField_.MakeReadOnly(); + repeatedEnumField_.MakeReadOnly(); + repeatedMessageField_.MakeReadOnly(); + repeatedStringPieceField_.MakeReadOnly(); + repeatedCordField_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestCamelCaseFieldNames prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestCamelCaseFieldNames cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestCamelCaseFieldNames result; + + private TestCamelCaseFieldNames PrepareBuilder() + { + if (resultIsReadOnly) + { + TestCamelCaseFieldNames original = result; + result = new TestCamelCaseFieldNames(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestCamelCaseFieldNames MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.Descriptor; } + } + + public override TestCamelCaseFieldNames DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.DefaultInstance; } + } + + public override TestCamelCaseFieldNames BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestCamelCaseFieldNames) + { + return MergeFrom((TestCamelCaseFieldNames)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestCamelCaseFieldNames other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasPrimitiveField) + { + PrimitiveField = other.PrimitiveField; + } + if (other.HasStringField) + { + StringField = other.StringField; + } + if (other.HasEnumField) + { + EnumField = other.EnumField; + } + if (other.HasMessageField) + { + MergeMessageField(other.MessageField); + } + if (other.HasStringPieceField) + { + StringPieceField = other.StringPieceField; + } + if (other.HasCordField) + { + CordField = other.CordField; + } + if (other.repeatedPrimitiveField_.Count != 0) + { + result.repeatedPrimitiveField_.Add(other.repeatedPrimitiveField_); + } + if (other.repeatedStringField_.Count != 0) + { + result.repeatedStringField_.Add(other.repeatedStringField_); + } + if (other.repeatedEnumField_.Count != 0) + { + result.repeatedEnumField_.Add(other.repeatedEnumField_); + } + if (other.repeatedMessageField_.Count != 0) + { + result.repeatedMessageField_.Add(other.repeatedMessageField_); + } + if (other.repeatedStringPieceField_.Count != 0) + { + result.repeatedStringPieceField_.Add(other.repeatedStringPieceField_); + } + if (other.repeatedCordField_.Count != 0) + { + result.repeatedCordField_.Add(other.repeatedCordField_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testCamelCaseFieldNamesFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testCamelCaseFieldNamesFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasPrimitiveField = input.ReadInt32(ref result.primitiveField_); + break; + } + case 18: + { + result.hasStringField = input.ReadString(ref result.stringField_); + break; + } + case 24: + { + object unknown; + if (input.ReadEnum(ref result.enumField_, out unknown)) + { + result.hasEnumField = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(3, (ulong)(int)unknown); + } + break; + } + case 34: + { + global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); + if (result.hasMessageField) + { + subBuilder.MergeFrom(MessageField); + } + input.ReadMessage(subBuilder, extensionRegistry); + MessageField = subBuilder.BuildPartial(); + break; + } + case 42: + { + result.hasStringPieceField = input.ReadString(ref result.stringPieceField_); + break; + } + case 50: + { + result.hasCordField = input.ReadString(ref result.cordField_); + break; + } + case 58: + case 56: + { + input.ReadInt32Array(tag, field_name, result.repeatedPrimitiveField_); + break; + } + case 66: + { + input.ReadStringArray(tag, field_name, result.repeatedStringField_); + break; + } + case 74: + case 72: + { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.repeatedEnumField_, out unknownItems); + if (unknownItems != null) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(9, (ulong)(int)rawValue); + } + break; + } + case 82: + { + input.ReadMessageArray(tag, field_name, result.repeatedMessageField_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); + break; + } + case 90: + { + input.ReadStringArray(tag, field_name, result.repeatedStringPieceField_); + break; + } + case 98: + { + input.ReadStringArray(tag, field_name, result.repeatedCordField_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasPrimitiveField + { + get { return result.hasPrimitiveField; } + } + public int PrimitiveField + { + get { return result.PrimitiveField; } + set { SetPrimitiveField(value); } + } + public Builder SetPrimitiveField(int value) + { + PrepareBuilder(); + result.hasPrimitiveField = true; + result.primitiveField_ = value; + return this; + } + public Builder ClearPrimitiveField() + { + PrepareBuilder(); + result.hasPrimitiveField = false; + result.primitiveField_ = 0; + return this; + } + + public bool HasStringField + { + get { return result.hasStringField; } + } + public string StringField + { + get { return result.StringField; } + set { SetStringField(value); } + } + public Builder SetStringField(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasStringField = true; + result.stringField_ = value; + return this; + } + public Builder ClearStringField() + { + PrepareBuilder(); + result.hasStringField = false; + result.stringField_ = ""; + return this; + } + + public bool HasEnumField + { + get { return result.hasEnumField; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumField + { + get { return result.EnumField; } + set { SetEnumField(value); } + } + public Builder SetEnumField(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.hasEnumField = true; + result.enumField_ = value; + return this; + } + public Builder ClearEnumField() + { + PrepareBuilder(); + result.hasEnumField = false; + result.enumField_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + return this; + } + + public bool HasMessageField + { + get { return result.hasMessageField; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageField + { + get { return result.MessageField; } + set { SetMessageField(value); } + } + public Builder SetMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasMessageField = true; + result.messageField_ = value; + return this; + } + public Builder SetMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasMessageField = true; + result.messageField_ = builderForValue.Build(); + return this; + } + public Builder MergeMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasMessageField && + result.messageField_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) + { + result.messageField_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.messageField_).MergeFrom(value).BuildPartial(); + } + else + { + result.messageField_ = value; + } + result.hasMessageField = true; + return this; + } + public Builder ClearMessageField() + { + PrepareBuilder(); + result.hasMessageField = false; + result.messageField_ = null; + return this; + } + + public bool HasStringPieceField + { + get { return result.hasStringPieceField; } + } + public string StringPieceField + { + get { return result.StringPieceField; } + set { SetStringPieceField(value); } + } + public Builder SetStringPieceField(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasStringPieceField = true; + result.stringPieceField_ = value; + return this; + } + public Builder ClearStringPieceField() + { + PrepareBuilder(); + result.hasStringPieceField = false; + result.stringPieceField_ = ""; + return this; + } + + public bool HasCordField + { + get { return result.hasCordField; } + } + public string CordField + { + get { return result.CordField; } + set { SetCordField(value); } + } + public Builder SetCordField(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasCordField = true; + result.cordField_ = value; + return this; + } + public Builder ClearCordField() + { + PrepareBuilder(); + result.hasCordField = false; + result.cordField_ = ""; + return this; + } + + public pbc::IPopsicleList RepeatedPrimitiveFieldList + { + get { return PrepareBuilder().repeatedPrimitiveField_; } + } + public int RepeatedPrimitiveFieldCount + { + get { return result.RepeatedPrimitiveFieldCount; } + } + public int GetRepeatedPrimitiveField(int index) + { + return result.GetRepeatedPrimitiveField(index); + } + public Builder SetRepeatedPrimitiveField(int index, int value) + { + PrepareBuilder(); + result.repeatedPrimitiveField_[index] = value; + return this; + } + public Builder AddRepeatedPrimitiveField(int value) + { + PrepareBuilder(); + result.repeatedPrimitiveField_.Add(value); + return this; + } + public Builder AddRangeRepeatedPrimitiveField(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedPrimitiveField_.Add(values); + return this; + } + public Builder ClearRepeatedPrimitiveField() + { + PrepareBuilder(); + result.repeatedPrimitiveField_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedStringFieldList + { + get { return PrepareBuilder().repeatedStringField_; } + } + public int RepeatedStringFieldCount + { + get { return result.RepeatedStringFieldCount; } + } + public string GetRepeatedStringField(int index) + { + return result.GetRepeatedStringField(index); + } + public Builder SetRepeatedStringField(int index, string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringField_[index] = value; + return this; + } + public Builder AddRepeatedStringField(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringField_.Add(value); + return this; + } + public Builder AddRangeRepeatedStringField(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedStringField_.Add(values); + return this; + } + public Builder ClearRepeatedStringField() + { + PrepareBuilder(); + result.repeatedStringField_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedEnumFieldList + { + get { return PrepareBuilder().repeatedEnumField_; } + } + public int RepeatedEnumFieldCount + { + get { return result.RepeatedEnumFieldCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedEnumField(int index) + { + return result.GetRepeatedEnumField(index); + } + public Builder SetRepeatedEnumField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.repeatedEnumField_[index] = value; + return this; + } + public Builder AddRepeatedEnumField(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.repeatedEnumField_.Add(value); + return this; + } + public Builder AddRangeRepeatedEnumField(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedEnumField_.Add(values); + return this; + } + public Builder ClearRepeatedEnumField() + { + PrepareBuilder(); + result.repeatedEnumField_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedMessageFieldList + { + get { return PrepareBuilder().repeatedMessageField_; } + } + public int RepeatedMessageFieldCount + { + get { return result.RepeatedMessageFieldCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedMessageField(int index) + { + return result.GetRepeatedMessageField(index); + } + public Builder SetRepeatedMessageField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedMessageField_[index] = value; + return this; + } + public Builder SetRepeatedMessageField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedMessageField_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedMessageField_.Add(value); + return this; + } + public Builder AddRepeatedMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedMessageField_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedMessageField(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedMessageField_.Add(values); + return this; + } + public Builder ClearRepeatedMessageField() + { + PrepareBuilder(); + result.repeatedMessageField_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedStringPieceFieldList + { + get { return PrepareBuilder().repeatedStringPieceField_; } + } + public int RepeatedStringPieceFieldCount + { + get { return result.RepeatedStringPieceFieldCount; } + } + public string GetRepeatedStringPieceField(int index) + { + return result.GetRepeatedStringPieceField(index); + } + public Builder SetRepeatedStringPieceField(int index, string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringPieceField_[index] = value; + return this; + } + public Builder AddRepeatedStringPieceField(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedStringPieceField_.Add(value); + return this; + } + public Builder AddRangeRepeatedStringPieceField(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedStringPieceField_.Add(values); + return this; + } + public Builder ClearRepeatedStringPieceField() + { + PrepareBuilder(); + result.repeatedStringPieceField_.Clear(); + return this; + } + + public pbc::IPopsicleList RepeatedCordFieldList + { + get { return PrepareBuilder().repeatedCordField_; } + } + public int RepeatedCordFieldCount + { + get { return result.RepeatedCordFieldCount; } + } + public string GetRepeatedCordField(int index) + { + return result.GetRepeatedCordField(index); + } + public Builder SetRepeatedCordField(int index, string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedCordField_[index] = value; + return this; + } + public Builder AddRepeatedCordField(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedCordField_.Add(value); + return this; + } + public Builder AddRangeRepeatedCordField(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedCordField_.Add(values); + return this; + } + public Builder ClearRepeatedCordField() + { + PrepareBuilder(); + result.repeatedCordField_.Clear(); + return this; + } + } + static TestCamelCaseFieldNames() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestFieldOrderings : pb::ExtendableMessage + { + private TestFieldOrderings() { } + private static readonly TestFieldOrderings defaultInstance = new TestFieldOrderings().MakeReadOnly(); + private static readonly string[] _testFieldOrderingsFieldNames = new string[] { "my_float", "my_int", "my_string", "optional_nested_message" }; + private static readonly uint[] _testFieldOrderingsFieldTags = new uint[] { 813, 8, 90, 1602 }; + public static TestFieldOrderings DefaultInstance + { + get { return defaultInstance; } + } + + public override TestFieldOrderings DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestFieldOrderings ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessage + { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "bb", "oo" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8, 16 }; + public static NestedMessage DefaultInstance + { + get { return defaultInstance; } + } + + public override NestedMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override NestedMessage ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__FieldAccessorTable; } + } + + public const int OoFieldNumber = 2; + private bool hasOo; + private long oo_; + public bool HasOo + { + get { return hasOo; } + } + public long Oo + { + get { return oo_; } + } + + public const int BbFieldNumber = 1; + private bool hasBb; + private int bb_; + public bool HasBb + { + get { return hasBb; } + } + public int Bb + { + get { return bb_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (hasBb) + { + output.WriteInt32(1, field_names[0], Bb); + } + if (hasOo) + { + output.WriteInt64(2, field_names[1], Oo); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasOo) + { + size += pb::CodedOutputStream.ComputeInt64Size(2, Oo); + } + if (hasBb) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, Bb); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override NestedMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.Descriptor; } + } + + public override NestedMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance; } + } + + public override NestedMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is NestedMessage) + { + return MergeFrom((NestedMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(NestedMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOo) + { + Oo = other.Oo; + } + if (other.HasBb) + { + Bb = other.Bb; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasBb = input.ReadInt32(ref result.bb_); + break; + } + case 16: + { + result.hasOo = input.ReadInt64(ref result.oo_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasOo + { + get { return result.hasOo; } + } + public long Oo + { + get { return result.Oo; } + set { SetOo(value); } + } + public Builder SetOo(long value) + { + PrepareBuilder(); + result.hasOo = true; + result.oo_ = value; + return this; + } + public Builder ClearOo() + { + PrepareBuilder(); + result.hasOo = false; + result.oo_ = 0L; + return this; + } + + public bool HasBb + { + get { return result.hasBb; } + } + public int Bb + { + get { return result.Bb; } + set { SetBb(value); } + } + public Builder SetBb(int value) + { + PrepareBuilder(); + result.hasBb = true; + result.bb_ = value; + return this; + } + public Builder ClearBb() + { + PrepareBuilder(); + result.hasBb = false; + result.bb_ = 0; + return this; + } + } + static NestedMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int MyStringFieldNumber = 11; + private bool hasMyString; + private string myString_ = ""; + public bool HasMyString + { + get { return hasMyString; } + } + public string MyString + { + get { return myString_; } + } + + public const int MyIntFieldNumber = 1; + private bool hasMyInt; + private long myInt_; + public bool HasMyInt + { + get { return hasMyInt; } + } + public long MyInt + { + get { return myInt_; } + } + + public const int MyFloatFieldNumber = 101; + private bool hasMyFloat; + private float myFloat_; + public bool HasMyFloat + { + get { return hasMyFloat; } + } + public float MyFloat + { + get { return myFloat_; } + } + + public const int OptionalNestedMessageFieldNumber = 200; + private bool hasOptionalNestedMessage; + private global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage optionalNestedMessage_; + public bool HasOptionalNestedMessage + { + get { return hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage OptionalNestedMessage + { + get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance; } + } + + public override bool IsInitialized + { + get + { + if (!ExtensionsAreInitialized) return false; + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testFieldOrderingsFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + if (hasMyInt) + { + output.WriteInt64(1, field_names[1], MyInt); + } + extensionWriter.WriteUntil(11, output); + if (hasMyString) + { + output.WriteString(11, field_names[2], MyString); + } + extensionWriter.WriteUntil(101, output); + if (hasMyFloat) + { + output.WriteFloat(101, field_names[0], MyFloat); + } + if (hasOptionalNestedMessage) + { + output.WriteMessage(200, field_names[3], OptionalNestedMessage); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasMyString) + { + size += pb::CodedOutputStream.ComputeStringSize(11, MyString); + } + if (hasMyInt) + { + size += pb::CodedOutputStream.ComputeInt64Size(1, MyInt); + } + if (hasMyFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(101, MyFloat); + } + if (hasOptionalNestedMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(200, OptionalNestedMessage); + } + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestFieldOrderings ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestFieldOrderings ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestFieldOrderings ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestFieldOrderings ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestFieldOrderings MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestFieldOrderings prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestFieldOrderings cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestFieldOrderings result; + + private TestFieldOrderings PrepareBuilder() + { + if (resultIsReadOnly) + { + TestFieldOrderings original = result; + result = new TestFieldOrderings(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestFieldOrderings MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Descriptor; } + } + + public override TestFieldOrderings DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.DefaultInstance; } + } + + public override TestFieldOrderings BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestFieldOrderings) + { + return MergeFrom((TestFieldOrderings)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestFieldOrderings other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasMyString) + { + MyString = other.MyString; + } + if (other.HasMyInt) + { + MyInt = other.MyInt; + } + if (other.HasMyFloat) + { + MyFloat = other.MyFloat; + } + if (other.HasOptionalNestedMessage) + { + MergeOptionalNestedMessage(other.OptionalNestedMessage); + } + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testFieldOrderingsFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testFieldOrderingsFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasMyInt = input.ReadInt64(ref result.myInt_); + break; + } + case 90: + { + result.hasMyString = input.ReadString(ref result.myString_); + break; + } + case 813: + { + result.hasMyFloat = input.ReadFloat(ref result.myFloat_); + break; + } + case 1602: + { + global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.CreateBuilder(); + if (result.hasOptionalNestedMessage) + { + subBuilder.MergeFrom(OptionalNestedMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalNestedMessage = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasMyString + { + get { return result.hasMyString; } + } + public string MyString + { + get { return result.MyString; } + set { SetMyString(value); } + } + public Builder SetMyString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasMyString = true; + result.myString_ = value; + return this; + } + public Builder ClearMyString() + { + PrepareBuilder(); + result.hasMyString = false; + result.myString_ = ""; + return this; + } + + public bool HasMyInt + { + get { return result.hasMyInt; } + } + public long MyInt + { + get { return result.MyInt; } + set { SetMyInt(value); } + } + public Builder SetMyInt(long value) + { + PrepareBuilder(); + result.hasMyInt = true; + result.myInt_ = value; + return this; + } + public Builder ClearMyInt() + { + PrepareBuilder(); + result.hasMyInt = false; + result.myInt_ = 0L; + return this; + } + + public bool HasMyFloat + { + get { return result.hasMyFloat; } + } + public float MyFloat + { + get { return result.MyFloat; } + set { SetMyFloat(value); } + } + public Builder SetMyFloat(float value) + { + PrepareBuilder(); + result.hasMyFloat = true; + result.myFloat_ = value; + return this; + } + public Builder ClearMyFloat() + { + PrepareBuilder(); + result.hasMyFloat = false; + result.myFloat_ = 0F; + return this; + } + + public bool HasOptionalNestedMessage + { + get { return result.hasOptionalNestedMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage OptionalNestedMessage + { + get { return result.OptionalNestedMessage; } + set { SetOptionalNestedMessage(value); } + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = value; + return this; + } + public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalNestedMessage = true; + result.optionalNestedMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalNestedMessage && + result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance) + { + result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalNestedMessage_ = value; + } + result.hasOptionalNestedMessage = true; + return this; + } + public Builder ClearOptionalNestedMessage() + { + PrepareBuilder(); + result.hasOptionalNestedMessage = false; + result.optionalNestedMessage_ = null; + return this; + } + } + static TestFieldOrderings() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestExtremeDefaultValues : pb::GeneratedMessage + { + private TestExtremeDefaultValues() { } + private static readonly TestExtremeDefaultValues defaultInstance = new TestExtremeDefaultValues().MakeReadOnly(); + private static readonly string[] _testExtremeDefaultValuesFieldNames = new string[] { "bytes_with_zero", "cord_with_zero", "cpp_trigraph", "escaped_bytes", "inf_double", "inf_float", "large_float", "large_uint32", "large_uint64", "nan_double", "nan_float", "neg_inf_double", "neg_inf_float", "negative_float", "negative_one_float", "one_float", "really_small_int32", "really_small_int64", "replacement_string", "small_float", "small_int32", "small_int64", "small_negative_float", "string_piece_with_zero", "string_with_zero", "utf8_string", "zero_float" }; + private static readonly uint[] _testExtremeDefaultValuesFieldTags = new uint[] { 194, 210, 162, 10, 113, 141, 101, 16, 24, 129, 157, 121, 149, 93, 85, 69, 168, 176, 218, 77, 32, 40, 109, 202, 186, 50, 61 }; + public static TestExtremeDefaultValues DefaultInstance + { + get { return defaultInstance; } + } + + public override TestExtremeDefaultValues DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestExtremeDefaultValues ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable; } + } + + public const int EscapedBytesFieldNumber = 1; + private bool hasEscapedBytes; + private pb::ByteString escapedBytes_ = (pb::ByteString)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[0].DefaultValue; + public bool HasEscapedBytes + { + get { return hasEscapedBytes; } + } + public pb::ByteString EscapedBytes + { + get { return escapedBytes_; } + } + + public const int LargeUint32FieldNumber = 2; + private bool hasLargeUint32; + private uint largeUint32_ = 4294967295; + public bool HasLargeUint32 + { + get { return hasLargeUint32; } + } + [global::System.CLSCompliant(false)] + public uint LargeUint32 + { + get { return largeUint32_; } + } + + public const int LargeUint64FieldNumber = 3; + private bool hasLargeUint64; + private ulong largeUint64_ = 18446744073709551615UL; + public bool HasLargeUint64 + { + get { return hasLargeUint64; } + } + [global::System.CLSCompliant(false)] + public ulong LargeUint64 + { + get { return largeUint64_; } + } + + public const int SmallInt32FieldNumber = 4; + private bool hasSmallInt32; + private int smallInt32_ = -2147483647; + public bool HasSmallInt32 + { + get { return hasSmallInt32; } + } + public int SmallInt32 + { + get { return smallInt32_; } + } + + public const int SmallInt64FieldNumber = 5; + private bool hasSmallInt64; + private long smallInt64_ = -9223372036854775807L; + public bool HasSmallInt64 + { + get { return hasSmallInt64; } + } + public long SmallInt64 + { + get { return smallInt64_; } + } + + public const int ReallySmallInt32FieldNumber = 21; + private bool hasReallySmallInt32; + private int reallySmallInt32_ = -2147483648; + public bool HasReallySmallInt32 + { + get { return hasReallySmallInt32; } + } + public int ReallySmallInt32 + { + get { return reallySmallInt32_; } + } + + public const int ReallySmallInt64FieldNumber = 22; + private bool hasReallySmallInt64; + private long reallySmallInt64_ = -9223372036854775808L; + public bool HasReallySmallInt64 + { + get { return hasReallySmallInt64; } + } + public long ReallySmallInt64 + { + get { return reallySmallInt64_; } + } + + public const int Utf8StringFieldNumber = 6; + private bool hasUtf8String; + private string utf8String_ = (string)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[7].DefaultValue; + public bool HasUtf8String + { + get { return hasUtf8String; } + } + public string Utf8String + { + get { return utf8String_; } + } + + public const int ZeroFloatFieldNumber = 7; + private bool hasZeroFloat; + private float zeroFloat_; + public bool HasZeroFloat + { + get { return hasZeroFloat; } + } + public float ZeroFloat + { + get { return zeroFloat_; } + } + + public const int OneFloatFieldNumber = 8; + private bool hasOneFloat; + private float oneFloat_ = 1F; + public bool HasOneFloat + { + get { return hasOneFloat; } + } + public float OneFloat + { + get { return oneFloat_; } + } + + public const int SmallFloatFieldNumber = 9; + private bool hasSmallFloat; + private float smallFloat_ = 1.5F; + public bool HasSmallFloat + { + get { return hasSmallFloat; } + } + public float SmallFloat + { + get { return smallFloat_; } + } + + public const int NegativeOneFloatFieldNumber = 10; + private bool hasNegativeOneFloat; + private float negativeOneFloat_ = -1F; + public bool HasNegativeOneFloat + { + get { return hasNegativeOneFloat; } + } + public float NegativeOneFloat + { + get { return negativeOneFloat_; } + } + + public const int NegativeFloatFieldNumber = 11; + private bool hasNegativeFloat; + private float negativeFloat_ = -1.5F; + public bool HasNegativeFloat + { + get { return hasNegativeFloat; } + } + public float NegativeFloat + { + get { return negativeFloat_; } + } + + public const int LargeFloatFieldNumber = 12; + private bool hasLargeFloat; + private float largeFloat_ = 2e+08F; + public bool HasLargeFloat + { + get { return hasLargeFloat; } + } + public float LargeFloat + { + get { return largeFloat_; } + } + + public const int SmallNegativeFloatFieldNumber = 13; + private bool hasSmallNegativeFloat; + private float smallNegativeFloat_ = -8e-28F; + public bool HasSmallNegativeFloat + { + get { return hasSmallNegativeFloat; } + } + public float SmallNegativeFloat + { + get { return smallNegativeFloat_; } + } + + public const int InfDoubleFieldNumber = 14; + private bool hasInfDouble; + private double infDouble_ = double.PositiveInfinity; + public bool HasInfDouble + { + get { return hasInfDouble; } + } + public double InfDouble + { + get { return infDouble_; } + } + + public const int NegInfDoubleFieldNumber = 15; + private bool hasNegInfDouble; + private double negInfDouble_ = double.NegativeInfinity; + public bool HasNegInfDouble + { + get { return hasNegInfDouble; } + } + public double NegInfDouble + { + get { return negInfDouble_; } + } + + public const int NanDoubleFieldNumber = 16; + private bool hasNanDouble; + private double nanDouble_ = double.NaN; + public bool HasNanDouble + { + get { return hasNanDouble; } + } + public double NanDouble + { + get { return nanDouble_; } + } + + public const int InfFloatFieldNumber = 17; + private bool hasInfFloat; + private float infFloat_ = float.PositiveInfinity; + public bool HasInfFloat + { + get { return hasInfFloat; } + } + public float InfFloat + { + get { return infFloat_; } + } + + public const int NegInfFloatFieldNumber = 18; + private bool hasNegInfFloat; + private float negInfFloat_ = float.NegativeInfinity; + public bool HasNegInfFloat + { + get { return hasNegInfFloat; } + } + public float NegInfFloat + { + get { return negInfFloat_; } + } + + public const int NanFloatFieldNumber = 19; + private bool hasNanFloat; + private float nanFloat_ = float.NaN; + public bool HasNanFloat + { + get { return hasNanFloat; } + } + public float NanFloat + { + get { return nanFloat_; } + } + + public const int CppTrigraphFieldNumber = 20; + private bool hasCppTrigraph; + private string cppTrigraph_ = "? ? ?? ?? ??? ??/ ??-"; + public bool HasCppTrigraph + { + get { return hasCppTrigraph; } + } + public string CppTrigraph + { + get { return cppTrigraph_; } + } + + public const int StringWithZeroFieldNumber = 23; + private bool hasStringWithZero; + private string stringWithZero_ = (string)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[22].DefaultValue; + public bool HasStringWithZero + { + get { return hasStringWithZero; } + } + public string StringWithZero + { + get { return stringWithZero_; } + } + + public const int BytesWithZeroFieldNumber = 24; + private bool hasBytesWithZero; + private pb::ByteString bytesWithZero_ = (pb::ByteString)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[23].DefaultValue; + public bool HasBytesWithZero + { + get { return hasBytesWithZero; } + } + public pb::ByteString BytesWithZero + { + get { return bytesWithZero_; } + } + + public const int StringPieceWithZeroFieldNumber = 25; + private bool hasStringPieceWithZero; + private string stringPieceWithZero_ = (string)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[24].DefaultValue; + public bool HasStringPieceWithZero + { + get { return hasStringPieceWithZero; } + } + public string StringPieceWithZero + { + get { return stringPieceWithZero_; } + } + + public const int CordWithZeroFieldNumber = 26; + private bool hasCordWithZero; + private string cordWithZero_ = (string)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[25].DefaultValue; + public bool HasCordWithZero + { + get { return hasCordWithZero; } + } + public string CordWithZero + { + get { return cordWithZero_; } + } + + public const int ReplacementStringFieldNumber = 27; + private bool hasReplacementString; + private string replacementString_ = "${unknown}"; + public bool HasReplacementString + { + get { return hasReplacementString; } + } + public string ReplacementString + { + get { return replacementString_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testExtremeDefaultValuesFieldNames; + if (hasEscapedBytes) + { + output.WriteBytes(1, field_names[3], EscapedBytes); + } + if (hasLargeUint32) + { + output.WriteUInt32(2, field_names[7], LargeUint32); + } + if (hasLargeUint64) + { + output.WriteUInt64(3, field_names[8], LargeUint64); + } + if (hasSmallInt32) + { + output.WriteInt32(4, field_names[20], SmallInt32); + } + if (hasSmallInt64) + { + output.WriteInt64(5, field_names[21], SmallInt64); + } + if (hasUtf8String) + { + output.WriteString(6, field_names[25], Utf8String); + } + if (hasZeroFloat) + { + output.WriteFloat(7, field_names[26], ZeroFloat); + } + if (hasOneFloat) + { + output.WriteFloat(8, field_names[15], OneFloat); + } + if (hasSmallFloat) + { + output.WriteFloat(9, field_names[19], SmallFloat); + } + if (hasNegativeOneFloat) + { + output.WriteFloat(10, field_names[14], NegativeOneFloat); + } + if (hasNegativeFloat) + { + output.WriteFloat(11, field_names[13], NegativeFloat); + } + if (hasLargeFloat) + { + output.WriteFloat(12, field_names[6], LargeFloat); + } + if (hasSmallNegativeFloat) + { + output.WriteFloat(13, field_names[22], SmallNegativeFloat); + } + if (hasInfDouble) + { + output.WriteDouble(14, field_names[4], InfDouble); + } + if (hasNegInfDouble) + { + output.WriteDouble(15, field_names[11], NegInfDouble); + } + if (hasNanDouble) + { + output.WriteDouble(16, field_names[9], NanDouble); + } + if (hasInfFloat) + { + output.WriteFloat(17, field_names[5], InfFloat); + } + if (hasNegInfFloat) + { + output.WriteFloat(18, field_names[12], NegInfFloat); + } + if (hasNanFloat) + { + output.WriteFloat(19, field_names[10], NanFloat); + } + if (hasCppTrigraph) + { + output.WriteString(20, field_names[2], CppTrigraph); + } + if (hasReallySmallInt32) + { + output.WriteInt32(21, field_names[16], ReallySmallInt32); + } + if (hasReallySmallInt64) + { + output.WriteInt64(22, field_names[17], ReallySmallInt64); + } + if (hasStringWithZero) + { + output.WriteString(23, field_names[24], StringWithZero); + } + if (hasBytesWithZero) + { + output.WriteBytes(24, field_names[0], BytesWithZero); + } + if (hasStringPieceWithZero) + { + output.WriteString(25, field_names[23], StringPieceWithZero); + } + if (hasCordWithZero) + { + output.WriteString(26, field_names[1], CordWithZero); + } + if (hasReplacementString) + { + output.WriteString(27, field_names[18], ReplacementString); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasEscapedBytes) + { + size += pb::CodedOutputStream.ComputeBytesSize(1, EscapedBytes); + } + if (hasLargeUint32) + { + size += pb::CodedOutputStream.ComputeUInt32Size(2, LargeUint32); + } + if (hasLargeUint64) + { + size += pb::CodedOutputStream.ComputeUInt64Size(3, LargeUint64); + } + if (hasSmallInt32) + { + size += pb::CodedOutputStream.ComputeInt32Size(4, SmallInt32); + } + if (hasSmallInt64) + { + size += pb::CodedOutputStream.ComputeInt64Size(5, SmallInt64); + } + if (hasReallySmallInt32) + { + size += pb::CodedOutputStream.ComputeInt32Size(21, ReallySmallInt32); + } + if (hasReallySmallInt64) + { + size += pb::CodedOutputStream.ComputeInt64Size(22, ReallySmallInt64); + } + if (hasUtf8String) + { + size += pb::CodedOutputStream.ComputeStringSize(6, Utf8String); + } + if (hasZeroFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(7, ZeroFloat); + } + if (hasOneFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(8, OneFloat); + } + if (hasSmallFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(9, SmallFloat); + } + if (hasNegativeOneFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(10, NegativeOneFloat); + } + if (hasNegativeFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(11, NegativeFloat); + } + if (hasLargeFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(12, LargeFloat); + } + if (hasSmallNegativeFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(13, SmallNegativeFloat); + } + if (hasInfDouble) + { + size += pb::CodedOutputStream.ComputeDoubleSize(14, InfDouble); + } + if (hasNegInfDouble) + { + size += pb::CodedOutputStream.ComputeDoubleSize(15, NegInfDouble); + } + if (hasNanDouble) + { + size += pb::CodedOutputStream.ComputeDoubleSize(16, NanDouble); + } + if (hasInfFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(17, InfFloat); + } + if (hasNegInfFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(18, NegInfFloat); + } + if (hasNanFloat) + { + size += pb::CodedOutputStream.ComputeFloatSize(19, NanFloat); + } + if (hasCppTrigraph) + { + size += pb::CodedOutputStream.ComputeStringSize(20, CppTrigraph); + } + if (hasStringWithZero) + { + size += pb::CodedOutputStream.ComputeStringSize(23, StringWithZero); + } + if (hasBytesWithZero) + { + size += pb::CodedOutputStream.ComputeBytesSize(24, BytesWithZero); + } + if (hasStringPieceWithZero) + { + size += pb::CodedOutputStream.ComputeStringSize(25, StringPieceWithZero); + } + if (hasCordWithZero) + { + size += pb::CodedOutputStream.ComputeStringSize(26, CordWithZero); + } + if (hasReplacementString) + { + size += pb::CodedOutputStream.ComputeStringSize(27, ReplacementString); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestExtremeDefaultValues ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestExtremeDefaultValues ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestExtremeDefaultValues ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestExtremeDefaultValues MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestExtremeDefaultValues prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestExtremeDefaultValues cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestExtremeDefaultValues result; + + private TestExtremeDefaultValues PrepareBuilder() + { + if (resultIsReadOnly) + { + TestExtremeDefaultValues original = result; + result = new TestExtremeDefaultValues(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestExtremeDefaultValues MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor; } + } + + public override TestExtremeDefaultValues DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.DefaultInstance; } + } + + public override TestExtremeDefaultValues BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestExtremeDefaultValues) + { + return MergeFrom((TestExtremeDefaultValues)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestExtremeDefaultValues other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasEscapedBytes) + { + EscapedBytes = other.EscapedBytes; + } + if (other.HasLargeUint32) + { + LargeUint32 = other.LargeUint32; + } + if (other.HasLargeUint64) + { + LargeUint64 = other.LargeUint64; + } + if (other.HasSmallInt32) + { + SmallInt32 = other.SmallInt32; + } + if (other.HasSmallInt64) + { + SmallInt64 = other.SmallInt64; + } + if (other.HasReallySmallInt32) + { + ReallySmallInt32 = other.ReallySmallInt32; + } + if (other.HasReallySmallInt64) + { + ReallySmallInt64 = other.ReallySmallInt64; + } + if (other.HasUtf8String) + { + Utf8String = other.Utf8String; + } + if (other.HasZeroFloat) + { + ZeroFloat = other.ZeroFloat; + } + if (other.HasOneFloat) + { + OneFloat = other.OneFloat; + } + if (other.HasSmallFloat) + { + SmallFloat = other.SmallFloat; + } + if (other.HasNegativeOneFloat) + { + NegativeOneFloat = other.NegativeOneFloat; + } + if (other.HasNegativeFloat) + { + NegativeFloat = other.NegativeFloat; + } + if (other.HasLargeFloat) + { + LargeFloat = other.LargeFloat; + } + if (other.HasSmallNegativeFloat) + { + SmallNegativeFloat = other.SmallNegativeFloat; + } + if (other.HasInfDouble) + { + InfDouble = other.InfDouble; + } + if (other.HasNegInfDouble) + { + NegInfDouble = other.NegInfDouble; + } + if (other.HasNanDouble) + { + NanDouble = other.NanDouble; + } + if (other.HasInfFloat) + { + InfFloat = other.InfFloat; + } + if (other.HasNegInfFloat) + { + NegInfFloat = other.NegInfFloat; + } + if (other.HasNanFloat) + { + NanFloat = other.NanFloat; + } + if (other.HasCppTrigraph) + { + CppTrigraph = other.CppTrigraph; + } + if (other.HasStringWithZero) + { + StringWithZero = other.StringWithZero; + } + if (other.HasBytesWithZero) + { + BytesWithZero = other.BytesWithZero; + } + if (other.HasStringPieceWithZero) + { + StringPieceWithZero = other.StringPieceWithZero; + } + if (other.HasCordWithZero) + { + CordWithZero = other.CordWithZero; + } + if (other.HasReplacementString) + { + ReplacementString = other.ReplacementString; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testExtremeDefaultValuesFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testExtremeDefaultValuesFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + result.hasEscapedBytes = input.ReadBytes(ref result.escapedBytes_); + break; + } + case 16: + { + result.hasLargeUint32 = input.ReadUInt32(ref result.largeUint32_); + break; + } + case 24: + { + result.hasLargeUint64 = input.ReadUInt64(ref result.largeUint64_); + break; + } + case 32: + { + result.hasSmallInt32 = input.ReadInt32(ref result.smallInt32_); + break; + } + case 40: + { + result.hasSmallInt64 = input.ReadInt64(ref result.smallInt64_); + break; + } + case 50: + { + result.hasUtf8String = input.ReadString(ref result.utf8String_); + break; + } + case 61: + { + result.hasZeroFloat = input.ReadFloat(ref result.zeroFloat_); + break; + } + case 69: + { + result.hasOneFloat = input.ReadFloat(ref result.oneFloat_); + break; + } + case 77: + { + result.hasSmallFloat = input.ReadFloat(ref result.smallFloat_); + break; + } + case 85: + { + result.hasNegativeOneFloat = input.ReadFloat(ref result.negativeOneFloat_); + break; + } + case 93: + { + result.hasNegativeFloat = input.ReadFloat(ref result.negativeFloat_); + break; + } + case 101: + { + result.hasLargeFloat = input.ReadFloat(ref result.largeFloat_); + break; + } + case 109: + { + result.hasSmallNegativeFloat = input.ReadFloat(ref result.smallNegativeFloat_); + break; + } + case 113: + { + result.hasInfDouble = input.ReadDouble(ref result.infDouble_); + break; + } + case 121: + { + result.hasNegInfDouble = input.ReadDouble(ref result.negInfDouble_); + break; + } + case 129: + { + result.hasNanDouble = input.ReadDouble(ref result.nanDouble_); + break; + } + case 141: + { + result.hasInfFloat = input.ReadFloat(ref result.infFloat_); + break; + } + case 149: + { + result.hasNegInfFloat = input.ReadFloat(ref result.negInfFloat_); + break; + } + case 157: + { + result.hasNanFloat = input.ReadFloat(ref result.nanFloat_); + break; + } + case 162: + { + result.hasCppTrigraph = input.ReadString(ref result.cppTrigraph_); + break; + } + case 168: + { + result.hasReallySmallInt32 = input.ReadInt32(ref result.reallySmallInt32_); + break; + } + case 176: + { + result.hasReallySmallInt64 = input.ReadInt64(ref result.reallySmallInt64_); + break; + } + case 186: + { + result.hasStringWithZero = input.ReadString(ref result.stringWithZero_); + break; + } + case 194: + { + result.hasBytesWithZero = input.ReadBytes(ref result.bytesWithZero_); + break; + } + case 202: + { + result.hasStringPieceWithZero = input.ReadString(ref result.stringPieceWithZero_); + break; + } + case 210: + { + result.hasCordWithZero = input.ReadString(ref result.cordWithZero_); + break; + } + case 218: + { + result.hasReplacementString = input.ReadString(ref result.replacementString_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasEscapedBytes + { + get { return result.hasEscapedBytes; } + } + public pb::ByteString EscapedBytes + { + get { return result.EscapedBytes; } + set { SetEscapedBytes(value); } + } + public Builder SetEscapedBytes(pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasEscapedBytes = true; + result.escapedBytes_ = value; + return this; + } + public Builder ClearEscapedBytes() + { + PrepareBuilder(); + result.hasEscapedBytes = false; + result.escapedBytes_ = (pb::ByteString)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[0].DefaultValue; + return this; + } + + public bool HasLargeUint32 + { + get { return result.hasLargeUint32; } + } + [global::System.CLSCompliant(false)] + public uint LargeUint32 + { + get { return result.LargeUint32; } + set { SetLargeUint32(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetLargeUint32(uint value) + { + PrepareBuilder(); + result.hasLargeUint32 = true; + result.largeUint32_ = value; + return this; + } + public Builder ClearLargeUint32() + { + PrepareBuilder(); + result.hasLargeUint32 = false; + result.largeUint32_ = 4294967295; + return this; + } + + public bool HasLargeUint64 + { + get { return result.hasLargeUint64; } + } + [global::System.CLSCompliant(false)] + public ulong LargeUint64 + { + get { return result.LargeUint64; } + set { SetLargeUint64(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetLargeUint64(ulong value) + { + PrepareBuilder(); + result.hasLargeUint64 = true; + result.largeUint64_ = value; + return this; + } + public Builder ClearLargeUint64() + { + PrepareBuilder(); + result.hasLargeUint64 = false; + result.largeUint64_ = 18446744073709551615UL; + return this; + } + + public bool HasSmallInt32 + { + get { return result.hasSmallInt32; } + } + public int SmallInt32 + { + get { return result.SmallInt32; } + set { SetSmallInt32(value); } + } + public Builder SetSmallInt32(int value) + { + PrepareBuilder(); + result.hasSmallInt32 = true; + result.smallInt32_ = value; + return this; + } + public Builder ClearSmallInt32() + { + PrepareBuilder(); + result.hasSmallInt32 = false; + result.smallInt32_ = -2147483647; + return this; + } + + public bool HasSmallInt64 + { + get { return result.hasSmallInt64; } + } + public long SmallInt64 + { + get { return result.SmallInt64; } + set { SetSmallInt64(value); } + } + public Builder SetSmallInt64(long value) + { + PrepareBuilder(); + result.hasSmallInt64 = true; + result.smallInt64_ = value; + return this; + } + public Builder ClearSmallInt64() + { + PrepareBuilder(); + result.hasSmallInt64 = false; + result.smallInt64_ = -9223372036854775807L; + return this; + } + + public bool HasReallySmallInt32 + { + get { return result.hasReallySmallInt32; } + } + public int ReallySmallInt32 + { + get { return result.ReallySmallInt32; } + set { SetReallySmallInt32(value); } + } + public Builder SetReallySmallInt32(int value) + { + PrepareBuilder(); + result.hasReallySmallInt32 = true; + result.reallySmallInt32_ = value; + return this; + } + public Builder ClearReallySmallInt32() + { + PrepareBuilder(); + result.hasReallySmallInt32 = false; + result.reallySmallInt32_ = -2147483648; + return this; + } + + public bool HasReallySmallInt64 + { + get { return result.hasReallySmallInt64; } + } + public long ReallySmallInt64 + { + get { return result.ReallySmallInt64; } + set { SetReallySmallInt64(value); } + } + public Builder SetReallySmallInt64(long value) + { + PrepareBuilder(); + result.hasReallySmallInt64 = true; + result.reallySmallInt64_ = value; + return this; + } + public Builder ClearReallySmallInt64() + { + PrepareBuilder(); + result.hasReallySmallInt64 = false; + result.reallySmallInt64_ = -9223372036854775808L; + return this; + } + + public bool HasUtf8String + { + get { return result.hasUtf8String; } + } + public string Utf8String + { + get { return result.Utf8String; } + set { SetUtf8String(value); } + } + public Builder SetUtf8String(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasUtf8String = true; + result.utf8String_ = value; + return this; + } + public Builder ClearUtf8String() + { + PrepareBuilder(); + result.hasUtf8String = false; + result.utf8String_ = (string)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[7].DefaultValue; + return this; + } + + public bool HasZeroFloat + { + get { return result.hasZeroFloat; } + } + public float ZeroFloat + { + get { return result.ZeroFloat; } + set { SetZeroFloat(value); } + } + public Builder SetZeroFloat(float value) + { + PrepareBuilder(); + result.hasZeroFloat = true; + result.zeroFloat_ = value; + return this; + } + public Builder ClearZeroFloat() + { + PrepareBuilder(); + result.hasZeroFloat = false; + result.zeroFloat_ = 0F; + return this; + } + + public bool HasOneFloat + { + get { return result.hasOneFloat; } + } + public float OneFloat + { + get { return result.OneFloat; } + set { SetOneFloat(value); } + } + public Builder SetOneFloat(float value) + { + PrepareBuilder(); + result.hasOneFloat = true; + result.oneFloat_ = value; + return this; + } + public Builder ClearOneFloat() + { + PrepareBuilder(); + result.hasOneFloat = false; + result.oneFloat_ = 1F; + return this; + } + + public bool HasSmallFloat + { + get { return result.hasSmallFloat; } + } + public float SmallFloat + { + get { return result.SmallFloat; } + set { SetSmallFloat(value); } + } + public Builder SetSmallFloat(float value) + { + PrepareBuilder(); + result.hasSmallFloat = true; + result.smallFloat_ = value; + return this; + } + public Builder ClearSmallFloat() + { + PrepareBuilder(); + result.hasSmallFloat = false; + result.smallFloat_ = 1.5F; + return this; + } + + public bool HasNegativeOneFloat + { + get { return result.hasNegativeOneFloat; } + } + public float NegativeOneFloat + { + get { return result.NegativeOneFloat; } + set { SetNegativeOneFloat(value); } + } + public Builder SetNegativeOneFloat(float value) + { + PrepareBuilder(); + result.hasNegativeOneFloat = true; + result.negativeOneFloat_ = value; + return this; + } + public Builder ClearNegativeOneFloat() + { + PrepareBuilder(); + result.hasNegativeOneFloat = false; + result.negativeOneFloat_ = -1F; + return this; + } + + public bool HasNegativeFloat + { + get { return result.hasNegativeFloat; } + } + public float NegativeFloat + { + get { return result.NegativeFloat; } + set { SetNegativeFloat(value); } + } + public Builder SetNegativeFloat(float value) + { + PrepareBuilder(); + result.hasNegativeFloat = true; + result.negativeFloat_ = value; + return this; + } + public Builder ClearNegativeFloat() + { + PrepareBuilder(); + result.hasNegativeFloat = false; + result.negativeFloat_ = -1.5F; + return this; + } + + public bool HasLargeFloat + { + get { return result.hasLargeFloat; } + } + public float LargeFloat + { + get { return result.LargeFloat; } + set { SetLargeFloat(value); } + } + public Builder SetLargeFloat(float value) + { + PrepareBuilder(); + result.hasLargeFloat = true; + result.largeFloat_ = value; + return this; + } + public Builder ClearLargeFloat() + { + PrepareBuilder(); + result.hasLargeFloat = false; + result.largeFloat_ = 2e+08F; + return this; + } + + public bool HasSmallNegativeFloat + { + get { return result.hasSmallNegativeFloat; } + } + public float SmallNegativeFloat + { + get { return result.SmallNegativeFloat; } + set { SetSmallNegativeFloat(value); } + } + public Builder SetSmallNegativeFloat(float value) + { + PrepareBuilder(); + result.hasSmallNegativeFloat = true; + result.smallNegativeFloat_ = value; + return this; + } + public Builder ClearSmallNegativeFloat() + { + PrepareBuilder(); + result.hasSmallNegativeFloat = false; + result.smallNegativeFloat_ = -8e-28F; + return this; + } + + public bool HasInfDouble + { + get { return result.hasInfDouble; } + } + public double InfDouble + { + get { return result.InfDouble; } + set { SetInfDouble(value); } + } + public Builder SetInfDouble(double value) + { + PrepareBuilder(); + result.hasInfDouble = true; + result.infDouble_ = value; + return this; + } + public Builder ClearInfDouble() + { + PrepareBuilder(); + result.hasInfDouble = false; + result.infDouble_ = double.PositiveInfinity; + return this; + } + + public bool HasNegInfDouble + { + get { return result.hasNegInfDouble; } + } + public double NegInfDouble + { + get { return result.NegInfDouble; } + set { SetNegInfDouble(value); } + } + public Builder SetNegInfDouble(double value) + { + PrepareBuilder(); + result.hasNegInfDouble = true; + result.negInfDouble_ = value; + return this; + } + public Builder ClearNegInfDouble() + { + PrepareBuilder(); + result.hasNegInfDouble = false; + result.negInfDouble_ = double.NegativeInfinity; + return this; + } + + public bool HasNanDouble + { + get { return result.hasNanDouble; } + } + public double NanDouble + { + get { return result.NanDouble; } + set { SetNanDouble(value); } + } + public Builder SetNanDouble(double value) + { + PrepareBuilder(); + result.hasNanDouble = true; + result.nanDouble_ = value; + return this; + } + public Builder ClearNanDouble() + { + PrepareBuilder(); + result.hasNanDouble = false; + result.nanDouble_ = double.NaN; + return this; + } + + public bool HasInfFloat + { + get { return result.hasInfFloat; } + } + public float InfFloat + { + get { return result.InfFloat; } + set { SetInfFloat(value); } + } + public Builder SetInfFloat(float value) + { + PrepareBuilder(); + result.hasInfFloat = true; + result.infFloat_ = value; + return this; + } + public Builder ClearInfFloat() + { + PrepareBuilder(); + result.hasInfFloat = false; + result.infFloat_ = float.PositiveInfinity; + return this; + } + + public bool HasNegInfFloat + { + get { return result.hasNegInfFloat; } + } + public float NegInfFloat + { + get { return result.NegInfFloat; } + set { SetNegInfFloat(value); } + } + public Builder SetNegInfFloat(float value) + { + PrepareBuilder(); + result.hasNegInfFloat = true; + result.negInfFloat_ = value; + return this; + } + public Builder ClearNegInfFloat() + { + PrepareBuilder(); + result.hasNegInfFloat = false; + result.negInfFloat_ = float.NegativeInfinity; + return this; + } + + public bool HasNanFloat + { + get { return result.hasNanFloat; } + } + public float NanFloat + { + get { return result.NanFloat; } + set { SetNanFloat(value); } + } + public Builder SetNanFloat(float value) + { + PrepareBuilder(); + result.hasNanFloat = true; + result.nanFloat_ = value; + return this; + } + public Builder ClearNanFloat() + { + PrepareBuilder(); + result.hasNanFloat = false; + result.nanFloat_ = float.NaN; + return this; + } + + public bool HasCppTrigraph + { + get { return result.hasCppTrigraph; } + } + public string CppTrigraph + { + get { return result.CppTrigraph; } + set { SetCppTrigraph(value); } + } + public Builder SetCppTrigraph(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasCppTrigraph = true; + result.cppTrigraph_ = value; + return this; + } + public Builder ClearCppTrigraph() + { + PrepareBuilder(); + result.hasCppTrigraph = false; + result.cppTrigraph_ = "? ? ?? ?? ??? ??/ ??-"; + return this; + } + + public bool HasStringWithZero + { + get { return result.hasStringWithZero; } + } + public string StringWithZero + { + get { return result.StringWithZero; } + set { SetStringWithZero(value); } + } + public Builder SetStringWithZero(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasStringWithZero = true; + result.stringWithZero_ = value; + return this; + } + public Builder ClearStringWithZero() + { + PrepareBuilder(); + result.hasStringWithZero = false; + result.stringWithZero_ = (string)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[22].DefaultValue; + return this; + } + + public bool HasBytesWithZero + { + get { return result.hasBytesWithZero; } + } + public pb::ByteString BytesWithZero + { + get { return result.BytesWithZero; } + set { SetBytesWithZero(value); } + } + public Builder SetBytesWithZero(pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBytesWithZero = true; + result.bytesWithZero_ = value; + return this; + } + public Builder ClearBytesWithZero() + { + PrepareBuilder(); + result.hasBytesWithZero = false; + result.bytesWithZero_ = (pb::ByteString)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[23].DefaultValue; + return this; + } + + public bool HasStringPieceWithZero + { + get { return result.hasStringPieceWithZero; } + } + public string StringPieceWithZero + { + get { return result.StringPieceWithZero; } + set { SetStringPieceWithZero(value); } + } + public Builder SetStringPieceWithZero(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasStringPieceWithZero = true; + result.stringPieceWithZero_ = value; + return this; + } + public Builder ClearStringPieceWithZero() + { + PrepareBuilder(); + result.hasStringPieceWithZero = false; + result.stringPieceWithZero_ = (string)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[24].DefaultValue; + return this; + } + + public bool HasCordWithZero + { + get { return result.hasCordWithZero; } + } + public string CordWithZero + { + get { return result.CordWithZero; } + set { SetCordWithZero(value); } + } + public Builder SetCordWithZero(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasCordWithZero = true; + result.cordWithZero_ = value; + return this; + } + public Builder ClearCordWithZero() + { + PrepareBuilder(); + result.hasCordWithZero = false; + result.cordWithZero_ = (string)global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[25].DefaultValue; + return this; + } + + public bool HasReplacementString + { + get { return result.hasReplacementString; } + } + public string ReplacementString + { + get { return result.ReplacementString; } + set { SetReplacementString(value); } + } + public Builder SetReplacementString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasReplacementString = true; + result.replacementString_ = value; + return this; + } + public Builder ClearReplacementString() + { + PrepareBuilder(); + result.hasReplacementString = false; + result.replacementString_ = "${unknown}"; + return this; + } + } + static TestExtremeDefaultValues() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class SparseEnumMessage : pb::GeneratedMessage + { + private SparseEnumMessage() { } + private static readonly SparseEnumMessage defaultInstance = new SparseEnumMessage().MakeReadOnly(); + private static readonly string[] _sparseEnumMessageFieldNames = new string[] { "sparse_enum" }; + private static readonly uint[] _sparseEnumMessageFieldTags = new uint[] { 8 }; + public static SparseEnumMessage DefaultInstance + { + get { return defaultInstance; } + } + + public override SparseEnumMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override SparseEnumMessage ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_SparseEnumMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable; } + } + + public const int SparseEnumFieldNumber = 1; + private bool hasSparseEnum; + private global::Google.ProtocolBuffers.TestProtos.TestSparseEnum sparseEnum_ = global::Google.ProtocolBuffers.TestProtos.TestSparseEnum.SPARSE_A; + public bool HasSparseEnum + { + get { return hasSparseEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestSparseEnum SparseEnum + { + get { return sparseEnum_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _sparseEnumMessageFieldNames; + if (hasSparseEnum) + { + output.WriteEnum(1, field_names[0], (int)SparseEnum, SparseEnum); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasSparseEnum) + { + size += pb::CodedOutputStream.ComputeEnumSize(1, (int)SparseEnum); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static SparseEnumMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static SparseEnumMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static SparseEnumMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static SparseEnumMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private SparseEnumMessage MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(SparseEnumMessage prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(SparseEnumMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private SparseEnumMessage result; + + private SparseEnumMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + SparseEnumMessage original = result; + result = new SparseEnumMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override SparseEnumMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.Descriptor; } + } + + public override SparseEnumMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.DefaultInstance; } + } + + public override SparseEnumMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is SparseEnumMessage) + { + return MergeFrom((SparseEnumMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(SparseEnumMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasSparseEnum) + { + SparseEnum = other.SparseEnum; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_sparseEnumMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _sparseEnumMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + object unknown; + if (input.ReadEnum(ref result.sparseEnum_, out unknown)) + { + result.hasSparseEnum = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(1, (ulong)(int)unknown); + } + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasSparseEnum + { + get { return result.hasSparseEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestSparseEnum SparseEnum + { + get { return result.SparseEnum; } + set { SetSparseEnum(value); } + } + public Builder SetSparseEnum(global::Google.ProtocolBuffers.TestProtos.TestSparseEnum value) + { + PrepareBuilder(); + result.hasSparseEnum = true; + result.sparseEnum_ = value; + return this; + } + public Builder ClearSparseEnum() + { + PrepareBuilder(); + result.hasSparseEnum = false; + result.sparseEnum_ = global::Google.ProtocolBuffers.TestProtos.TestSparseEnum.SPARSE_A; + return this; + } + } + static SparseEnumMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OneString : pb::GeneratedMessage + { + private OneString() { } + private static readonly OneString defaultInstance = new OneString().MakeReadOnly(); + private static readonly string[] _oneStringFieldNames = new string[] { "data" }; + private static readonly uint[] _oneStringFieldTags = new uint[] { 10 }; + public static OneString DefaultInstance + { + get { return defaultInstance; } + } + + public override OneString DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override OneString ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneString__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneString__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private string data_ = ""; + public bool HasData + { + get { return hasData; } + } + public string Data + { + get { return data_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _oneStringFieldNames; + if (hasData) + { + output.WriteString(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) + { + size += pb::CodedOutputStream.ComputeStringSize(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static OneString ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OneString ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OneString ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OneString ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OneString ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OneString ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OneString ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OneString ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OneString ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OneString ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OneString MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OneString prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OneString cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OneString result; + + private OneString PrepareBuilder() + { + if (resultIsReadOnly) + { + OneString original = result; + result = new OneString(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override OneString MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.OneString.Descriptor; } + } + + public override OneString DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.OneString.DefaultInstance; } + } + + public override OneString BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is OneString) + { + return MergeFrom((OneString)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OneString other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.OneString.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) + { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_oneStringFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _oneStringFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + result.hasData = input.ReadString(ref result.data_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData + { + get { return result.hasData; } + } + public string Data + { + get { return result.Data; } + set { SetData(value); } + } + public Builder SetData(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() + { + PrepareBuilder(); + result.hasData = false; + result.data_ = ""; + return this; + } + } + static OneString() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class MoreString : pb::GeneratedMessage + { + private MoreString() { } + private static readonly MoreString defaultInstance = new MoreString().MakeReadOnly(); + private static readonly string[] _moreStringFieldNames = new string[] { "data" }; + private static readonly uint[] _moreStringFieldTags = new uint[] { 10 }; + public static MoreString DefaultInstance + { + get { return defaultInstance; } + } + + public override MoreString DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override MoreString ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreString__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreString__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private pbc::PopsicleList data_ = new pbc::PopsicleList(); + public scg::IList DataList + { + get { return pbc::Lists.AsReadOnly(data_); } + } + public int DataCount + { + get { return data_.Count; } + } + public string GetData(int index) + { + return data_[index]; + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _moreStringFieldNames; + if (data_.Count > 0) + { + output.WriteStringArray(1, field_names[0], data_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + foreach (string element in DataList) + { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 1 * data_.Count; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static MoreString ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MoreString ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MoreString ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MoreString ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MoreString ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MoreString ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static MoreString ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static MoreString ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static MoreString ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MoreString ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private MoreString MakeReadOnly() + { + data_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(MoreString prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(MoreString cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private MoreString result; + + private MoreString PrepareBuilder() + { + if (resultIsReadOnly) + { + MoreString original = result; + result = new MoreString(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override MoreString MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.MoreString.Descriptor; } + } + + public override MoreString DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.MoreString.DefaultInstance; } + } + + public override MoreString BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is MoreString) + { + return MergeFrom((MoreString)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(MoreString other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.MoreString.DefaultInstance) return this; + PrepareBuilder(); + if (other.data_.Count != 0) + { + result.data_.Add(other.data_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_moreStringFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _moreStringFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + input.ReadStringArray(tag, field_name, result.data_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList DataList + { + get { return PrepareBuilder().data_; } + } + public int DataCount + { + get { return result.DataCount; } + } + public string GetData(int index) + { + return result.GetData(index); + } + public Builder SetData(int index, string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.data_[index] = value; + return this; + } + public Builder AddData(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.data_.Add(value); + return this; + } + public Builder AddRangeData(scg::IEnumerable values) + { + PrepareBuilder(); + result.data_.Add(values); + return this; + } + public Builder ClearData() + { + PrepareBuilder(); + result.data_.Clear(); + return this; + } + } + static MoreString() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OneBytes : pb::GeneratedMessage + { + private OneBytes() { } + private static readonly OneBytes defaultInstance = new OneBytes().MakeReadOnly(); + private static readonly string[] _oneBytesFieldNames = new string[] { "data" }; + private static readonly uint[] _oneBytesFieldTags = new uint[] { 10 }; + public static OneBytes DefaultInstance + { + get { return defaultInstance; } + } + + public override OneBytes DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override OneBytes ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneBytes__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneBytes__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private pb::ByteString data_ = pb::ByteString.Empty; + public bool HasData + { + get { return hasData; } + } + public pb::ByteString Data + { + get { return data_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _oneBytesFieldNames; + if (hasData) + { + output.WriteBytes(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) + { + size += pb::CodedOutputStream.ComputeBytesSize(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static OneBytes ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OneBytes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OneBytes ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OneBytes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OneBytes ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OneBytes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OneBytes ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OneBytes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OneBytes ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OneBytes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OneBytes MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OneBytes prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OneBytes cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private OneBytes result; + + private OneBytes PrepareBuilder() + { + if (resultIsReadOnly) + { + OneBytes original = result; + result = new OneBytes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override OneBytes MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.OneBytes.Descriptor; } + } + + public override OneBytes DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.OneBytes.DefaultInstance; } + } + + public override OneBytes BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is OneBytes) + { + return MergeFrom((OneBytes)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(OneBytes other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.OneBytes.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) + { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_oneBytesFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _oneBytesFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + result.hasData = input.ReadBytes(ref result.data_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData + { + get { return result.hasData; } + } + public pb::ByteString Data + { + get { return result.Data; } + set { SetData(value); } + } + public Builder SetData(pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() + { + PrepareBuilder(); + result.hasData = false; + result.data_ = pb::ByteString.Empty; + return this; + } + } + static OneBytes() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class MoreBytes : pb::GeneratedMessage + { + private MoreBytes() { } + private static readonly MoreBytes defaultInstance = new MoreBytes().MakeReadOnly(); + private static readonly string[] _moreBytesFieldNames = new string[] { "data" }; + private static readonly uint[] _moreBytesFieldTags = new uint[] { 10 }; + public static MoreBytes DefaultInstance + { + get { return defaultInstance; } + } + + public override MoreBytes DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override MoreBytes ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreBytes__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreBytes__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private pbc::PopsicleList data_ = new pbc::PopsicleList(); + public scg::IList DataList + { + get { return pbc::Lists.AsReadOnly(data_); } + } + public int DataCount + { + get { return data_.Count; } + } + public pb::ByteString GetData(int index) + { + return data_[index]; + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _moreBytesFieldNames; + if (data_.Count > 0) + { + output.WriteBytesArray(1, field_names[0], data_); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + { + int dataSize = 0; + foreach (pb::ByteString element in DataList) + { + dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element); + } + size += dataSize; + size += 1 * data_.Count; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static MoreBytes ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MoreBytes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MoreBytes ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static MoreBytes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static MoreBytes ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MoreBytes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static MoreBytes ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static MoreBytes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static MoreBytes ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static MoreBytes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private MoreBytes MakeReadOnly() + { + data_.MakeReadOnly(); + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(MoreBytes prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(MoreBytes cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private MoreBytes result; + + private MoreBytes PrepareBuilder() + { + if (resultIsReadOnly) + { + MoreBytes original = result; + result = new MoreBytes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override MoreBytes MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.MoreBytes.Descriptor; } + } + + public override MoreBytes DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.MoreBytes.DefaultInstance; } + } + + public override MoreBytes BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is MoreBytes) + { + return MergeFrom((MoreBytes)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(MoreBytes other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.MoreBytes.DefaultInstance) return this; + PrepareBuilder(); + if (other.data_.Count != 0) + { + result.data_.Add(other.data_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_moreBytesFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _moreBytesFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + input.ReadBytesArray(tag, field_name, result.data_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public pbc::IPopsicleList DataList + { + get { return PrepareBuilder().data_; } + } + public int DataCount + { + get { return result.DataCount; } + } + public pb::ByteString GetData(int index) + { + return result.GetData(index); + } + public Builder SetData(int index, pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.data_[index] = value; + return this; + } + public Builder AddData(pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.data_.Add(value); + return this; + } + public Builder AddRangeData(scg::IEnumerable values) + { + PrepareBuilder(); + result.data_.Add(values); + return this; + } + public Builder ClearData() + { + PrepareBuilder(); + result.data_.Clear(); + return this; + } + } + static MoreBytes() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Int32Message : pb::GeneratedMessage + { + private Int32Message() { } + private static readonly Int32Message defaultInstance = new Int32Message().MakeReadOnly(); + private static readonly string[] _int32MessageFieldNames = new string[] { "data" }; + private static readonly uint[] _int32MessageFieldTags = new uint[] { 8 }; + public static Int32Message DefaultInstance + { + get { return defaultInstance; } + } + + public override Int32Message DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override Int32Message ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int32Message__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int32Message__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private int data_; + public bool HasData + { + get { return hasData; } + } + public int Data + { + get { return data_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _int32MessageFieldNames; + if (hasData) + { + output.WriteInt32(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Int32Message ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Int32Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Int32Message ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Int32Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Int32Message ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Int32Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Int32Message ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Int32Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Int32Message ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Int32Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Int32Message MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Int32Message prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Int32Message cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Int32Message result; + + private Int32Message PrepareBuilder() + { + if (resultIsReadOnly) + { + Int32Message original = result; + result = new Int32Message(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override Int32Message MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.Int32Message.Descriptor; } + } + + public override Int32Message DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.Int32Message.DefaultInstance; } + } + + public override Int32Message BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is Int32Message) + { + return MergeFrom((Int32Message)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Int32Message other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.Int32Message.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) + { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_int32MessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _int32MessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasData = input.ReadInt32(ref result.data_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData + { + get { return result.hasData; } + } + public int Data + { + get { return result.Data; } + set { SetData(value); } + } + public Builder SetData(int value) + { + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() + { + PrepareBuilder(); + result.hasData = false; + result.data_ = 0; + return this; + } + } + static Int32Message() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Uint32Message : pb::GeneratedMessage + { + private Uint32Message() { } + private static readonly Uint32Message defaultInstance = new Uint32Message().MakeReadOnly(); + private static readonly string[] _uint32MessageFieldNames = new string[] { "data" }; + private static readonly uint[] _uint32MessageFieldTags = new uint[] { 8 }; + public static Uint32Message DefaultInstance + { + get { return defaultInstance; } + } + + public override Uint32Message DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override Uint32Message ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint32Message__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint32Message__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private uint data_; + public bool HasData + { + get { return hasData; } + } + [global::System.CLSCompliant(false)] + public uint Data + { + get { return data_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _uint32MessageFieldNames; + if (hasData) + { + output.WriteUInt32(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) + { + size += pb::CodedOutputStream.ComputeUInt32Size(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Uint32Message ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Uint32Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Uint32Message ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Uint32Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Uint32Message ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Uint32Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Uint32Message ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Uint32Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Uint32Message ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Uint32Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Uint32Message MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Uint32Message prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Uint32Message cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Uint32Message result; + + private Uint32Message PrepareBuilder() + { + if (resultIsReadOnly) + { + Uint32Message original = result; + result = new Uint32Message(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override Uint32Message MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.Uint32Message.Descriptor; } + } + + public override Uint32Message DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.Uint32Message.DefaultInstance; } + } + + public override Uint32Message BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is Uint32Message) + { + return MergeFrom((Uint32Message)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Uint32Message other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.Uint32Message.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) + { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_uint32MessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _uint32MessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasData = input.ReadUInt32(ref result.data_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData + { + get { return result.hasData; } + } + [global::System.CLSCompliant(false)] + public uint Data + { + get { return result.Data; } + set { SetData(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetData(uint value) + { + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() + { + PrepareBuilder(); + result.hasData = false; + result.data_ = 0; + return this; + } + } + static Uint32Message() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Int64Message : pb::GeneratedMessage + { + private Int64Message() { } + private static readonly Int64Message defaultInstance = new Int64Message().MakeReadOnly(); + private static readonly string[] _int64MessageFieldNames = new string[] { "data" }; + private static readonly uint[] _int64MessageFieldTags = new uint[] { 8 }; + public static Int64Message DefaultInstance + { + get { return defaultInstance; } + } + + public override Int64Message DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override Int64Message ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int64Message__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int64Message__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private long data_; + public bool HasData + { + get { return hasData; } + } + public long Data + { + get { return data_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _int64MessageFieldNames; + if (hasData) + { + output.WriteInt64(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) + { + size += pb::CodedOutputStream.ComputeInt64Size(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Int64Message ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Int64Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Int64Message ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Int64Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Int64Message ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Int64Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Int64Message ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Int64Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Int64Message ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Int64Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Int64Message MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Int64Message prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Int64Message cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Int64Message result; + + private Int64Message PrepareBuilder() + { + if (resultIsReadOnly) + { + Int64Message original = result; + result = new Int64Message(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override Int64Message MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.Int64Message.Descriptor; } + } + + public override Int64Message DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.Int64Message.DefaultInstance; } + } + + public override Int64Message BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is Int64Message) + { + return MergeFrom((Int64Message)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Int64Message other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.Int64Message.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) + { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_int64MessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _int64MessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasData = input.ReadInt64(ref result.data_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData + { + get { return result.hasData; } + } + public long Data + { + get { return result.Data; } + set { SetData(value); } + } + public Builder SetData(long value) + { + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() + { + PrepareBuilder(); + result.hasData = false; + result.data_ = 0L; + return this; + } + } + static Int64Message() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Uint64Message : pb::GeneratedMessage + { + private Uint64Message() { } + private static readonly Uint64Message defaultInstance = new Uint64Message().MakeReadOnly(); + private static readonly string[] _uint64MessageFieldNames = new string[] { "data" }; + private static readonly uint[] _uint64MessageFieldTags = new uint[] { 8 }; + public static Uint64Message DefaultInstance + { + get { return defaultInstance; } + } + + public override Uint64Message DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override Uint64Message ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint64Message__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint64Message__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private ulong data_; + public bool HasData + { + get { return hasData; } + } + [global::System.CLSCompliant(false)] + public ulong Data + { + get { return data_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _uint64MessageFieldNames; + if (hasData) + { + output.WriteUInt64(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) + { + size += pb::CodedOutputStream.ComputeUInt64Size(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Uint64Message ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Uint64Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Uint64Message ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Uint64Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Uint64Message ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Uint64Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Uint64Message ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Uint64Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Uint64Message ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Uint64Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Uint64Message MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Uint64Message prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Uint64Message cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Uint64Message result; + + private Uint64Message PrepareBuilder() + { + if (resultIsReadOnly) + { + Uint64Message original = result; + result = new Uint64Message(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override Uint64Message MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.Uint64Message.Descriptor; } + } + + public override Uint64Message DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.Uint64Message.DefaultInstance; } + } + + public override Uint64Message BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is Uint64Message) + { + return MergeFrom((Uint64Message)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Uint64Message other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.Uint64Message.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) + { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_uint64MessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _uint64MessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasData = input.ReadUInt64(ref result.data_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData + { + get { return result.hasData; } + } + [global::System.CLSCompliant(false)] + public ulong Data + { + get { return result.Data; } + set { SetData(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetData(ulong value) + { + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() + { + PrepareBuilder(); + result.hasData = false; + result.data_ = 0UL; + return this; + } + } + static Uint64Message() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class BoolMessage : pb::GeneratedMessage + { + private BoolMessage() { } + private static readonly BoolMessage defaultInstance = new BoolMessage().MakeReadOnly(); + private static readonly string[] _boolMessageFieldNames = new string[] { "data" }; + private static readonly uint[] _boolMessageFieldTags = new uint[] { 8 }; + public static BoolMessage DefaultInstance + { + get { return defaultInstance; } + } + + public override BoolMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override BoolMessage ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BoolMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BoolMessage__FieldAccessorTable; } + } + + public const int DataFieldNumber = 1; + private bool hasData; + private bool data_; + public bool HasData + { + get { return hasData; } + } + public bool Data + { + get { return data_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _boolMessageFieldNames; + if (hasData) + { + output.WriteBool(1, field_names[0], Data); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasData) + { + size += pb::CodedOutputStream.ComputeBoolSize(1, Data); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static BoolMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BoolMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BoolMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BoolMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BoolMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BoolMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static BoolMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static BoolMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static BoolMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BoolMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private BoolMessage MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(BoolMessage prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(BoolMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private BoolMessage result; + + private BoolMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + BoolMessage original = result; + result = new BoolMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override BoolMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.BoolMessage.Descriptor; } + } + + public override BoolMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.BoolMessage.DefaultInstance; } + } + + public override BoolMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is BoolMessage) + { + return MergeFrom((BoolMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(BoolMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.BoolMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasData) + { + Data = other.Data; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_boolMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _boolMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasData = input.ReadBool(ref result.data_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasData + { + get { return result.hasData; } + } + public bool Data + { + get { return result.Data; } + set { SetData(value); } + } + public Builder SetData(bool value) + { + PrepareBuilder(); + result.hasData = true; + result.data_ = value; + return this; + } + public Builder ClearData() + { + PrepareBuilder(); + result.hasData = false; + result.data_ = false; + return this; + } + } + static BoolMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestOneof : pb::GeneratedMessage + { + private TestOneof() { } + private static readonly TestOneof defaultInstance = new TestOneof().MakeReadOnly(); + private static readonly string[] _testOneofFieldNames = new string[] { "foo_int", "foo_message", "foo_string", "foogroup" }; + private static readonly uint[] _testOneofFieldTags = new uint[] { 8, 26, 18, 35 }; + public static TestOneof DefaultInstance + { + get { return defaultInstance; } + } + + public override TestOneof DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestOneof ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooGroup : pb::GeneratedMessage + { + private FooGroup() { } + private static readonly FooGroup defaultInstance = new FooGroup().MakeReadOnly(); + private static readonly string[] _fooGroupFieldNames = new string[] { "a", "b" }; + private static readonly uint[] _fooGroupFieldTags = new uint[] { 40, 50 }; + public static FooGroup DefaultInstance + { + get { return defaultInstance; } + } + + public override FooGroup DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override FooGroup ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof_FooGroup__FieldAccessorTable; } + } + + public const int AFieldNumber = 5; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } + + public const int BFieldNumber = 6; + private bool hasB; + private string b_ = ""; + public bool HasB + { + get { return hasB; } + } + public string B + { + get { return b_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _fooGroupFieldNames; + if (hasA) + { + output.WriteInt32(5, field_names[0], A); + } + if (hasB) + { + output.WriteString(6, field_names[1], B); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(5, A); + } + if (hasB) + { + size += pb::CodedOutputStream.ComputeStringSize(6, B); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooGroup ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooGroup MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooGroup prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooGroup cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private FooGroup result; + + private FooGroup PrepareBuilder() + { + if (resultIsReadOnly) + { + FooGroup original = result; + result = new FooGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override FooGroup MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.Descriptor; } + } + + public override FooGroup DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance; } + } + + public override FooGroup BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is FooGroup) + { + return MergeFrom((FooGroup)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(FooGroup other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + if (other.HasB) + { + B = other.B; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_fooGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _fooGroupFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 40: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 50: + { + result.hasB = input.ReadString(ref result.b_); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } + + public bool HasB + { + get { return result.hasB; } + } + public string B + { + get { return result.B; } + set { SetB(value); } + } + public Builder SetB(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasB = true; + result.b_ = value; + return this; + } + public Builder ClearB() + { + PrepareBuilder(); + result.hasB = false; + result.b_ = ""; + return this; + } + } + static FooGroup() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + } + #endregion + + public const int FooIntFieldNumber = 1; + private bool hasFooInt; + private int fooInt_; + public bool HasFooInt + { + get { return hasFooInt; } + } + public int FooInt + { + get { return fooInt_; } + } + + public const int FooStringFieldNumber = 2; + private bool hasFooString; + private string fooString_ = ""; + public bool HasFooString + { + get { return hasFooString; } + } + public string FooString + { + get { return fooString_; } + } + + public const int FooMessageFieldNumber = 3; + private bool hasFooMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes fooMessage_; + public bool HasFooMessage + { + get { return hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage + { + get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } + + public const int FooGroupFieldNumber = 4; + private bool hasFooGroup; + private global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup fooGroup_; + public bool HasFooGroup + { + get { return hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup FooGroup + { + get { return fooGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testOneofFieldNames; + if (hasFooInt) + { + output.WriteInt32(1, field_names[0], FooInt); + } + if (hasFooString) + { + output.WriteString(2, field_names[2], FooString); + } + if (hasFooMessage) + { + output.WriteMessage(3, field_names[1], FooMessage); + } + if (hasFooGroup) + { + output.WriteGroup(4, field_names[3], FooGroup); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasFooInt) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); + } + if (hasFooString) + { + size += pb::CodedOutputStream.ComputeStringSize(2, FooString); + } + if (hasFooMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(3, FooMessage); + } + if (hasFooGroup) + { + size += pb::CodedOutputStream.ComputeGroupSize(4, FooGroup); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestOneof ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneof ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneof ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneof ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneof ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneof ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestOneof ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestOneof ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestOneof ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneof ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestOneof MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestOneof prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestOneof cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestOneof result; + + private TestOneof PrepareBuilder() + { + if (resultIsReadOnly) + { + TestOneof original = result; + result = new TestOneof(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestOneof MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.Descriptor; } + } + + public override TestOneof DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.DefaultInstance; } + } + + public override TestOneof BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestOneof) + { + return MergeFrom((TestOneof)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestOneof other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasFooInt) + { + FooInt = other.FooInt; + } + if (other.HasFooString) + { + FooString = other.FooString; + } + if (other.HasFooMessage) + { + MergeFooMessage(other.FooMessage); + } + if (other.HasFooGroup) + { + MergeFooGroup(other.FooGroup); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testOneofFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testOneofFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasFooInt = input.ReadInt32(ref result.fooInt_); + break; + } + case 18: + { + result.hasFooString = input.ReadString(ref result.fooString_); + break; + } + case 26: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasFooMessage) + { + subBuilder.MergeFrom(FooMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + FooMessage = subBuilder.BuildPartial(); + break; + } + case 35: + { + global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.CreateBuilder(); + if (result.hasFooGroup) + { + subBuilder.MergeFrom(FooGroup); + } + input.ReadGroup(4, subBuilder, extensionRegistry); + FooGroup = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasFooInt + { + get { return result.hasFooInt; } + } + public int FooInt + { + get { return result.FooInt; } + set { SetFooInt(value); } + } + public Builder SetFooInt(int value) + { + PrepareBuilder(); + result.hasFooInt = true; + result.fooInt_ = value; + return this; + } + public Builder ClearFooInt() + { + PrepareBuilder(); + result.hasFooInt = false; + result.fooInt_ = 0; + return this; + } + + public bool HasFooString + { + get { return result.hasFooString; } + } + public string FooString + { + get { return result.FooString; } + set { SetFooString(value); } + } + public Builder SetFooString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooString = true; + result.fooString_ = value; + return this; + } + public Builder ClearFooString() + { + PrepareBuilder(); + result.hasFooString = false; + result.fooString_ = ""; + return this; + } + + public bool HasFooMessage + { + get { return result.hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage + { + get { return result.FooMessage; } + set { SetFooMessage(value); } + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = value; + return this; + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooMessage && + result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.fooMessage_ = value; + } + result.hasFooMessage = true; + return this; + } + public Builder ClearFooMessage() + { + PrepareBuilder(); + result.hasFooMessage = false; + result.fooMessage_ = null; + return this; + } + + public bool HasFooGroup + { + get { return result.hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup FooGroup + { + get { return result.FooGroup; } + set { SetFooGroup(value); } + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = value; + return this; + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooGroup && + result.fooGroup_ != global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance) + { + result.fooGroup_ = global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.CreateBuilder(result.fooGroup_).MergeFrom(value).BuildPartial(); + } + else + { + result.fooGroup_ = value; + } + result.hasFooGroup = true; + return this; + } + public Builder ClearFooGroup() + { + PrepareBuilder(); + result.hasFooGroup = false; + result.fooGroup_ = null; + return this; + } + } + static TestOneof() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_ForeignMessage__Descriptor; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestOneofBackwardsCompatible : pb::GeneratedMessage + { + private TestOneofBackwardsCompatible() { } + private static readonly TestOneofBackwardsCompatible defaultInstance = new TestOneofBackwardsCompatible().MakeReadOnly(); + private static readonly string[] _testOneofBackwardsCompatibleFieldNames = new string[] { "foo_int", "foo_message", "foo_string", "foogroup" }; + private static readonly uint[] _testOneofBackwardsCompatibleFieldTags = new uint[] { 8, 26, 18, 35 }; + public static TestOneofBackwardsCompatible DefaultInstance + { + get { return defaultInstance; } + } + + public override TestOneofBackwardsCompatible DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestOneofBackwardsCompatible ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible__FieldAccessorTable; } + } + + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooGroup : pb::GeneratedMessage + { + private FooGroup() { } + private static readonly FooGroup defaultInstance = new FooGroup().MakeReadOnly(); + private static readonly string[] _fooGroupFieldNames = new string[] { "a", "b" }; + private static readonly uint[] _fooGroupFieldTags = new uint[] { 40, 50 }; + public static FooGroup DefaultInstance + { + get { return defaultInstance; } + } + + public override FooGroup DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override FooGroup ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__FieldAccessorTable; } + } + + public const int AFieldNumber = 5; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } + + public const int BFieldNumber = 6; + private bool hasB; + private string b_ = ""; + public bool HasB + { + get { return hasB; } + } + public string B + { + get { return b_; } + } + + public override bool IsInitialized + { + get + { + return true; + } + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _fooGroupFieldNames; + if (hasA) + { + output.WriteInt32(5, field_names[0], A); + } + if (hasB) + { + output.WriteString(6, field_names[1], B); + } + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(5, A); + } + if (hasB) + { + size += pb::CodedOutputStream.ComputeStringSize(6, B); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooGroup ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooGroup MakeReadOnly() + { + return this; + } + + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooGroup prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooGroup cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private FooGroup result; + + private FooGroup PrepareBuilder() + { + if (resultIsReadOnly) + { + FooGroup original = result; + result = new FooGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public const int CFieldNumber = 1; - private bool hasC; - private int c_; - public bool HasC { - get { return hasC; } - } - public int C { - get { return c_; } - } + protected override FooGroup MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public override bool IsInitialized { - get { - return true; - } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _foreignMessageFieldNames; - if (hasC) { - output.WriteInt32(1, field_names[0], C); - } - UnknownFields.WriteTo(output); - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.Descriptor; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasC) { - size += pb::CodedOutputStream.ComputeInt32Size(1, C); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static ForeignMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ForeignMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ForeignMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ForeignMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ForeignMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ForeignMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static ForeignMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ForeignMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private ForeignMessage MakeReadOnly() { - return this; - } + public override FooGroup DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(ForeignMessage prototype) { - return new Builder(prototype); - } + public override FooGroup BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(ForeignMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private ForeignMessage result; - - private ForeignMessage PrepareBuilder() { - if (resultIsReadOnly) { - ForeignMessage original = result; - result = new ForeignMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override ForeignMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Descriptor; } - } - - public override ForeignMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } - } - - public override ForeignMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is ForeignMessage) { - return MergeFrom((ForeignMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(ForeignMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasC) { - C = other.C; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_foreignMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _foreignMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasC = input.ReadInt32(ref result.c_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasC { - get { return result.hasC; } - } - public int C { - get { return result.C; } - set { SetC(value); } - } - public Builder SetC(int value) { - PrepareBuilder(); - result.hasC = true; - result.c_ = value; - return this; - } - public Builder ClearC() { - PrepareBuilder(); - result.hasC = false; - result.c_ = 0; - return this; - } - } - static ForeignMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestAllExtensions : pb::ExtendableMessage { - private TestAllExtensions() { } - private static readonly TestAllExtensions defaultInstance = new TestAllExtensions().MakeReadOnly(); - private static readonly string[] _testAllExtensionsFieldNames = new string[] { }; - private static readonly uint[] _testAllExtensionsFieldTags = new uint[] { }; - public static TestAllExtensions DefaultInstance { - get { return defaultInstance; } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is FooGroup) + { + return MergeFrom((FooGroup)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public override TestAllExtensions DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder MergeFrom(FooGroup other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + if (other.HasB) + { + B = other.B; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - protected override TestAllExtensions ThisMessage { - get { return this; } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllExtensions__Descriptor; } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_fooGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _fooGroupFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 40: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 50: + { + result.hasB = input.ReadString(ref result.b_); + break; + } + } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable; } - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testAllExtensionsFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(536870912, output); - UnknownFields.WriteTo(output); - } + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public bool HasB + { + get { return result.hasB; } + } + public string B + { + get { return result.B; } + set { SetB(value); } + } + public Builder SetB(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasB = true; + result.b_ = value; + return this; + } + public Builder ClearB() + { + PrepareBuilder(); + result.hasB = false; + result.b_ = ""; + return this; + } + } + static FooGroup() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + } + #endregion - size = 0; - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestAllExtensions ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestAllExtensions ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestAllExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestAllExtensions ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestAllExtensions MakeReadOnly() { - return this; - } + public const int FooIntFieldNumber = 1; + private bool hasFooInt; + private int fooInt_; + public bool HasFooInt + { + get { return hasFooInt; } + } + public int FooInt + { + get { return fooInt_; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestAllExtensions prototype) { - return new Builder(prototype); - } + public const int FooStringFieldNumber = 2; + private bool hasFooString; + private string fooString_ = ""; + public bool HasFooString + { + get { return hasFooString; } + } + public string FooString + { + get { return fooString_; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestAllExtensions cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestAllExtensions result; - - private TestAllExtensions PrepareBuilder() { - if (resultIsReadOnly) { - TestAllExtensions original = result; - result = new TestAllExtensions(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestAllExtensions MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.Descriptor; } - } - - public override TestAllExtensions DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.DefaultInstance; } - } - - public override TestAllExtensions BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestAllExtensions) { - return MergeFrom((TestAllExtensions) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestAllExtensions other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testAllExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testAllExtensionsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + public const int FooMessageFieldNumber = 3; + private bool hasFooMessage; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes fooMessage_; + public bool HasFooMessage + { + get { return hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage + { + get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } - } - static TestAllExtensions() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OptionalGroup_extension : pb::GeneratedMessage { - private OptionalGroup_extension() { } - private static readonly OptionalGroup_extension defaultInstance = new OptionalGroup_extension().MakeReadOnly(); - private static readonly string[] _optionalGroupExtensionFieldNames = new string[] { "a" }; - private static readonly uint[] _optionalGroupExtensionFieldTags = new uint[] { 136 }; - public static OptionalGroup_extension DefaultInstance { - get { return defaultInstance; } - } + public const int FooGroupFieldNumber = 4; + private bool hasFooGroup; + private global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup fooGroup_; + public bool HasFooGroup + { + get { return hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup FooGroup + { + get { return fooGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance; } + } - public override OptionalGroup_extension DefaultInstanceForType { - get { return DefaultInstance; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - protected override OptionalGroup_extension ThisMessage { - get { return this; } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testOneofBackwardsCompatibleFieldNames; + if (hasFooInt) + { + output.WriteInt32(1, field_names[0], FooInt); + } + if (hasFooString) + { + output.WriteString(2, field_names[2], FooString); + } + if (hasFooMessage) + { + output.WriteMessage(3, field_names[1], FooMessage); + } + if (hasFooGroup) + { + output.WriteGroup(4, field_names[3], FooGroup); + } + UnknownFields.WriteTo(output); + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor; } - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable; } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public const int AFieldNumber = 17; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } + size = 0; + if (hasFooInt) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); + } + if (hasFooString) + { + size += pb::CodedOutputStream.ComputeStringSize(2, FooString); + } + if (hasFooMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(3, FooMessage); + } + if (hasFooGroup) + { + size += pb::CodedOutputStream.ComputeGroupSize(4, FooGroup); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestOneofBackwardsCompatible ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneofBackwardsCompatible ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestOneofBackwardsCompatible MakeReadOnly() + { + return this; + } - public override bool IsInitialized { - get { - return true; - } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestOneofBackwardsCompatible prototype) + { + return new Builder(prototype); + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _optionalGroupExtensionFieldNames; - if (hasA) { - output.WriteInt32(17, field_names[0], A); - } - UnknownFields.WriteTo(output); - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestOneofBackwardsCompatible cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + private bool resultIsReadOnly; + private TestOneofBackwardsCompatible result; - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(17, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static OptionalGroup_extension ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static OptionalGroup_extension ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static OptionalGroup_extension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OptionalGroup_extension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private OptionalGroup_extension MakeReadOnly() { - return this; - } + private TestOneofBackwardsCompatible PrepareBuilder() + { + if (resultIsReadOnly) + { + TestOneofBackwardsCompatible original = result; + result = new TestOneofBackwardsCompatible(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override TestOneofBackwardsCompatible MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Descriptor; } + } + + public override TestOneofBackwardsCompatible DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.DefaultInstance; } + } + + public override TestOneofBackwardsCompatible BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestOneofBackwardsCompatible) + { + return MergeFrom((TestOneofBackwardsCompatible)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(TestOneofBackwardsCompatible other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasFooInt) + { + FooInt = other.FooInt; + } + if (other.HasFooString) + { + FooString = other.FooString; + } + if (other.HasFooMessage) + { + MergeFooMessage(other.FooMessage); + } + if (other.HasFooGroup) + { + MergeFooGroup(other.FooGroup); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testOneofBackwardsCompatibleFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testOneofBackwardsCompatibleFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasFooInt = input.ReadInt32(ref result.fooInt_); + break; + } + case 18: + { + result.hasFooString = input.ReadString(ref result.fooString_); + break; + } + case 26: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasFooMessage) + { + subBuilder.MergeFrom(FooMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + FooMessage = subBuilder.BuildPartial(); + break; + } + case 35: + { + global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.CreateBuilder(); + if (result.hasFooGroup) + { + subBuilder.MergeFrom(FooGroup); + } + input.ReadGroup(4, subBuilder, extensionRegistry); + FooGroup = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasFooInt + { + get { return result.hasFooInt; } + } + public int FooInt + { + get { return result.FooInt; } + set { SetFooInt(value); } + } + public Builder SetFooInt(int value) + { + PrepareBuilder(); + result.hasFooInt = true; + result.fooInt_ = value; + return this; + } + public Builder ClearFooInt() + { + PrepareBuilder(); + result.hasFooInt = false; + result.fooInt_ = 0; + return this; + } + + public bool HasFooString + { + get { return result.hasFooString; } + } + public string FooString + { + get { return result.FooString; } + set { SetFooString(value); } + } + public Builder SetFooString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooString = true; + result.fooString_ = value; + return this; + } + public Builder ClearFooString() + { + PrepareBuilder(); + result.hasFooString = false; + result.fooString_ = ""; + return this; + } + + public bool HasFooMessage + { + get { return result.hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage + { + get { return result.FooMessage; } + set { SetFooMessage(value); } + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = value; + return this; + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooMessage && + result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.fooMessage_ = value; + } + result.hasFooMessage = true; + return this; + } + public Builder ClearFooMessage() + { + PrepareBuilder(); + result.hasFooMessage = false; + result.fooMessage_ = null; + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OptionalGroup_extension prototype) { - return new Builder(prototype); + public bool HasFooGroup + { + get { return result.hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup FooGroup + { + get { return result.FooGroup; } + set { SetFooGroup(value); } + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = value; + return this; + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooGroup && + result.fooGroup_ != global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance) + { + result.fooGroup_ = global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.CreateBuilder(result.fooGroup_).MergeFrom(value).BuildPartial(); + } + else + { + result.fooGroup_ = value; + } + result.hasFooGroup = true; + return this; + } + public Builder ClearFooGroup() + { + PrepareBuilder(); + result.hasFooGroup = false; + result.fooGroup_ = null; + return this; + } + } + static TestOneofBackwardsCompatible() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OptionalGroup_extension cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OptionalGroup_extension result; - - private OptionalGroup_extension PrepareBuilder() { - if (resultIsReadOnly) { - OptionalGroup_extension original = result; - result = new OptionalGroup_extension(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OptionalGroup_extension MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.Descriptor; } - } - - public override OptionalGroup_extension DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.DefaultInstance; } - } - - public override OptionalGroup_extension BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is OptionalGroup_extension) { - return MergeFrom((OptionalGroup_extension) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(OptionalGroup_extension other) { - if (other == global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_optionalGroupExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _optionalGroupExtensionFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 136: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static OptionalGroup_extension() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class RepeatedGroup_extension : pb::GeneratedMessage { - private RepeatedGroup_extension() { } - private static readonly RepeatedGroup_extension defaultInstance = new RepeatedGroup_extension().MakeReadOnly(); - private static readonly string[] _repeatedGroupExtensionFieldNames = new string[] { "a" }; - private static readonly uint[] _repeatedGroupExtensionFieldTags = new uint[] { 376 }; - public static RepeatedGroup_extension DefaultInstance { - get { return defaultInstance; } - } - - public override RepeatedGroup_extension DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override RepeatedGroup_extension ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable; } - } + public sealed partial class TestOneof2 : pb::GeneratedMessage + { + private TestOneof2() { } + private static readonly TestOneof2 defaultInstance = new TestOneof2().MakeReadOnly(); + private static readonly string[] _testOneof2FieldNames = new string[] { "bar_bytes", "bar_cord", "bar_enum", "bar_int", "bar_string", "bar_string_piece", "baz_int", "baz_string", "foo_bytes", "foo_cord", "foo_enum", "foo_int", "foo_lazy_message", "foo_message", "foo_string", "foo_string_piece", "foogroup" }; + private static readonly uint[] _testOneof2FieldTags = new uint[] { 130, 114, 136, 96, 106, 122, 144, 154, 42, 26, 48, 8, 90, 58, 18, 34, 67 }; + public static TestOneof2 DefaultInstance + { + get { return defaultInstance; } + } - public const int AFieldNumber = 47; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } + public override TestOneof2 DefaultInstanceForType + { + get { return DefaultInstance; } + } - public override bool IsInitialized { - get { - return true; - } - } + protected override TestOneof2 ThisMessage + { + get { return this; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _repeatedGroupExtensionFieldNames; - if (hasA) { - output.WriteInt32(47, field_names[0], A); - } - UnknownFields.WriteTo(output); - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2__Descriptor; } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2__FieldAccessorTable; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(47, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static RepeatedGroup_extension ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static RepeatedGroup_extension ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static RepeatedGroup_extension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedGroup_extension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private RepeatedGroup_extension MakeReadOnly() { - return this; - } + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + public enum NestedEnum + { + FOO = 1, + BAR = 2, + BAZ = 3, + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(RepeatedGroup_extension prototype) { - return new Builder(prototype); - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooGroup : pb::GeneratedMessage + { + private FooGroup() { } + private static readonly FooGroup defaultInstance = new FooGroup().MakeReadOnly(); + private static readonly string[] _fooGroupFieldNames = new string[] { "a", "b" }; + private static readonly uint[] _fooGroupFieldTags = new uint[] { 72, 82 }; + public static FooGroup DefaultInstance + { + get { return defaultInstance; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(RepeatedGroup_extension cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private RepeatedGroup_extension result; - - private RepeatedGroup_extension PrepareBuilder() { - if (resultIsReadOnly) { - RepeatedGroup_extension original = result; - result = new RepeatedGroup_extension(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override RepeatedGroup_extension MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.Descriptor; } - } - - public override RepeatedGroup_extension DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.DefaultInstance; } - } - - public override RepeatedGroup_extension BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is RepeatedGroup_extension) { - return MergeFrom((RepeatedGroup_extension) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(RepeatedGroup_extension other) { - if (other == global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _repeatedGroupExtensionFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 376: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - } - static RepeatedGroup_extension() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestNestedExtension : pb::GeneratedMessage { - private TestNestedExtension() { } - private static readonly TestNestedExtension defaultInstance = new TestNestedExtension().MakeReadOnly(); - private static readonly string[] _testNestedExtensionFieldNames = new string[] { }; - private static readonly uint[] _testNestedExtensionFieldTags = new uint[] { }; - public static TestNestedExtension DefaultInstance { - get { return defaultInstance; } - } + public override FooGroup DefaultInstanceForType + { + get { return DefaultInstance; } + } - public override TestNestedExtension DefaultInstanceForType { - get { return DefaultInstance; } - } + protected override FooGroup ThisMessage + { + get { return this; } + } - protected override TestNestedExtension ThisMessage { - get { return this; } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedExtension__Descriptor; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_FooGroup__FieldAccessorTable; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable; } - } + public const int AFieldNumber = 9; + private bool hasA; + private int a_; + public bool HasA + { + get { return hasA; } + } + public int A + { + get { return a_; } + } - public const int TestFieldNumber = 1002; - public static pb::GeneratedExtensionBase Test; - public const int NestedStringExtensionFieldNumber = 1003; - public static pb::GeneratedExtensionBase NestedStringExtension; - public override bool IsInitialized { - get { - return true; - } - } + public const int BFieldNumber = 10; + private bool hasB; + private string b_ = ""; + public bool HasB + { + get { return hasB; } + } + public string B + { + get { return b_; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testNestedExtensionFieldNames; - UnknownFields.WriteTo(output); - } + public override bool IsInitialized + { + get + { + return true; + } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _fooGroupFieldNames; + if (hasA) + { + output.WriteInt32(9, field_names[0], A); + } + if (hasB) + { + output.WriteString(10, field_names[1], B); + } + UnknownFields.WriteTo(output); + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestNestedExtension ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestNestedExtension ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestNestedExtension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestNestedExtension ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestNestedExtension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestNestedExtension MakeReadOnly() { - return this; - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestNestedExtension prototype) { - return new Builder(prototype); - } + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeInt32Size(9, A); + } + if (hasB) + { + size += pb::CodedOutputStream.ComputeStringSize(10, B); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooGroup ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooGroup MakeReadOnly() + { + return this; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestNestedExtension cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestNestedExtension result; - - private TestNestedExtension PrepareBuilder() { - if (resultIsReadOnly) { - TestNestedExtension original = result; - result = new TestNestedExtension(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestNestedExtension MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor; } - } - - public override TestNestedExtension DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.DefaultInstance; } - } - - public override TestNestedExtension BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestNestedExtension) { - return MergeFrom((TestNestedExtension) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestNestedExtension other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testNestedExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testNestedExtensionFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooGroup prototype) + { + return new Builder(prototype); + } - } - static TestNestedExtension() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestRequired : pb::GeneratedMessage { - private TestRequired() { } - private static readonly TestRequired defaultInstance = new TestRequired().MakeReadOnly(); - private static readonly string[] _testRequiredFieldNames = new string[] { "a", "b", "c", "dummy10", "dummy11", "dummy12", "dummy13", "dummy14", "dummy15", "dummy16", "dummy17", "dummy18", "dummy19", "dummy2", "dummy20", "dummy21", "dummy22", "dummy23", "dummy24", "dummy25", "dummy26", "dummy27", "dummy28", "dummy29", "dummy30", "dummy31", "dummy32", "dummy4", "dummy5", "dummy6", "dummy7", "dummy8", "dummy9" }; - private static readonly uint[] _testRequiredFieldTags = new uint[] { 8, 24, 264, 80, 88, 96, 104, 112, 120, 128, 136, 144, 152, 16, 160, 168, 176, 184, 192, 200, 208, 216, 224, 232, 240, 248, 256, 32, 40, 48, 56, 64, 72 }; - public static TestRequired DefaultInstance { - get { return defaultInstance; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooGroup cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - public override TestRequired DefaultInstanceForType { - get { return DefaultInstance; } - } + private bool resultIsReadOnly; + private FooGroup result; + + private FooGroup PrepareBuilder() + { + if (resultIsReadOnly) + { + FooGroup original = result; + result = new FooGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - protected override TestRequired ThisMessage { - get { return this; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequired__Descriptor; } - } + protected override FooGroup MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequired__FieldAccessorTable; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public const int SingleFieldNumber = 1000; - public static pb::GeneratedExtensionBase Single; - public const int MultiFieldNumber = 1001; - public static pb::GeneratedExtensionBase> Multi; - public const int AFieldNumber = 1; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public const int Dummy2FieldNumber = 2; - private bool hasDummy2; - private int dummy2_; - public bool HasDummy2 { - get { return hasDummy2; } - } - public int Dummy2 { - get { return dummy2_; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.Descriptor; } + } - public const int BFieldNumber = 3; - private bool hasB; - private int b_; - public bool HasB { - get { return hasB; } - } - public int B { - get { return b_; } - } + public override FooGroup DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance; } + } - public const int Dummy4FieldNumber = 4; - private bool hasDummy4; - private int dummy4_; - public bool HasDummy4 { - get { return hasDummy4; } - } - public int Dummy4 { - get { return dummy4_; } - } + public override FooGroup BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public const int Dummy5FieldNumber = 5; - private bool hasDummy5; - private int dummy5_; - public bool HasDummy5 { - get { return hasDummy5; } - } - public int Dummy5 { - get { return dummy5_; } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is FooGroup) + { + return MergeFrom((FooGroup)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public const int Dummy6FieldNumber = 6; - private bool hasDummy6; - private int dummy6_; - public bool HasDummy6 { - get { return hasDummy6; } - } - public int Dummy6 { - get { return dummy6_; } - } + public override Builder MergeFrom(FooGroup other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasA) + { + A = other.A; + } + if (other.HasB) + { + B = other.B; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public const int Dummy7FieldNumber = 7; - private bool hasDummy7; - private int dummy7_; - public bool HasDummy7 { - get { return hasDummy7; } - } - public int Dummy7 { - get { return dummy7_; } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public const int Dummy8FieldNumber = 8; - private bool hasDummy8; - private int dummy8_; - public bool HasDummy8 { - get { return hasDummy8; } - } - public int Dummy8 { - get { return dummy8_; } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_fooGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _fooGroupFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 72: + { + result.hasA = input.ReadInt32(ref result.a_); + break; + } + case 82: + { + result.hasB = input.ReadString(ref result.b_); + break; + } + } + } - public const int Dummy9FieldNumber = 9; - private bool hasDummy9; - private int dummy9_; - public bool HasDummy9 { - get { return hasDummy9; } - } - public int Dummy9 { - get { return dummy9_; } - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public const int Dummy10FieldNumber = 10; - private bool hasDummy10; - private int dummy10_; - public bool HasDummy10 { - get { return hasDummy10; } - } - public int Dummy10 { - get { return dummy10_; } - } - public const int Dummy11FieldNumber = 11; - private bool hasDummy11; - private int dummy11_; - public bool HasDummy11 { - get { return hasDummy11; } - } - public int Dummy11 { - get { return dummy11_; } - } + public bool HasA + { + get { return result.hasA; } + } + public int A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(int value) + { + PrepareBuilder(); + result.hasA = true; + result.a_ = value; + return this; + } + public Builder ClearA() + { + PrepareBuilder(); + result.hasA = false; + result.a_ = 0; + return this; + } - public const int Dummy12FieldNumber = 12; - private bool hasDummy12; - private int dummy12_; - public bool HasDummy12 { - get { return hasDummy12; } - } - public int Dummy12 { - get { return dummy12_; } - } + public bool HasB + { + get { return result.hasB; } + } + public string B + { + get { return result.B; } + set { SetB(value); } + } + public Builder SetB(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasB = true; + result.b_ = value; + return this; + } + public Builder ClearB() + { + PrepareBuilder(); + result.hasB = false; + result.b_ = ""; + return this; + } + } + static FooGroup() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - public const int Dummy13FieldNumber = 13; - private bool hasDummy13; - private int dummy13_; - public bool HasDummy13 { - get { return hasDummy13; } - } - public int Dummy13 { - get { return dummy13_; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessage + { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "corge_int", "qux_int" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 16, 8 }; + public static NestedMessage DefaultInstance + { + get { return defaultInstance; } + } - public const int Dummy14FieldNumber = 14; - private bool hasDummy14; - private int dummy14_; - public bool HasDummy14 { - get { return hasDummy14; } - } - public int Dummy14 { - get { return dummy14_; } - } + public override NestedMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } - public const int Dummy15FieldNumber = 15; - private bool hasDummy15; - private int dummy15_; - public bool HasDummy15 { - get { return hasDummy15; } - } - public int Dummy15 { - get { return dummy15_; } - } + protected override NestedMessage ThisMessage + { + get { return this; } + } - public const int Dummy16FieldNumber = 16; - private bool hasDummy16; - private int dummy16_; - public bool HasDummy16 { - get { return hasDummy16; } - } - public int Dummy16 { - get { return dummy16_; } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor; } + } - public const int Dummy17FieldNumber = 17; - private bool hasDummy17; - private int dummy17_; - public bool HasDummy17 { - get { return hasDummy17; } - } - public int Dummy17 { - get { return dummy17_; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_NestedMessage__FieldAccessorTable; } + } - public const int Dummy18FieldNumber = 18; - private bool hasDummy18; - private int dummy18_; - public bool HasDummy18 { - get { return hasDummy18; } - } - public int Dummy18 { - get { return dummy18_; } - } + public const int QuxIntFieldNumber = 1; + private bool hasQuxInt; + private long quxInt_; + public bool HasQuxInt + { + get { return hasQuxInt; } + } + public long QuxInt + { + get { return quxInt_; } + } - public const int Dummy19FieldNumber = 19; - private bool hasDummy19; - private int dummy19_; - public bool HasDummy19 { - get { return hasDummy19; } - } - public int Dummy19 { - get { return dummy19_; } - } + public const int CorgeIntFieldNumber = 2; + private pbc::PopsicleList corgeInt_ = new pbc::PopsicleList(); + public scg::IList CorgeIntList + { + get { return pbc::Lists.AsReadOnly(corgeInt_); } + } + public int CorgeIntCount + { + get { return corgeInt_.Count; } + } + public int GetCorgeInt(int index) + { + return corgeInt_[index]; + } - public const int Dummy20FieldNumber = 20; - private bool hasDummy20; - private int dummy20_; - public bool HasDummy20 { - get { return hasDummy20; } - } - public int Dummy20 { - get { return dummy20_; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - public const int Dummy21FieldNumber = 21; - private bool hasDummy21; - private int dummy21_; - public bool HasDummy21 { - get { return hasDummy21; } - } - public int Dummy21 { - get { return dummy21_; } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (hasQuxInt) + { + output.WriteInt64(1, field_names[1], QuxInt); + } + if (corgeInt_.Count > 0) + { + output.WriteInt32Array(2, field_names[0], corgeInt_); + } + UnknownFields.WriteTo(output); + } - public const int Dummy22FieldNumber = 22; - private bool hasDummy22; - private int dummy22_; - public bool HasDummy22 { - get { return hasDummy22; } - } - public int Dummy22 { - get { return dummy22_; } - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public const int Dummy23FieldNumber = 23; - private bool hasDummy23; - private int dummy23_; - public bool HasDummy23 { - get { return hasDummy23; } - } - public int Dummy23 { - get { return dummy23_; } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public const int Dummy24FieldNumber = 24; - private bool hasDummy24; - private int dummy24_; - public bool HasDummy24 { - get { return hasDummy24; } - } - public int Dummy24 { - get { return dummy24_; } - } + size = 0; + if (hasQuxInt) + { + size += pb::CodedOutputStream.ComputeInt64Size(1, QuxInt); + } + { + int dataSize = 0; + foreach (int element in CorgeIntList) + { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 1 * corgeInt_.Count; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() + { + corgeInt_.MakeReadOnly(); + return this; + } - public const int Dummy25FieldNumber = 25; - private bool hasDummy25; - private int dummy25_; - public bool HasDummy25 { - get { return hasDummy25; } - } - public int Dummy25 { - get { return dummy25_; } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) + { + return new Builder(prototype); + } - public const int Dummy26FieldNumber = 26; - private bool hasDummy26; - private int dummy26_; - public bool HasDummy26 { - get { return hasDummy26; } - } - public int Dummy26 { - get { return dummy26_; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - public const int Dummy27FieldNumber = 27; - private bool hasDummy27; - private int dummy27_; - public bool HasDummy27 { - get { return hasDummy27; } - } - public int Dummy27 { - get { return dummy27_; } - } + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public const int Dummy28FieldNumber = 28; - private bool hasDummy28; - private int dummy28_; - public bool HasDummy28 { - get { return hasDummy28; } - } - public int Dummy28 { - get { return dummy28_; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public const int Dummy29FieldNumber = 29; - private bool hasDummy29; - private int dummy29_; - public bool HasDummy29 { - get { return hasDummy29; } - } - public int Dummy29 { - get { return dummy29_; } - } + protected override NestedMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public const int Dummy30FieldNumber = 30; - private bool hasDummy30; - private int dummy30_; - public bool HasDummy30 { - get { return hasDummy30; } - } - public int Dummy30 { - get { return dummy30_; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public const int Dummy31FieldNumber = 31; - private bool hasDummy31; - private int dummy31_; - public bool HasDummy31 { - get { return hasDummy31; } - } - public int Dummy31 { - get { return dummy31_; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public const int Dummy32FieldNumber = 32; - private bool hasDummy32; - private int dummy32_; - public bool HasDummy32 { - get { return hasDummy32; } - } - public int Dummy32 { - get { return dummy32_; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Descriptor; } + } - public const int CFieldNumber = 33; - private bool hasC; - private int c_; - public bool HasC { - get { return hasC; } - } - public int C { - get { return c_; } - } + public override NestedMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance; } + } - public override bool IsInitialized { - get { - if (!hasA) return false; - if (!hasB) return false; - if (!hasC) return false; - return true; - } - } + public override NestedMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testRequiredFieldNames; - if (hasA) { - output.WriteInt32(1, field_names[0], A); - } - if (hasDummy2) { - output.WriteInt32(2, field_names[13], Dummy2); - } - if (hasB) { - output.WriteInt32(3, field_names[1], B); - } - if (hasDummy4) { - output.WriteInt32(4, field_names[27], Dummy4); - } - if (hasDummy5) { - output.WriteInt32(5, field_names[28], Dummy5); - } - if (hasDummy6) { - output.WriteInt32(6, field_names[29], Dummy6); - } - if (hasDummy7) { - output.WriteInt32(7, field_names[30], Dummy7); - } - if (hasDummy8) { - output.WriteInt32(8, field_names[31], Dummy8); - } - if (hasDummy9) { - output.WriteInt32(9, field_names[32], Dummy9); - } - if (hasDummy10) { - output.WriteInt32(10, field_names[3], Dummy10); - } - if (hasDummy11) { - output.WriteInt32(11, field_names[4], Dummy11); - } - if (hasDummy12) { - output.WriteInt32(12, field_names[5], Dummy12); - } - if (hasDummy13) { - output.WriteInt32(13, field_names[6], Dummy13); - } - if (hasDummy14) { - output.WriteInt32(14, field_names[7], Dummy14); - } - if (hasDummy15) { - output.WriteInt32(15, field_names[8], Dummy15); - } - if (hasDummy16) { - output.WriteInt32(16, field_names[9], Dummy16); - } - if (hasDummy17) { - output.WriteInt32(17, field_names[10], Dummy17); - } - if (hasDummy18) { - output.WriteInt32(18, field_names[11], Dummy18); - } - if (hasDummy19) { - output.WriteInt32(19, field_names[12], Dummy19); - } - if (hasDummy20) { - output.WriteInt32(20, field_names[14], Dummy20); - } - if (hasDummy21) { - output.WriteInt32(21, field_names[15], Dummy21); - } - if (hasDummy22) { - output.WriteInt32(22, field_names[16], Dummy22); - } - if (hasDummy23) { - output.WriteInt32(23, field_names[17], Dummy23); - } - if (hasDummy24) { - output.WriteInt32(24, field_names[18], Dummy24); - } - if (hasDummy25) { - output.WriteInt32(25, field_names[19], Dummy25); - } - if (hasDummy26) { - output.WriteInt32(26, field_names[20], Dummy26); - } - if (hasDummy27) { - output.WriteInt32(27, field_names[21], Dummy27); - } - if (hasDummy28) { - output.WriteInt32(28, field_names[22], Dummy28); - } - if (hasDummy29) { - output.WriteInt32(29, field_names[23], Dummy29); - } - if (hasDummy30) { - output.WriteInt32(30, field_names[24], Dummy30); - } - if (hasDummy31) { - output.WriteInt32(31, field_names[25], Dummy31); - } - if (hasDummy32) { - output.WriteInt32(32, field_names[26], Dummy32); - } - if (hasC) { - output.WriteInt32(33, field_names[2], C); - } - UnknownFields.WriteTo(output); - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is NestedMessage) + { + return MergeFrom((NestedMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override Builder MergeFrom(NestedMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasQuxInt) + { + QuxInt = other.QuxInt; + } + if (other.corgeInt_.Count != 0) + { + result.corgeInt_.Add(other.corgeInt_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A); - } - if (hasDummy2) { - size += pb::CodedOutputStream.ComputeInt32Size(2, Dummy2); - } - if (hasB) { - size += pb::CodedOutputStream.ComputeInt32Size(3, B); - } - if (hasDummy4) { - size += pb::CodedOutputStream.ComputeInt32Size(4, Dummy4); - } - if (hasDummy5) { - size += pb::CodedOutputStream.ComputeInt32Size(5, Dummy5); - } - if (hasDummy6) { - size += pb::CodedOutputStream.ComputeInt32Size(6, Dummy6); - } - if (hasDummy7) { - size += pb::CodedOutputStream.ComputeInt32Size(7, Dummy7); - } - if (hasDummy8) { - size += pb::CodedOutputStream.ComputeInt32Size(8, Dummy8); - } - if (hasDummy9) { - size += pb::CodedOutputStream.ComputeInt32Size(9, Dummy9); - } - if (hasDummy10) { - size += pb::CodedOutputStream.ComputeInt32Size(10, Dummy10); - } - if (hasDummy11) { - size += pb::CodedOutputStream.ComputeInt32Size(11, Dummy11); - } - if (hasDummy12) { - size += pb::CodedOutputStream.ComputeInt32Size(12, Dummy12); - } - if (hasDummy13) { - size += pb::CodedOutputStream.ComputeInt32Size(13, Dummy13); - } - if (hasDummy14) { - size += pb::CodedOutputStream.ComputeInt32Size(14, Dummy14); - } - if (hasDummy15) { - size += pb::CodedOutputStream.ComputeInt32Size(15, Dummy15); - } - if (hasDummy16) { - size += pb::CodedOutputStream.ComputeInt32Size(16, Dummy16); - } - if (hasDummy17) { - size += pb::CodedOutputStream.ComputeInt32Size(17, Dummy17); - } - if (hasDummy18) { - size += pb::CodedOutputStream.ComputeInt32Size(18, Dummy18); - } - if (hasDummy19) { - size += pb::CodedOutputStream.ComputeInt32Size(19, Dummy19); - } - if (hasDummy20) { - size += pb::CodedOutputStream.ComputeInt32Size(20, Dummy20); - } - if (hasDummy21) { - size += pb::CodedOutputStream.ComputeInt32Size(21, Dummy21); - } - if (hasDummy22) { - size += pb::CodedOutputStream.ComputeInt32Size(22, Dummy22); - } - if (hasDummy23) { - size += pb::CodedOutputStream.ComputeInt32Size(23, Dummy23); - } - if (hasDummy24) { - size += pb::CodedOutputStream.ComputeInt32Size(24, Dummy24); - } - if (hasDummy25) { - size += pb::CodedOutputStream.ComputeInt32Size(25, Dummy25); - } - if (hasDummy26) { - size += pb::CodedOutputStream.ComputeInt32Size(26, Dummy26); - } - if (hasDummy27) { - size += pb::CodedOutputStream.ComputeInt32Size(27, Dummy27); - } - if (hasDummy28) { - size += pb::CodedOutputStream.ComputeInt32Size(28, Dummy28); - } - if (hasDummy29) { - size += pb::CodedOutputStream.ComputeInt32Size(29, Dummy29); - } - if (hasDummy30) { - size += pb::CodedOutputStream.ComputeInt32Size(30, Dummy30); - } - if (hasDummy31) { - size += pb::CodedOutputStream.ComputeInt32Size(31, Dummy31); - } - if (hasDummy32) { - size += pb::CodedOutputStream.ComputeInt32Size(32, Dummy32); - } - if (hasC) { - size += pb::CodedOutputStream.ComputeInt32Size(33, C); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestRequired ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequired ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequired ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequired ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequired ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequired ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestRequired ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestRequired ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestRequired ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequired ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestRequired MakeReadOnly() { - return this; - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestRequired prototype) { - return new Builder(prototype); - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasQuxInt = input.ReadInt64(ref result.quxInt_); + break; + } + case 18: + case 16: + { + input.ReadInt32Array(tag, field_name, result.corgeInt_); + break; + } + } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestRequired cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestRequired result; - - private TestRequired PrepareBuilder() { - if (resultIsReadOnly) { - TestRequired original = result; - result = new TestRequired(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public override bool IsInitialized { - get { return result.IsInitialized; } - } - protected override TestRequired MessageBeingBuilt { - get { return PrepareBuilder(); } - } + public bool HasQuxInt + { + get { return result.hasQuxInt; } + } + public long QuxInt + { + get { return result.QuxInt; } + set { SetQuxInt(value); } + } + public Builder SetQuxInt(long value) + { + PrepareBuilder(); + result.hasQuxInt = true; + result.quxInt_ = value; + return this; + } + public Builder ClearQuxInt() + { + PrepareBuilder(); + result.hasQuxInt = false; + result.quxInt_ = 0L; + return this; + } - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + public pbc::IPopsicleList CorgeIntList + { + get { return PrepareBuilder().corgeInt_; } + } + public int CorgeIntCount + { + get { return result.CorgeIntCount; } + } + public int GetCorgeInt(int index) + { + return result.GetCorgeInt(index); + } + public Builder SetCorgeInt(int index, int value) + { + PrepareBuilder(); + result.corgeInt_[index] = value; + return this; + } + public Builder AddCorgeInt(int value) + { + PrepareBuilder(); + result.corgeInt_.Add(value); + return this; + } + public Builder AddRangeCorgeInt(scg::IEnumerable values) + { + PrepareBuilder(); + result.corgeInt_.Add(values); + return this; + } + public Builder ClearCorgeInt() + { + PrepareBuilder(); + result.corgeInt_.Clear(); + return this; + } + } + static NestedMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor; } - } - - public override TestRequired DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance; } - } + #endregion - public override TestRequired BuildPartial() { - if (resultIsReadOnly) { - return result; + public const int FooIntFieldNumber = 1; + private bool hasFooInt; + private int fooInt_; + public bool HasFooInt + { + get { return hasFooInt; } } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestRequired) { - return MergeFrom((TestRequired) other); - } else { - base.MergeFrom(other); - return this; + public int FooInt + { + get { return fooInt_; } } - } - public override Builder MergeFrom(TestRequired other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - if (other.HasDummy2) { - Dummy2 = other.Dummy2; - } - if (other.HasB) { - B = other.B; - } - if (other.HasDummy4) { - Dummy4 = other.Dummy4; + public const int FooStringFieldNumber = 2; + private bool hasFooString; + private string fooString_ = ""; + public bool HasFooString + { + get { return hasFooString; } } - if (other.HasDummy5) { - Dummy5 = other.Dummy5; + public string FooString + { + get { return fooString_; } } - if (other.HasDummy6) { - Dummy6 = other.Dummy6; - } - if (other.HasDummy7) { - Dummy7 = other.Dummy7; - } - if (other.HasDummy8) { - Dummy8 = other.Dummy8; + + public const int FooCordFieldNumber = 3; + private bool hasFooCord; + private string fooCord_ = ""; + public bool HasFooCord + { + get { return hasFooCord; } } - if (other.HasDummy9) { - Dummy9 = other.Dummy9; + public string FooCord + { + get { return fooCord_; } } - if (other.HasDummy10) { - Dummy10 = other.Dummy10; + + public const int FooStringPieceFieldNumber = 4; + private bool hasFooStringPiece; + private string fooStringPiece_ = ""; + public bool HasFooStringPiece + { + get { return hasFooStringPiece; } } - if (other.HasDummy11) { - Dummy11 = other.Dummy11; + public string FooStringPiece + { + get { return fooStringPiece_; } } - if (other.HasDummy12) { - Dummy12 = other.Dummy12; + + public const int FooBytesFieldNumber = 5; + private bool hasFooBytes; + private pb::ByteString fooBytes_ = pb::ByteString.Empty; + public bool HasFooBytes + { + get { return hasFooBytes; } } - if (other.HasDummy13) { - Dummy13 = other.Dummy13; + public pb::ByteString FooBytes + { + get { return fooBytes_; } } - if (other.HasDummy14) { - Dummy14 = other.Dummy14; + + public const int FooEnumFieldNumber = 6; + private bool hasFooEnum; + private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum fooEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.FOO; + public bool HasFooEnum + { + get { return hasFooEnum; } } - if (other.HasDummy15) { - Dummy15 = other.Dummy15; + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum FooEnum + { + get { return fooEnum_; } } - if (other.HasDummy16) { - Dummy16 = other.Dummy16; + + public const int FooMessageFieldNumber = 7; + private bool hasFooMessage; + private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage fooMessage_; + public bool HasFooMessage + { + get { return hasFooMessage; } } - if (other.HasDummy17) { - Dummy17 = other.Dummy17; + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooMessage + { + get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance; } } - if (other.HasDummy18) { - Dummy18 = other.Dummy18; + + public const int FooGroupFieldNumber = 8; + private bool hasFooGroup; + private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup fooGroup_; + public bool HasFooGroup + { + get { return hasFooGroup; } } - if (other.HasDummy19) { - Dummy19 = other.Dummy19; + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup FooGroup + { + get { return fooGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance; } } - if (other.HasDummy20) { - Dummy20 = other.Dummy20; + + public const int FooLazyMessageFieldNumber = 11; + private bool hasFooLazyMessage; + private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage fooLazyMessage_; + public bool HasFooLazyMessage + { + get { return hasFooLazyMessage; } } - if (other.HasDummy21) { - Dummy21 = other.Dummy21; + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooLazyMessage + { + get { return fooLazyMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance; } } - if (other.HasDummy22) { - Dummy22 = other.Dummy22; + + public const int BarIntFieldNumber = 12; + private bool hasBarInt; + private int barInt_ = 5; + public bool HasBarInt + { + get { return hasBarInt; } } - if (other.HasDummy23) { - Dummy23 = other.Dummy23; + public int BarInt + { + get { return barInt_; } } - if (other.HasDummy24) { - Dummy24 = other.Dummy24; + + public const int BarStringFieldNumber = 13; + private bool hasBarString; + private string barString_ = "STRING"; + public bool HasBarString + { + get { return hasBarString; } } - if (other.HasDummy25) { - Dummy25 = other.Dummy25; + public string BarString + { + get { return barString_; } } - if (other.HasDummy26) { - Dummy26 = other.Dummy26; + + public const int BarCordFieldNumber = 14; + private bool hasBarCord; + private string barCord_ = "CORD"; + public bool HasBarCord + { + get { return hasBarCord; } } - if (other.HasDummy27) { - Dummy27 = other.Dummy27; + public string BarCord + { + get { return barCord_; } } - if (other.HasDummy28) { - Dummy28 = other.Dummy28; + + public const int BarStringPieceFieldNumber = 15; + private bool hasBarStringPiece; + private string barStringPiece_ = "SPIECE"; + public bool HasBarStringPiece + { + get { return hasBarStringPiece; } } - if (other.HasDummy29) { - Dummy29 = other.Dummy29; + public string BarStringPiece + { + get { return barStringPiece_; } } - if (other.HasDummy30) { - Dummy30 = other.Dummy30; + + public const int BarBytesFieldNumber = 16; + private bool hasBarBytes; + private pb::ByteString barBytes_ = (pb::ByteString)global::Google.ProtocolBuffers.TestProtos.TestOneof2.Descriptor.Fields[13].DefaultValue; + public bool HasBarBytes + { + get { return hasBarBytes; } } - if (other.HasDummy31) { - Dummy31 = other.Dummy31; + public pb::ByteString BarBytes + { + get { return barBytes_; } } - if (other.HasDummy32) { - Dummy32 = other.Dummy32; + + public const int BarEnumFieldNumber = 17; + private bool hasBarEnum; + private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum barEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.BAR; + public bool HasBarEnum + { + get { return hasBarEnum; } } - if (other.HasC) { - C = other.C; + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum BarEnum + { + get { return barEnum_; } } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testRequiredFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testRequiredFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - case 16: { - result.hasDummy2 = input.ReadInt32(ref result.dummy2_); - break; - } - case 24: { - result.hasB = input.ReadInt32(ref result.b_); - break; - } - case 32: { - result.hasDummy4 = input.ReadInt32(ref result.dummy4_); - break; - } - case 40: { - result.hasDummy5 = input.ReadInt32(ref result.dummy5_); - break; - } - case 48: { - result.hasDummy6 = input.ReadInt32(ref result.dummy6_); - break; - } - case 56: { - result.hasDummy7 = input.ReadInt32(ref result.dummy7_); - break; - } - case 64: { - result.hasDummy8 = input.ReadInt32(ref result.dummy8_); - break; - } - case 72: { - result.hasDummy9 = input.ReadInt32(ref result.dummy9_); - break; - } - case 80: { - result.hasDummy10 = input.ReadInt32(ref result.dummy10_); - break; - } - case 88: { - result.hasDummy11 = input.ReadInt32(ref result.dummy11_); - break; - } - case 96: { - result.hasDummy12 = input.ReadInt32(ref result.dummy12_); - break; - } - case 104: { - result.hasDummy13 = input.ReadInt32(ref result.dummy13_); - break; - } - case 112: { - result.hasDummy14 = input.ReadInt32(ref result.dummy14_); - break; - } - case 120: { - result.hasDummy15 = input.ReadInt32(ref result.dummy15_); - break; - } - case 128: { - result.hasDummy16 = input.ReadInt32(ref result.dummy16_); - break; - } - case 136: { - result.hasDummy17 = input.ReadInt32(ref result.dummy17_); - break; - } - case 144: { - result.hasDummy18 = input.ReadInt32(ref result.dummy18_); - break; - } - case 152: { - result.hasDummy19 = input.ReadInt32(ref result.dummy19_); - break; - } - case 160: { - result.hasDummy20 = input.ReadInt32(ref result.dummy20_); - break; - } - case 168: { - result.hasDummy21 = input.ReadInt32(ref result.dummy21_); - break; - } - case 176: { - result.hasDummy22 = input.ReadInt32(ref result.dummy22_); - break; - } - case 184: { - result.hasDummy23 = input.ReadInt32(ref result.dummy23_); - break; - } - case 192: { - result.hasDummy24 = input.ReadInt32(ref result.dummy24_); - break; - } - case 200: { - result.hasDummy25 = input.ReadInt32(ref result.dummy25_); - break; - } - case 208: { - result.hasDummy26 = input.ReadInt32(ref result.dummy26_); - break; - } - case 216: { - result.hasDummy27 = input.ReadInt32(ref result.dummy27_); - break; - } - case 224: { - result.hasDummy28 = input.ReadInt32(ref result.dummy28_); - break; - } - case 232: { - result.hasDummy29 = input.ReadInt32(ref result.dummy29_); - break; - } - case 240: { - result.hasDummy30 = input.ReadInt32(ref result.dummy30_); - break; - } - case 248: { - result.hasDummy31 = input.ReadInt32(ref result.dummy31_); - break; - } - case 256: { - result.hasDummy32 = input.ReadInt32(ref result.dummy32_); - break; - } - case 264: { - result.hasC = input.ReadInt32(ref result.c_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - - public bool HasDummy2 { - get { return result.hasDummy2; } - } - public int Dummy2 { - get { return result.Dummy2; } - set { SetDummy2(value); } - } - public Builder SetDummy2(int value) { - PrepareBuilder(); - result.hasDummy2 = true; - result.dummy2_ = value; - return this; - } - public Builder ClearDummy2() { - PrepareBuilder(); - result.hasDummy2 = false; - result.dummy2_ = 0; - return this; - } - - public bool HasB { - get { return result.hasB; } - } - public int B { - get { return result.B; } - set { SetB(value); } - } - public Builder SetB(int value) { - PrepareBuilder(); - result.hasB = true; - result.b_ = value; - return this; - } - public Builder ClearB() { - PrepareBuilder(); - result.hasB = false; - result.b_ = 0; - return this; - } - - public bool HasDummy4 { - get { return result.hasDummy4; } - } - public int Dummy4 { - get { return result.Dummy4; } - set { SetDummy4(value); } - } - public Builder SetDummy4(int value) { - PrepareBuilder(); - result.hasDummy4 = true; - result.dummy4_ = value; - return this; - } - public Builder ClearDummy4() { - PrepareBuilder(); - result.hasDummy4 = false; - result.dummy4_ = 0; - return this; - } - - public bool HasDummy5 { - get { return result.hasDummy5; } - } - public int Dummy5 { - get { return result.Dummy5; } - set { SetDummy5(value); } - } - public Builder SetDummy5(int value) { - PrepareBuilder(); - result.hasDummy5 = true; - result.dummy5_ = value; - return this; - } - public Builder ClearDummy5() { - PrepareBuilder(); - result.hasDummy5 = false; - result.dummy5_ = 0; - return this; - } - - public bool HasDummy6 { - get { return result.hasDummy6; } - } - public int Dummy6 { - get { return result.Dummy6; } - set { SetDummy6(value); } - } - public Builder SetDummy6(int value) { - PrepareBuilder(); - result.hasDummy6 = true; - result.dummy6_ = value; - return this; - } - public Builder ClearDummy6() { - PrepareBuilder(); - result.hasDummy6 = false; - result.dummy6_ = 0; - return this; - } - - public bool HasDummy7 { - get { return result.hasDummy7; } - } - public int Dummy7 { - get { return result.Dummy7; } - set { SetDummy7(value); } - } - public Builder SetDummy7(int value) { - PrepareBuilder(); - result.hasDummy7 = true; - result.dummy7_ = value; - return this; - } - public Builder ClearDummy7() { - PrepareBuilder(); - result.hasDummy7 = false; - result.dummy7_ = 0; - return this; - } - - public bool HasDummy8 { - get { return result.hasDummy8; } - } - public int Dummy8 { - get { return result.Dummy8; } - set { SetDummy8(value); } - } - public Builder SetDummy8(int value) { - PrepareBuilder(); - result.hasDummy8 = true; - result.dummy8_ = value; - return this; - } - public Builder ClearDummy8() { - PrepareBuilder(); - result.hasDummy8 = false; - result.dummy8_ = 0; - return this; - } - - public bool HasDummy9 { - get { return result.hasDummy9; } - } - public int Dummy9 { - get { return result.Dummy9; } - set { SetDummy9(value); } - } - public Builder SetDummy9(int value) { - PrepareBuilder(); - result.hasDummy9 = true; - result.dummy9_ = value; - return this; - } - public Builder ClearDummy9() { - PrepareBuilder(); - result.hasDummy9 = false; - result.dummy9_ = 0; - return this; - } - - public bool HasDummy10 { - get { return result.hasDummy10; } - } - public int Dummy10 { - get { return result.Dummy10; } - set { SetDummy10(value); } - } - public Builder SetDummy10(int value) { - PrepareBuilder(); - result.hasDummy10 = true; - result.dummy10_ = value; - return this; - } - public Builder ClearDummy10() { - PrepareBuilder(); - result.hasDummy10 = false; - result.dummy10_ = 0; - return this; - } - - public bool HasDummy11 { - get { return result.hasDummy11; } - } - public int Dummy11 { - get { return result.Dummy11; } - set { SetDummy11(value); } - } - public Builder SetDummy11(int value) { - PrepareBuilder(); - result.hasDummy11 = true; - result.dummy11_ = value; - return this; - } - public Builder ClearDummy11() { - PrepareBuilder(); - result.hasDummy11 = false; - result.dummy11_ = 0; - return this; - } - - public bool HasDummy12 { - get { return result.hasDummy12; } - } - public int Dummy12 { - get { return result.Dummy12; } - set { SetDummy12(value); } - } - public Builder SetDummy12(int value) { - PrepareBuilder(); - result.hasDummy12 = true; - result.dummy12_ = value; - return this; - } - public Builder ClearDummy12() { - PrepareBuilder(); - result.hasDummy12 = false; - result.dummy12_ = 0; - return this; - } - - public bool HasDummy13 { - get { return result.hasDummy13; } - } - public int Dummy13 { - get { return result.Dummy13; } - set { SetDummy13(value); } - } - public Builder SetDummy13(int value) { - PrepareBuilder(); - result.hasDummy13 = true; - result.dummy13_ = value; - return this; - } - public Builder ClearDummy13() { - PrepareBuilder(); - result.hasDummy13 = false; - result.dummy13_ = 0; - return this; - } - - public bool HasDummy14 { - get { return result.hasDummy14; } - } - public int Dummy14 { - get { return result.Dummy14; } - set { SetDummy14(value); } - } - public Builder SetDummy14(int value) { - PrepareBuilder(); - result.hasDummy14 = true; - result.dummy14_ = value; - return this; - } - public Builder ClearDummy14() { - PrepareBuilder(); - result.hasDummy14 = false; - result.dummy14_ = 0; - return this; - } - - public bool HasDummy15 { - get { return result.hasDummy15; } - } - public int Dummy15 { - get { return result.Dummy15; } - set { SetDummy15(value); } - } - public Builder SetDummy15(int value) { - PrepareBuilder(); - result.hasDummy15 = true; - result.dummy15_ = value; - return this; - } - public Builder ClearDummy15() { - PrepareBuilder(); - result.hasDummy15 = false; - result.dummy15_ = 0; - return this; - } - - public bool HasDummy16 { - get { return result.hasDummy16; } - } - public int Dummy16 { - get { return result.Dummy16; } - set { SetDummy16(value); } - } - public Builder SetDummy16(int value) { - PrepareBuilder(); - result.hasDummy16 = true; - result.dummy16_ = value; - return this; - } - public Builder ClearDummy16() { - PrepareBuilder(); - result.hasDummy16 = false; - result.dummy16_ = 0; - return this; - } - - public bool HasDummy17 { - get { return result.hasDummy17; } - } - public int Dummy17 { - get { return result.Dummy17; } - set { SetDummy17(value); } - } - public Builder SetDummy17(int value) { - PrepareBuilder(); - result.hasDummy17 = true; - result.dummy17_ = value; - return this; - } - public Builder ClearDummy17() { - PrepareBuilder(); - result.hasDummy17 = false; - result.dummy17_ = 0; - return this; - } - - public bool HasDummy18 { - get { return result.hasDummy18; } - } - public int Dummy18 { - get { return result.Dummy18; } - set { SetDummy18(value); } - } - public Builder SetDummy18(int value) { - PrepareBuilder(); - result.hasDummy18 = true; - result.dummy18_ = value; - return this; - } - public Builder ClearDummy18() { - PrepareBuilder(); - result.hasDummy18 = false; - result.dummy18_ = 0; - return this; - } - - public bool HasDummy19 { - get { return result.hasDummy19; } - } - public int Dummy19 { - get { return result.Dummy19; } - set { SetDummy19(value); } - } - public Builder SetDummy19(int value) { - PrepareBuilder(); - result.hasDummy19 = true; - result.dummy19_ = value; - return this; - } - public Builder ClearDummy19() { - PrepareBuilder(); - result.hasDummy19 = false; - result.dummy19_ = 0; - return this; - } - - public bool HasDummy20 { - get { return result.hasDummy20; } - } - public int Dummy20 { - get { return result.Dummy20; } - set { SetDummy20(value); } - } - public Builder SetDummy20(int value) { - PrepareBuilder(); - result.hasDummy20 = true; - result.dummy20_ = value; - return this; - } - public Builder ClearDummy20() { - PrepareBuilder(); - result.hasDummy20 = false; - result.dummy20_ = 0; - return this; - } - - public bool HasDummy21 { - get { return result.hasDummy21; } - } - public int Dummy21 { - get { return result.Dummy21; } - set { SetDummy21(value); } - } - public Builder SetDummy21(int value) { - PrepareBuilder(); - result.hasDummy21 = true; - result.dummy21_ = value; - return this; - } - public Builder ClearDummy21() { - PrepareBuilder(); - result.hasDummy21 = false; - result.dummy21_ = 0; - return this; - } - - public bool HasDummy22 { - get { return result.hasDummy22; } - } - public int Dummy22 { - get { return result.Dummy22; } - set { SetDummy22(value); } - } - public Builder SetDummy22(int value) { - PrepareBuilder(); - result.hasDummy22 = true; - result.dummy22_ = value; - return this; - } - public Builder ClearDummy22() { - PrepareBuilder(); - result.hasDummy22 = false; - result.dummy22_ = 0; - return this; - } - - public bool HasDummy23 { - get { return result.hasDummy23; } - } - public int Dummy23 { - get { return result.Dummy23; } - set { SetDummy23(value); } - } - public Builder SetDummy23(int value) { - PrepareBuilder(); - result.hasDummy23 = true; - result.dummy23_ = value; - return this; - } - public Builder ClearDummy23() { - PrepareBuilder(); - result.hasDummy23 = false; - result.dummy23_ = 0; - return this; - } - - public bool HasDummy24 { - get { return result.hasDummy24; } - } - public int Dummy24 { - get { return result.Dummy24; } - set { SetDummy24(value); } - } - public Builder SetDummy24(int value) { - PrepareBuilder(); - result.hasDummy24 = true; - result.dummy24_ = value; - return this; - } - public Builder ClearDummy24() { - PrepareBuilder(); - result.hasDummy24 = false; - result.dummy24_ = 0; - return this; - } - - public bool HasDummy25 { - get { return result.hasDummy25; } - } - public int Dummy25 { - get { return result.Dummy25; } - set { SetDummy25(value); } - } - public Builder SetDummy25(int value) { - PrepareBuilder(); - result.hasDummy25 = true; - result.dummy25_ = value; - return this; - } - public Builder ClearDummy25() { - PrepareBuilder(); - result.hasDummy25 = false; - result.dummy25_ = 0; - return this; - } - - public bool HasDummy26 { - get { return result.hasDummy26; } - } - public int Dummy26 { - get { return result.Dummy26; } - set { SetDummy26(value); } - } - public Builder SetDummy26(int value) { - PrepareBuilder(); - result.hasDummy26 = true; - result.dummy26_ = value; - return this; - } - public Builder ClearDummy26() { - PrepareBuilder(); - result.hasDummy26 = false; - result.dummy26_ = 0; - return this; - } - - public bool HasDummy27 { - get { return result.hasDummy27; } - } - public int Dummy27 { - get { return result.Dummy27; } - set { SetDummy27(value); } - } - public Builder SetDummy27(int value) { - PrepareBuilder(); - result.hasDummy27 = true; - result.dummy27_ = value; - return this; - } - public Builder ClearDummy27() { - PrepareBuilder(); - result.hasDummy27 = false; - result.dummy27_ = 0; - return this; - } - - public bool HasDummy28 { - get { return result.hasDummy28; } - } - public int Dummy28 { - get { return result.Dummy28; } - set { SetDummy28(value); } - } - public Builder SetDummy28(int value) { - PrepareBuilder(); - result.hasDummy28 = true; - result.dummy28_ = value; - return this; - } - public Builder ClearDummy28() { - PrepareBuilder(); - result.hasDummy28 = false; - result.dummy28_ = 0; - return this; - } - - public bool HasDummy29 { - get { return result.hasDummy29; } - } - public int Dummy29 { - get { return result.Dummy29; } - set { SetDummy29(value); } - } - public Builder SetDummy29(int value) { - PrepareBuilder(); - result.hasDummy29 = true; - result.dummy29_ = value; - return this; - } - public Builder ClearDummy29() { - PrepareBuilder(); - result.hasDummy29 = false; - result.dummy29_ = 0; - return this; - } - - public bool HasDummy30 { - get { return result.hasDummy30; } - } - public int Dummy30 { - get { return result.Dummy30; } - set { SetDummy30(value); } - } - public Builder SetDummy30(int value) { - PrepareBuilder(); - result.hasDummy30 = true; - result.dummy30_ = value; - return this; - } - public Builder ClearDummy30() { - PrepareBuilder(); - result.hasDummy30 = false; - result.dummy30_ = 0; - return this; - } - - public bool HasDummy31 { - get { return result.hasDummy31; } - } - public int Dummy31 { - get { return result.Dummy31; } - set { SetDummy31(value); } - } - public Builder SetDummy31(int value) { - PrepareBuilder(); - result.hasDummy31 = true; - result.dummy31_ = value; - return this; - } - public Builder ClearDummy31() { - PrepareBuilder(); - result.hasDummy31 = false; - result.dummy31_ = 0; - return this; - } - - public bool HasDummy32 { - get { return result.hasDummy32; } - } - public int Dummy32 { - get { return result.Dummy32; } - set { SetDummy32(value); } - } - public Builder SetDummy32(int value) { - PrepareBuilder(); - result.hasDummy32 = true; - result.dummy32_ = value; - return this; - } - public Builder ClearDummy32() { - PrepareBuilder(); - result.hasDummy32 = false; - result.dummy32_ = 0; - return this; - } - - public bool HasC { - get { return result.hasC; } - } - public int C { - get { return result.C; } - set { SetC(value); } - } - public Builder SetC(int value) { - PrepareBuilder(); - result.hasC = true; - result.c_ = value; - return this; - } - public Builder ClearC() { - PrepareBuilder(); - result.hasC = false; - result.c_ = 0; - return this; - } - } - static TestRequired() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestRequiredForeign : pb::GeneratedMessage { - private TestRequiredForeign() { } - private static readonly TestRequiredForeign defaultInstance = new TestRequiredForeign().MakeReadOnly(); - private static readonly string[] _testRequiredForeignFieldNames = new string[] { "dummy", "optional_message", "repeated_message" }; - private static readonly uint[] _testRequiredForeignFieldTags = new uint[] { 24, 10, 18 }; - public static TestRequiredForeign DefaultInstance { - get { return defaultInstance; } - } - - public override TestRequiredForeign DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestRequiredForeign ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredForeign__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable; } - } - - public const int OptionalMessageFieldNumber = 1; - private bool hasOptionalMessage; - private global::Google.ProtocolBuffers.TestProtos.TestRequired optionalMessage_; - public bool HasOptionalMessage { - get { return hasOptionalMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequired OptionalMessage { - get { return optionalMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance; } - } - public const int RepeatedMessageFieldNumber = 2; - private pbc::PopsicleList repeatedMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedMessageList { - get { return repeatedMessage_; } - } - public int RepeatedMessageCount { - get { return repeatedMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequired GetRepeatedMessage(int index) { - return repeatedMessage_[index]; - } - - public const int DummyFieldNumber = 3; - private bool hasDummy; - private int dummy_; - public bool HasDummy { - get { return hasDummy; } - } - public int Dummy { - get { return dummy_; } - } - - public override bool IsInitialized { - get { - if (HasOptionalMessage) { - if (!OptionalMessage.IsInitialized) return false; + public const int BazIntFieldNumber = 18; + private bool hasBazInt; + private int bazInt_; + public bool HasBazInt + { + get { return hasBazInt; } } - foreach (global::Google.ProtocolBuffers.TestProtos.TestRequired element in RepeatedMessageList) { - if (!element.IsInitialized) return false; + public int BazInt + { + get { return bazInt_; } } - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testRequiredForeignFieldNames; - if (hasOptionalMessage) { - output.WriteMessage(1, field_names[1], OptionalMessage); - } - if (repeatedMessage_.Count > 0) { - output.WriteMessageArray(2, field_names[2], repeatedMessage_); - } - if (hasDummy) { - output.WriteInt32(3, field_names[0], Dummy); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasOptionalMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(1, OptionalMessage); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestRequired element in RepeatedMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(2, element); - } - if (hasDummy) { - size += pb::CodedOutputStream.ComputeInt32Size(3, Dummy); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestRequiredForeign ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestRequiredForeign ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestRequiredForeign ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequiredForeign ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestRequiredForeign MakeReadOnly() { - repeatedMessage_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestRequiredForeign prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestRequiredForeign cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestRequiredForeign result; - - private TestRequiredForeign PrepareBuilder() { - if (resultIsReadOnly) { - TestRequiredForeign original = result; - result = new TestRequiredForeign(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestRequiredForeign MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.Descriptor; } - } - - public override TestRequiredForeign DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.DefaultInstance; } - } - - public override TestRequiredForeign BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestRequiredForeign) { - return MergeFrom((TestRequiredForeign) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestRequiredForeign other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasOptionalMessage) { - MergeOptionalMessage(other.OptionalMessage); - } - if (other.repeatedMessage_.Count != 0) { - result.repeatedMessage_.Add(other.repeatedMessage_); - } - if (other.HasDummy) { - Dummy = other.Dummy; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testRequiredForeignFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testRequiredForeignFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(); - if (result.hasOptionalMessage) { - subBuilder.MergeFrom(OptionalMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalMessage = subBuilder.BuildPartial(); - break; - } - case 18: { - input.ReadMessageArray(tag, field_name, result.repeatedMessage_, global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance, extensionRegistry); - break; - } - case 24: { - result.hasDummy = input.ReadInt32(ref result.dummy_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasOptionalMessage { - get { return result.hasOptionalMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequired OptionalMessage { - get { return result.OptionalMessage; } - set { SetOptionalMessage(value); } - } - public Builder SetOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalMessage = true; - result.optionalMessage_ = value; - return this; - } - public Builder SetOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalMessage = true; - result.optionalMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalMessage && - result.optionalMessage_ != global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) { - result.optionalMessage_ = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(result.optionalMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalMessage_ = value; - } - result.hasOptionalMessage = true; - return this; - } - public Builder ClearOptionalMessage() { - PrepareBuilder(); - result.hasOptionalMessage = false; - result.optionalMessage_ = null; - return this; - } - - public pbc::IPopsicleList RepeatedMessageList { - get { return PrepareBuilder().repeatedMessage_; } - } - public int RepeatedMessageCount { - get { return result.RepeatedMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequired GetRepeatedMessage(int index) { - return result.GetRepeatedMessage(index); - } - public Builder SetRepeatedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestRequired value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedMessage_[index] = value; - return this; - } - public Builder SetRepeatedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedMessage_.Add(value); - return this; - } - public Builder AddRepeatedMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedMessage_.Add(values); - return this; - } - public Builder ClearRepeatedMessage() { - PrepareBuilder(); - result.repeatedMessage_.Clear(); - return this; - } - - public bool HasDummy { - get { return result.hasDummy; } - } - public int Dummy { - get { return result.Dummy; } - set { SetDummy(value); } - } - public Builder SetDummy(int value) { - PrepareBuilder(); - result.hasDummy = true; - result.dummy_ = value; - return this; - } - public Builder ClearDummy() { - PrepareBuilder(); - result.hasDummy = false; - result.dummy_ = 0; - return this; - } - } - static TestRequiredForeign() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestForeignNested : pb::GeneratedMessage { - private TestForeignNested() { } - private static readonly TestForeignNested defaultInstance = new TestForeignNested().MakeReadOnly(); - private static readonly string[] _testForeignNestedFieldNames = new string[] { "foreign_nested" }; - private static readonly uint[] _testForeignNestedFieldTags = new uint[] { 10 }; - public static TestForeignNested DefaultInstance { - get { return defaultInstance; } - } - - public override TestForeignNested DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestForeignNested ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestForeignNested__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable; } - } - - public const int ForeignNestedFieldNumber = 1; - private bool hasForeignNested; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage foreignNested_; - public bool HasForeignNested { - get { return hasForeignNested; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage ForeignNested { - get { return foreignNested_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testForeignNestedFieldNames; - if (hasForeignNested) { - output.WriteMessage(1, field_names[0], ForeignNested); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasForeignNested) { - size += pb::CodedOutputStream.ComputeMessageSize(1, ForeignNested); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestForeignNested ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestForeignNested ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestForeignNested ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestForeignNested ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestForeignNested ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestForeignNested ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestForeignNested ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestForeignNested ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestForeignNested ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestForeignNested ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestForeignNested MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestForeignNested prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestForeignNested cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestForeignNested result; - - private TestForeignNested PrepareBuilder() { - if (resultIsReadOnly) { - TestForeignNested original = result; - result = new TestForeignNested(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestForeignNested MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestForeignNested.Descriptor; } - } - - public override TestForeignNested DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestForeignNested.DefaultInstance; } - } - - public override TestForeignNested BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestForeignNested) { - return MergeFrom((TestForeignNested) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestForeignNested other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestForeignNested.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasForeignNested) { - MergeForeignNested(other.ForeignNested); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testForeignNestedFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testForeignNestedFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); - if (result.hasForeignNested) { - subBuilder.MergeFrom(ForeignNested); - } - input.ReadMessage(subBuilder, extensionRegistry); - ForeignNested = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasForeignNested { - get { return result.hasForeignNested; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage ForeignNested { - get { return result.ForeignNested; } - set { SetForeignNested(value); } - } - public Builder SetForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasForeignNested = true; - result.foreignNested_ = value; - return this; - } - public Builder SetForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasForeignNested = true; - result.foreignNested_ = builderForValue.Build(); - return this; - } - public Builder MergeForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasForeignNested && - result.foreignNested_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { - result.foreignNested_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.foreignNested_).MergeFrom(value).BuildPartial(); - } else { - result.foreignNested_ = value; - } - result.hasForeignNested = true; - return this; - } - public Builder ClearForeignNested() { - PrepareBuilder(); - result.hasForeignNested = false; - result.foreignNested_ = null; - return this; - } - } - static TestForeignNested() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestEmptyMessage : pb::GeneratedMessage { - private TestEmptyMessage() { } - private static readonly TestEmptyMessage defaultInstance = new TestEmptyMessage().MakeReadOnly(); - private static readonly string[] _testEmptyMessageFieldNames = new string[] { }; - private static readonly uint[] _testEmptyMessageFieldTags = new uint[] { }; - public static TestEmptyMessage DefaultInstance { - get { return defaultInstance; } - } - - public override TestEmptyMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestEmptyMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testEmptyMessageFieldNames; - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestEmptyMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestEmptyMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestEmptyMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestEmptyMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestEmptyMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestEmptyMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestEmptyMessage result; - - private TestEmptyMessage PrepareBuilder() { - if (resultIsReadOnly) { - TestEmptyMessage original = result; - result = new TestEmptyMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestEmptyMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.Descriptor; } - } - - public override TestEmptyMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.DefaultInstance; } - } - - public override TestEmptyMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestEmptyMessage) { - return MergeFrom((TestEmptyMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestEmptyMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testEmptyMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static TestEmptyMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestEmptyMessageWithExtensions : pb::ExtendableMessage { - private TestEmptyMessageWithExtensions() { } - private static readonly TestEmptyMessageWithExtensions defaultInstance = new TestEmptyMessageWithExtensions().MakeReadOnly(); - private static readonly string[] _testEmptyMessageWithExtensionsFieldNames = new string[] { }; - private static readonly uint[] _testEmptyMessageWithExtensionsFieldTags = new uint[] { }; - public static TestEmptyMessageWithExtensions DefaultInstance { - get { return defaultInstance; } - } - - public override TestEmptyMessageWithExtensions DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestEmptyMessageWithExtensions ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testEmptyMessageWithExtensionsFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(536870912, output); - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public const int BazStringFieldNumber = 19; + private bool hasBazString; + private string bazString_ = "BAZ"; + public bool HasBazString + { + get { return hasBazString; } + } + public string BazString + { + get { return bazString_; } + } - size = 0; - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestEmptyMessageWithExtensions ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestEmptyMessageWithExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestEmptyMessageWithExtensions MakeReadOnly() { - return this; - } + public override bool IsInitialized + { + get + { + return true; + } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestEmptyMessageWithExtensions prototype) { - return new Builder(prototype); - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testOneof2FieldNames; + if (hasFooInt) + { + output.WriteInt32(1, field_names[11], FooInt); + } + if (hasFooString) + { + output.WriteString(2, field_names[14], FooString); + } + if (hasFooCord) + { + output.WriteString(3, field_names[9], FooCord); + } + if (hasFooStringPiece) + { + output.WriteString(4, field_names[15], FooStringPiece); + } + if (hasFooBytes) + { + output.WriteBytes(5, field_names[8], FooBytes); + } + if (hasFooEnum) + { + output.WriteEnum(6, field_names[10], (int)FooEnum, FooEnum); + } + if (hasFooMessage) + { + output.WriteMessage(7, field_names[13], FooMessage); + } + if (hasFooGroup) + { + output.WriteGroup(8, field_names[16], FooGroup); + } + if (hasFooLazyMessage) + { + output.WriteMessage(11, field_names[12], FooLazyMessage); + } + if (hasBarInt) + { + output.WriteInt32(12, field_names[3], BarInt); + } + if (hasBarString) + { + output.WriteString(13, field_names[4], BarString); + } + if (hasBarCord) + { + output.WriteString(14, field_names[1], BarCord); + } + if (hasBarStringPiece) + { + output.WriteString(15, field_names[5], BarStringPiece); + } + if (hasBarBytes) + { + output.WriteBytes(16, field_names[0], BarBytes); + } + if (hasBarEnum) + { + output.WriteEnum(17, field_names[2], (int)BarEnum, BarEnum); + } + if (hasBazInt) + { + output.WriteInt32(18, field_names[6], BazInt); + } + if (hasBazString) + { + output.WriteString(19, field_names[7], BazString); + } + UnknownFields.WriteTo(output); + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestEmptyMessageWithExtensions cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestEmptyMessageWithExtensions result; - - private TestEmptyMessageWithExtensions PrepareBuilder() { - if (resultIsReadOnly) { - TestEmptyMessageWithExtensions original = result; - result = new TestEmptyMessageWithExtensions(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestEmptyMessageWithExtensions MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.Descriptor; } - } - - public override TestEmptyMessageWithExtensions DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.DefaultInstance; } - } - - public override TestEmptyMessageWithExtensions BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestEmptyMessageWithExtensions) { - return MergeFrom((TestEmptyMessageWithExtensions) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestEmptyMessageWithExtensions other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageWithExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testEmptyMessageWithExtensionsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - } - static TestEmptyMessageWithExtensions() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestMultipleExtensionRanges : pb::ExtendableMessage { - private TestMultipleExtensionRanges() { } - private static readonly TestMultipleExtensionRanges defaultInstance = new TestMultipleExtensionRanges().MakeReadOnly(); - private static readonly string[] _testMultipleExtensionRangesFieldNames = new string[] { }; - private static readonly uint[] _testMultipleExtensionRangesFieldTags = new uint[] { }; - public static TestMultipleExtensionRanges DefaultInstance { - get { return defaultInstance; } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public override TestMultipleExtensionRanges DefaultInstanceForType { - get { return DefaultInstance; } - } + size = 0; + if (hasFooInt) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); + } + if (hasFooString) + { + size += pb::CodedOutputStream.ComputeStringSize(2, FooString); + } + if (hasFooCord) + { + size += pb::CodedOutputStream.ComputeStringSize(3, FooCord); + } + if (hasFooStringPiece) + { + size += pb::CodedOutputStream.ComputeStringSize(4, FooStringPiece); + } + if (hasFooBytes) + { + size += pb::CodedOutputStream.ComputeBytesSize(5, FooBytes); + } + if (hasFooEnum) + { + size += pb::CodedOutputStream.ComputeEnumSize(6, (int)FooEnum); + } + if (hasFooMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(7, FooMessage); + } + if (hasFooGroup) + { + size += pb::CodedOutputStream.ComputeGroupSize(8, FooGroup); + } + if (hasFooLazyMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(11, FooLazyMessage); + } + if (hasBarInt) + { + size += pb::CodedOutputStream.ComputeInt32Size(12, BarInt); + } + if (hasBarString) + { + size += pb::CodedOutputStream.ComputeStringSize(13, BarString); + } + if (hasBarCord) + { + size += pb::CodedOutputStream.ComputeStringSize(14, BarCord); + } + if (hasBarStringPiece) + { + size += pb::CodedOutputStream.ComputeStringSize(15, BarStringPiece); + } + if (hasBarBytes) + { + size += pb::CodedOutputStream.ComputeBytesSize(16, BarBytes); + } + if (hasBarEnum) + { + size += pb::CodedOutputStream.ComputeEnumSize(17, (int)BarEnum); + } + if (hasBazInt) + { + size += pb::CodedOutputStream.ComputeInt32Size(18, BazInt); + } + if (hasBazString) + { + size += pb::CodedOutputStream.ComputeStringSize(19, BazString); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestOneof2 ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneof2 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneof2 ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestOneof2 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestOneof2 ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneof2 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestOneof2 ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestOneof2 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestOneof2 ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestOneof2 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestOneof2 MakeReadOnly() + { + return this; + } - protected override TestMultipleExtensionRanges ThisMessage { - get { return this; } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestOneof2 prototype) + { + return new Builder(prototype); + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestOneof2 cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable; } - } + private bool resultIsReadOnly; + private TestOneof2 result; - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } + private TestOneof2 PrepareBuilder() + { + if (resultIsReadOnly) + { + TestOneof2 original = result; + result = new TestOneof2(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testMultipleExtensionRangesFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(43, output); - extensionWriter.WriteUntil(4244, output); - extensionWriter.WriteUntil(536870912, output); - UnknownFields.WriteTo(output); - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + protected override TestOneof2 MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - size = 0; - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestMultipleExtensionRanges ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMultipleExtensionRanges ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestMultipleExtensionRanges MakeReadOnly() { - return this; - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestMultipleExtensionRanges prototype) { - return new Builder(prototype); - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Descriptor; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestMultipleExtensionRanges cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestMultipleExtensionRanges result; - - private TestMultipleExtensionRanges PrepareBuilder() { - if (resultIsReadOnly) { - TestMultipleExtensionRanges original = result; - result = new TestMultipleExtensionRanges(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestMultipleExtensionRanges MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.Descriptor; } - } - - public override TestMultipleExtensionRanges DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.DefaultInstance; } - } - - public override TestMultipleExtensionRanges BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestMultipleExtensionRanges) { - return MergeFrom((TestMultipleExtensionRanges) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestMultipleExtensionRanges other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testMultipleExtensionRangesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testMultipleExtensionRangesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + public override TestOneof2 DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.DefaultInstance; } + } - } - static TestMultipleExtensionRanges() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestReallyLargeTagNumber : pb::GeneratedMessage { - private TestReallyLargeTagNumber() { } - private static readonly TestReallyLargeTagNumber defaultInstance = new TestReallyLargeTagNumber().MakeReadOnly(); - private static readonly string[] _testReallyLargeTagNumberFieldNames = new string[] { "a", "bb" }; - private static readonly uint[] _testReallyLargeTagNumberFieldTags = new uint[] { 8, 2147483640 }; - public static TestReallyLargeTagNumber DefaultInstance { - get { return defaultInstance; } - } + public override TestOneof2 BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public override TestReallyLargeTagNumber DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestOneof2) + { + return MergeFrom((TestOneof2)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - protected override TestReallyLargeTagNumber ThisMessage { - get { return this; } - } + public override Builder MergeFrom(TestOneof2 other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof2.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasFooInt) + { + FooInt = other.FooInt; + } + if (other.HasFooString) + { + FooString = other.FooString; + } + if (other.HasFooCord) + { + FooCord = other.FooCord; + } + if (other.HasFooStringPiece) + { + FooStringPiece = other.FooStringPiece; + } + if (other.HasFooBytes) + { + FooBytes = other.FooBytes; + } + if (other.HasFooEnum) + { + FooEnum = other.FooEnum; + } + if (other.HasFooMessage) + { + MergeFooMessage(other.FooMessage); + } + if (other.HasFooGroup) + { + MergeFooGroup(other.FooGroup); + } + if (other.HasFooLazyMessage) + { + MergeFooLazyMessage(other.FooLazyMessage); + } + if (other.HasBarInt) + { + BarInt = other.BarInt; + } + if (other.HasBarString) + { + BarString = other.BarString; + } + if (other.HasBarCord) + { + BarCord = other.BarCord; + } + if (other.HasBarStringPiece) + { + BarStringPiece = other.BarStringPiece; + } + if (other.HasBarBytes) + { + BarBytes = other.BarBytes; + } + if (other.HasBarEnum) + { + BarEnum = other.BarEnum; + } + if (other.HasBazInt) + { + BazInt = other.BazInt; + } + if (other.HasBazString) + { + BazString = other.BazString; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor; } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable; } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testOneof2FieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testOneof2FieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasFooInt = input.ReadInt32(ref result.fooInt_); + break; + } + case 18: + { + result.hasFooString = input.ReadString(ref result.fooString_); + break; + } + case 26: + { + result.hasFooCord = input.ReadString(ref result.fooCord_); + break; + } + case 34: + { + result.hasFooStringPiece = input.ReadString(ref result.fooStringPiece_); + break; + } + case 42: + { + result.hasFooBytes = input.ReadBytes(ref result.fooBytes_); + break; + } + case 48: + { + object unknown; + if (input.ReadEnum(ref result.fooEnum_, out unknown)) + { + result.hasFooEnum = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(6, (ulong)(int)unknown); + } + break; + } + case 58: + { + global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(); + if (result.hasFooMessage) + { + subBuilder.MergeFrom(FooMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + FooMessage = subBuilder.BuildPartial(); + break; + } + case 67: + { + global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.CreateBuilder(); + if (result.hasFooGroup) + { + subBuilder.MergeFrom(FooGroup); + } + input.ReadGroup(8, subBuilder, extensionRegistry); + FooGroup = subBuilder.BuildPartial(); + break; + } + case 90: + { + global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(); + if (result.hasFooLazyMessage) + { + subBuilder.MergeFrom(FooLazyMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + FooLazyMessage = subBuilder.BuildPartial(); + break; + } + case 96: + { + result.hasBarInt = input.ReadInt32(ref result.barInt_); + break; + } + case 106: + { + result.hasBarString = input.ReadString(ref result.barString_); + break; + } + case 114: + { + result.hasBarCord = input.ReadString(ref result.barCord_); + break; + } + case 122: + { + result.hasBarStringPiece = input.ReadString(ref result.barStringPiece_); + break; + } + case 130: + { + result.hasBarBytes = input.ReadBytes(ref result.barBytes_); + break; + } + case 136: + { + object unknown; + if (input.ReadEnum(ref result.barEnum_, out unknown)) + { + result.hasBarEnum = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(17, (ulong)(int)unknown); + } + break; + } + case 144: + { + result.hasBazInt = input.ReadInt32(ref result.bazInt_); + break; + } + case 154: + { + result.hasBazString = input.ReadString(ref result.bazString_); + break; + } + } + } - public const int AFieldNumber = 1; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public const int BbFieldNumber = 268435455; - private bool hasBb; - private int bb_; - public bool HasBb { - get { return hasBb; } - } - public int Bb { - get { return bb_; } - } - public override bool IsInitialized { - get { - return true; - } - } + public bool HasFooInt + { + get { return result.hasFooInt; } + } + public int FooInt + { + get { return result.FooInt; } + set { SetFooInt(value); } + } + public Builder SetFooInt(int value) + { + PrepareBuilder(); + result.hasFooInt = true; + result.fooInt_ = value; + return this; + } + public Builder ClearFooInt() + { + PrepareBuilder(); + result.hasFooInt = false; + result.fooInt_ = 0; + return this; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testReallyLargeTagNumberFieldNames; - if (hasA) { - output.WriteInt32(1, field_names[0], A); - } - if (hasBb) { - output.WriteInt32(268435455, field_names[1], Bb); - } - UnknownFields.WriteTo(output); - } + public bool HasFooString + { + get { return result.hasFooString; } + } + public string FooString + { + get { return result.FooString; } + set { SetFooString(value); } + } + public Builder SetFooString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooString = true; + result.fooString_ = value; + return this; + } + public Builder ClearFooString() + { + PrepareBuilder(); + result.hasFooString = false; + result.fooString_ = ""; + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public bool HasFooCord + { + get { return result.hasFooCord; } + } + public string FooCord + { + get { return result.FooCord; } + set { SetFooCord(value); } + } + public Builder SetFooCord(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooCord = true; + result.fooCord_ = value; + return this; + } + public Builder ClearFooCord() + { + PrepareBuilder(); + result.hasFooCord = false; + result.fooCord_ = ""; + return this; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A); - } - if (hasBb) { - size += pb::CodedOutputStream.ComputeInt32Size(268435455, Bb); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestReallyLargeTagNumber ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestReallyLargeTagNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestReallyLargeTagNumber MakeReadOnly() { - return this; - } + public bool HasFooStringPiece + { + get { return result.hasFooStringPiece; } + } + public string FooStringPiece + { + get { return result.FooStringPiece; } + set { SetFooStringPiece(value); } + } + public Builder SetFooStringPiece(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooStringPiece = true; + result.fooStringPiece_ = value; + return this; + } + public Builder ClearFooStringPiece() + { + PrepareBuilder(); + result.hasFooStringPiece = false; + result.fooStringPiece_ = ""; + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestReallyLargeTagNumber prototype) { - return new Builder(prototype); - } + public bool HasFooBytes + { + get { return result.hasFooBytes; } + } + public pb::ByteString FooBytes + { + get { return result.FooBytes; } + set { SetFooBytes(value); } + } + public Builder SetFooBytes(pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooBytes = true; + result.fooBytes_ = value; + return this; + } + public Builder ClearFooBytes() + { + PrepareBuilder(); + result.hasFooBytes = false; + result.fooBytes_ = pb::ByteString.Empty; + return this; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestReallyLargeTagNumber cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestReallyLargeTagNumber result; - - private TestReallyLargeTagNumber PrepareBuilder() { - if (resultIsReadOnly) { - TestReallyLargeTagNumber original = result; - result = new TestReallyLargeTagNumber(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestReallyLargeTagNumber MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.Descriptor; } - } - - public override TestReallyLargeTagNumber DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.DefaultInstance; } - } - - public override TestReallyLargeTagNumber BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestReallyLargeTagNumber) { - return MergeFrom((TestReallyLargeTagNumber) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestReallyLargeTagNumber other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - if (other.HasBb) { - Bb = other.Bb; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testReallyLargeTagNumberFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testReallyLargeTagNumberFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - case 2147483640: { - result.hasBb = input.ReadInt32(ref result.bb_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - - public bool HasBb { - get { return result.hasBb; } - } - public int Bb { - get { return result.Bb; } - set { SetBb(value); } - } - public Builder SetBb(int value) { - PrepareBuilder(); - result.hasBb = true; - result.bb_ = value; - return this; - } - public Builder ClearBb() { - PrepareBuilder(); - result.hasBb = false; - result.bb_ = 0; - return this; - } - } - static TestReallyLargeTagNumber() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestRecursiveMessage : pb::GeneratedMessage { - private TestRecursiveMessage() { } - private static readonly TestRecursiveMessage defaultInstance = new TestRecursiveMessage().MakeReadOnly(); - private static readonly string[] _testRecursiveMessageFieldNames = new string[] { "a", "i" }; - private static readonly uint[] _testRecursiveMessageFieldTags = new uint[] { 10, 16 }; - public static TestRecursiveMessage DefaultInstance { - get { return defaultInstance; } - } + public bool HasFooEnum + { + get { return result.hasFooEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum FooEnum + { + get { return result.FooEnum; } + set { SetFooEnum(value); } + } + public Builder SetFooEnum(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum value) + { + PrepareBuilder(); + result.hasFooEnum = true; + result.fooEnum_ = value; + return this; + } + public Builder ClearFooEnum() + { + PrepareBuilder(); + result.hasFooEnum = false; + result.fooEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.FOO; + return this; + } - public override TestRecursiveMessage DefaultInstanceForType { - get { return DefaultInstance; } - } + public bool HasFooMessage + { + get { return result.hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooMessage + { + get { return result.FooMessage; } + set { SetFooMessage(value); } + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = value; + return this; + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooMessage && + result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance) + { + result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.fooMessage_ = value; + } + result.hasFooMessage = true; + return this; + } + public Builder ClearFooMessage() + { + PrepareBuilder(); + result.hasFooMessage = false; + result.fooMessage_ = null; + return this; + } - protected override TestRecursiveMessage ThisMessage { - get { return this; } - } + public bool HasFooGroup + { + get { return result.hasFooGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup FooGroup + { + get { return result.FooGroup; } + set { SetFooGroup(value); } + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = value; + return this; + } + public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooGroup = true; + result.fooGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooGroup && + result.fooGroup_ != global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance) + { + result.fooGroup_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.CreateBuilder(result.fooGroup_).MergeFrom(value).BuildPartial(); + } + else + { + result.fooGroup_ = value; + } + result.hasFooGroup = true; + return this; + } + public Builder ClearFooGroup() + { + PrepareBuilder(); + result.hasFooGroup = false; + result.fooGroup_ = null; + return this; + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor; } - } + public bool HasFooLazyMessage + { + get { return result.hasFooLazyMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooLazyMessage + { + get { return result.FooLazyMessage; } + set { SetFooLazyMessage(value); } + } + public Builder SetFooLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooLazyMessage = true; + result.fooLazyMessage_ = value; + return this; + } + public Builder SetFooLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooLazyMessage = true; + result.fooLazyMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeFooLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooLazyMessage && + result.fooLazyMessage_ != global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance) + { + result.fooLazyMessage_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(result.fooLazyMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.fooLazyMessage_ = value; + } + result.hasFooLazyMessage = true; + return this; + } + public Builder ClearFooLazyMessage() + { + PrepareBuilder(); + result.hasFooLazyMessage = false; + result.fooLazyMessage_ = null; + return this; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable; } - } + public bool HasBarInt + { + get { return result.hasBarInt; } + } + public int BarInt + { + get { return result.BarInt; } + set { SetBarInt(value); } + } + public Builder SetBarInt(int value) + { + PrepareBuilder(); + result.hasBarInt = true; + result.barInt_ = value; + return this; + } + public Builder ClearBarInt() + { + PrepareBuilder(); + result.hasBarInt = false; + result.barInt_ = 5; + return this; + } - public const int AFieldNumber = 1; - private bool hasA; - private global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage a_; - public bool HasA { - get { return hasA; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage A { - get { return a_ ?? global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance; } - } + public bool HasBarString + { + get { return result.hasBarString; } + } + public string BarString + { + get { return result.BarString; } + set { SetBarString(value); } + } + public Builder SetBarString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBarString = true; + result.barString_ = value; + return this; + } + public Builder ClearBarString() + { + PrepareBuilder(); + result.hasBarString = false; + result.barString_ = "STRING"; + return this; + } - public const int IFieldNumber = 2; - private bool hasI; - private int i_; - public bool HasI { - get { return hasI; } - } - public int I { - get { return i_; } - } + public bool HasBarCord + { + get { return result.hasBarCord; } + } + public string BarCord + { + get { return result.BarCord; } + set { SetBarCord(value); } + } + public Builder SetBarCord(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBarCord = true; + result.barCord_ = value; + return this; + } + public Builder ClearBarCord() + { + PrepareBuilder(); + result.hasBarCord = false; + result.barCord_ = "CORD"; + return this; + } - public override bool IsInitialized { - get { - return true; - } - } + public bool HasBarStringPiece + { + get { return result.hasBarStringPiece; } + } + public string BarStringPiece + { + get { return result.BarStringPiece; } + set { SetBarStringPiece(value); } + } + public Builder SetBarStringPiece(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBarStringPiece = true; + result.barStringPiece_ = value; + return this; + } + public Builder ClearBarStringPiece() + { + PrepareBuilder(); + result.hasBarStringPiece = false; + result.barStringPiece_ = "SPIECE"; + return this; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testRecursiveMessageFieldNames; - if (hasA) { - output.WriteMessage(1, field_names[0], A); - } - if (hasI) { - output.WriteInt32(2, field_names[1], I); - } - UnknownFields.WriteTo(output); - } + public bool HasBarBytes + { + get { return result.hasBarBytes; } + } + public pb::ByteString BarBytes + { + get { return result.BarBytes; } + set { SetBarBytes(value); } + } + public Builder SetBarBytes(pb::ByteString value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBarBytes = true; + result.barBytes_ = value; + return this; + } + public Builder ClearBarBytes() + { + PrepareBuilder(); + result.hasBarBytes = false; + result.barBytes_ = (pb::ByteString)global::Google.ProtocolBuffers.TestProtos.TestOneof2.Descriptor.Fields[13].DefaultValue; + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public bool HasBarEnum + { + get { return result.hasBarEnum; } + } + public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum BarEnum + { + get { return result.BarEnum; } + set { SetBarEnum(value); } + } + public Builder SetBarEnum(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum value) + { + PrepareBuilder(); + result.hasBarEnum = true; + result.barEnum_ = value; + return this; + } + public Builder ClearBarEnum() + { + PrepareBuilder(); + result.hasBarEnum = false; + result.barEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.BAR; + return this; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeMessageSize(1, A); - } - if (hasI) { - size += pb::CodedOutputStream.ComputeInt32Size(2, I); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestRecursiveMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestRecursiveMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestRecursiveMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRecursiveMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestRecursiveMessage MakeReadOnly() { - return this; - } + public bool HasBazInt + { + get { return result.hasBazInt; } + } + public int BazInt + { + get { return result.BazInt; } + set { SetBazInt(value); } + } + public Builder SetBazInt(int value) + { + PrepareBuilder(); + result.hasBazInt = true; + result.bazInt_ = value; + return this; + } + public Builder ClearBazInt() + { + PrepareBuilder(); + result.hasBazInt = false; + result.bazInt_ = 0; + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestRecursiveMessage prototype) { - return new Builder(prototype); + public bool HasBazString + { + get { return result.hasBazString; } + } + public string BazString + { + get { return result.BazString; } + set { SetBazString(value); } + } + public Builder SetBazString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasBazString = true; + result.bazString_ = value; + return this; + } + public Builder ClearBazString() + { + PrepareBuilder(); + result.hasBazString = false; + result.bazString_ = "BAZ"; + return this; + } + } + static TestOneof2() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestRecursiveMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestRecursiveMessage result; - - private TestRecursiveMessage PrepareBuilder() { - if (resultIsReadOnly) { - TestRecursiveMessage original = result; - result = new TestRecursiveMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestRecursiveMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Descriptor; } - } - - public override TestRecursiveMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance; } - } - - public override TestRecursiveMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestRecursiveMessage) { - return MergeFrom((TestRecursiveMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestRecursiveMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - MergeA(other.A); - } - if (other.HasI) { - I = other.I; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testRecursiveMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testRecursiveMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.CreateBuilder(); - if (result.hasA) { - subBuilder.MergeFrom(A); - } - input.ReadMessage(subBuilder, extensionRegistry); - A = subBuilder.BuildPartial(); - break; - } - case 16: { - result.hasI = input.ReadInt32(ref result.i_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasA = true; - result.a_ = builderForValue.Build(); - return this; - } - public Builder MergeA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasA && - result.a_ != global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance) { - result.a_ = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.CreateBuilder(result.a_).MergeFrom(value).BuildPartial(); - } else { - result.a_ = value; - } - result.hasA = true; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = null; - return this; - } - - public bool HasI { - get { return result.hasI; } - } - public int I { - get { return result.I; } - set { SetI(value); } - } - public Builder SetI(int value) { - PrepareBuilder(); - result.hasI = true; - result.i_ = value; - return this; - } - public Builder ClearI() { - PrepareBuilder(); - result.hasI = false; - result.i_ = 0; - return this; - } - } - static TestRecursiveMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestMutualRecursionA : pb::GeneratedMessage { - private TestMutualRecursionA() { } - private static readonly TestMutualRecursionA defaultInstance = new TestMutualRecursionA().MakeReadOnly(); - private static readonly string[] _testMutualRecursionAFieldNames = new string[] { "bb" }; - private static readonly uint[] _testMutualRecursionAFieldTags = new uint[] { 10 }; - public static TestMutualRecursionA DefaultInstance { - get { return defaultInstance; } - } - - public override TestMutualRecursionA DefaultInstanceForType { - get { return DefaultInstance; } - } + public sealed partial class TestRequiredOneof : pb::GeneratedMessage + { + private TestRequiredOneof() { } + private static readonly TestRequiredOneof defaultInstance = new TestRequiredOneof().MakeReadOnly(); + private static readonly string[] _testRequiredOneofFieldNames = new string[] { "foo_int", "foo_message", "foo_string" }; + private static readonly uint[] _testRequiredOneofFieldTags = new uint[] { 8, 26, 18 }; + public static TestRequiredOneof DefaultInstance + { + get { return defaultInstance; } + } - protected override TestMutualRecursionA ThisMessage { - get { return this; } - } + public override TestRequiredOneof DefaultInstanceForType + { + get { return DefaultInstance; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor; } - } + protected override TestRequiredOneof ThisMessage + { + get { return this; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable; } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof__Descriptor; } + } - public const int BbFieldNumber = 1; - private bool hasBb; - private global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB bb_; - public bool HasBb { - get { return hasBb; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB Bb { - get { return bb_ ?? global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof__FieldAccessorTable; } + } - public override bool IsInitialized { - get { - return true; - } - } + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class NestedMessage : pb::GeneratedMessage + { + private NestedMessage() { } + private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); + private static readonly string[] _nestedMessageFieldNames = new string[] { "required_double" }; + private static readonly uint[] _nestedMessageFieldTags = new uint[] { 9 }; + public static NestedMessage DefaultInstance + { + get { return defaultInstance; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testMutualRecursionAFieldNames; - if (hasBb) { - output.WriteMessage(1, field_names[0], Bb); - } - UnknownFields.WriteTo(output); - } + public override NestedMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + protected override NestedMessage ThisMessage + { + get { return this; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasBb) { - size += pb::CodedOutputStream.ComputeMessageSize(1, Bb); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestMutualRecursionA ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionA ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestMutualRecursionA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMutualRecursionA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestMutualRecursionA MakeReadOnly() { - return this; - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestMutualRecursionA prototype) { - return new Builder(prototype); - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__FieldAccessorTable; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestMutualRecursionA cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestMutualRecursionA result; - - private TestMutualRecursionA PrepareBuilder() { - if (resultIsReadOnly) { - TestMutualRecursionA original = result; - result = new TestMutualRecursionA(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestMutualRecursionA MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Descriptor; } - } - - public override TestMutualRecursionA DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance; } - } - - public override TestMutualRecursionA BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestMutualRecursionA) { - return MergeFrom((TestMutualRecursionA) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestMutualRecursionA other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasBb) { - MergeBb(other.Bb); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testMutualRecursionAFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testMutualRecursionAFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.CreateBuilder(); - if (result.hasBb) { - subBuilder.MergeFrom(Bb); - } - input.ReadMessage(subBuilder, extensionRegistry); - Bb = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasBb { - get { return result.hasBb; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB Bb { - get { return result.Bb; } - set { SetBb(value); } - } - public Builder SetBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBb = true; - result.bb_ = value; - return this; - } - public Builder SetBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasBb = true; - result.bb_ = builderForValue.Build(); - return this; - } - public Builder MergeBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasBb && - result.bb_ != global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance) { - result.bb_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.CreateBuilder(result.bb_).MergeFrom(value).BuildPartial(); - } else { - result.bb_ = value; - } - result.hasBb = true; - return this; - } - public Builder ClearBb() { - PrepareBuilder(); - result.hasBb = false; - result.bb_ = null; - return this; - } - } - static TestMutualRecursionA() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestMutualRecursionB : pb::GeneratedMessage { - private TestMutualRecursionB() { } - private static readonly TestMutualRecursionB defaultInstance = new TestMutualRecursionB().MakeReadOnly(); - private static readonly string[] _testMutualRecursionBFieldNames = new string[] { "a", "optional_int32" }; - private static readonly uint[] _testMutualRecursionBFieldTags = new uint[] { 10, 16 }; - public static TestMutualRecursionB DefaultInstance { - get { return defaultInstance; } - } + public const int RequiredDoubleFieldNumber = 1; + private bool hasRequiredDouble; + private double requiredDouble_; + public bool HasRequiredDouble + { + get { return hasRequiredDouble; } + } + public double RequiredDouble + { + get { return requiredDouble_; } + } - public override TestMutualRecursionB DefaultInstanceForType { - get { return DefaultInstance; } - } + public override bool IsInitialized + { + get + { + if (!hasRequiredDouble) return false; + return true; + } + } - protected override TestMutualRecursionB ThisMessage { - get { return this; } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _nestedMessageFieldNames; + if (hasRequiredDouble) + { + output.WriteDouble(1, field_names[0], RequiredDouble); + } + UnknownFields.WriteTo(output); + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor; } - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable; } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public const int AFieldNumber = 1; - private bool hasA; - private global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA a_; - public bool HasA { - get { return hasA; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA A { - get { return a_ ?? global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance; } - } + size = 0; + if (hasRequiredDouble) + { + size += pb::CodedOutputStream.ComputeDoubleSize(1, RequiredDouble); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static NestedMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private NestedMessage MakeReadOnly() + { + return this; + } - public const int OptionalInt32FieldNumber = 2; - private bool hasOptionalInt32; - private int optionalInt32_; - public bool HasOptionalInt32 { - get { return hasOptionalInt32; } - } - public int OptionalInt32 { - get { return optionalInt32_; } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(NestedMessage prototype) + { + return new Builder(prototype); + } - public override bool IsInitialized { - get { - return true; - } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(NestedMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testMutualRecursionBFieldNames; - if (hasA) { - output.WriteMessage(1, field_names[0], A); - } - if (hasOptionalInt32) { - output.WriteInt32(2, field_names[1], OptionalInt32); - } - UnknownFields.WriteTo(output); - } + private bool resultIsReadOnly; + private NestedMessage result; + + private NestedMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + NestedMessage original = result; + result = new NestedMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeMessageSize(1, A); - } - if (hasOptionalInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(2, OptionalInt32); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestMutualRecursionB ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestMutualRecursionB ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestMutualRecursionB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestMutualRecursionB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestMutualRecursionB MakeReadOnly() { - return this; - } + protected override NestedMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestMutualRecursionB prototype) { - return new Builder(prototype); - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestMutualRecursionB cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestMutualRecursionB result; - - private TestMutualRecursionB PrepareBuilder() { - if (resultIsReadOnly) { - TestMutualRecursionB original = result; - result = new TestMutualRecursionB(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestMutualRecursionB MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Descriptor; } - } - - public override TestMutualRecursionB DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance; } - } - - public override TestMutualRecursionB BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestMutualRecursionB) { - return MergeFrom((TestMutualRecursionB) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestMutualRecursionB other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - MergeA(other.A); - } - if (other.HasOptionalInt32) { - OptionalInt32 = other.OptionalInt32; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testMutualRecursionBFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testMutualRecursionBFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.CreateBuilder(); - if (result.hasA) { - subBuilder.MergeFrom(A); - } - input.ReadMessage(subBuilder, extensionRegistry); - A = subBuilder.BuildPartial(); - break; - } - case 16: { - result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasA = true; - result.a_ = builderForValue.Build(); - return this; - } - public Builder MergeA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasA && - result.a_ != global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance) { - result.a_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.CreateBuilder(result.a_).MergeFrom(value).BuildPartial(); - } else { - result.a_ = value; - } - result.hasA = true; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = null; - return this; - } - - public bool HasOptionalInt32 { - get { return result.hasOptionalInt32; } - } - public int OptionalInt32 { - get { return result.OptionalInt32; } - set { SetOptionalInt32(value); } - } - public Builder SetOptionalInt32(int value) { - PrepareBuilder(); - result.hasOptionalInt32 = true; - result.optionalInt32_ = value; - return this; - } - public Builder ClearOptionalInt32() { - PrepareBuilder(); - result.hasOptionalInt32 = false; - result.optionalInt32_ = 0; - return this; - } - } - static TestMutualRecursionB() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestDupFieldNumber : pb::GeneratedMessage { - private TestDupFieldNumber() { } - private static readonly TestDupFieldNumber defaultInstance = new TestDupFieldNumber().MakeReadOnly(); - private static readonly string[] _testDupFieldNumberFieldNames = new string[] { "a", "bar", "foo" }; - private static readonly uint[] _testDupFieldNumberFieldTags = new uint[] { 8, 27, 19 }; - public static TestDupFieldNumber DefaultInstance { - get { return defaultInstance; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public override TestDupFieldNumber DefaultInstanceForType { - get { return DefaultInstance; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.Descriptor; } + } - protected override TestDupFieldNumber ThisMessage { - get { return this; } - } + public override NestedMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor; } - } + public override NestedMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable; } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is NestedMessage) + { + return MergeFrom((NestedMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Foo : pb::GeneratedMessage { - private Foo() { } - private static readonly Foo defaultInstance = new Foo().MakeReadOnly(); - private static readonly string[] _fooFieldNames = new string[] { "a" }; - private static readonly uint[] _fooFieldTags = new uint[] { 8 }; - public static Foo DefaultInstance { - get { return defaultInstance; } - } + public override Builder MergeFrom(NestedMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasRequiredDouble) + { + RequiredDouble = other.RequiredDouble; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public override Foo DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - protected override Foo ThisMessage { - get { return this; } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _nestedMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 9: + { + result.hasRequiredDouble = input.ReadDouble(ref result.requiredDouble_); + break; + } + } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor; } - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable; } - } - public const int AFieldNumber = 1; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } + public bool HasRequiredDouble + { + get { return result.hasRequiredDouble; } + } + public double RequiredDouble + { + get { return result.RequiredDouble; } + set { SetRequiredDouble(value); } + } + public Builder SetRequiredDouble(double value) + { + PrepareBuilder(); + result.hasRequiredDouble = true; + result.requiredDouble_ = value; + return this; + } + public Builder ClearRequiredDouble() + { + PrepareBuilder(); + result.hasRequiredDouble = false; + result.requiredDouble_ = 0D; + return this; + } + } + static NestedMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + } + #endregion - public override bool IsInitialized { - get { - return true; - } + public const int FooIntFieldNumber = 1; + private bool hasFooInt; + private int fooInt_; + public bool HasFooInt + { + get { return hasFooInt; } + } + public int FooInt + { + get { return fooInt_; } + } + + public const int FooStringFieldNumber = 2; + private bool hasFooString; + private string fooString_ = ""; + public bool HasFooString + { + get { return hasFooString; } + } + public string FooString + { + get { return fooString_; } + } + + public const int FooMessageFieldNumber = 3; + private bool hasFooMessage; + private global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage fooMessage_; + public bool HasFooMessage + { + get { return hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage FooMessage + { + get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance; } + } + + public override bool IsInitialized + { + get + { + if (HasFooMessage) + { + if (!FooMessage.IsInitialized) return false; + } + return true; + } } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooFieldNames; - if (hasA) { - output.WriteInt32(1, field_names[0], A); - } - UnknownFields.WriteTo(output); + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testRequiredOneofFieldNames; + if (hasFooInt) + { + output.WriteInt32(1, field_names[0], FooInt); + } + if (hasFooString) + { + output.WriteString(2, field_names[2], FooString); + } + if (hasFooMessage) + { + output.WriteMessage(3, field_names[1], FooMessage); + } + UnknownFields.WriteTo(output); } private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; + size = 0; + if (hasFooInt) + { + size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); + } + if (hasFooString) + { + size += pb::CodedOutputStream.ComputeStringSize(2, FooString); + } + if (hasFooMessage) + { + size += pb::CodedOutputStream.ComputeMessageSize(3, FooMessage); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; } - public static Foo ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public static TestRequiredOneof ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static Foo ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public static TestRequiredOneof ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public static Foo ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public static TestRequiredOneof ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static Foo ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public static TestRequiredOneof ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public static Foo ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public static TestRequiredOneof ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static Foo ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public static TestRequiredOneof ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - public static Foo ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + public static TestRequiredOneof ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); } - public static Foo ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + public static TestRequiredOneof ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); } - public static Foo ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public static TestRequiredOneof ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static Foo ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public static TestRequiredOneof ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - private Foo MakeReadOnly() { - return this; + private TestRequiredOneof MakeReadOnly() + { + return this; } public static Builder CreateBuilder() { return new Builder(); } public override Builder ToBuilder() { return CreateBuilder(this); } public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Foo prototype) { - return new Builder(prototype); + public static Builder CreateBuilder(TestRequiredOneof prototype) + { + return new Builder(prototype); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Foo cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Foo result; - - private Foo PrepareBuilder() { - if (resultIsReadOnly) { - Foo original = result; - result = new Foo(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Foo MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRequiredOneof cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private TestRequiredOneof result; + + private TestRequiredOneof PrepareBuilder() + { + if (resultIsReadOnly) + { + TestRequiredOneof original = result; + result = new TestRequiredOneof(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + protected override TestRequiredOneof MessageBeingBuilt + { + get { return PrepareBuilder(); } } - } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Descriptor; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public override Foo DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public override Foo BuildPartial() { - if (resultIsReadOnly) { - return result; + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Descriptor; } } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - public override Builder MergeFrom(pb::IMessage other) { - if (other is Foo) { - return MergeFrom((Foo) other); - } else { - base.MergeFrom(other); - return this; + public override TestRequiredOneof DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.DefaultInstance; } } - } - public override Builder MergeFrom(Foo other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; + public override TestRequiredOneof BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestRequiredOneof) + { + return MergeFrom((TestRequiredOneof)other); + } + else + { + base.MergeFrom(other); return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; } - case 8: { - result.hasA = input.ReadInt32(ref result.a_); - break; + } + + public override Builder MergeFrom(TestRequiredOneof other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasFooInt) + { + FooInt = other.FooInt; + } + if (other.HasFooString) + { + FooString = other.FooString; + } + if (other.HasFooMessage) + { + MergeFooMessage(other.FooMessage); } - } + this.MergeUnknownFields(other.UnknownFields); + return this; } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testRequiredOneofFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testRequiredOneofFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 8: + { + result.hasFooInt = input.ReadInt32(ref result.fooInt_); + break; + } + case 18: + { + result.hasFooString = input.ReadString(ref result.fooString_); + break; + } + case 26: + { + global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.CreateBuilder(); + if (result.hasFooMessage) + { + subBuilder.MergeFrom(FooMessage); + } + input.ReadMessage(subBuilder, extensionRegistry); + FooMessage = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasFooInt + { + get { return result.hasFooInt; } + } + public int FooInt + { + get { return result.FooInt; } + set { SetFooInt(value); } + } + public Builder SetFooInt(int value) + { + PrepareBuilder(); + result.hasFooInt = true; + result.fooInt_ = value; + return this; + } + public Builder ClearFooInt() + { + PrepareBuilder(); + result.hasFooInt = false; + result.fooInt_ = 0; + return this; + } + + public bool HasFooString + { + get { return result.hasFooString; } + } + public string FooString + { + get { return result.FooString; } + set { SetFooString(value); } + } + public Builder SetFooString(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooString = true; + result.fooString_ = value; + return this; + } + public Builder ClearFooString() + { + PrepareBuilder(); + result.hasFooString = false; + result.fooString_ = ""; + return this; + } + + public bool HasFooMessage + { + get { return result.hasFooMessage; } + } + public global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage FooMessage + { + get { return result.FooMessage; } + set { SetFooMessage(value); } + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = value; + return this; + } + public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasFooMessage = true; + result.fooMessage_ = builderForValue.Build(); + return this; + } + public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasFooMessage && + result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance) + { + result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); + } + else + { + result.fooMessage_ = value; + } + result.hasFooMessage = true; + return this; + } + public Builder ClearFooMessage() + { + PrepareBuilder(); + result.hasFooMessage = false; + result.fooMessage_ = null; + return this; } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } } - static Foo() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + static TestRequiredOneof() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); } - } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Bar : pb::GeneratedMessage { - private Bar() { } - private static readonly Bar defaultInstance = new Bar().MakeReadOnly(); - private static readonly string[] _barFieldNames = new string[] { "a" }; - private static readonly uint[] _barFieldTags = new uint[] { 8 }; - public static Bar DefaultInstance { - get { return defaultInstance; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestPackedTypes : pb::GeneratedMessage + { + private TestPackedTypes() { } + private static readonly TestPackedTypes defaultInstance = new TestPackedTypes().MakeReadOnly(); + private static readonly string[] _testPackedTypesFieldNames = new string[] { "packed_bool", "packed_double", "packed_enum", "packed_fixed32", "packed_fixed64", "packed_float", "packed_int32", "packed_int64", "packed_sfixed32", "packed_sfixed64", "packed_sint32", "packed_sint64", "packed_uint32", "packed_uint64" }; + private static readonly uint[] _testPackedTypesFieldTags = new uint[] { 818, 810, 826, 770, 778, 802, 722, 730, 786, 794, 754, 762, 738, 746 }; + public static TestPackedTypes DefaultInstance + { + get { return defaultInstance; } } - public override Bar DefaultInstanceForType { - get { return DefaultInstance; } + public override TestPackedTypes DefaultInstanceForType + { + get { return DefaultInstance; } } - protected override Bar ThisMessage { - get { return this; } + protected override TestPackedTypes ThisMessage + { + get { return this; } } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor; } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedTypes__Descriptor; } } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable; } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable; } } - public const int AFieldNumber = 1; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } + public const int PackedInt32FieldNumber = 90; + private int packedInt32MemoizedSerializedSize; + private pbc::PopsicleList packedInt32_ = new pbc::PopsicleList(); + public scg::IList PackedInt32List + { + get { return pbc::Lists.AsReadOnly(packedInt32_); } } - public int A { - get { return a_; } + public int PackedInt32Count + { + get { return packedInt32_.Count; } } - - public override bool IsInitialized { - get { - return true; - } + public int GetPackedInt32(int index) + { + return packedInt32_[index]; } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _barFieldNames; - if (hasA) { - output.WriteInt32(1, field_names[0], A); - } - UnknownFields.WriteTo(output); + public const int PackedInt64FieldNumber = 91; + private int packedInt64MemoizedSerializedSize; + private pbc::PopsicleList packedInt64_ = new pbc::PopsicleList(); + public scg::IList PackedInt64List + { + get { return pbc::Lists.AsReadOnly(packedInt64_); } + } + public int PackedInt64Count + { + get { return packedInt64_.Count; } + } + public long GetPackedInt64(int index) + { + return packedInt64_[index]; } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } + public const int PackedUint32FieldNumber = 92; + private int packedUint32MemoizedSerializedSize; + private pbc::PopsicleList packedUint32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedUint32List + { + get { return pbc::Lists.AsReadOnly(packedUint32_); } + } + public int PackedUint32Count + { + get { return packedUint32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedUint32(int index) + { + return packedUint32_[index]; } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public const int PackedUint64FieldNumber = 93; + private int packedUint64MemoizedSerializedSize; + private pbc::PopsicleList packedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedUint64List + { + get { return pbc::Lists.AsReadOnly(packedUint64_); } + } + public int PackedUint64Count + { + get { return packedUint64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedUint64(int index) + { + return packedUint64_[index]; + } - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; + public const int PackedSint32FieldNumber = 94; + private int packedSint32MemoizedSerializedSize; + private pbc::PopsicleList packedSint32_ = new pbc::PopsicleList(); + public scg::IList PackedSint32List + { + get { return pbc::Lists.AsReadOnly(packedSint32_); } } - public static Bar ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public int PackedSint32Count + { + get { return packedSint32_.Count; } } - public static Bar ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public int GetPackedSint32(int index) + { + return packedSint32_[index]; } - public static Bar ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + + public const int PackedSint64FieldNumber = 95; + private int packedSint64MemoizedSerializedSize; + private pbc::PopsicleList packedSint64_ = new pbc::PopsicleList(); + public scg::IList PackedSint64List + { + get { return pbc::Lists.AsReadOnly(packedSint64_); } + } + public int PackedSint64Count + { + get { return packedSint64_.Count; } + } + public long GetPackedSint64(int index) + { + return packedSint64_[index]; + } + + public const int PackedFixed32FieldNumber = 96; + private int packedFixed32MemoizedSerializedSize; + private pbc::PopsicleList packedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedFixed32List + { + get { return pbc::Lists.AsReadOnly(packedFixed32_); } + } + public int PackedFixed32Count + { + get { return packedFixed32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedFixed32(int index) + { + return packedFixed32_[index]; + } + + public const int PackedFixed64FieldNumber = 97; + private int packedFixed64MemoizedSerializedSize; + private pbc::PopsicleList packedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList PackedFixed64List + { + get { return pbc::Lists.AsReadOnly(packedFixed64_); } + } + public int PackedFixed64Count + { + get { return packedFixed64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedFixed64(int index) + { + return packedFixed64_[index]; + } + + public const int PackedSfixed32FieldNumber = 98; + private int packedSfixed32MemoizedSerializedSize; + private pbc::PopsicleList packedSfixed32_ = new pbc::PopsicleList(); + public scg::IList PackedSfixed32List + { + get { return pbc::Lists.AsReadOnly(packedSfixed32_); } + } + public int PackedSfixed32Count + { + get { return packedSfixed32_.Count; } + } + public int GetPackedSfixed32(int index) + { + return packedSfixed32_[index]; + } + + public const int PackedSfixed64FieldNumber = 99; + private int packedSfixed64MemoizedSerializedSize; + private pbc::PopsicleList packedSfixed64_ = new pbc::PopsicleList(); + public scg::IList PackedSfixed64List + { + get { return pbc::Lists.AsReadOnly(packedSfixed64_); } + } + public int PackedSfixed64Count + { + get { return packedSfixed64_.Count; } + } + public long GetPackedSfixed64(int index) + { + return packedSfixed64_[index]; + } + + public const int PackedFloatFieldNumber = 100; + private int packedFloatMemoizedSerializedSize; + private pbc::PopsicleList packedFloat_ = new pbc::PopsicleList(); + public scg::IList PackedFloatList + { + get { return pbc::Lists.AsReadOnly(packedFloat_); } } - public static Bar ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public int PackedFloatCount + { + get { return packedFloat_.Count; } } - public static Bar ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public float GetPackedFloat(int index) + { + return packedFloat_[index]; } - public static Bar ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + + public const int PackedDoubleFieldNumber = 101; + private int packedDoubleMemoizedSerializedSize; + private pbc::PopsicleList packedDouble_ = new pbc::PopsicleList(); + public scg::IList PackedDoubleList + { + get { return pbc::Lists.AsReadOnly(packedDouble_); } } - public static Bar ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + public int PackedDoubleCount + { + get { return packedDouble_.Count; } } - public static Bar ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + public double GetPackedDouble(int index) + { + return packedDouble_[index]; } - public static Bar ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + + public const int PackedBoolFieldNumber = 102; + private int packedBoolMemoizedSerializedSize; + private pbc::PopsicleList packedBool_ = new pbc::PopsicleList(); + public scg::IList PackedBoolList + { + get { return pbc::Lists.AsReadOnly(packedBool_); } } - public static Bar ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public int PackedBoolCount + { + get { return packedBool_.Count; } } - private Bar MakeReadOnly() { - return this; + public bool GetPackedBool(int index) + { + return packedBool_[index]; } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Bar prototype) { - return new Builder(prototype); + public const int PackedEnumFieldNumber = 103; + private int packedEnumMemoizedSerializedSize; + private pbc::PopsicleList packedEnum_ = new pbc::PopsicleList(); + public scg::IList PackedEnumList + { + get { return pbc::Lists.AsReadOnly(packedEnum_); } + } + public int PackedEnumCount + { + get { return packedEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetPackedEnum(int index) + { + return packedEnum_[index]; } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Bar cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Bar result; - - private Bar PrepareBuilder() { - if (resultIsReadOnly) { - Bar original = result; - result = new Bar(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Bar MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + public override bool IsInitialized + { + get + { + return true; + } + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testPackedTypesFieldNames; + if (packedInt32_.Count > 0) + { + output.WritePackedInt32Array(90, field_names[6], packedInt32MemoizedSerializedSize, packedInt32_); + } + if (packedInt64_.Count > 0) + { + output.WritePackedInt64Array(91, field_names[7], packedInt64MemoizedSerializedSize, packedInt64_); + } + if (packedUint32_.Count > 0) + { + output.WritePackedUInt32Array(92, field_names[12], packedUint32MemoizedSerializedSize, packedUint32_); + } + if (packedUint64_.Count > 0) + { + output.WritePackedUInt64Array(93, field_names[13], packedUint64MemoizedSerializedSize, packedUint64_); + } + if (packedSint32_.Count > 0) + { + output.WritePackedSInt32Array(94, field_names[10], packedSint32MemoizedSerializedSize, packedSint32_); + } + if (packedSint64_.Count > 0) + { + output.WritePackedSInt64Array(95, field_names[11], packedSint64MemoizedSerializedSize, packedSint64_); + } + if (packedFixed32_.Count > 0) + { + output.WritePackedFixed32Array(96, field_names[3], packedFixed32MemoizedSerializedSize, packedFixed32_); + } + if (packedFixed64_.Count > 0) + { + output.WritePackedFixed64Array(97, field_names[4], packedFixed64MemoizedSerializedSize, packedFixed64_); } - } + if (packedSfixed32_.Count > 0) + { + output.WritePackedSFixed32Array(98, field_names[8], packedSfixed32MemoizedSerializedSize, packedSfixed32_); + } + if (packedSfixed64_.Count > 0) + { + output.WritePackedSFixed64Array(99, field_names[9], packedSfixed64MemoizedSerializedSize, packedSfixed64_); + } + if (packedFloat_.Count > 0) + { + output.WritePackedFloatArray(100, field_names[5], packedFloatMemoizedSerializedSize, packedFloat_); + } + if (packedDouble_.Count > 0) + { + output.WritePackedDoubleArray(101, field_names[1], packedDoubleMemoizedSerializedSize, packedDouble_); + } + if (packedBool_.Count > 0) + { + output.WritePackedBoolArray(102, field_names[0], packedBoolMemoizedSerializedSize, packedBool_); + } + if (packedEnum_.Count > 0) + { + output.WritePackedEnumArray(103, field_names[2], packedEnumMemoizedSerializedSize, packedEnum_); + } + UnknownFields.WriteTo(output); + } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Descriptor; } - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public override Bar DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance; } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public override Bar BuildPartial() { - if (resultIsReadOnly) { - return result; + size = 0; + { + int dataSize = 0; + foreach (int element in PackedInt32List) + { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + if (packedInt32_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedInt32MemoizedSerializedSize = dataSize; } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is Bar) { - return MergeFrom((Bar) other); - } else { - base.MergeFrom(other); - return this; + { + int dataSize = 0; + foreach (long element in PackedInt64List) + { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + if (packedInt64_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedInt64MemoizedSerializedSize = dataSize; } - } - - public override Builder MergeFrom(Bar other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; + { + int dataSize = 0; + foreach (uint element in PackedUint32List) + { + dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); + } + size += dataSize; + if (packedUint32_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedUint32MemoizedSerializedSize = dataSize; } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_barFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _barFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; + { + int dataSize = 0; + foreach (ulong element in PackedUint64List) + { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); } - case 8: { - result.hasA = input.ReadInt32(ref result.a_); - break; + size += dataSize; + if (packedUint64_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); } - } + packedUint64MemoizedSerializedSize = dataSize; } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + { + int dataSize = 0; + foreach (int element in PackedSint32List) + { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + if (packedSint32_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSint32MemoizedSerializedSize = dataSize; } + { + int dataSize = 0; + foreach (long element in PackedSint64List) + { + dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); + } + size += dataSize; + if (packedSint64_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSint64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 4 * packedFixed32_.Count; + size += dataSize; + if (packedFixed32_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedFixed32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 8 * packedFixed64_.Count; + size += dataSize; + if (packedFixed64_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedFixed64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 4 * packedSfixed32_.Count; + size += dataSize; + if (packedSfixed32_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSfixed32MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 8 * packedSfixed64_.Count; + size += dataSize; + if (packedSfixed64_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedSfixed64MemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 4 * packedFloat_.Count; + size += dataSize; + if (packedFloat_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedFloatMemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 8 * packedDouble_.Count; + size += dataSize; + if (packedDouble_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedDoubleMemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + dataSize = 1 * packedBool_.Count; + size += dataSize; + if (packedBool_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedBoolMemoizedSerializedSize = dataSize; + } + { + int dataSize = 0; + if (packedEnum_.Count > 0) + { + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in packedEnum_) + { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int)element); + } + size += dataSize; + size += 2; + size += pb::CodedOutputStream.ComputeRawVarint32Size((uint)dataSize); + } + packedEnumMemoizedSerializedSize = dataSize; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestPackedTypes ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestPackedTypes ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestPackedTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestPackedTypes ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestPackedTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestPackedTypes MakeReadOnly() + { + packedInt32_.MakeReadOnly(); + packedInt64_.MakeReadOnly(); + packedUint32_.MakeReadOnly(); + packedUint64_.MakeReadOnly(); + packedSint32_.MakeReadOnly(); + packedSint64_.MakeReadOnly(); + packedFixed32_.MakeReadOnly(); + packedFixed64_.MakeReadOnly(); + packedSfixed32_.MakeReadOnly(); + packedSfixed64_.MakeReadOnly(); + packedFloat_.MakeReadOnly(); + packedDouble_.MakeReadOnly(); + packedBool_.MakeReadOnly(); + packedEnum_.MakeReadOnly(); return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } } - static Bar() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - } - #endregion - - public const int AFieldNumber = 1; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } - - public const int FooFieldNumber = 2; - private bool hasFoo; - private global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo foo_; - public bool HasFoo { - get { return hasFoo; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo Foo { - get { return foo_ ?? global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance; } - } - - public const int BarFieldNumber = 3; - private bool hasBar; - private global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar bar_; - public bool HasBar { - get { return hasBar; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar Bar { - get { return bar_ ?? global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance; } - } - - public override bool IsInitialized { - get { - return true; - } - } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testDupFieldNumberFieldNames; - if (hasA) { - output.WriteInt32(1, field_names[0], A); - } - if (hasFoo) { - output.WriteGroup(2, field_names[2], Foo); - } - if (hasBar) { - output.WriteGroup(3, field_names[1], Bar); - } - UnknownFields.WriteTo(output); - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestPackedTypes prototype) + { + return new Builder(prototype); + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestPackedTypes cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A); - } - if (hasFoo) { - size += pb::CodedOutputStream.ComputeGroupSize(2, Foo); - } - if (hasBar) { - size += pb::CodedOutputStream.ComputeGroupSize(3, Bar); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestDupFieldNumber ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestDupFieldNumber ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestDupFieldNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDupFieldNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestDupFieldNumber MakeReadOnly() { - return this; - } + private bool resultIsReadOnly; + private TestPackedTypes result; - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestDupFieldNumber prototype) { - return new Builder(prototype); - } + private TestPackedTypes PrepareBuilder() + { + if (resultIsReadOnly) + { + TestPackedTypes original = result; + result = new TestPackedTypes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestDupFieldNumber cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestDupFieldNumber result; - - private TestDupFieldNumber PrepareBuilder() { - if (resultIsReadOnly) { - TestDupFieldNumber original = result; - result = new TestDupFieldNumber(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestDupFieldNumber MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Descriptor; } - } - - public override TestDupFieldNumber DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.DefaultInstance; } - } - - public override TestDupFieldNumber BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestDupFieldNumber) { - return MergeFrom((TestDupFieldNumber) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestDupFieldNumber other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - if (other.HasFoo) { - MergeFoo(other.Foo); - } - if (other.HasBar) { - MergeBar(other.Bar); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testDupFieldNumberFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testDupFieldNumberFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - case 19: { - global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.CreateBuilder(); - if (result.hasFoo) { - subBuilder.MergeFrom(Foo); - } - input.ReadGroup(2, subBuilder, extensionRegistry); - Foo = subBuilder.BuildPartial(); - break; - } - case 27: { - global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.CreateBuilder(); - if (result.hasBar) { - subBuilder.MergeFrom(Bar); - } - input.ReadGroup(3, subBuilder, extensionRegistry); - Bar = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - - public bool HasFoo { - get { return result.hasFoo; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo Foo { - get { return result.Foo; } - set { SetFoo(value); } - } - public Builder SetFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFoo = true; - result.foo_ = value; - return this; - } - public Builder SetFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasFoo = true; - result.foo_ = builderForValue.Build(); - return this; - } - public Builder MergeFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasFoo && - result.foo_ != global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance) { - result.foo_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.CreateBuilder(result.foo_).MergeFrom(value).BuildPartial(); - } else { - result.foo_ = value; - } - result.hasFoo = true; - return this; - } - public Builder ClearFoo() { - PrepareBuilder(); - result.hasFoo = false; - result.foo_ = null; - return this; - } - - public bool HasBar { - get { return result.hasBar; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar Bar { - get { return result.Bar; } - set { SetBar(value); } - } - public Builder SetBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBar = true; - result.bar_ = value; - return this; - } - public Builder SetBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasBar = true; - result.bar_ = builderForValue.Build(); - return this; - } - public Builder MergeBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasBar && - result.bar_ != global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance) { - result.bar_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.CreateBuilder(result.bar_).MergeFrom(value).BuildPartial(); - } else { - result.bar_ = value; - } - result.hasBar = true; - return this; - } - public Builder ClearBar() { - PrepareBuilder(); - result.hasBar = false; - result.bar_ = null; - return this; - } - } - static TestDupFieldNumber() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestEagerMessage : pb::GeneratedMessage { - private TestEagerMessage() { } - private static readonly TestEagerMessage defaultInstance = new TestEagerMessage().MakeReadOnly(); - private static readonly string[] _testEagerMessageFieldNames = new string[] { "sub_message" }; - private static readonly uint[] _testEagerMessageFieldTags = new uint[] { 10 }; - public static TestEagerMessage DefaultInstance { - get { return defaultInstance; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public override TestEagerMessage DefaultInstanceForType { - get { return DefaultInstance; } - } + protected override TestPackedTypes MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - protected override TestEagerMessage ThisMessage { - get { return this; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEagerMessage__Descriptor; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestEagerMessage__FieldAccessorTable; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.Descriptor; } + } - public const int SubMessageFieldNumber = 1; - private bool hasSubMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes subMessage_; - public bool HasSubMessage { - get { return hasSubMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage { - get { return subMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } + public override TestPackedTypes DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.DefaultInstance; } + } - public override bool IsInitialized { - get { - return true; - } - } + public override TestPackedTypes BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testEagerMessageFieldNames; - if (hasSubMessage) { - output.WriteMessage(1, field_names[0], SubMessage); - } - UnknownFields.WriteTo(output); - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestPackedTypes) + { + return MergeFrom((TestPackedTypes)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override Builder MergeFrom(TestPackedTypes other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.DefaultInstance) return this; + PrepareBuilder(); + if (other.packedInt32_.Count != 0) + { + result.packedInt32_.Add(other.packedInt32_); + } + if (other.packedInt64_.Count != 0) + { + result.packedInt64_.Add(other.packedInt64_); + } + if (other.packedUint32_.Count != 0) + { + result.packedUint32_.Add(other.packedUint32_); + } + if (other.packedUint64_.Count != 0) + { + result.packedUint64_.Add(other.packedUint64_); + } + if (other.packedSint32_.Count != 0) + { + result.packedSint32_.Add(other.packedSint32_); + } + if (other.packedSint64_.Count != 0) + { + result.packedSint64_.Add(other.packedSint64_); + } + if (other.packedFixed32_.Count != 0) + { + result.packedFixed32_.Add(other.packedFixed32_); + } + if (other.packedFixed64_.Count != 0) + { + result.packedFixed64_.Add(other.packedFixed64_); + } + if (other.packedSfixed32_.Count != 0) + { + result.packedSfixed32_.Add(other.packedSfixed32_); + } + if (other.packedSfixed64_.Count != 0) + { + result.packedSfixed64_.Add(other.packedSfixed64_); + } + if (other.packedFloat_.Count != 0) + { + result.packedFloat_.Add(other.packedFloat_); + } + if (other.packedDouble_.Count != 0) + { + result.packedDouble_.Add(other.packedDouble_); + } + if (other.packedBool_.Count != 0) + { + result.packedBool_.Add(other.packedBool_); + } + if (other.packedEnum_.Count != 0) + { + result.packedEnum_.Add(other.packedEnum_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasSubMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(1, SubMessage); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestEagerMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestEagerMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestEagerMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestEagerMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestEagerMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestEagerMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestEagerMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestEagerMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestEagerMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestEagerMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestEagerMessage MakeReadOnly() { - return this; - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestEagerMessage prototype) { - return new Builder(prototype); - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testPackedTypesFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testPackedTypesFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 722: + case 720: + { + input.ReadInt32Array(tag, field_name, result.packedInt32_); + break; + } + case 730: + case 728: + { + input.ReadInt64Array(tag, field_name, result.packedInt64_); + break; + } + case 738: + case 736: + { + input.ReadUInt32Array(tag, field_name, result.packedUint32_); + break; + } + case 746: + case 744: + { + input.ReadUInt64Array(tag, field_name, result.packedUint64_); + break; + } + case 754: + case 752: + { + input.ReadSInt32Array(tag, field_name, result.packedSint32_); + break; + } + case 762: + case 760: + { + input.ReadSInt64Array(tag, field_name, result.packedSint64_); + break; + } + case 770: + case 773: + { + input.ReadFixed32Array(tag, field_name, result.packedFixed32_); + break; + } + case 778: + case 777: + { + input.ReadFixed64Array(tag, field_name, result.packedFixed64_); + break; + } + case 786: + case 789: + { + input.ReadSFixed32Array(tag, field_name, result.packedSfixed32_); + break; + } + case 794: + case 793: + { + input.ReadSFixed64Array(tag, field_name, result.packedSfixed64_); + break; + } + case 802: + case 805: + { + input.ReadFloatArray(tag, field_name, result.packedFloat_); + break; + } + case 810: + case 809: + { + input.ReadDoubleArray(tag, field_name, result.packedDouble_); + break; + } + case 818: + case 816: + { + input.ReadBoolArray(tag, field_name, result.packedBool_); + break; + } + case 826: + case 824: + { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.packedEnum_, out unknownItems); + if (unknownItems != null) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(103, (ulong)(int)rawValue); + } + break; + } + } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestEagerMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestEagerMessage result; - - private TestEagerMessage PrepareBuilder() { - if (resultIsReadOnly) { - TestEagerMessage original = result; - result = new TestEagerMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestEagerMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestEagerMessage.Descriptor; } - } - - public override TestEagerMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestEagerMessage.DefaultInstance; } - } - - public override TestEagerMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestEagerMessage) { - return MergeFrom((TestEagerMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestEagerMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestEagerMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasSubMessage) { - MergeSubMessage(other.SubMessage); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testEagerMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testEagerMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasSubMessage) { - subBuilder.MergeFrom(SubMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - SubMessage = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasSubMessage { - get { return result.hasSubMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage { - get { return result.SubMessage; } - set { SetSubMessage(value); } - } - public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasSubMessage = true; - result.subMessage_ = value; - return this; - } - public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasSubMessage = true; - result.subMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasSubMessage && - result.subMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.subMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.subMessage_).MergeFrom(value).BuildPartial(); - } else { - result.subMessage_ = value; - } - result.hasSubMessage = true; - return this; - } - public Builder ClearSubMessage() { - PrepareBuilder(); - result.hasSubMessage = false; - result.subMessage_ = null; - return this; - } - } - static TestEagerMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestLazyMessage : pb::GeneratedMessage { - private TestLazyMessage() { } - private static readonly TestLazyMessage defaultInstance = new TestLazyMessage().MakeReadOnly(); - private static readonly string[] _testLazyMessageFieldNames = new string[] { "sub_message" }; - private static readonly uint[] _testLazyMessageFieldTags = new uint[] { 10 }; - public static TestLazyMessage DefaultInstance { - get { return defaultInstance; } - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public override TestLazyMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - protected override TestLazyMessage ThisMessage { - get { return this; } - } + public pbc::IPopsicleList PackedInt32List + { + get { return PrepareBuilder().packedInt32_; } + } + public int PackedInt32Count + { + get { return result.PackedInt32Count; } + } + public int GetPackedInt32(int index) + { + return result.GetPackedInt32(index); + } + public Builder SetPackedInt32(int index, int value) + { + PrepareBuilder(); + result.packedInt32_[index] = value; + return this; + } + public Builder AddPackedInt32(int value) + { + PrepareBuilder(); + result.packedInt32_.Add(value); + return this; + } + public Builder AddRangePackedInt32(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedInt32_.Add(values); + return this; + } + public Builder ClearPackedInt32() + { + PrepareBuilder(); + result.packedInt32_.Clear(); + return this; + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestLazyMessage__Descriptor; } - } + public pbc::IPopsicleList PackedInt64List + { + get { return PrepareBuilder().packedInt64_; } + } + public int PackedInt64Count + { + get { return result.PackedInt64Count; } + } + public long GetPackedInt64(int index) + { + return result.GetPackedInt64(index); + } + public Builder SetPackedInt64(int index, long value) + { + PrepareBuilder(); + result.packedInt64_[index] = value; + return this; + } + public Builder AddPackedInt64(long value) + { + PrepareBuilder(); + result.packedInt64_.Add(value); + return this; + } + public Builder AddRangePackedInt64(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedInt64_.Add(values); + return this; + } + public Builder ClearPackedInt64() + { + PrepareBuilder(); + result.packedInt64_.Clear(); + return this; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestLazyMessage__FieldAccessorTable; } - } + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedUint32List + { + get { return PrepareBuilder().packedUint32_; } + } + public int PackedUint32Count + { + get { return result.PackedUint32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedUint32(int index) + { + return result.GetPackedUint32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedUint32(int index, uint value) + { + PrepareBuilder(); + result.packedUint32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedUint32(uint value) + { + PrepareBuilder(); + result.packedUint32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedUint32(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedUint32_.Add(values); + return this; + } + public Builder ClearPackedUint32() + { + PrepareBuilder(); + result.packedUint32_.Clear(); + return this; + } - public const int SubMessageFieldNumber = 1; - private bool hasSubMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes subMessage_; - public bool HasSubMessage { - get { return hasSubMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage { - get { return subMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedUint64List + { + get { return PrepareBuilder().packedUint64_; } + } + public int PackedUint64Count + { + get { return result.PackedUint64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedUint64(int index) + { + return result.GetPackedUint64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedUint64(int index, ulong value) + { + PrepareBuilder(); + result.packedUint64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedUint64(ulong value) + { + PrepareBuilder(); + result.packedUint64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedUint64(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedUint64_.Add(values); + return this; + } + public Builder ClearPackedUint64() + { + PrepareBuilder(); + result.packedUint64_.Clear(); + return this; + } - public override bool IsInitialized { - get { - return true; - } - } + public pbc::IPopsicleList PackedSint32List + { + get { return PrepareBuilder().packedSint32_; } + } + public int PackedSint32Count + { + get { return result.PackedSint32Count; } + } + public int GetPackedSint32(int index) + { + return result.GetPackedSint32(index); + } + public Builder SetPackedSint32(int index, int value) + { + PrepareBuilder(); + result.packedSint32_[index] = value; + return this; + } + public Builder AddPackedSint32(int value) + { + PrepareBuilder(); + result.packedSint32_.Add(value); + return this; + } + public Builder AddRangePackedSint32(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedSint32_.Add(values); + return this; + } + public Builder ClearPackedSint32() + { + PrepareBuilder(); + result.packedSint32_.Clear(); + return this; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testLazyMessageFieldNames; - if (hasSubMessage) { - output.WriteMessage(1, field_names[0], SubMessage); - } - UnknownFields.WriteTo(output); - } + public pbc::IPopsicleList PackedSint64List + { + get { return PrepareBuilder().packedSint64_; } + } + public int PackedSint64Count + { + get { return result.PackedSint64Count; } + } + public long GetPackedSint64(int index) + { + return result.GetPackedSint64(index); + } + public Builder SetPackedSint64(int index, long value) + { + PrepareBuilder(); + result.packedSint64_[index] = value; + return this; + } + public Builder AddPackedSint64(long value) + { + PrepareBuilder(); + result.packedSint64_.Add(value); + return this; + } + public Builder AddRangePackedSint64(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedSint64_.Add(values); + return this; + } + public Builder ClearPackedSint64() + { + PrepareBuilder(); + result.packedSint64_.Clear(); + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedFixed32List + { + get { return PrepareBuilder().packedFixed32_; } + } + public int PackedFixed32Count + { + get { return result.PackedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetPackedFixed32(int index) + { + return result.GetPackedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedFixed32(int index, uint value) + { + PrepareBuilder(); + result.packedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedFixed32(uint value) + { + PrepareBuilder(); + result.packedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedFixed32(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedFixed32_.Add(values); + return this; + } + public Builder ClearPackedFixed32() + { + PrepareBuilder(); + result.packedFixed32_.Clear(); + return this; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasSubMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(1, SubMessage); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestLazyMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestLazyMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestLazyMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestLazyMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestLazyMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestLazyMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestLazyMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestLazyMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestLazyMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestLazyMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestLazyMessage MakeReadOnly() { - return this; - } + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList PackedFixed64List + { + get { return PrepareBuilder().packedFixed64_; } + } + public int PackedFixed64Count + { + get { return result.PackedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetPackedFixed64(int index) + { + return result.GetPackedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetPackedFixed64(int index, ulong value) + { + PrepareBuilder(); + result.packedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddPackedFixed64(ulong value) + { + PrepareBuilder(); + result.packedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangePackedFixed64(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedFixed64_.Add(values); + return this; + } + public Builder ClearPackedFixed64() + { + PrepareBuilder(); + result.packedFixed64_.Clear(); + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestLazyMessage prototype) { - return new Builder(prototype); - } + public pbc::IPopsicleList PackedSfixed32List + { + get { return PrepareBuilder().packedSfixed32_; } + } + public int PackedSfixed32Count + { + get { return result.PackedSfixed32Count; } + } + public int GetPackedSfixed32(int index) + { + return result.GetPackedSfixed32(index); + } + public Builder SetPackedSfixed32(int index, int value) + { + PrepareBuilder(); + result.packedSfixed32_[index] = value; + return this; + } + public Builder AddPackedSfixed32(int value) + { + PrepareBuilder(); + result.packedSfixed32_.Add(value); + return this; + } + public Builder AddRangePackedSfixed32(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedSfixed32_.Add(values); + return this; + } + public Builder ClearPackedSfixed32() + { + PrepareBuilder(); + result.packedSfixed32_.Clear(); + return this; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestLazyMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestLazyMessage result; - - private TestLazyMessage PrepareBuilder() { - if (resultIsReadOnly) { - TestLazyMessage original = result; - result = new TestLazyMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestLazyMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestLazyMessage.Descriptor; } - } - - public override TestLazyMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestLazyMessage.DefaultInstance; } - } - - public override TestLazyMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestLazyMessage) { - return MergeFrom((TestLazyMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestLazyMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestLazyMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasSubMessage) { - MergeSubMessage(other.SubMessage); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testLazyMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testLazyMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasSubMessage) { - subBuilder.MergeFrom(SubMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - SubMessage = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasSubMessage { - get { return result.hasSubMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes SubMessage { - get { return result.SubMessage; } - set { SetSubMessage(value); } - } - public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasSubMessage = true; - result.subMessage_ = value; - return this; - } - public Builder SetSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasSubMessage = true; - result.subMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeSubMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasSubMessage && - result.subMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.subMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.subMessage_).MergeFrom(value).BuildPartial(); - } else { - result.subMessage_ = value; - } - result.hasSubMessage = true; - return this; - } - public Builder ClearSubMessage() { - PrepareBuilder(); - result.hasSubMessage = false; - result.subMessage_ = null; - return this; - } - } - static TestLazyMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestNestedMessageHasBits : pb::GeneratedMessage { - private TestNestedMessageHasBits() { } - private static readonly TestNestedMessageHasBits defaultInstance = new TestNestedMessageHasBits().MakeReadOnly(); - private static readonly string[] _testNestedMessageHasBitsFieldNames = new string[] { "optional_nested_message" }; - private static readonly uint[] _testNestedMessageHasBitsFieldTags = new uint[] { 10 }; - public static TestNestedMessageHasBits DefaultInstance { - get { return defaultInstance; } - } + public pbc::IPopsicleList PackedSfixed64List + { + get { return PrepareBuilder().packedSfixed64_; } + } + public int PackedSfixed64Count + { + get { return result.PackedSfixed64Count; } + } + public long GetPackedSfixed64(int index) + { + return result.GetPackedSfixed64(index); + } + public Builder SetPackedSfixed64(int index, long value) + { + PrepareBuilder(); + result.packedSfixed64_[index] = value; + return this; + } + public Builder AddPackedSfixed64(long value) + { + PrepareBuilder(); + result.packedSfixed64_.Add(value); + return this; + } + public Builder AddRangePackedSfixed64(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedSfixed64_.Add(values); + return this; + } + public Builder ClearPackedSfixed64() + { + PrepareBuilder(); + result.packedSfixed64_.Clear(); + return this; + } - public override TestNestedMessageHasBits DefaultInstanceForType { - get { return DefaultInstance; } - } + public pbc::IPopsicleList PackedFloatList + { + get { return PrepareBuilder().packedFloat_; } + } + public int PackedFloatCount + { + get { return result.PackedFloatCount; } + } + public float GetPackedFloat(int index) + { + return result.GetPackedFloat(index); + } + public Builder SetPackedFloat(int index, float value) + { + PrepareBuilder(); + result.packedFloat_[index] = value; + return this; + } + public Builder AddPackedFloat(float value) + { + PrepareBuilder(); + result.packedFloat_.Add(value); + return this; + } + public Builder AddRangePackedFloat(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedFloat_.Add(values); + return this; + } + public Builder ClearPackedFloat() + { + PrepareBuilder(); + result.packedFloat_.Clear(); + return this; + } - protected override TestNestedMessageHasBits ThisMessage { - get { return this; } - } + public pbc::IPopsicleList PackedDoubleList + { + get { return PrepareBuilder().packedDouble_; } + } + public int PackedDoubleCount + { + get { return result.PackedDoubleCount; } + } + public double GetPackedDouble(int index) + { + return result.GetPackedDouble(index); + } + public Builder SetPackedDouble(int index, double value) + { + PrepareBuilder(); + result.packedDouble_[index] = value; + return this; + } + public Builder AddPackedDouble(double value) + { + PrepareBuilder(); + result.packedDouble_.Add(value); + return this; + } + public Builder AddRangePackedDouble(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedDouble_.Add(values); + return this; + } + public Builder ClearPackedDouble() + { + PrepareBuilder(); + result.packedDouble_.Clear(); + return this; + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor; } - } + public pbc::IPopsicleList PackedBoolList + { + get { return PrepareBuilder().packedBool_; } + } + public int PackedBoolCount + { + get { return result.PackedBoolCount; } + } + public bool GetPackedBool(int index) + { + return result.GetPackedBool(index); + } + public Builder SetPackedBool(int index, bool value) + { + PrepareBuilder(); + result.packedBool_[index] = value; + return this; + } + public Builder AddPackedBool(bool value) + { + PrepareBuilder(); + result.packedBool_.Add(value); + return this; + } + public Builder AddRangePackedBool(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedBool_.Add(values); + return this; + } + public Builder ClearPackedBool() + { + PrepareBuilder(); + result.packedBool_.Clear(); + return this; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable; } + public pbc::IPopsicleList PackedEnumList + { + get { return PrepareBuilder().packedEnum_; } + } + public int PackedEnumCount + { + get { return result.PackedEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetPackedEnum(int index) + { + return result.GetPackedEnum(index); + } + public Builder SetPackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.packedEnum_[index] = value; + return this; + } + public Builder AddPackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.packedEnum_.Add(value); + return this; + } + public Builder AddRangePackedEnum(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedEnum_.Add(values); + return this; + } + public Builder ClearPackedEnum() + { + PrepareBuilder(); + result.packedEnum_.Clear(); + return this; + } + } + static TestPackedTypes() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } - #region Nested types [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NestedMessage : pb::GeneratedMessage { - private NestedMessage() { } - private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); - private static readonly string[] _nestedMessageFieldNames = new string[] { "nestedmessage_repeated_foreignmessage", "nestedmessage_repeated_int32" }; - private static readonly uint[] _nestedMessageFieldTags = new uint[] { 18, 8 }; - public static NestedMessage DefaultInstance { - get { return defaultInstance; } + public sealed partial class TestUnpackedTypes : pb::GeneratedMessage + { + private TestUnpackedTypes() { } + private static readonly TestUnpackedTypes defaultInstance = new TestUnpackedTypes().MakeReadOnly(); + private static readonly string[] _testUnpackedTypesFieldNames = new string[] { "unpacked_bool", "unpacked_double", "unpacked_enum", "unpacked_fixed32", "unpacked_fixed64", "unpacked_float", "unpacked_int32", "unpacked_int64", "unpacked_sfixed32", "unpacked_sfixed64", "unpacked_sint32", "unpacked_sint64", "unpacked_uint32", "unpacked_uint64" }; + private static readonly uint[] _testUnpackedTypesFieldTags = new uint[] { 816, 809, 824, 773, 777, 805, 720, 728, 789, 793, 752, 760, 736, 744 }; + public static TestUnpackedTypes DefaultInstance + { + get { return defaultInstance; } } - public override NestedMessage DefaultInstanceForType { - get { return DefaultInstance; } + public override TestUnpackedTypes DefaultInstanceForType + { + get { return DefaultInstance; } } - protected override NestedMessage ThisMessage { - get { return this; } + protected override TestUnpackedTypes ThisMessage + { + get { return this; } } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor; } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor; } } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable; } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable; } } - public const int NestedmessageRepeatedInt32FieldNumber = 1; - private pbc::PopsicleList nestedmessageRepeatedInt32_ = new pbc::PopsicleList(); - public scg::IList NestedmessageRepeatedInt32List { - get { return pbc::Lists.AsReadOnly(nestedmessageRepeatedInt32_); } + public const int UnpackedInt32FieldNumber = 90; + private pbc::PopsicleList unpackedInt32_ = new pbc::PopsicleList(); + public scg::IList UnpackedInt32List + { + get { return pbc::Lists.AsReadOnly(unpackedInt32_); } } - public int NestedmessageRepeatedInt32Count { - get { return nestedmessageRepeatedInt32_.Count; } + public int UnpackedInt32Count + { + get { return unpackedInt32_.Count; } } - public int GetNestedmessageRepeatedInt32(int index) { - return nestedmessageRepeatedInt32_[index]; + public int GetUnpackedInt32(int index) + { + return unpackedInt32_[index]; } - public const int NestedmessageRepeatedForeignmessageFieldNumber = 2; - private pbc::PopsicleList nestedmessageRepeatedForeignmessage_ = new pbc::PopsicleList(); - public scg::IList NestedmessageRepeatedForeignmessageList { - get { return nestedmessageRepeatedForeignmessage_; } + public const int UnpackedInt64FieldNumber = 91; + private pbc::PopsicleList unpackedInt64_ = new pbc::PopsicleList(); + public scg::IList UnpackedInt64List + { + get { return pbc::Lists.AsReadOnly(unpackedInt64_); } } - public int NestedmessageRepeatedForeignmessageCount { - get { return nestedmessageRepeatedForeignmessage_.Count; } + public int UnpackedInt64Count + { + get { return unpackedInt64_.Count; } } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetNestedmessageRepeatedForeignmessage(int index) { - return nestedmessageRepeatedForeignmessage_[index]; + public long GetUnpackedInt64(int index) + { + return unpackedInt64_[index]; } - public override bool IsInitialized { - get { - return true; - } + public const int UnpackedUint32FieldNumber = 92; + private pbc::PopsicleList unpackedUint32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedUint32List + { + get { return pbc::Lists.AsReadOnly(unpackedUint32_); } } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _nestedMessageFieldNames; - if (nestedmessageRepeatedInt32_.Count > 0) { - output.WriteInt32Array(1, field_names[1], nestedmessageRepeatedInt32_); - } - if (nestedmessageRepeatedForeignmessage_.Count > 0) { - output.WriteMessageArray(2, field_names[0], nestedmessageRepeatedForeignmessage_); - } - UnknownFields.WriteTo(output); + public int UnpackedUint32Count + { + get { return unpackedUint32_.Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedUint32(int index) + { + return unpackedUint32_[index]; } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } + public const int UnpackedUint64FieldNumber = 93; + private pbc::PopsicleList unpackedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedUint64List + { + get { return pbc::Lists.AsReadOnly(unpackedUint64_); } + } + public int UnpackedUint64Count + { + get { return unpackedUint64_.Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedUint64(int index) + { + return unpackedUint64_[index]; } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public const int UnpackedSint32FieldNumber = 94; + private pbc::PopsicleList unpackedSint32_ = new pbc::PopsicleList(); + public scg::IList UnpackedSint32List + { + get { return pbc::Lists.AsReadOnly(unpackedSint32_); } + } + public int UnpackedSint32Count + { + get { return unpackedSint32_.Count; } + } + public int GetUnpackedSint32(int index) + { + return unpackedSint32_[index]; + } - size = 0; - { - int dataSize = 0; - foreach (int element in NestedmessageRepeatedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 1 * nestedmessageRepeatedInt32_.Count; - } - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in NestedmessageRepeatedForeignmessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(2, element); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; + public const int UnpackedSint64FieldNumber = 95; + private pbc::PopsicleList unpackedSint64_ = new pbc::PopsicleList(); + public scg::IList UnpackedSint64List + { + get { return pbc::Lists.AsReadOnly(unpackedSint64_); } } - public static NestedMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public int UnpackedSint64Count + { + get { return unpackedSint64_.Count; } } - public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public long GetUnpackedSint64(int index) + { + return unpackedSint64_[index]; } - public static NestedMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + + public const int UnpackedFixed32FieldNumber = 96; + private pbc::PopsicleList unpackedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedFixed32List + { + get { return pbc::Lists.AsReadOnly(unpackedFixed32_); } } - public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public int UnpackedFixed32Count + { + get { return unpackedFixed32_.Count; } } - public static NestedMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + [global::System.CLSCompliant(false)] + public uint GetUnpackedFixed32(int index) + { + return unpackedFixed32_[index]; } - public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + + public const int UnpackedFixed64FieldNumber = 97; + private pbc::PopsicleList unpackedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList UnpackedFixed64List + { + get { return pbc::Lists.AsReadOnly(unpackedFixed64_); } } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + public int UnpackedFixed64Count + { + get { return unpackedFixed64_.Count; } } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + [global::System.CLSCompliant(false)] + public ulong GetUnpackedFixed64(int index) + { + return unpackedFixed64_[index]; } - public static NestedMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + + public const int UnpackedSfixed32FieldNumber = 98; + private pbc::PopsicleList unpackedSfixed32_ = new pbc::PopsicleList(); + public scg::IList UnpackedSfixed32List + { + get { return pbc::Lists.AsReadOnly(unpackedSfixed32_); } } - public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public int UnpackedSfixed32Count + { + get { return unpackedSfixed32_.Count; } } - private NestedMessage MakeReadOnly() { - nestedmessageRepeatedInt32_.MakeReadOnly(); - nestedmessageRepeatedForeignmessage_.MakeReadOnly(); - return this; + public int GetUnpackedSfixed32(int index) + { + return unpackedSfixed32_[index]; } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NestedMessage prototype) { - return new Builder(prototype); + public const int UnpackedSfixed64FieldNumber = 99; + private pbc::PopsicleList unpackedSfixed64_ = new pbc::PopsicleList(); + public scg::IList UnpackedSfixed64List + { + get { return pbc::Lists.AsReadOnly(unpackedSfixed64_); } + } + public int UnpackedSfixed64Count + { + get { return unpackedSfixed64_.Count; } + } + public long GetUnpackedSfixed64(int index) + { + return unpackedSfixed64_[index]; } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NestedMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NestedMessage result; - - private NestedMessage PrepareBuilder() { - if (resultIsReadOnly) { - NestedMessage original = result; - result = new NestedMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NestedMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + public const int UnpackedFloatFieldNumber = 100; + private pbc::PopsicleList unpackedFloat_ = new pbc::PopsicleList(); + public scg::IList UnpackedFloatList + { + get { return pbc::Lists.AsReadOnly(unpackedFloat_); } + } + public int UnpackedFloatCount + { + get { return unpackedFloat_.Count; } + } + public float GetUnpackedFloat(int index) + { + return unpackedFloat_[index]; + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } + public const int UnpackedDoubleFieldNumber = 101; + private pbc::PopsicleList unpackedDouble_ = new pbc::PopsicleList(); + public scg::IList UnpackedDoubleList + { + get { return pbc::Lists.AsReadOnly(unpackedDouble_); } + } + public int UnpackedDoubleCount + { + get { return unpackedDouble_.Count; } + } + public double GetUnpackedDouble(int index) + { + return unpackedDouble_[index]; + } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Descriptor; } - } + public const int UnpackedBoolFieldNumber = 102; + private pbc::PopsicleList unpackedBool_ = new pbc::PopsicleList(); + public scg::IList UnpackedBoolList + { + get { return pbc::Lists.AsReadOnly(unpackedBool_); } + } + public int UnpackedBoolCount + { + get { return unpackedBool_.Count; } + } + public bool GetUnpackedBool(int index) + { + return unpackedBool_[index]; + } - public override NestedMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance; } - } + public const int UnpackedEnumFieldNumber = 103; + private pbc::PopsicleList unpackedEnum_ = new pbc::PopsicleList(); + public scg::IList UnpackedEnumList + { + get { return pbc::Lists.AsReadOnly(unpackedEnum_); } + } + public int UnpackedEnumCount + { + get { return unpackedEnum_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetUnpackedEnum(int index) + { + return unpackedEnum_[index]; + } - public override NestedMessage BuildPartial() { - if (resultIsReadOnly) { - return result; + public override bool IsInitialized + { + get + { + return true; } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } + } - public override Builder MergeFrom(pb::IMessage other) { - if (other is NestedMessage) { - return MergeFrom((NestedMessage) other); - } else { - base.MergeFrom(other); - return this; + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testUnpackedTypesFieldNames; + if (unpackedInt32_.Count > 0) + { + output.WriteInt32Array(90, field_names[6], unpackedInt32_); } - } - - public override Builder MergeFrom(NestedMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.nestedmessageRepeatedInt32_.Count != 0) { - result.nestedmessageRepeatedInt32_.Add(other.nestedmessageRepeatedInt32_); + if (unpackedInt64_.Count > 0) + { + output.WriteInt64Array(91, field_names[7], unpackedInt64_); } - if (other.nestedmessageRepeatedForeignmessage_.Count != 0) { - result.nestedmessageRepeatedForeignmessage_.Add(other.nestedmessageRepeatedForeignmessage_); + if (unpackedUint32_.Count > 0) + { + output.WriteUInt32Array(92, field_names[12], unpackedUint32_); } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _nestedMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: - case 8: { - input.ReadInt32Array(tag, field_name, result.nestedmessageRepeatedInt32_); - break; - } - case 18: { - input.ReadMessageArray(tag, field_name, result.nestedmessageRepeatedForeignmessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); - break; - } - } + if (unpackedUint64_.Count > 0) + { + output.WriteUInt64Array(93, field_names[13], unpackedUint64_); } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + if (unpackedSint32_.Count > 0) + { + output.WriteSInt32Array(94, field_names[10], unpackedSint32_); } - return this; - } - - - public pbc::IPopsicleList NestedmessageRepeatedInt32List { - get { return PrepareBuilder().nestedmessageRepeatedInt32_; } - } - public int NestedmessageRepeatedInt32Count { - get { return result.NestedmessageRepeatedInt32Count; } - } - public int GetNestedmessageRepeatedInt32(int index) { - return result.GetNestedmessageRepeatedInt32(index); - } - public Builder SetNestedmessageRepeatedInt32(int index, int value) { - PrepareBuilder(); - result.nestedmessageRepeatedInt32_[index] = value; - return this; - } - public Builder AddNestedmessageRepeatedInt32(int value) { - PrepareBuilder(); - result.nestedmessageRepeatedInt32_.Add(value); - return this; - } - public Builder AddRangeNestedmessageRepeatedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.nestedmessageRepeatedInt32_.Add(values); - return this; - } - public Builder ClearNestedmessageRepeatedInt32() { - PrepareBuilder(); - result.nestedmessageRepeatedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList NestedmessageRepeatedForeignmessageList { - get { return PrepareBuilder().nestedmessageRepeatedForeignmessage_; } - } - public int NestedmessageRepeatedForeignmessageCount { - get { return result.NestedmessageRepeatedForeignmessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetNestedmessageRepeatedForeignmessage(int index) { - return result.GetNestedmessageRepeatedForeignmessage(index); - } - public Builder SetNestedmessageRepeatedForeignmessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_[index] = value; - return this; - } - public Builder SetNestedmessageRepeatedForeignmessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddNestedmessageRepeatedForeignmessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_.Add(value); - return this; - } - public Builder AddNestedmessageRepeatedForeignmessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeNestedmessageRepeatedForeignmessage(scg::IEnumerable values) { - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_.Add(values); - return this; - } - public Builder ClearNestedmessageRepeatedForeignmessage() { - PrepareBuilder(); - result.nestedmessageRepeatedForeignmessage_.Clear(); - return this; - } - } - static NestedMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + if (unpackedSint64_.Count > 0) + { + output.WriteSInt64Array(95, field_names[11], unpackedSint64_); + } + if (unpackedFixed32_.Count > 0) + { + output.WriteFixed32Array(96, field_names[3], unpackedFixed32_); + } + if (unpackedFixed64_.Count > 0) + { + output.WriteFixed64Array(97, field_names[4], unpackedFixed64_); + } + if (unpackedSfixed32_.Count > 0) + { + output.WriteSFixed32Array(98, field_names[8], unpackedSfixed32_); + } + if (unpackedSfixed64_.Count > 0) + { + output.WriteSFixed64Array(99, field_names[9], unpackedSfixed64_); + } + if (unpackedFloat_.Count > 0) + { + output.WriteFloatArray(100, field_names[5], unpackedFloat_); + } + if (unpackedDouble_.Count > 0) + { + output.WriteDoubleArray(101, field_names[1], unpackedDouble_); + } + if (unpackedBool_.Count > 0) + { + output.WriteBoolArray(102, field_names[0], unpackedBool_); + } + if (unpackedEnum_.Count > 0) + { + output.WriteEnumArray(103, field_names[2], unpackedEnum_); + } + UnknownFields.WriteTo(output); } - } - - } - #endregion - - public const int OptionalNestedMessageFieldNumber = 1; - private bool hasOptionalNestedMessage; - private global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage optionalNestedMessage_; - public bool HasOptionalNestedMessage { - get { return hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage OptionalNestedMessage { - get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testNestedMessageHasBitsFieldNames; - if (hasOptionalNestedMessage) { - output.WriteMessage(1, field_names[0], OptionalNestedMessage); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasOptionalNestedMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(1, OptionalNestedMessage); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestNestedMessageHasBits ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestNestedMessageHasBits ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestNestedMessageHasBits ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestNestedMessageHasBits MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestNestedMessageHasBits prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestNestedMessageHasBits cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestNestedMessageHasBits result; - - private TestNestedMessageHasBits PrepareBuilder() { - if (resultIsReadOnly) { - TestNestedMessageHasBits original = result; - result = new TestNestedMessageHasBits(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestNestedMessageHasBits MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Descriptor; } - } - - public override TestNestedMessageHasBits DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.DefaultInstance; } - } - - public override TestNestedMessageHasBits BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestNestedMessageHasBits) { - return MergeFrom((TestNestedMessageHasBits) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestNestedMessageHasBits other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasOptionalNestedMessage) { - MergeOptionalNestedMessage(other.OptionalNestedMessage); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testNestedMessageHasBitsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testNestedMessageHasBitsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.CreateBuilder(); - if (result.hasOptionalNestedMessage) { - subBuilder.MergeFrom(OptionalNestedMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalNestedMessage = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasOptionalNestedMessage { - get { return result.hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage OptionalNestedMessage { - get { return result.OptionalNestedMessage; } - set { SetOptionalNestedMessage(value); } - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = value; - return this; - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalNestedMessage && - result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance) { - result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalNestedMessage_ = value; - } - result.hasOptionalNestedMessage = true; - return this; - } - public Builder ClearOptionalNestedMessage() { - PrepareBuilder(); - result.hasOptionalNestedMessage = false; - result.optionalNestedMessage_ = null; - return this; - } - } - static TestNestedMessageHasBits() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestCamelCaseFieldNames : pb::GeneratedMessage { - private TestCamelCaseFieldNames() { } - private static readonly TestCamelCaseFieldNames defaultInstance = new TestCamelCaseFieldNames().MakeReadOnly(); - private static readonly string[] _testCamelCaseFieldNamesFieldNames = new string[] { "CordField", "EnumField", "MessageField", "PrimitiveField", "RepeatedCordField", "RepeatedEnumField", "RepeatedMessageField", "RepeatedPrimitiveField", "RepeatedStringField", "RepeatedStringPieceField", "StringField", "StringPieceField" }; - private static readonly uint[] _testCamelCaseFieldNamesFieldTags = new uint[] { 50, 24, 34, 8, 98, 72, 82, 56, 66, 90, 18, 42 }; - public static TestCamelCaseFieldNames DefaultInstance { - get { return defaultInstance; } - } - - public override TestCamelCaseFieldNames DefaultInstanceForType { - get { return DefaultInstance; } - } - protected override TestCamelCaseFieldNames ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable; } - } - - public const int PrimitiveFieldFieldNumber = 1; - private bool hasPrimitiveField; - private int primitiveField_; - public bool HasPrimitiveField { - get { return hasPrimitiveField; } - } - public int PrimitiveField { - get { return primitiveField_; } - } - - public const int StringFieldFieldNumber = 2; - private bool hasStringField; - private string stringField_ = ""; - public bool HasStringField { - get { return hasStringField; } - } - public string StringField { - get { return stringField_; } - } - - public const int EnumFieldFieldNumber = 3; - private bool hasEnumField; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnum enumField_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - public bool HasEnumField { - get { return hasEnumField; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumField { - get { return enumField_; } - } - - public const int MessageFieldFieldNumber = 4; - private bool hasMessageField; - private global::Google.ProtocolBuffers.TestProtos.ForeignMessage messageField_; - public bool HasMessageField { - get { return hasMessageField; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageField { - get { return messageField_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } - } - - public const int StringPieceFieldFieldNumber = 5; - private bool hasStringPieceField; - private string stringPieceField_ = ""; - public bool HasStringPieceField { - get { return hasStringPieceField; } - } - public string StringPieceField { - get { return stringPieceField_; } - } - - public const int CordFieldFieldNumber = 6; - private bool hasCordField; - private string cordField_ = ""; - public bool HasCordField { - get { return hasCordField; } - } - public string CordField { - get { return cordField_; } - } - - public const int RepeatedPrimitiveFieldFieldNumber = 7; - private pbc::PopsicleList repeatedPrimitiveField_ = new pbc::PopsicleList(); - public scg::IList RepeatedPrimitiveFieldList { - get { return pbc::Lists.AsReadOnly(repeatedPrimitiveField_); } - } - public int RepeatedPrimitiveFieldCount { - get { return repeatedPrimitiveField_.Count; } - } - public int GetRepeatedPrimitiveField(int index) { - return repeatedPrimitiveField_[index]; - } - - public const int RepeatedStringFieldFieldNumber = 8; - private pbc::PopsicleList repeatedStringField_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringFieldList { - get { return pbc::Lists.AsReadOnly(repeatedStringField_); } - } - public int RepeatedStringFieldCount { - get { return repeatedStringField_.Count; } - } - public string GetRepeatedStringField(int index) { - return repeatedStringField_[index]; - } - - public const int RepeatedEnumFieldFieldNumber = 9; - private pbc::PopsicleList repeatedEnumField_ = new pbc::PopsicleList(); - public scg::IList RepeatedEnumFieldList { - get { return pbc::Lists.AsReadOnly(repeatedEnumField_); } - } - public int RepeatedEnumFieldCount { - get { return repeatedEnumField_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedEnumField(int index) { - return repeatedEnumField_[index]; - } - - public const int RepeatedMessageFieldFieldNumber = 10; - private pbc::PopsicleList repeatedMessageField_ = new pbc::PopsicleList(); - public scg::IList RepeatedMessageFieldList { - get { return repeatedMessageField_; } - } - public int RepeatedMessageFieldCount { - get { return repeatedMessageField_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedMessageField(int index) { - return repeatedMessageField_[index]; - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public const int RepeatedStringPieceFieldFieldNumber = 11; - private pbc::PopsicleList repeatedStringPieceField_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringPieceFieldList { - get { return pbc::Lists.AsReadOnly(repeatedStringPieceField_); } - } - public int RepeatedStringPieceFieldCount { - get { return repeatedStringPieceField_.Count; } - } - public string GetRepeatedStringPieceField(int index) { - return repeatedStringPieceField_[index]; - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public const int RepeatedCordFieldFieldNumber = 12; - private pbc::PopsicleList repeatedCordField_ = new pbc::PopsicleList(); - public scg::IList RepeatedCordFieldList { - get { return pbc::Lists.AsReadOnly(repeatedCordField_); } - } - public int RepeatedCordFieldCount { - get { return repeatedCordField_.Count; } - } - public string GetRepeatedCordField(int index) { - return repeatedCordField_[index]; - } + size = 0; + { + int dataSize = 0; + foreach (int element in UnpackedInt32List) + { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedInt32_.Count; + } + { + int dataSize = 0; + foreach (long element in UnpackedInt64List) + { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedInt64_.Count; + } + { + int dataSize = 0; + foreach (uint element in UnpackedUint32List) + { + dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedUint32_.Count; + } + { + int dataSize = 0; + foreach (ulong element in UnpackedUint64List) + { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedUint64_.Count; + } + { + int dataSize = 0; + foreach (int element in UnpackedSint32List) + { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedSint32_.Count; + } + { + int dataSize = 0; + foreach (long element in UnpackedSint64List) + { + dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * unpackedSint64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * unpackedFixed32_.Count; + size += dataSize; + size += 2 * unpackedFixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * unpackedFixed64_.Count; + size += dataSize; + size += 2 * unpackedFixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * unpackedSfixed32_.Count; + size += dataSize; + size += 2 * unpackedSfixed32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * unpackedSfixed64_.Count; + size += dataSize; + size += 2 * unpackedSfixed64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * unpackedFloat_.Count; + size += dataSize; + size += 2 * unpackedFloat_.Count; + } + { + int dataSize = 0; + dataSize = 8 * unpackedDouble_.Count; + size += dataSize; + size += 2 * unpackedDouble_.Count; + } + { + int dataSize = 0; + dataSize = 1 * unpackedBool_.Count; + size += dataSize; + size += 2 * unpackedBool_.Count; + } + { + int dataSize = 0; + if (unpackedEnum_.Count > 0) + { + foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in unpackedEnum_) + { + dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int)element); + } + size += dataSize; + size += 2 * unpackedEnum_.Count; + } + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestUnpackedTypes ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedTypes ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestUnpackedTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestUnpackedTypes MakeReadOnly() + { + unpackedInt32_.MakeReadOnly(); + unpackedInt64_.MakeReadOnly(); + unpackedUint32_.MakeReadOnly(); + unpackedUint64_.MakeReadOnly(); + unpackedSint32_.MakeReadOnly(); + unpackedSint64_.MakeReadOnly(); + unpackedFixed32_.MakeReadOnly(); + unpackedFixed64_.MakeReadOnly(); + unpackedSfixed32_.MakeReadOnly(); + unpackedSfixed64_.MakeReadOnly(); + unpackedFloat_.MakeReadOnly(); + unpackedDouble_.MakeReadOnly(); + unpackedBool_.MakeReadOnly(); + unpackedEnum_.MakeReadOnly(); + return this; + } - public override bool IsInitialized { - get { - return true; - } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestUnpackedTypes prototype) + { + return new Builder(prototype); + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testCamelCaseFieldNamesFieldNames; - if (hasPrimitiveField) { - output.WriteInt32(1, field_names[3], PrimitiveField); - } - if (hasStringField) { - output.WriteString(2, field_names[10], StringField); - } - if (hasEnumField) { - output.WriteEnum(3, field_names[1], (int) EnumField, EnumField); - } - if (hasMessageField) { - output.WriteMessage(4, field_names[2], MessageField); - } - if (hasStringPieceField) { - output.WriteString(5, field_names[11], StringPieceField); - } - if (hasCordField) { - output.WriteString(6, field_names[0], CordField); - } - if (repeatedPrimitiveField_.Count > 0) { - output.WriteInt32Array(7, field_names[7], repeatedPrimitiveField_); - } - if (repeatedStringField_.Count > 0) { - output.WriteStringArray(8, field_names[8], repeatedStringField_); - } - if (repeatedEnumField_.Count > 0) { - output.WriteEnumArray(9, field_names[5], repeatedEnumField_); - } - if (repeatedMessageField_.Count > 0) { - output.WriteMessageArray(10, field_names[6], repeatedMessageField_); - } - if (repeatedStringPieceField_.Count > 0) { - output.WriteStringArray(11, field_names[9], repeatedStringPieceField_); - } - if (repeatedCordField_.Count > 0) { - output.WriteStringArray(12, field_names[4], repeatedCordField_); - } - UnknownFields.WriteTo(output); - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestUnpackedTypes cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + private bool resultIsReadOnly; + private TestUnpackedTypes result; - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasPrimitiveField) { - size += pb::CodedOutputStream.ComputeInt32Size(1, PrimitiveField); - } - if (hasStringField) { - size += pb::CodedOutputStream.ComputeStringSize(2, StringField); - } - if (hasEnumField) { - size += pb::CodedOutputStream.ComputeEnumSize(3, (int) EnumField); - } - if (hasMessageField) { - size += pb::CodedOutputStream.ComputeMessageSize(4, MessageField); - } - if (hasStringPieceField) { - size += pb::CodedOutputStream.ComputeStringSize(5, StringPieceField); - } - if (hasCordField) { - size += pb::CodedOutputStream.ComputeStringSize(6, CordField); - } - { - int dataSize = 0; - foreach (int element in RepeatedPrimitiveFieldList) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 1 * repeatedPrimitiveField_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedStringFieldList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 1 * repeatedStringField_.Count; - } - { - int dataSize = 0; - if (repeatedEnumField_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedEnumField_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * repeatedEnumField_.Count; - } - } - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedMessageFieldList) { - size += pb::CodedOutputStream.ComputeMessageSize(10, element); - } - { - int dataSize = 0; - foreach (string element in RepeatedStringPieceFieldList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 1 * repeatedStringPieceField_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedCordFieldList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 1 * repeatedCordField_.Count; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestCamelCaseFieldNames ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestCamelCaseFieldNames ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestCamelCaseFieldNames MakeReadOnly() { - repeatedPrimitiveField_.MakeReadOnly(); - repeatedStringField_.MakeReadOnly(); - repeatedEnumField_.MakeReadOnly(); - repeatedMessageField_.MakeReadOnly(); - repeatedStringPieceField_.MakeReadOnly(); - repeatedCordField_.MakeReadOnly(); - return this; - } + private TestUnpackedTypes PrepareBuilder() + { + if (resultIsReadOnly) + { + TestUnpackedTypes original = result; + result = new TestUnpackedTypes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestCamelCaseFieldNames prototype) { - return new Builder(prototype); - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestCamelCaseFieldNames cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestCamelCaseFieldNames result; - - private TestCamelCaseFieldNames PrepareBuilder() { - if (resultIsReadOnly) { - TestCamelCaseFieldNames original = result; - result = new TestCamelCaseFieldNames(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestCamelCaseFieldNames MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.Descriptor; } - } - - public override TestCamelCaseFieldNames DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.DefaultInstance; } - } - - public override TestCamelCaseFieldNames BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestCamelCaseFieldNames) { - return MergeFrom((TestCamelCaseFieldNames) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestCamelCaseFieldNames other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasPrimitiveField) { - PrimitiveField = other.PrimitiveField; - } - if (other.HasStringField) { - StringField = other.StringField; - } - if (other.HasEnumField) { - EnumField = other.EnumField; - } - if (other.HasMessageField) { - MergeMessageField(other.MessageField); - } - if (other.HasStringPieceField) { - StringPieceField = other.StringPieceField; - } - if (other.HasCordField) { - CordField = other.CordField; - } - if (other.repeatedPrimitiveField_.Count != 0) { - result.repeatedPrimitiveField_.Add(other.repeatedPrimitiveField_); - } - if (other.repeatedStringField_.Count != 0) { - result.repeatedStringField_.Add(other.repeatedStringField_); - } - if (other.repeatedEnumField_.Count != 0) { - result.repeatedEnumField_.Add(other.repeatedEnumField_); - } - if (other.repeatedMessageField_.Count != 0) { - result.repeatedMessageField_.Add(other.repeatedMessageField_); - } - if (other.repeatedStringPieceField_.Count != 0) { - result.repeatedStringPieceField_.Add(other.repeatedStringPieceField_); - } - if (other.repeatedCordField_.Count != 0) { - result.repeatedCordField_.Add(other.repeatedCordField_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testCamelCaseFieldNamesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testCamelCaseFieldNamesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasPrimitiveField = input.ReadInt32(ref result.primitiveField_); - break; - } - case 18: { - result.hasStringField = input.ReadString(ref result.stringField_); - break; - } - case 24: { - object unknown; - if(input.ReadEnum(ref result.enumField_, out unknown)) { - result.hasEnumField = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(3, (ulong)(int)unknown); - } - break; - } - case 34: { - global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); - if (result.hasMessageField) { - subBuilder.MergeFrom(MessageField); - } - input.ReadMessage(subBuilder, extensionRegistry); - MessageField = subBuilder.BuildPartial(); - break; - } - case 42: { - result.hasStringPieceField = input.ReadString(ref result.stringPieceField_); - break; - } - case 50: { - result.hasCordField = input.ReadString(ref result.cordField_); - break; - } - case 58: - case 56: { - input.ReadInt32Array(tag, field_name, result.repeatedPrimitiveField_); - break; - } - case 66: { - input.ReadStringArray(tag, field_name, result.repeatedStringField_); - break; - } - case 74: - case 72: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedEnumField_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(9, (ulong)(int)rawValue); - } - break; - } - case 82: { - input.ReadMessageArray(tag, field_name, result.repeatedMessageField_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); - break; - } - case 90: { - input.ReadStringArray(tag, field_name, result.repeatedStringPieceField_); - break; - } - case 98: { - input.ReadStringArray(tag, field_name, result.repeatedCordField_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasPrimitiveField { - get { return result.hasPrimitiveField; } - } - public int PrimitiveField { - get { return result.PrimitiveField; } - set { SetPrimitiveField(value); } - } - public Builder SetPrimitiveField(int value) { - PrepareBuilder(); - result.hasPrimitiveField = true; - result.primitiveField_ = value; - return this; - } - public Builder ClearPrimitiveField() { - PrepareBuilder(); - result.hasPrimitiveField = false; - result.primitiveField_ = 0; - return this; - } - - public bool HasStringField { - get { return result.hasStringField; } - } - public string StringField { - get { return result.StringField; } - set { SetStringField(value); } - } - public Builder SetStringField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasStringField = true; - result.stringField_ = value; - return this; - } - public Builder ClearStringField() { - PrepareBuilder(); - result.hasStringField = false; - result.stringField_ = ""; - return this; - } - - public bool HasEnumField { - get { return result.hasEnumField; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumField { - get { return result.EnumField; } - set { SetEnumField(value); } - } - public Builder SetEnumField(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.hasEnumField = true; - result.enumField_ = value; - return this; - } - public Builder ClearEnumField() { - PrepareBuilder(); - result.hasEnumField = false; - result.enumField_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - return this; - } - - public bool HasMessageField { - get { return result.hasMessageField; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageField { - get { return result.MessageField; } - set { SetMessageField(value); } - } - public Builder SetMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasMessageField = true; - result.messageField_ = value; - return this; - } - public Builder SetMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasMessageField = true; - result.messageField_ = builderForValue.Build(); - return this; - } - public Builder MergeMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasMessageField && - result.messageField_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) { - result.messageField_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.messageField_).MergeFrom(value).BuildPartial(); - } else { - result.messageField_ = value; - } - result.hasMessageField = true; - return this; - } - public Builder ClearMessageField() { - PrepareBuilder(); - result.hasMessageField = false; - result.messageField_ = null; - return this; - } - - public bool HasStringPieceField { - get { return result.hasStringPieceField; } - } - public string StringPieceField { - get { return result.StringPieceField; } - set { SetStringPieceField(value); } - } - public Builder SetStringPieceField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasStringPieceField = true; - result.stringPieceField_ = value; - return this; - } - public Builder ClearStringPieceField() { - PrepareBuilder(); - result.hasStringPieceField = false; - result.stringPieceField_ = ""; - return this; - } - - public bool HasCordField { - get { return result.hasCordField; } - } - public string CordField { - get { return result.CordField; } - set { SetCordField(value); } - } - public Builder SetCordField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasCordField = true; - result.cordField_ = value; - return this; - } - public Builder ClearCordField() { - PrepareBuilder(); - result.hasCordField = false; - result.cordField_ = ""; - return this; - } - - public pbc::IPopsicleList RepeatedPrimitiveFieldList { - get { return PrepareBuilder().repeatedPrimitiveField_; } - } - public int RepeatedPrimitiveFieldCount { - get { return result.RepeatedPrimitiveFieldCount; } - } - public int GetRepeatedPrimitiveField(int index) { - return result.GetRepeatedPrimitiveField(index); - } - public Builder SetRepeatedPrimitiveField(int index, int value) { - PrepareBuilder(); - result.repeatedPrimitiveField_[index] = value; - return this; - } - public Builder AddRepeatedPrimitiveField(int value) { - PrepareBuilder(); - result.repeatedPrimitiveField_.Add(value); - return this; - } - public Builder AddRangeRepeatedPrimitiveField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedPrimitiveField_.Add(values); - return this; - } - public Builder ClearRepeatedPrimitiveField() { - PrepareBuilder(); - result.repeatedPrimitiveField_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringFieldList { - get { return PrepareBuilder().repeatedStringField_; } - } - public int RepeatedStringFieldCount { - get { return result.RepeatedStringFieldCount; } - } - public string GetRepeatedStringField(int index) { - return result.GetRepeatedStringField(index); - } - public Builder SetRepeatedStringField(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringField_[index] = value; - return this; - } - public Builder AddRepeatedStringField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringField_.Add(value); - return this; - } - public Builder AddRangeRepeatedStringField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedStringField_.Add(values); - return this; - } - public Builder ClearRepeatedStringField() { - PrepareBuilder(); - result.repeatedStringField_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedEnumFieldList { - get { return PrepareBuilder().repeatedEnumField_; } - } - public int RepeatedEnumFieldCount { - get { return result.RepeatedEnumFieldCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedEnumField(int index) { - return result.GetRepeatedEnumField(index); - } - public Builder SetRepeatedEnumField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.repeatedEnumField_[index] = value; - return this; - } - public Builder AddRepeatedEnumField(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.repeatedEnumField_.Add(value); - return this; - } - public Builder AddRangeRepeatedEnumField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedEnumField_.Add(values); - return this; - } - public Builder ClearRepeatedEnumField() { - PrepareBuilder(); - result.repeatedEnumField_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedMessageFieldList { - get { return PrepareBuilder().repeatedMessageField_; } - } - public int RepeatedMessageFieldCount { - get { return result.RepeatedMessageFieldCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedMessageField(int index) { - return result.GetRepeatedMessageField(index); - } - public Builder SetRepeatedMessageField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedMessageField_[index] = value; - return this; - } - public Builder SetRepeatedMessageField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedMessageField_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedMessageField_.Add(value); - return this; - } - public Builder AddRepeatedMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedMessageField_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedMessageField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedMessageField_.Add(values); - return this; - } - public Builder ClearRepeatedMessageField() { - PrepareBuilder(); - result.repeatedMessageField_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringPieceFieldList { - get { return PrepareBuilder().repeatedStringPieceField_; } - } - public int RepeatedStringPieceFieldCount { - get { return result.RepeatedStringPieceFieldCount; } - } - public string GetRepeatedStringPieceField(int index) { - return result.GetRepeatedStringPieceField(index); - } - public Builder SetRepeatedStringPieceField(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPieceField_[index] = value; - return this; - } - public Builder AddRepeatedStringPieceField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPieceField_.Add(value); - return this; - } - public Builder AddRangeRepeatedStringPieceField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedStringPieceField_.Add(values); - return this; - } - public Builder ClearRepeatedStringPieceField() { - PrepareBuilder(); - result.repeatedStringPieceField_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedCordFieldList { - get { return PrepareBuilder().repeatedCordField_; } - } - public int RepeatedCordFieldCount { - get { return result.RepeatedCordFieldCount; } - } - public string GetRepeatedCordField(int index) { - return result.GetRepeatedCordField(index); - } - public Builder SetRepeatedCordField(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCordField_[index] = value; - return this; - } - public Builder AddRepeatedCordField(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCordField_.Add(value); - return this; - } - public Builder AddRangeRepeatedCordField(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedCordField_.Add(values); - return this; - } - public Builder ClearRepeatedCordField() { - PrepareBuilder(); - result.repeatedCordField_.Clear(); - return this; - } - } - static TestCamelCaseFieldNames() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestFieldOrderings : pb::ExtendableMessage { - private TestFieldOrderings() { } - private static readonly TestFieldOrderings defaultInstance = new TestFieldOrderings().MakeReadOnly(); - private static readonly string[] _testFieldOrderingsFieldNames = new string[] { "my_float", "my_int", "my_string", "optional_nested_message" }; - private static readonly uint[] _testFieldOrderingsFieldTags = new uint[] { 813, 8, 90, 1602 }; - public static TestFieldOrderings DefaultInstance { - get { return defaultInstance; } - } + protected override TestUnpackedTypes MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public override TestFieldOrderings DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - protected override TestFieldOrderings ThisMessage { - get { return this; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings__Descriptor; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.Descriptor; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable; } - } + public override TestUnpackedTypes DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.DefaultInstance; } + } - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NestedMessage : pb::GeneratedMessage { - private NestedMessage() { } - private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); - private static readonly string[] _nestedMessageFieldNames = new string[] { "bb", "oo" }; - private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8, 16 }; - public static NestedMessage DefaultInstance { - get { return defaultInstance; } - } + public override TestUnpackedTypes BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public override NestedMessage DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestUnpackedTypes) + { + return MergeFrom((TestUnpackedTypes)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - protected override NestedMessage ThisMessage { - get { return this; } - } + public override Builder MergeFrom(TestUnpackedTypes other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.DefaultInstance) return this; + PrepareBuilder(); + if (other.unpackedInt32_.Count != 0) + { + result.unpackedInt32_.Add(other.unpackedInt32_); + } + if (other.unpackedInt64_.Count != 0) + { + result.unpackedInt64_.Add(other.unpackedInt64_); + } + if (other.unpackedUint32_.Count != 0) + { + result.unpackedUint32_.Add(other.unpackedUint32_); + } + if (other.unpackedUint64_.Count != 0) + { + result.unpackedUint64_.Add(other.unpackedUint64_); + } + if (other.unpackedSint32_.Count != 0) + { + result.unpackedSint32_.Add(other.unpackedSint32_); + } + if (other.unpackedSint64_.Count != 0) + { + result.unpackedSint64_.Add(other.unpackedSint64_); + } + if (other.unpackedFixed32_.Count != 0) + { + result.unpackedFixed32_.Add(other.unpackedFixed32_); + } + if (other.unpackedFixed64_.Count != 0) + { + result.unpackedFixed64_.Add(other.unpackedFixed64_); + } + if (other.unpackedSfixed32_.Count != 0) + { + result.unpackedSfixed32_.Add(other.unpackedSfixed32_); + } + if (other.unpackedSfixed64_.Count != 0) + { + result.unpackedSfixed64_.Add(other.unpackedSfixed64_); + } + if (other.unpackedFloat_.Count != 0) + { + result.unpackedFloat_.Add(other.unpackedFloat_); + } + if (other.unpackedDouble_.Count != 0) + { + result.unpackedDouble_.Add(other.unpackedDouble_); + } + if (other.unpackedBool_.Count != 0) + { + result.unpackedBool_.Add(other.unpackedBool_); + } + if (other.unpackedEnum_.Count != 0) + { + result.unpackedEnum_.Add(other.unpackedEnum_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__Descriptor; } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestFieldOrderings_NestedMessage__FieldAccessorTable; } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testUnpackedTypesFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testUnpackedTypesFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 722: + case 720: + { + input.ReadInt32Array(tag, field_name, result.unpackedInt32_); + break; + } + case 730: + case 728: + { + input.ReadInt64Array(tag, field_name, result.unpackedInt64_); + break; + } + case 738: + case 736: + { + input.ReadUInt32Array(tag, field_name, result.unpackedUint32_); + break; + } + case 746: + case 744: + { + input.ReadUInt64Array(tag, field_name, result.unpackedUint64_); + break; + } + case 754: + case 752: + { + input.ReadSInt32Array(tag, field_name, result.unpackedSint32_); + break; + } + case 762: + case 760: + { + input.ReadSInt64Array(tag, field_name, result.unpackedSint64_); + break; + } + case 770: + case 773: + { + input.ReadFixed32Array(tag, field_name, result.unpackedFixed32_); + break; + } + case 778: + case 777: + { + input.ReadFixed64Array(tag, field_name, result.unpackedFixed64_); + break; + } + case 786: + case 789: + { + input.ReadSFixed32Array(tag, field_name, result.unpackedSfixed32_); + break; + } + case 794: + case 793: + { + input.ReadSFixed64Array(tag, field_name, result.unpackedSfixed64_); + break; + } + case 802: + case 805: + { + input.ReadFloatArray(tag, field_name, result.unpackedFloat_); + break; + } + case 810: + case 809: + { + input.ReadDoubleArray(tag, field_name, result.unpackedDouble_); + break; + } + case 818: + case 816: + { + input.ReadBoolArray(tag, field_name, result.unpackedBool_); + break; + } + case 826: + case 824: + { + scg::ICollection unknownItems; + input.ReadEnumArray(tag, field_name, result.unpackedEnum_, out unknownItems); + if (unknownItems != null) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + foreach (object rawValue in unknownItems) + if (rawValue is int) + unknownFields.MergeVarintField(103, (ulong)(int)rawValue); + } + break; + } + } + } - public const int OoFieldNumber = 2; - private bool hasOo; - private long oo_; - public bool HasOo { - get { return hasOo; } - } - public long Oo { - get { return oo_; } - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public const int BbFieldNumber = 1; - private bool hasBb; - private int bb_; - public bool HasBb { - get { return hasBb; } - } - public int Bb { - get { return bb_; } - } - public override bool IsInitialized { - get { - return true; - } - } + public pbc::IPopsicleList UnpackedInt32List + { + get { return PrepareBuilder().unpackedInt32_; } + } + public int UnpackedInt32Count + { + get { return result.UnpackedInt32Count; } + } + public int GetUnpackedInt32(int index) + { + return result.GetUnpackedInt32(index); + } + public Builder SetUnpackedInt32(int index, int value) + { + PrepareBuilder(); + result.unpackedInt32_[index] = value; + return this; + } + public Builder AddUnpackedInt32(int value) + { + PrepareBuilder(); + result.unpackedInt32_.Add(value); + return this; + } + public Builder AddRangeUnpackedInt32(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedInt32_.Add(values); + return this; + } + public Builder ClearUnpackedInt32() + { + PrepareBuilder(); + result.unpackedInt32_.Clear(); + return this; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _nestedMessageFieldNames; - if (hasBb) { - output.WriteInt32(1, field_names[0], Bb); - } - if (hasOo) { - output.WriteInt64(2, field_names[1], Oo); - } - UnknownFields.WriteTo(output); - } + public pbc::IPopsicleList UnpackedInt64List + { + get { return PrepareBuilder().unpackedInt64_; } + } + public int UnpackedInt64Count + { + get { return result.UnpackedInt64Count; } + } + public long GetUnpackedInt64(int index) + { + return result.GetUnpackedInt64(index); + } + public Builder SetUnpackedInt64(int index, long value) + { + PrepareBuilder(); + result.unpackedInt64_[index] = value; + return this; + } + public Builder AddUnpackedInt64(long value) + { + PrepareBuilder(); + result.unpackedInt64_.Add(value); + return this; + } + public Builder AddRangeUnpackedInt64(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedInt64_.Add(values); + return this; + } + public Builder ClearUnpackedInt64() + { + PrepareBuilder(); + result.unpackedInt64_.Clear(); + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedUint32List + { + get { return PrepareBuilder().unpackedUint32_; } + } + public int UnpackedUint32Count + { + get { return result.UnpackedUint32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedUint32(int index) + { + return result.GetUnpackedUint32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedUint32(int index, uint value) + { + PrepareBuilder(); + result.unpackedUint32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedUint32(uint value) + { + PrepareBuilder(); + result.unpackedUint32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedUint32(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedUint32_.Add(values); + return this; + } + public Builder ClearUnpackedUint32() + { + PrepareBuilder(); + result.unpackedUint32_.Clear(); + return this; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedUint64List + { + get { return PrepareBuilder().unpackedUint64_; } + } + public int UnpackedUint64Count + { + get { return result.UnpackedUint64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedUint64(int index) + { + return result.GetUnpackedUint64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedUint64(int index, ulong value) + { + PrepareBuilder(); + result.unpackedUint64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedUint64(ulong value) + { + PrepareBuilder(); + result.unpackedUint64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedUint64(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedUint64_.Add(values); + return this; + } + public Builder ClearUnpackedUint64() + { + PrepareBuilder(); + result.unpackedUint64_.Clear(); + return this; + } - size = 0; - if (hasOo) { - size += pb::CodedOutputStream.ComputeInt64Size(2, Oo); - } - if (hasBb) { - size += pb::CodedOutputStream.ComputeInt32Size(1, Bb); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static NestedMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NestedMessage MakeReadOnly() { - return this; - } + public pbc::IPopsicleList UnpackedSint32List + { + get { return PrepareBuilder().unpackedSint32_; } + } + public int UnpackedSint32Count + { + get { return result.UnpackedSint32Count; } + } + public int GetUnpackedSint32(int index) + { + return result.GetUnpackedSint32(index); + } + public Builder SetUnpackedSint32(int index, int value) + { + PrepareBuilder(); + result.unpackedSint32_[index] = value; + return this; + } + public Builder AddUnpackedSint32(int value) + { + PrepareBuilder(); + result.unpackedSint32_.Add(value); + return this; + } + public Builder AddRangeUnpackedSint32(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedSint32_.Add(values); + return this; + } + public Builder ClearUnpackedSint32() + { + PrepareBuilder(); + result.unpackedSint32_.Clear(); + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NestedMessage prototype) { - return new Builder(prototype); - } + public pbc::IPopsicleList UnpackedSint64List + { + get { return PrepareBuilder().unpackedSint64_; } + } + public int UnpackedSint64Count + { + get { return result.UnpackedSint64Count; } + } + public long GetUnpackedSint64(int index) + { + return result.GetUnpackedSint64(index); + } + public Builder SetUnpackedSint64(int index, long value) + { + PrepareBuilder(); + result.unpackedSint64_[index] = value; + return this; + } + public Builder AddUnpackedSint64(long value) + { + PrepareBuilder(); + result.unpackedSint64_.Add(value); + return this; + } + public Builder AddRangeUnpackedSint64(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedSint64_.Add(values); + return this; + } + public Builder ClearUnpackedSint64() + { + PrepareBuilder(); + result.unpackedSint64_.Clear(); + return this; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NestedMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NestedMessage result; - - private NestedMessage PrepareBuilder() { - if (resultIsReadOnly) { - NestedMessage original = result; - result = new NestedMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NestedMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedFixed32List + { + get { return PrepareBuilder().unpackedFixed32_; } + } + public int UnpackedFixed32Count + { + get { return result.UnpackedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetUnpackedFixed32(int index) + { + return result.GetUnpackedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedFixed32(int index, uint value) + { + PrepareBuilder(); + result.unpackedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedFixed32(uint value) + { + PrepareBuilder(); + result.unpackedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedFixed32(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedFixed32_.Add(values); + return this; + } + public Builder ClearUnpackedFixed32() + { + PrepareBuilder(); + result.unpackedFixed32_.Clear(); + return this; + } + + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList UnpackedFixed64List + { + get { return PrepareBuilder().unpackedFixed64_; } + } + public int UnpackedFixed64Count + { + get { return result.UnpackedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetUnpackedFixed64(int index) + { + return result.GetUnpackedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetUnpackedFixed64(int index, ulong value) + { + PrepareBuilder(); + result.unpackedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddUnpackedFixed64(ulong value) + { + PrepareBuilder(); + result.unpackedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeUnpackedFixed64(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedFixed64_.Add(values); + return this; + } + public Builder ClearUnpackedFixed64() + { + PrepareBuilder(); + result.unpackedFixed64_.Clear(); + return this; + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public pbc::IPopsicleList UnpackedSfixed32List + { + get { return PrepareBuilder().unpackedSfixed32_; } + } + public int UnpackedSfixed32Count + { + get { return result.UnpackedSfixed32Count; } + } + public int GetUnpackedSfixed32(int index) + { + return result.GetUnpackedSfixed32(index); + } + public Builder SetUnpackedSfixed32(int index, int value) + { + PrepareBuilder(); + result.unpackedSfixed32_[index] = value; + return this; + } + public Builder AddUnpackedSfixed32(int value) + { + PrepareBuilder(); + result.unpackedSfixed32_.Add(value); + return this; + } + public Builder AddRangeUnpackedSfixed32(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedSfixed32_.Add(values); + return this; + } + public Builder ClearUnpackedSfixed32() + { + PrepareBuilder(); + result.unpackedSfixed32_.Clear(); + return this; } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.Descriptor; } - } - public override NestedMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance; } - } + public pbc::IPopsicleList UnpackedSfixed64List + { + get { return PrepareBuilder().unpackedSfixed64_; } + } + public int UnpackedSfixed64Count + { + get { return result.UnpackedSfixed64Count; } + } + public long GetUnpackedSfixed64(int index) + { + return result.GetUnpackedSfixed64(index); + } + public Builder SetUnpackedSfixed64(int index, long value) + { + PrepareBuilder(); + result.unpackedSfixed64_[index] = value; + return this; + } + public Builder AddUnpackedSfixed64(long value) + { + PrepareBuilder(); + result.unpackedSfixed64_.Add(value); + return this; + } + public Builder AddRangeUnpackedSfixed64(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedSfixed64_.Add(values); + return this; + } + public Builder ClearUnpackedSfixed64() + { + PrepareBuilder(); + result.unpackedSfixed64_.Clear(); + return this; + } - public override NestedMessage BuildPartial() { - if (resultIsReadOnly) { - return result; + public pbc::IPopsicleList UnpackedFloatList + { + get { return PrepareBuilder().unpackedFloat_; } + } + public int UnpackedFloatCount + { + get { return result.UnpackedFloatCount; } + } + public float GetUnpackedFloat(int index) + { + return result.GetUnpackedFloat(index); + } + public Builder SetUnpackedFloat(int index, float value) + { + PrepareBuilder(); + result.unpackedFloat_[index] = value; + return this; + } + public Builder AddUnpackedFloat(float value) + { + PrepareBuilder(); + result.unpackedFloat_.Add(value); + return this; + } + public Builder AddRangeUnpackedFloat(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedFloat_.Add(values); + return this; + } + public Builder ClearUnpackedFloat() + { + PrepareBuilder(); + result.unpackedFloat_.Clear(); + return this; } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - public override Builder MergeFrom(pb::IMessage other) { - if (other is NestedMessage) { - return MergeFrom((NestedMessage) other); - } else { - base.MergeFrom(other); - return this; + public pbc::IPopsicleList UnpackedDoubleList + { + get { return PrepareBuilder().unpackedDouble_; } + } + public int UnpackedDoubleCount + { + get { return result.UnpackedDoubleCount; } + } + public double GetUnpackedDouble(int index) + { + return result.GetUnpackedDouble(index); + } + public Builder SetUnpackedDouble(int index, double value) + { + PrepareBuilder(); + result.unpackedDouble_[index] = value; + return this; + } + public Builder AddUnpackedDouble(double value) + { + PrepareBuilder(); + result.unpackedDouble_.Add(value); + return this; + } + public Builder AddRangeUnpackedDouble(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedDouble_.Add(values); + return this; + } + public Builder ClearUnpackedDouble() + { + PrepareBuilder(); + result.unpackedDouble_.Clear(); + return this; } - } - public override Builder MergeFrom(NestedMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasOo) { - Oo = other.Oo; + public pbc::IPopsicleList UnpackedBoolList + { + get { return PrepareBuilder().unpackedBool_; } } - if (other.HasBb) { - Bb = other.Bb; + public int UnpackedBoolCount + { + get { return result.UnpackedBoolCount; } } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _nestedMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasBb = input.ReadInt32(ref result.bb_); - break; - } - case 16: { - result.hasOo = input.ReadInt64(ref result.oo_); - break; - } - } + public bool GetUnpackedBool(int index) + { + return result.GetUnpackedBool(index); + } + public Builder SetUnpackedBool(int index, bool value) + { + PrepareBuilder(); + result.unpackedBool_[index] = value; + return this; + } + public Builder AddUnpackedBool(bool value) + { + PrepareBuilder(); + result.unpackedBool_.Add(value); + return this; + } + public Builder AddRangeUnpackedBool(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedBool_.Add(values); + return this; + } + public Builder ClearUnpackedBool() + { + PrepareBuilder(); + result.unpackedBool_.Clear(); + return this; } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + public pbc::IPopsicleList UnpackedEnumList + { + get { return PrepareBuilder().unpackedEnum_; } + } + public int UnpackedEnumCount + { + get { return result.UnpackedEnumCount; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetUnpackedEnum(int index) + { + return result.GetUnpackedEnum(index); + } + public Builder SetUnpackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.unpackedEnum_[index] = value; + return this; + } + public Builder AddUnpackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.unpackedEnum_.Add(value); + return this; + } + public Builder AddRangeUnpackedEnum(scg::IEnumerable values) + { + PrepareBuilder(); + result.unpackedEnum_.Add(values); + return this; + } + public Builder ClearUnpackedEnum() + { + PrepareBuilder(); + result.unpackedEnum_.Clear(); + return this; } - return this; - } - - - public bool HasOo { - get { return result.hasOo; } - } - public long Oo { - get { return result.Oo; } - set { SetOo(value); } - } - public Builder SetOo(long value) { - PrepareBuilder(); - result.hasOo = true; - result.oo_ = value; - return this; - } - public Builder ClearOo() { - PrepareBuilder(); - result.hasOo = false; - result.oo_ = 0L; - return this; - } - - public bool HasBb { - get { return result.hasBb; } - } - public int Bb { - get { return result.Bb; } - set { SetBb(value); } - } - public Builder SetBb(int value) { - PrepareBuilder(); - result.hasBb = true; - result.bb_ = value; - return this; - } - public Builder ClearBb() { - PrepareBuilder(); - result.hasBb = false; - result.bb_ = 0; - return this; - } } - static NestedMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + static TestUnpackedTypes() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); } - } - - } - #endregion - - public const int MyStringFieldNumber = 11; - private bool hasMyString; - private string myString_ = ""; - public bool HasMyString { - get { return hasMyString; } - } - public string MyString { - get { return myString_; } - } - - public const int MyIntFieldNumber = 1; - private bool hasMyInt; - private long myInt_; - public bool HasMyInt { - get { return hasMyInt; } - } - public long MyInt { - get { return myInt_; } - } - - public const int MyFloatFieldNumber = 101; - private bool hasMyFloat; - private float myFloat_; - public bool HasMyFloat { - get { return hasMyFloat; } - } - public float MyFloat { - get { return myFloat_; } - } - - public const int OptionalNestedMessageFieldNumber = 200; - private bool hasOptionalNestedMessage; - private global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage optionalNestedMessage_; - public bool HasOptionalNestedMessage { - get { return hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage OptionalNestedMessage { - get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance; } - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testFieldOrderingsFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - if (hasMyInt) { - output.WriteInt64(1, field_names[1], MyInt); - } - extensionWriter.WriteUntil(11, output); - if (hasMyString) { - output.WriteString(11, field_names[2], MyString); - } - extensionWriter.WriteUntil(101, output); - if (hasMyFloat) { - output.WriteFloat(101, field_names[0], MyFloat); - } - if (hasOptionalNestedMessage) { - output.WriteMessage(200, field_names[3], OptionalNestedMessage); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasMyString) { - size += pb::CodedOutputStream.ComputeStringSize(11, MyString); - } - if (hasMyInt) { - size += pb::CodedOutputStream.ComputeInt64Size(1, MyInt); - } - if (hasMyFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(101, MyFloat); - } - if (hasOptionalNestedMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(200, OptionalNestedMessage); - } - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestFieldOrderings ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestFieldOrderings ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestFieldOrderings ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestFieldOrderings ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestFieldOrderings MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestFieldOrderings prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestFieldOrderings cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestFieldOrderings result; - - private TestFieldOrderings PrepareBuilder() { - if (resultIsReadOnly) { - TestFieldOrderings original = result; - result = new TestFieldOrderings(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestFieldOrderings MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Descriptor; } - } - - public override TestFieldOrderings DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.DefaultInstance; } - } - - public override TestFieldOrderings BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestFieldOrderings) { - return MergeFrom((TestFieldOrderings) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestFieldOrderings other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasMyString) { - MyString = other.MyString; - } - if (other.HasMyInt) { - MyInt = other.MyInt; - } - if (other.HasMyFloat) { - MyFloat = other.MyFloat; - } - if (other.HasOptionalNestedMessage) { - MergeOptionalNestedMessage(other.OptionalNestedMessage); - } - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testFieldOrderingsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testFieldOrderingsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasMyInt = input.ReadInt64(ref result.myInt_); - break; - } - case 90: { - result.hasMyString = input.ReadString(ref result.myString_); - break; - } - case 813: { - result.hasMyFloat = input.ReadFloat(ref result.myFloat_); - break; - } - case 1602: { - global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.CreateBuilder(); - if (result.hasOptionalNestedMessage) { - subBuilder.MergeFrom(OptionalNestedMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalNestedMessage = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasMyString { - get { return result.hasMyString; } - } - public string MyString { - get { return result.MyString; } - set { SetMyString(value); } - } - public Builder SetMyString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasMyString = true; - result.myString_ = value; - return this; - } - public Builder ClearMyString() { - PrepareBuilder(); - result.hasMyString = false; - result.myString_ = ""; - return this; - } - - public bool HasMyInt { - get { return result.hasMyInt; } - } - public long MyInt { - get { return result.MyInt; } - set { SetMyInt(value); } - } - public Builder SetMyInt(long value) { - PrepareBuilder(); - result.hasMyInt = true; - result.myInt_ = value; - return this; - } - public Builder ClearMyInt() { - PrepareBuilder(); - result.hasMyInt = false; - result.myInt_ = 0L; - return this; - } - - public bool HasMyFloat { - get { return result.hasMyFloat; } - } - public float MyFloat { - get { return result.MyFloat; } - set { SetMyFloat(value); } - } - public Builder SetMyFloat(float value) { - PrepareBuilder(); - result.hasMyFloat = true; - result.myFloat_ = value; - return this; - } - public Builder ClearMyFloat() { - PrepareBuilder(); - result.hasMyFloat = false; - result.myFloat_ = 0F; - return this; - } - - public bool HasOptionalNestedMessage { - get { return result.hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage OptionalNestedMessage { - get { return result.OptionalNestedMessage; } - set { SetOptionalNestedMessage(value); } - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = value; - return this; - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalNestedMessage && - result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.DefaultInstance) { - result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalNestedMessage_ = value; - } - result.hasOptionalNestedMessage = true; - return this; - } - public Builder ClearOptionalNestedMessage() { - PrepareBuilder(); - result.hasOptionalNestedMessage = false; - result.optionalNestedMessage_ = null; - return this; - } - } - static TestFieldOrderings() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestExtremeDefaultValues : pb::GeneratedMessage { - private TestExtremeDefaultValues() { } - private static readonly TestExtremeDefaultValues defaultInstance = new TestExtremeDefaultValues().MakeReadOnly(); - private static readonly string[] _testExtremeDefaultValuesFieldNames = new string[] { "bytes_with_zero", "cord_with_zero", "cpp_trigraph", "escaped_bytes", "inf_double", "inf_float", "large_float", "large_uint32", "large_uint64", "nan_double", "nan_float", "neg_inf_double", "neg_inf_float", "negative_float", "negative_one_float", "one_float", "really_small_int32", "really_small_int64", "replacement_string", "small_float", "small_int32", "small_int64", "small_negative_float", "string_piece_with_zero", "string_with_zero", "utf8_string", "zero_float" }; - private static readonly uint[] _testExtremeDefaultValuesFieldTags = new uint[] { 194, 210, 162, 10, 113, 141, 101, 16, 24, 129, 157, 121, 149, 93, 85, 69, 168, 176, 218, 77, 32, 40, 109, 202, 186, 50, 61 }; - public static TestExtremeDefaultValues DefaultInstance { - get { return defaultInstance; } - } - - public override TestExtremeDefaultValues DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestExtremeDefaultValues ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable; } - } - - public const int EscapedBytesFieldNumber = 1; - private bool hasEscapedBytes; - private pb::ByteString escapedBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[0].DefaultValue; - public bool HasEscapedBytes { - get { return hasEscapedBytes; } - } - public pb::ByteString EscapedBytes { - get { return escapedBytes_; } - } - - public const int LargeUint32FieldNumber = 2; - private bool hasLargeUint32; - private uint largeUint32_ = 4294967295; - public bool HasLargeUint32 { - get { return hasLargeUint32; } - } - [global::System.CLSCompliant(false)] - public uint LargeUint32 { - get { return largeUint32_; } - } - - public const int LargeUint64FieldNumber = 3; - private bool hasLargeUint64; - private ulong largeUint64_ = 18446744073709551615UL; - public bool HasLargeUint64 { - get { return hasLargeUint64; } - } - [global::System.CLSCompliant(false)] - public ulong LargeUint64 { - get { return largeUint64_; } - } - - public const int SmallInt32FieldNumber = 4; - private bool hasSmallInt32; - private int smallInt32_ = -2147483647; - public bool HasSmallInt32 { - get { return hasSmallInt32; } - } - public int SmallInt32 { - get { return smallInt32_; } - } - - public const int SmallInt64FieldNumber = 5; - private bool hasSmallInt64; - private long smallInt64_ = -9223372036854775807L; - public bool HasSmallInt64 { - get { return hasSmallInt64; } - } - public long SmallInt64 { - get { return smallInt64_; } - } - - public const int ReallySmallInt32FieldNumber = 21; - private bool hasReallySmallInt32; - private int reallySmallInt32_ = -2147483648; - public bool HasReallySmallInt32 { - get { return hasReallySmallInt32; } - } - public int ReallySmallInt32 { - get { return reallySmallInt32_; } - } - - public const int ReallySmallInt64FieldNumber = 22; - private bool hasReallySmallInt64; - private long reallySmallInt64_ = -9223372036854775808L; - public bool HasReallySmallInt64 { - get { return hasReallySmallInt64; } - } - public long ReallySmallInt64 { - get { return reallySmallInt64_; } - } - - public const int Utf8StringFieldNumber = 6; - private bool hasUtf8String; - private string utf8String_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[7].DefaultValue; - public bool HasUtf8String { - get { return hasUtf8String; } - } - public string Utf8String { - get { return utf8String_; } - } - - public const int ZeroFloatFieldNumber = 7; - private bool hasZeroFloat; - private float zeroFloat_; - public bool HasZeroFloat { - get { return hasZeroFloat; } - } - public float ZeroFloat { - get { return zeroFloat_; } - } - - public const int OneFloatFieldNumber = 8; - private bool hasOneFloat; - private float oneFloat_ = 1F; - public bool HasOneFloat { - get { return hasOneFloat; } - } - public float OneFloat { - get { return oneFloat_; } - } - - public const int SmallFloatFieldNumber = 9; - private bool hasSmallFloat; - private float smallFloat_ = 1.5F; - public bool HasSmallFloat { - get { return hasSmallFloat; } - } - public float SmallFloat { - get { return smallFloat_; } - } - - public const int NegativeOneFloatFieldNumber = 10; - private bool hasNegativeOneFloat; - private float negativeOneFloat_ = -1F; - public bool HasNegativeOneFloat { - get { return hasNegativeOneFloat; } - } - public float NegativeOneFloat { - get { return negativeOneFloat_; } - } - - public const int NegativeFloatFieldNumber = 11; - private bool hasNegativeFloat; - private float negativeFloat_ = -1.5F; - public bool HasNegativeFloat { - get { return hasNegativeFloat; } - } - public float NegativeFloat { - get { return negativeFloat_; } - } - - public const int LargeFloatFieldNumber = 12; - private bool hasLargeFloat; - private float largeFloat_ = 2e+08F; - public bool HasLargeFloat { - get { return hasLargeFloat; } - } - public float LargeFloat { - get { return largeFloat_; } - } - - public const int SmallNegativeFloatFieldNumber = 13; - private bool hasSmallNegativeFloat; - private float smallNegativeFloat_ = -8e-28F; - public bool HasSmallNegativeFloat { - get { return hasSmallNegativeFloat; } - } - public float SmallNegativeFloat { - get { return smallNegativeFloat_; } - } - - public const int InfDoubleFieldNumber = 14; - private bool hasInfDouble; - private double infDouble_ = double.PositiveInfinity; - public bool HasInfDouble { - get { return hasInfDouble; } - } - public double InfDouble { - get { return infDouble_; } - } - - public const int NegInfDoubleFieldNumber = 15; - private bool hasNegInfDouble; - private double negInfDouble_ = double.NegativeInfinity; - public bool HasNegInfDouble { - get { return hasNegInfDouble; } - } - public double NegInfDouble { - get { return negInfDouble_; } - } - - public const int NanDoubleFieldNumber = 16; - private bool hasNanDouble; - private double nanDouble_ = double.NaN; - public bool HasNanDouble { - get { return hasNanDouble; } - } - public double NanDouble { - get { return nanDouble_; } - } - - public const int InfFloatFieldNumber = 17; - private bool hasInfFloat; - private float infFloat_ = float.PositiveInfinity; - public bool HasInfFloat { - get { return hasInfFloat; } - } - public float InfFloat { - get { return infFloat_; } - } - - public const int NegInfFloatFieldNumber = 18; - private bool hasNegInfFloat; - private float negInfFloat_ = float.NegativeInfinity; - public bool HasNegInfFloat { - get { return hasNegInfFloat; } - } - public float NegInfFloat { - get { return negInfFloat_; } - } - - public const int NanFloatFieldNumber = 19; - private bool hasNanFloat; - private float nanFloat_ = float.NaN; - public bool HasNanFloat { - get { return hasNanFloat; } - } - public float NanFloat { - get { return nanFloat_; } - } - - public const int CppTrigraphFieldNumber = 20; - private bool hasCppTrigraph; - private string cppTrigraph_ = "? ? ?? ?? ??? ??/ ??-"; - public bool HasCppTrigraph { - get { return hasCppTrigraph; } - } - public string CppTrigraph { - get { return cppTrigraph_; } - } - - public const int StringWithZeroFieldNumber = 23; - private bool hasStringWithZero; - private string stringWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[22].DefaultValue; - public bool HasStringWithZero { - get { return hasStringWithZero; } - } - public string StringWithZero { - get { return stringWithZero_; } - } - - public const int BytesWithZeroFieldNumber = 24; - private bool hasBytesWithZero; - private pb::ByteString bytesWithZero_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[23].DefaultValue; - public bool HasBytesWithZero { - get { return hasBytesWithZero; } - } - public pb::ByteString BytesWithZero { - get { return bytesWithZero_; } - } - - public const int StringPieceWithZeroFieldNumber = 25; - private bool hasStringPieceWithZero; - private string stringPieceWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[24].DefaultValue; - public bool HasStringPieceWithZero { - get { return hasStringPieceWithZero; } - } - public string StringPieceWithZero { - get { return stringPieceWithZero_; } - } - - public const int CordWithZeroFieldNumber = 26; - private bool hasCordWithZero; - private string cordWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[25].DefaultValue; - public bool HasCordWithZero { - get { return hasCordWithZero; } - } - public string CordWithZero { - get { return cordWithZero_; } - } - - public const int ReplacementStringFieldNumber = 27; - private bool hasReplacementString; - private string replacementString_ = "${unknown}"; - public bool HasReplacementString { - get { return hasReplacementString; } - } - public string ReplacementString { - get { return replacementString_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testExtremeDefaultValuesFieldNames; - if (hasEscapedBytes) { - output.WriteBytes(1, field_names[3], EscapedBytes); - } - if (hasLargeUint32) { - output.WriteUInt32(2, field_names[7], LargeUint32); - } - if (hasLargeUint64) { - output.WriteUInt64(3, field_names[8], LargeUint64); - } - if (hasSmallInt32) { - output.WriteInt32(4, field_names[20], SmallInt32); - } - if (hasSmallInt64) { - output.WriteInt64(5, field_names[21], SmallInt64); - } - if (hasUtf8String) { - output.WriteString(6, field_names[25], Utf8String); - } - if (hasZeroFloat) { - output.WriteFloat(7, field_names[26], ZeroFloat); - } - if (hasOneFloat) { - output.WriteFloat(8, field_names[15], OneFloat); - } - if (hasSmallFloat) { - output.WriteFloat(9, field_names[19], SmallFloat); - } - if (hasNegativeOneFloat) { - output.WriteFloat(10, field_names[14], NegativeOneFloat); - } - if (hasNegativeFloat) { - output.WriteFloat(11, field_names[13], NegativeFloat); - } - if (hasLargeFloat) { - output.WriteFloat(12, field_names[6], LargeFloat); - } - if (hasSmallNegativeFloat) { - output.WriteFloat(13, field_names[22], SmallNegativeFloat); - } - if (hasInfDouble) { - output.WriteDouble(14, field_names[4], InfDouble); - } - if (hasNegInfDouble) { - output.WriteDouble(15, field_names[11], NegInfDouble); - } - if (hasNanDouble) { - output.WriteDouble(16, field_names[9], NanDouble); - } - if (hasInfFloat) { - output.WriteFloat(17, field_names[5], InfFloat); - } - if (hasNegInfFloat) { - output.WriteFloat(18, field_names[12], NegInfFloat); - } - if (hasNanFloat) { - output.WriteFloat(19, field_names[10], NanFloat); - } - if (hasCppTrigraph) { - output.WriteString(20, field_names[2], CppTrigraph); - } - if (hasReallySmallInt32) { - output.WriteInt32(21, field_names[16], ReallySmallInt32); - } - if (hasReallySmallInt64) { - output.WriteInt64(22, field_names[17], ReallySmallInt64); - } - if (hasStringWithZero) { - output.WriteString(23, field_names[24], StringWithZero); - } - if (hasBytesWithZero) { - output.WriteBytes(24, field_names[0], BytesWithZero); - } - if (hasStringPieceWithZero) { - output.WriteString(25, field_names[23], StringPieceWithZero); - } - if (hasCordWithZero) { - output.WriteString(26, field_names[1], CordWithZero); - } - if (hasReplacementString) { - output.WriteString(27, field_names[18], ReplacementString); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasEscapedBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(1, EscapedBytes); - } - if (hasLargeUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(2, LargeUint32); - } - if (hasLargeUint64) { - size += pb::CodedOutputStream.ComputeUInt64Size(3, LargeUint64); - } - if (hasSmallInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(4, SmallInt32); - } - if (hasSmallInt64) { - size += pb::CodedOutputStream.ComputeInt64Size(5, SmallInt64); - } - if (hasReallySmallInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(21, ReallySmallInt32); - } - if (hasReallySmallInt64) { - size += pb::CodedOutputStream.ComputeInt64Size(22, ReallySmallInt64); - } - if (hasUtf8String) { - size += pb::CodedOutputStream.ComputeStringSize(6, Utf8String); - } - if (hasZeroFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(7, ZeroFloat); - } - if (hasOneFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(8, OneFloat); - } - if (hasSmallFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(9, SmallFloat); - } - if (hasNegativeOneFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(10, NegativeOneFloat); - } - if (hasNegativeFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(11, NegativeFloat); - } - if (hasLargeFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(12, LargeFloat); - } - if (hasSmallNegativeFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(13, SmallNegativeFloat); - } - if (hasInfDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(14, InfDouble); - } - if (hasNegInfDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(15, NegInfDouble); - } - if (hasNanDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(16, NanDouble); - } - if (hasInfFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(17, InfFloat); - } - if (hasNegInfFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(18, NegInfFloat); - } - if (hasNanFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(19, NanFloat); - } - if (hasCppTrigraph) { - size += pb::CodedOutputStream.ComputeStringSize(20, CppTrigraph); - } - if (hasStringWithZero) { - size += pb::CodedOutputStream.ComputeStringSize(23, StringWithZero); - } - if (hasBytesWithZero) { - size += pb::CodedOutputStream.ComputeBytesSize(24, BytesWithZero); - } - if (hasStringPieceWithZero) { - size += pb::CodedOutputStream.ComputeStringSize(25, StringPieceWithZero); - } - if (hasCordWithZero) { - size += pb::CodedOutputStream.ComputeStringSize(26, CordWithZero); - } - if (hasReplacementString) { - size += pb::CodedOutputStream.ComputeStringSize(27, ReplacementString); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestExtremeDefaultValues ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestExtremeDefaultValues ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestExtremeDefaultValues ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestExtremeDefaultValues MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestExtremeDefaultValues prototype) { - return new Builder(prototype); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestExtremeDefaultValues cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestExtremeDefaultValues result; - - private TestExtremeDefaultValues PrepareBuilder() { - if (resultIsReadOnly) { - TestExtremeDefaultValues original = result; - result = new TestExtremeDefaultValues(); - resultIsReadOnly = false; - MergeFrom(original); + public sealed partial class TestPackedExtensions : pb::ExtendableMessage + { + private TestPackedExtensions() { } + private static readonly TestPackedExtensions defaultInstance = new TestPackedExtensions().MakeReadOnly(); + private static readonly string[] _testPackedExtensionsFieldNames = new string[] { }; + private static readonly uint[] _testPackedExtensionsFieldTags = new uint[] { }; + public static TestPackedExtensions DefaultInstance + { + get { return defaultInstance; } } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestExtremeDefaultValues MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public override TestPackedExtensions DefaultInstanceForType + { + get { return DefaultInstance; } } - } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor; } - } - - public override TestExtremeDefaultValues DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.DefaultInstance; } - } - - public override TestExtremeDefaultValues BuildPartial() { - if (resultIsReadOnly) { - return result; + protected override TestPackedExtensions ThisMessage + { + get { return this; } } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestExtremeDefaultValues) { - return MergeFrom((TestExtremeDefaultValues) other); - } else { - base.MergeFrom(other); - return this; + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedExtensions__Descriptor; } } - } - public override Builder MergeFrom(TestExtremeDefaultValues other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasEscapedBytes) { - EscapedBytes = other.EscapedBytes; - } - if (other.HasLargeUint32) { - LargeUint32 = other.LargeUint32; + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable; } } - if (other.HasLargeUint64) { - LargeUint64 = other.LargeUint64; - } - if (other.HasSmallInt32) { - SmallInt32 = other.SmallInt32; - } - if (other.HasSmallInt64) { - SmallInt64 = other.SmallInt64; - } - if (other.HasReallySmallInt32) { - ReallySmallInt32 = other.ReallySmallInt32; - } - if (other.HasReallySmallInt64) { - ReallySmallInt64 = other.ReallySmallInt64; - } - if (other.HasUtf8String) { - Utf8String = other.Utf8String; - } - if (other.HasZeroFloat) { - ZeroFloat = other.ZeroFloat; - } - if (other.HasOneFloat) { - OneFloat = other.OneFloat; - } - if (other.HasSmallFloat) { - SmallFloat = other.SmallFloat; - } - if (other.HasNegativeOneFloat) { - NegativeOneFloat = other.NegativeOneFloat; - } - if (other.HasNegativeFloat) { - NegativeFloat = other.NegativeFloat; + + public override bool IsInitialized + { + get + { + if (!ExtensionsAreInitialized) return false; + return true; + } } - if (other.HasLargeFloat) { - LargeFloat = other.LargeFloat; + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testPackedExtensionsFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); } - if (other.HasSmallNegativeFloat) { - SmallNegativeFloat = other.SmallNegativeFloat; + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } } - if (other.HasInfDouble) { - InfDouble = other.InfDouble; + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; } - if (other.HasNegInfDouble) { - NegInfDouble = other.NegInfDouble; + public static TestPackedExtensions ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - if (other.HasNanDouble) { - NanDouble = other.NanDouble; + public static TestPackedExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - if (other.HasInfFloat) { - InfFloat = other.InfFloat; + public static TestPackedExtensions ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - if (other.HasNegInfFloat) { - NegInfFloat = other.NegInfFloat; + public static TestPackedExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - if (other.HasNanFloat) { - NanFloat = other.NanFloat; + public static TestPackedExtensions ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - if (other.HasCppTrigraph) { - CppTrigraph = other.CppTrigraph; + public static TestPackedExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - if (other.HasStringWithZero) { - StringWithZero = other.StringWithZero; + public static TestPackedExtensions ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); } - if (other.HasBytesWithZero) { - BytesWithZero = other.BytesWithZero; + public static TestPackedExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); } - if (other.HasStringPieceWithZero) { - StringPieceWithZero = other.StringPieceWithZero; + public static TestPackedExtensions ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - if (other.HasCordWithZero) { - CordWithZero = other.CordWithZero; + public static TestPackedExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - if (other.HasReplacementString) { - ReplacementString = other.ReplacementString; + private TestPackedExtensions MakeReadOnly() + { + return this; } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestPackedExtensions prototype) + { + return new Builder(prototype); + } - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testExtremeDefaultValuesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testExtremeDefaultValuesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasEscapedBytes = input.ReadBytes(ref result.escapedBytes_); - break; - } - case 16: { - result.hasLargeUint32 = input.ReadUInt32(ref result.largeUint32_); - break; - } - case 24: { - result.hasLargeUint64 = input.ReadUInt64(ref result.largeUint64_); - break; - } - case 32: { - result.hasSmallInt32 = input.ReadInt32(ref result.smallInt32_); - break; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder + { + protected override Builder ThisBuilder + { + get { return this; } } - case 40: { - result.hasSmallInt64 = input.ReadInt64(ref result.smallInt64_); - break; + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; } - case 50: { - result.hasUtf8String = input.ReadString(ref result.utf8String_); - break; + internal Builder(TestPackedExtensions cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; } - case 61: { - result.hasZeroFloat = input.ReadFloat(ref result.zeroFloat_); - break; - } - case 69: { - result.hasOneFloat = input.ReadFloat(ref result.oneFloat_); - break; - } - case 77: { - result.hasSmallFloat = input.ReadFloat(ref result.smallFloat_); - break; - } - case 85: { - result.hasNegativeOneFloat = input.ReadFloat(ref result.negativeOneFloat_); - break; - } - case 93: { - result.hasNegativeFloat = input.ReadFloat(ref result.negativeFloat_); - break; - } - case 101: { - result.hasLargeFloat = input.ReadFloat(ref result.largeFloat_); - break; - } - case 109: { - result.hasSmallNegativeFloat = input.ReadFloat(ref result.smallNegativeFloat_); - break; - } - case 113: { - result.hasInfDouble = input.ReadDouble(ref result.infDouble_); - break; - } - case 121: { - result.hasNegInfDouble = input.ReadDouble(ref result.negInfDouble_); - break; - } - case 129: { - result.hasNanDouble = input.ReadDouble(ref result.nanDouble_); - break; - } - case 141: { - result.hasInfFloat = input.ReadFloat(ref result.infFloat_); - break; - } - case 149: { - result.hasNegInfFloat = input.ReadFloat(ref result.negInfFloat_); - break; - } - case 157: { - result.hasNanFloat = input.ReadFloat(ref result.nanFloat_); - break; - } - case 162: { - result.hasCppTrigraph = input.ReadString(ref result.cppTrigraph_); - break; - } - case 168: { - result.hasReallySmallInt32 = input.ReadInt32(ref result.reallySmallInt32_); - break; - } - case 176: { - result.hasReallySmallInt64 = input.ReadInt64(ref result.reallySmallInt64_); - break; - } - case 186: { - result.hasStringWithZero = input.ReadString(ref result.stringWithZero_); - break; - } - case 194: { - result.hasBytesWithZero = input.ReadBytes(ref result.bytesWithZero_); - break; - } - case 202: { - result.hasStringPieceWithZero = input.ReadString(ref result.stringPieceWithZero_); - break; - } - case 210: { - result.hasCordWithZero = input.ReadString(ref result.cordWithZero_); - break; - } - case 218: { - result.hasReplacementString = input.ReadString(ref result.replacementString_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasEscapedBytes { - get { return result.hasEscapedBytes; } - } - public pb::ByteString EscapedBytes { - get { return result.EscapedBytes; } - set { SetEscapedBytes(value); } - } - public Builder SetEscapedBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasEscapedBytes = true; - result.escapedBytes_ = value; - return this; - } - public Builder ClearEscapedBytes() { - PrepareBuilder(); - result.hasEscapedBytes = false; - result.escapedBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[0].DefaultValue; - return this; - } - - public bool HasLargeUint32 { - get { return result.hasLargeUint32; } - } - [global::System.CLSCompliant(false)] - public uint LargeUint32 { - get { return result.LargeUint32; } - set { SetLargeUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetLargeUint32(uint value) { - PrepareBuilder(); - result.hasLargeUint32 = true; - result.largeUint32_ = value; - return this; - } - public Builder ClearLargeUint32() { - PrepareBuilder(); - result.hasLargeUint32 = false; - result.largeUint32_ = 4294967295; - return this; - } - - public bool HasLargeUint64 { - get { return result.hasLargeUint64; } - } - [global::System.CLSCompliant(false)] - public ulong LargeUint64 { - get { return result.LargeUint64; } - set { SetLargeUint64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetLargeUint64(ulong value) { - PrepareBuilder(); - result.hasLargeUint64 = true; - result.largeUint64_ = value; - return this; - } - public Builder ClearLargeUint64() { - PrepareBuilder(); - result.hasLargeUint64 = false; - result.largeUint64_ = 18446744073709551615UL; - return this; - } - - public bool HasSmallInt32 { - get { return result.hasSmallInt32; } - } - public int SmallInt32 { - get { return result.SmallInt32; } - set { SetSmallInt32(value); } - } - public Builder SetSmallInt32(int value) { - PrepareBuilder(); - result.hasSmallInt32 = true; - result.smallInt32_ = value; - return this; - } - public Builder ClearSmallInt32() { - PrepareBuilder(); - result.hasSmallInt32 = false; - result.smallInt32_ = -2147483647; - return this; - } - - public bool HasSmallInt64 { - get { return result.hasSmallInt64; } - } - public long SmallInt64 { - get { return result.SmallInt64; } - set { SetSmallInt64(value); } - } - public Builder SetSmallInt64(long value) { - PrepareBuilder(); - result.hasSmallInt64 = true; - result.smallInt64_ = value; - return this; - } - public Builder ClearSmallInt64() { - PrepareBuilder(); - result.hasSmallInt64 = false; - result.smallInt64_ = -9223372036854775807L; - return this; - } - - public bool HasReallySmallInt32 { - get { return result.hasReallySmallInt32; } - } - public int ReallySmallInt32 { - get { return result.ReallySmallInt32; } - set { SetReallySmallInt32(value); } - } - public Builder SetReallySmallInt32(int value) { - PrepareBuilder(); - result.hasReallySmallInt32 = true; - result.reallySmallInt32_ = value; - return this; - } - public Builder ClearReallySmallInt32() { - PrepareBuilder(); - result.hasReallySmallInt32 = false; - result.reallySmallInt32_ = -2147483648; - return this; - } - - public bool HasReallySmallInt64 { - get { return result.hasReallySmallInt64; } - } - public long ReallySmallInt64 { - get { return result.ReallySmallInt64; } - set { SetReallySmallInt64(value); } - } - public Builder SetReallySmallInt64(long value) { - PrepareBuilder(); - result.hasReallySmallInt64 = true; - result.reallySmallInt64_ = value; - return this; - } - public Builder ClearReallySmallInt64() { - PrepareBuilder(); - result.hasReallySmallInt64 = false; - result.reallySmallInt64_ = -9223372036854775808L; - return this; - } - - public bool HasUtf8String { - get { return result.hasUtf8String; } - } - public string Utf8String { - get { return result.Utf8String; } - set { SetUtf8String(value); } - } - public Builder SetUtf8String(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasUtf8String = true; - result.utf8String_ = value; - return this; - } - public Builder ClearUtf8String() { - PrepareBuilder(); - result.hasUtf8String = false; - result.utf8String_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[7].DefaultValue; - return this; - } - - public bool HasZeroFloat { - get { return result.hasZeroFloat; } - } - public float ZeroFloat { - get { return result.ZeroFloat; } - set { SetZeroFloat(value); } - } - public Builder SetZeroFloat(float value) { - PrepareBuilder(); - result.hasZeroFloat = true; - result.zeroFloat_ = value; - return this; - } - public Builder ClearZeroFloat() { - PrepareBuilder(); - result.hasZeroFloat = false; - result.zeroFloat_ = 0F; - return this; - } - - public bool HasOneFloat { - get { return result.hasOneFloat; } - } - public float OneFloat { - get { return result.OneFloat; } - set { SetOneFloat(value); } - } - public Builder SetOneFloat(float value) { - PrepareBuilder(); - result.hasOneFloat = true; - result.oneFloat_ = value; - return this; - } - public Builder ClearOneFloat() { - PrepareBuilder(); - result.hasOneFloat = false; - result.oneFloat_ = 1F; - return this; - } - - public bool HasSmallFloat { - get { return result.hasSmallFloat; } - } - public float SmallFloat { - get { return result.SmallFloat; } - set { SetSmallFloat(value); } - } - public Builder SetSmallFloat(float value) { - PrepareBuilder(); - result.hasSmallFloat = true; - result.smallFloat_ = value; - return this; - } - public Builder ClearSmallFloat() { - PrepareBuilder(); - result.hasSmallFloat = false; - result.smallFloat_ = 1.5F; - return this; - } - - public bool HasNegativeOneFloat { - get { return result.hasNegativeOneFloat; } - } - public float NegativeOneFloat { - get { return result.NegativeOneFloat; } - set { SetNegativeOneFloat(value); } - } - public Builder SetNegativeOneFloat(float value) { - PrepareBuilder(); - result.hasNegativeOneFloat = true; - result.negativeOneFloat_ = value; - return this; - } - public Builder ClearNegativeOneFloat() { - PrepareBuilder(); - result.hasNegativeOneFloat = false; - result.negativeOneFloat_ = -1F; - return this; - } - - public bool HasNegativeFloat { - get { return result.hasNegativeFloat; } - } - public float NegativeFloat { - get { return result.NegativeFloat; } - set { SetNegativeFloat(value); } - } - public Builder SetNegativeFloat(float value) { - PrepareBuilder(); - result.hasNegativeFloat = true; - result.negativeFloat_ = value; - return this; - } - public Builder ClearNegativeFloat() { - PrepareBuilder(); - result.hasNegativeFloat = false; - result.negativeFloat_ = -1.5F; - return this; - } - - public bool HasLargeFloat { - get { return result.hasLargeFloat; } - } - public float LargeFloat { - get { return result.LargeFloat; } - set { SetLargeFloat(value); } - } - public Builder SetLargeFloat(float value) { - PrepareBuilder(); - result.hasLargeFloat = true; - result.largeFloat_ = value; - return this; - } - public Builder ClearLargeFloat() { - PrepareBuilder(); - result.hasLargeFloat = false; - result.largeFloat_ = 2e+08F; - return this; - } - - public bool HasSmallNegativeFloat { - get { return result.hasSmallNegativeFloat; } - } - public float SmallNegativeFloat { - get { return result.SmallNegativeFloat; } - set { SetSmallNegativeFloat(value); } - } - public Builder SetSmallNegativeFloat(float value) { - PrepareBuilder(); - result.hasSmallNegativeFloat = true; - result.smallNegativeFloat_ = value; - return this; - } - public Builder ClearSmallNegativeFloat() { - PrepareBuilder(); - result.hasSmallNegativeFloat = false; - result.smallNegativeFloat_ = -8e-28F; - return this; - } - - public bool HasInfDouble { - get { return result.hasInfDouble; } - } - public double InfDouble { - get { return result.InfDouble; } - set { SetInfDouble(value); } - } - public Builder SetInfDouble(double value) { - PrepareBuilder(); - result.hasInfDouble = true; - result.infDouble_ = value; - return this; - } - public Builder ClearInfDouble() { - PrepareBuilder(); - result.hasInfDouble = false; - result.infDouble_ = double.PositiveInfinity; - return this; - } - - public bool HasNegInfDouble { - get { return result.hasNegInfDouble; } - } - public double NegInfDouble { - get { return result.NegInfDouble; } - set { SetNegInfDouble(value); } - } - public Builder SetNegInfDouble(double value) { - PrepareBuilder(); - result.hasNegInfDouble = true; - result.negInfDouble_ = value; - return this; - } - public Builder ClearNegInfDouble() { - PrepareBuilder(); - result.hasNegInfDouble = false; - result.negInfDouble_ = double.NegativeInfinity; - return this; - } - - public bool HasNanDouble { - get { return result.hasNanDouble; } - } - public double NanDouble { - get { return result.NanDouble; } - set { SetNanDouble(value); } - } - public Builder SetNanDouble(double value) { - PrepareBuilder(); - result.hasNanDouble = true; - result.nanDouble_ = value; - return this; - } - public Builder ClearNanDouble() { - PrepareBuilder(); - result.hasNanDouble = false; - result.nanDouble_ = double.NaN; - return this; - } - - public bool HasInfFloat { - get { return result.hasInfFloat; } - } - public float InfFloat { - get { return result.InfFloat; } - set { SetInfFloat(value); } - } - public Builder SetInfFloat(float value) { - PrepareBuilder(); - result.hasInfFloat = true; - result.infFloat_ = value; - return this; - } - public Builder ClearInfFloat() { - PrepareBuilder(); - result.hasInfFloat = false; - result.infFloat_ = float.PositiveInfinity; - return this; - } - - public bool HasNegInfFloat { - get { return result.hasNegInfFloat; } - } - public float NegInfFloat { - get { return result.NegInfFloat; } - set { SetNegInfFloat(value); } - } - public Builder SetNegInfFloat(float value) { - PrepareBuilder(); - result.hasNegInfFloat = true; - result.negInfFloat_ = value; - return this; - } - public Builder ClearNegInfFloat() { - PrepareBuilder(); - result.hasNegInfFloat = false; - result.negInfFloat_ = float.NegativeInfinity; - return this; - } - - public bool HasNanFloat { - get { return result.hasNanFloat; } - } - public float NanFloat { - get { return result.NanFloat; } - set { SetNanFloat(value); } - } - public Builder SetNanFloat(float value) { - PrepareBuilder(); - result.hasNanFloat = true; - result.nanFloat_ = value; - return this; - } - public Builder ClearNanFloat() { - PrepareBuilder(); - result.hasNanFloat = false; - result.nanFloat_ = float.NaN; - return this; - } - - public bool HasCppTrigraph { - get { return result.hasCppTrigraph; } - } - public string CppTrigraph { - get { return result.CppTrigraph; } - set { SetCppTrigraph(value); } - } - public Builder SetCppTrigraph(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasCppTrigraph = true; - result.cppTrigraph_ = value; - return this; - } - public Builder ClearCppTrigraph() { - PrepareBuilder(); - result.hasCppTrigraph = false; - result.cppTrigraph_ = "? ? ?? ?? ??? ??/ ??-"; - return this; - } - - public bool HasStringWithZero { - get { return result.hasStringWithZero; } - } - public string StringWithZero { - get { return result.StringWithZero; } - set { SetStringWithZero(value); } - } - public Builder SetStringWithZero(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasStringWithZero = true; - result.stringWithZero_ = value; - return this; - } - public Builder ClearStringWithZero() { - PrepareBuilder(); - result.hasStringWithZero = false; - result.stringWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[22].DefaultValue; - return this; - } - - public bool HasBytesWithZero { - get { return result.hasBytesWithZero; } - } - public pb::ByteString BytesWithZero { - get { return result.BytesWithZero; } - set { SetBytesWithZero(value); } - } - public Builder SetBytesWithZero(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBytesWithZero = true; - result.bytesWithZero_ = value; - return this; - } - public Builder ClearBytesWithZero() { - PrepareBuilder(); - result.hasBytesWithZero = false; - result.bytesWithZero_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[23].DefaultValue; - return this; - } - - public bool HasStringPieceWithZero { - get { return result.hasStringPieceWithZero; } - } - public string StringPieceWithZero { - get { return result.StringPieceWithZero; } - set { SetStringPieceWithZero(value); } - } - public Builder SetStringPieceWithZero(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasStringPieceWithZero = true; - result.stringPieceWithZero_ = value; - return this; - } - public Builder ClearStringPieceWithZero() { - PrepareBuilder(); - result.hasStringPieceWithZero = false; - result.stringPieceWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[24].DefaultValue; - return this; - } - - public bool HasCordWithZero { - get { return result.hasCordWithZero; } - } - public string CordWithZero { - get { return result.CordWithZero; } - set { SetCordWithZero(value); } - } - public Builder SetCordWithZero(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasCordWithZero = true; - result.cordWithZero_ = value; - return this; - } - public Builder ClearCordWithZero() { - PrepareBuilder(); - result.hasCordWithZero = false; - result.cordWithZero_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[25].DefaultValue; - return this; - } - - public bool HasReplacementString { - get { return result.hasReplacementString; } - } - public string ReplacementString { - get { return result.ReplacementString; } - set { SetReplacementString(value); } - } - public Builder SetReplacementString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasReplacementString = true; - result.replacementString_ = value; - return this; - } - public Builder ClearReplacementString() { - PrepareBuilder(); - result.hasReplacementString = false; - result.replacementString_ = "${unknown}"; - return this; - } - } - static TestExtremeDefaultValues() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class SparseEnumMessage : pb::GeneratedMessage { - private SparseEnumMessage() { } - private static readonly SparseEnumMessage defaultInstance = new SparseEnumMessage().MakeReadOnly(); - private static readonly string[] _sparseEnumMessageFieldNames = new string[] { "sparse_enum" }; - private static readonly uint[] _sparseEnumMessageFieldTags = new uint[] { 8 }; - public static SparseEnumMessage DefaultInstance { - get { return defaultInstance; } - } - - public override SparseEnumMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override SparseEnumMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_SparseEnumMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_SparseEnumMessage__FieldAccessorTable; } - } - - public const int SparseEnumFieldNumber = 1; - private bool hasSparseEnum; - private global::Google.ProtocolBuffers.TestProtos.TestSparseEnum sparseEnum_ = global::Google.ProtocolBuffers.TestProtos.TestSparseEnum.SPARSE_A; - public bool HasSparseEnum { - get { return hasSparseEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestSparseEnum SparseEnum { - get { return sparseEnum_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _sparseEnumMessageFieldNames; - if (hasSparseEnum) { - output.WriteEnum(1, field_names[0], (int) SparseEnum, SparseEnum); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasSparseEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(1, (int) SparseEnum); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static SparseEnumMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static SparseEnumMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static SparseEnumMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static SparseEnumMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private SparseEnumMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(SparseEnumMessage prototype) { - return new Builder(prototype); - } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(SparseEnumMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private SparseEnumMessage result; - - private SparseEnumMessage PrepareBuilder() { - if (resultIsReadOnly) { - SparseEnumMessage original = result; - result = new SparseEnumMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override SparseEnumMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.Descriptor; } - } - - public override SparseEnumMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.DefaultInstance; } - } - - public override SparseEnumMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is SparseEnumMessage) { - return MergeFrom((SparseEnumMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(SparseEnumMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.SparseEnumMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasSparseEnum) { - SparseEnum = other.SparseEnum; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_sparseEnumMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _sparseEnumMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - object unknown; - if(input.ReadEnum(ref result.sparseEnum_, out unknown)) { - result.hasSparseEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(1, (ulong)(int)unknown); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasSparseEnum { - get { return result.hasSparseEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestSparseEnum SparseEnum { - get { return result.SparseEnum; } - set { SetSparseEnum(value); } - } - public Builder SetSparseEnum(global::Google.ProtocolBuffers.TestProtos.TestSparseEnum value) { - PrepareBuilder(); - result.hasSparseEnum = true; - result.sparseEnum_ = value; - return this; - } - public Builder ClearSparseEnum() { - PrepareBuilder(); - result.hasSparseEnum = false; - result.sparseEnum_ = global::Google.ProtocolBuffers.TestProtos.TestSparseEnum.SPARSE_A; - return this; - } - } - static SparseEnumMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OneString : pb::GeneratedMessage { - private OneString() { } - private static readonly OneString defaultInstance = new OneString().MakeReadOnly(); - private static readonly string[] _oneStringFieldNames = new string[] { "data" }; - private static readonly uint[] _oneStringFieldTags = new uint[] { 10 }; - public static OneString DefaultInstance { - get { return defaultInstance; } - } - - public override OneString DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override OneString ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneString__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneString__FieldAccessorTable; } - } - - public const int DataFieldNumber = 1; - private bool hasData; - private string data_ = ""; - public bool HasData { - get { return hasData; } - } - public string Data { - get { return data_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _oneStringFieldNames; - if (hasData) { - output.WriteString(1, field_names[0], Data); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasData) { - size += pb::CodedOutputStream.ComputeStringSize(1, Data); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static OneString ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OneString ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OneString ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OneString ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OneString ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OneString ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static OneString ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static OneString ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static OneString ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OneString ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private OneString MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OneString prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OneString cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OneString result; - - private OneString PrepareBuilder() { - if (resultIsReadOnly) { - OneString original = result; - result = new OneString(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OneString MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.OneString.Descriptor; } - } - - public override OneString DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.OneString.DefaultInstance; } - } - - public override OneString BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is OneString) { - return MergeFrom((OneString) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(OneString other) { - if (other == global::Google.ProtocolBuffers.TestProtos.OneString.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasData) { - Data = other.Data; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_oneStringFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _oneStringFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasData = input.ReadString(ref result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasData { - get { return result.hasData; } - } - public string Data { - get { return result.Data; } - set { SetData(value); } - } - public Builder SetData(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasData = true; - result.data_ = value; - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.hasData = false; - result.data_ = ""; - return this; - } - } - static OneString() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class MoreString : pb::GeneratedMessage { - private MoreString() { } - private static readonly MoreString defaultInstance = new MoreString().MakeReadOnly(); - private static readonly string[] _moreStringFieldNames = new string[] { "data" }; - private static readonly uint[] _moreStringFieldTags = new uint[] { 10 }; - public static MoreString DefaultInstance { - get { return defaultInstance; } - } - - public override MoreString DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override MoreString ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreString__Descriptor; } - } + private bool resultIsReadOnly; + private TestPackedExtensions result; - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreString__FieldAccessorTable; } - } - - public const int DataFieldNumber = 1; - private pbc::PopsicleList data_ = new pbc::PopsicleList(); - public scg::IList DataList { - get { return pbc::Lists.AsReadOnly(data_); } - } - public int DataCount { - get { return data_.Count; } - } - public string GetData(int index) { - return data_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _moreStringFieldNames; - if (data_.Count > 0) { - output.WriteStringArray(1, field_names[0], data_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + private TestPackedExtensions PrepareBuilder() + { + if (resultIsReadOnly) + { + TestPackedExtensions original = result; + result = new TestPackedExtensions(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (string element in DataList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 1 * data_.Count; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static MoreString ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MoreString ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MoreString ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MoreString ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MoreString ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MoreString ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static MoreString ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static MoreString ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static MoreString ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MoreString ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private MoreString MakeReadOnly() { - data_.MakeReadOnly(); - return this; - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(MoreString prototype) { - return new Builder(prototype); - } + protected override TestPackedExtensions MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(MoreString cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private MoreString result; - - private MoreString PrepareBuilder() { - if (resultIsReadOnly) { - MoreString original = result; - result = new MoreString(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override MoreString MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.MoreString.Descriptor; } - } - - public override MoreString DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.MoreString.DefaultInstance; } - } - - public override MoreString BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is MoreString) { - return MergeFrom((MoreString) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(MoreString other) { - if (other == global::Google.ProtocolBuffers.TestProtos.MoreString.DefaultInstance) return this; - PrepareBuilder(); - if (other.data_.Count != 0) { - result.data_.Add(other.data_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_moreStringFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _moreStringFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - input.ReadStringArray(tag, field_name, result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public pbc::IPopsicleList DataList { - get { return PrepareBuilder().data_; } - } - public int DataCount { - get { return result.DataCount; } - } - public string GetData(int index) { - return result.GetData(index); - } - public Builder SetData(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.data_[index] = value; - return this; - } - public Builder AddData(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.data_.Add(value); - return this; - } - public Builder AddRangeData(scg::IEnumerable values) { - PrepareBuilder(); - result.data_.Add(values); - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.data_.Clear(); - return this; - } - } - static MoreString() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OneBytes : pb::GeneratedMessage { - private OneBytes() { } - private static readonly OneBytes defaultInstance = new OneBytes().MakeReadOnly(); - private static readonly string[] _oneBytesFieldNames = new string[] { "data" }; - private static readonly uint[] _oneBytesFieldTags = new uint[] { 10 }; - public static OneBytes DefaultInstance { - get { return defaultInstance; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public override OneBytes DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - protected override OneBytes ThisMessage { - get { return this; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.Descriptor; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneBytes__Descriptor; } - } + public override TestPackedExtensions DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.DefaultInstance; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_OneBytes__FieldAccessorTable; } - } + public override TestPackedExtensions BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public const int DataFieldNumber = 1; - private bool hasData; - private pb::ByteString data_ = pb::ByteString.Empty; - public bool HasData { - get { return hasData; } - } - public pb::ByteString Data { - get { return data_; } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestPackedExtensions) + { + return MergeFrom((TestPackedExtensions)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public override bool IsInitialized { - get { - return true; - } - } + public override Builder MergeFrom(TestPackedExtensions other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _oneBytesFieldNames; - if (hasData) { - output.WriteBytes(1, field_names[0], Data); - } - UnknownFields.WriteTo(output); - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testPackedExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testPackedExtensionsFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasData) { - size += pb::CodedOutputStream.ComputeBytesSize(1, Data); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static OneBytes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OneBytes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OneBytes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static OneBytes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static OneBytes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OneBytes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static OneBytes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static OneBytes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static OneBytes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static OneBytes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private OneBytes MakeReadOnly() { - return this; - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OneBytes prototype) { - return new Builder(prototype); + } + static TestPackedExtensions() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OneBytes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OneBytes result; - - private OneBytes PrepareBuilder() { - if (resultIsReadOnly) { - OneBytes original = result; - result = new OneBytes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OneBytes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.OneBytes.Descriptor; } - } - - public override OneBytes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.OneBytes.DefaultInstance; } - } - - public override OneBytes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is OneBytes) { - return MergeFrom((OneBytes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(OneBytes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.OneBytes.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasData) { - Data = other.Data; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_oneBytesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _oneBytesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasData = input.ReadBytes(ref result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasData { - get { return result.hasData; } - } - public pb::ByteString Data { - get { return result.Data; } - set { SetData(value); } - } - public Builder SetData(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasData = true; - result.data_ = value; - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.hasData = false; - result.data_ = pb::ByteString.Empty; - return this; - } - } - static OneBytes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class MoreBytes : pb::GeneratedMessage { - private MoreBytes() { } - private static readonly MoreBytes defaultInstance = new MoreBytes().MakeReadOnly(); - private static readonly string[] _moreBytesFieldNames = new string[] { "data" }; - private static readonly uint[] _moreBytesFieldTags = new uint[] { 10 }; - public static MoreBytes DefaultInstance { - get { return defaultInstance; } - } - - public override MoreBytes DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override MoreBytes ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreBytes__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_MoreBytes__FieldAccessorTable; } - } - - public const int DataFieldNumber = 1; - private pbc::PopsicleList data_ = new pbc::PopsicleList(); - public scg::IList DataList { - get { return pbc::Lists.AsReadOnly(data_); } - } - public int DataCount { - get { return data_.Count; } - } - public pb::ByteString GetData(int index) { - return data_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } + public sealed partial class TestUnpackedExtensions : pb::ExtendableMessage + { + private TestUnpackedExtensions() { } + private static readonly TestUnpackedExtensions defaultInstance = new TestUnpackedExtensions().MakeReadOnly(); + private static readonly string[] _testUnpackedExtensionsFieldNames = new string[] { }; + private static readonly uint[] _testUnpackedExtensionsFieldTags = new uint[] { }; + public static TestUnpackedExtensions DefaultInstance + { + get { return defaultInstance; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _moreBytesFieldNames; - if (data_.Count > 0) { - output.WriteBytesArray(1, field_names[0], data_); - } - UnknownFields.WriteTo(output); - } + public override TestUnpackedExtensions DefaultInstanceForType + { + get { return DefaultInstance; } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + protected override TestUnpackedExtensions ThisMessage + { + get { return this; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (pb::ByteString element in DataList) { - dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element); - } - size += dataSize; - size += 1 * data_.Count; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static MoreBytes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MoreBytes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MoreBytes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MoreBytes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MoreBytes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MoreBytes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static MoreBytes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static MoreBytes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static MoreBytes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MoreBytes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private MoreBytes MakeReadOnly() { - data_.MakeReadOnly(); - return this; - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(MoreBytes prototype) { - return new Builder(prototype); - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(MoreBytes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private MoreBytes result; - - private MoreBytes PrepareBuilder() { - if (resultIsReadOnly) { - MoreBytes original = result; - result = new MoreBytes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override MoreBytes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.MoreBytes.Descriptor; } - } - - public override MoreBytes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.MoreBytes.DefaultInstance; } - } - - public override MoreBytes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is MoreBytes) { - return MergeFrom((MoreBytes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(MoreBytes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.MoreBytes.DefaultInstance) return this; - PrepareBuilder(); - if (other.data_.Count != 0) { - result.data_.Add(other.data_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_moreBytesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _moreBytesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - input.ReadBytesArray(tag, field_name, result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public pbc::IPopsicleList DataList { - get { return PrepareBuilder().data_; } - } - public int DataCount { - get { return result.DataCount; } - } - public pb::ByteString GetData(int index) { - return result.GetData(index); - } - public Builder SetData(int index, pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.data_[index] = value; - return this; - } - public Builder AddData(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.data_.Add(value); - return this; - } - public Builder AddRangeData(scg::IEnumerable values) { - PrepareBuilder(); - result.data_.Add(values); - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.data_.Clear(); - return this; - } - } - static MoreBytes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Int32Message : pb::GeneratedMessage { - private Int32Message() { } - private static readonly Int32Message defaultInstance = new Int32Message().MakeReadOnly(); - private static readonly string[] _int32MessageFieldNames = new string[] { "data" }; - private static readonly uint[] _int32MessageFieldTags = new uint[] { 8 }; - public static Int32Message DefaultInstance { - get { return defaultInstance; } - } + public override bool IsInitialized + { + get + { + if (!ExtensionsAreInitialized) return false; + return true; + } + } - public override Int32Message DefaultInstanceForType { - get { return DefaultInstance; } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testUnpackedExtensionsFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); + } - protected override Int32Message ThisMessage { - get { return this; } - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int32Message__Descriptor; } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int32Message__FieldAccessorTable; } - } + size = 0; + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestUnpackedExtensions ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestUnpackedExtensions ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestUnpackedExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestUnpackedExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestUnpackedExtensions MakeReadOnly() + { + return this; + } - public const int DataFieldNumber = 1; - private bool hasData; - private int data_; - public bool HasData { - get { return hasData; } - } - public int Data { - get { return data_; } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestUnpackedExtensions prototype) + { + return new Builder(prototype); + } - public override bool IsInitialized { - get { - return true; - } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestUnpackedExtensions cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _int32MessageFieldNames; - if (hasData) { - output.WriteInt32(1, field_names[0], Data); - } - UnknownFields.WriteTo(output); - } + private bool resultIsReadOnly; + private TestUnpackedExtensions result; - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + private TestUnpackedExtensions PrepareBuilder() + { + if (resultIsReadOnly) + { + TestUnpackedExtensions original = result; + result = new TestUnpackedExtensions(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasData) { - size += pb::CodedOutputStream.ComputeInt32Size(1, Data); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static Int32Message ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Int32Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Int32Message ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Int32Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Int32Message ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Int32Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static Int32Message ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static Int32Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static Int32Message ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Int32Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private Int32Message MakeReadOnly() { - return this; - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Int32Message prototype) { - return new Builder(prototype); - } + protected override TestUnpackedExtensions MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Int32Message cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Int32Message result; - - private Int32Message PrepareBuilder() { - if (resultIsReadOnly) { - Int32Message original = result; - result = new Int32Message(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Int32Message MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.Int32Message.Descriptor; } - } - - public override Int32Message DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.Int32Message.DefaultInstance; } - } - - public override Int32Message BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is Int32Message) { - return MergeFrom((Int32Message) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(Int32Message other) { - if (other == global::Google.ProtocolBuffers.TestProtos.Int32Message.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasData) { - Data = other.Data; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_int32MessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _int32MessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasData = input.ReadInt32(ref result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasData { - get { return result.hasData; } - } - public int Data { - get { return result.Data; } - set { SetData(value); } - } - public Builder SetData(int value) { - PrepareBuilder(); - result.hasData = true; - result.data_ = value; - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.hasData = false; - result.data_ = 0; - return this; - } - } - static Int32Message() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Uint32Message : pb::GeneratedMessage { - private Uint32Message() { } - private static readonly Uint32Message defaultInstance = new Uint32Message().MakeReadOnly(); - private static readonly string[] _uint32MessageFieldNames = new string[] { "data" }; - private static readonly uint[] _uint32MessageFieldTags = new uint[] { 8 }; - public static Uint32Message DefaultInstance { - get { return defaultInstance; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public override Uint32Message DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - protected override Uint32Message ThisMessage { - get { return this; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.Descriptor; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint32Message__Descriptor; } - } + public override TestUnpackedExtensions DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.DefaultInstance; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint32Message__FieldAccessorTable; } - } + public override TestUnpackedExtensions BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public const int DataFieldNumber = 1; - private bool hasData; - private uint data_; - public bool HasData { - get { return hasData; } - } - [global::System.CLSCompliant(false)] - public uint Data { - get { return data_; } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestUnpackedExtensions) + { + return MergeFrom((TestUnpackedExtensions)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public override bool IsInitialized { - get { - return true; - } - } + public override Builder MergeFrom(TestUnpackedExtensions other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.DefaultInstance) return this; + PrepareBuilder(); + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _uint32MessageFieldNames; - if (hasData) { - output.WriteUInt32(1, field_names[0], Data); - } - UnknownFields.WriteTo(output); - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testUnpackedExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testUnpackedExtensionsFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasData) { - size += pb::CodedOutputStream.ComputeUInt32Size(1, Data); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static Uint32Message ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Uint32Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Uint32Message ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Uint32Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Uint32Message ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Uint32Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static Uint32Message ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static Uint32Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static Uint32Message ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Uint32Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private Uint32Message MakeReadOnly() { - return this; - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Uint32Message prototype) { - return new Builder(prototype); + } + static TestUnpackedExtensions() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Uint32Message cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Uint32Message result; - - private Uint32Message PrepareBuilder() { - if (resultIsReadOnly) { - Uint32Message original = result; - result = new Uint32Message(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Uint32Message MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.Uint32Message.Descriptor; } - } - - public override Uint32Message DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.Uint32Message.DefaultInstance; } - } - - public override Uint32Message BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is Uint32Message) { - return MergeFrom((Uint32Message) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(Uint32Message other) { - if (other == global::Google.ProtocolBuffers.TestProtos.Uint32Message.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasData) { - Data = other.Data; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_uint32MessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _uint32MessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasData = input.ReadUInt32(ref result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasData { - get { return result.hasData; } - } - [global::System.CLSCompliant(false)] - public uint Data { - get { return result.Data; } - set { SetData(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetData(uint value) { - PrepareBuilder(); - result.hasData = true; - result.data_ = value; - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.hasData = false; - result.data_ = 0; - return this; - } - } - static Uint32Message() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Int64Message : pb::GeneratedMessage { - private Int64Message() { } - private static readonly Int64Message defaultInstance = new Int64Message().MakeReadOnly(); - private static readonly string[] _int64MessageFieldNames = new string[] { "data" }; - private static readonly uint[] _int64MessageFieldTags = new uint[] { 8 }; - public static Int64Message DefaultInstance { - get { return defaultInstance; } - } - - public override Int64Message DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override Int64Message ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int64Message__Descriptor; } - } + public sealed partial class TestDynamicExtensions : pb::GeneratedMessage + { + private TestDynamicExtensions() { } + private static readonly TestDynamicExtensions defaultInstance = new TestDynamicExtensions().MakeReadOnly(); + private static readonly string[] _testDynamicExtensionsFieldNames = new string[] { "dynamic_enum_extension", "dynamic_message_extension", "enum_extension", "message_extension", "packed_extension", "repeated_extension", "scalar_extension" }; + private static readonly uint[] _testDynamicExtensionsFieldTags = new uint[] { 16016, 16034, 16008, 16026, 16050, 16042, 16005 }; + public static TestDynamicExtensions DefaultInstance + { + get { return defaultInstance; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Int64Message__FieldAccessorTable; } - } + public override TestDynamicExtensions DefaultInstanceForType + { + get { return DefaultInstance; } + } - public const int DataFieldNumber = 1; - private bool hasData; - private long data_; - public bool HasData { - get { return hasData; } - } - public long Data { - get { return data_; } - } + protected override TestDynamicExtensions ThisMessage + { + get { return this; } + } - public override bool IsInitialized { - get { - return true; - } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _int64MessageFieldNames; - if (hasData) { - output.WriteInt64(1, field_names[0], Data); - } - UnknownFields.WriteTo(output); - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable; } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + public enum DynamicEnumType + { + DYNAMIC_FOO = 2200, + DYNAMIC_BAR = 2201, + DYNAMIC_BAZ = 2202, + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasData) { - size += pb::CodedOutputStream.ComputeInt64Size(1, Data); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static Int64Message ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Int64Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Int64Message ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Int64Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Int64Message ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Int64Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static Int64Message ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static Int64Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static Int64Message ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Int64Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private Int64Message MakeReadOnly() { - return this; - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class DynamicMessageType : pb::GeneratedMessage + { + private DynamicMessageType() { } + private static readonly DynamicMessageType defaultInstance = new DynamicMessageType().MakeReadOnly(); + private static readonly string[] _dynamicMessageTypeFieldNames = new string[] { "dynamic_field" }; + private static readonly uint[] _dynamicMessageTypeFieldTags = new uint[] { 16800 }; + public static DynamicMessageType DefaultInstance + { + get { return defaultInstance; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Int64Message prototype) { - return new Builder(prototype); - } + public override DynamicMessageType DefaultInstanceForType + { + get { return DefaultInstance; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Int64Message cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Int64Message result; - - private Int64Message PrepareBuilder() { - if (resultIsReadOnly) { - Int64Message original = result; - result = new Int64Message(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Int64Message MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.Int64Message.Descriptor; } - } - - public override Int64Message DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.Int64Message.DefaultInstance; } - } - - public override Int64Message BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is Int64Message) { - return MergeFrom((Int64Message) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(Int64Message other) { - if (other == global::Google.ProtocolBuffers.TestProtos.Int64Message.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasData) { - Data = other.Data; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_int64MessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _int64MessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasData = input.ReadInt64(ref result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasData { - get { return result.hasData; } - } - public long Data { - get { return result.Data; } - set { SetData(value); } - } - public Builder SetData(long value) { - PrepareBuilder(); - result.hasData = true; - result.data_ = value; - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.hasData = false; - result.data_ = 0L; - return this; - } - } - static Int64Message() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Uint64Message : pb::GeneratedMessage { - private Uint64Message() { } - private static readonly Uint64Message defaultInstance = new Uint64Message().MakeReadOnly(); - private static readonly string[] _uint64MessageFieldNames = new string[] { "data" }; - private static readonly uint[] _uint64MessageFieldTags = new uint[] { 8 }; - public static Uint64Message DefaultInstance { - get { return defaultInstance; } - } + protected override DynamicMessageType ThisMessage + { + get { return this; } + } - public override Uint64Message DefaultInstanceForType { - get { return DefaultInstance; } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor; } + } - protected override Uint64Message ThisMessage { - get { return this; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint64Message__Descriptor; } - } + public const int DynamicFieldFieldNumber = 2100; + private bool hasDynamicField; + private int dynamicField_; + public bool HasDynamicField + { + get { return hasDynamicField; } + } + public int DynamicField + { + get { return dynamicField_; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_Uint64Message__FieldAccessorTable; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - public const int DataFieldNumber = 1; - private bool hasData; - private ulong data_; - public bool HasData { - get { return hasData; } - } - [global::System.CLSCompliant(false)] - public ulong Data { - get { return data_; } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _dynamicMessageTypeFieldNames; + if (hasDynamicField) + { + output.WriteInt32(2100, field_names[0], DynamicField); + } + UnknownFields.WriteTo(output); + } - public override bool IsInitialized { - get { - return true; - } - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _uint64MessageFieldNames; - if (hasData) { - output.WriteUInt64(1, field_names[0], Data); - } - UnknownFields.WriteTo(output); - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + size = 0; + if (hasDynamicField) + { + size += pb::CodedOutputStream.ComputeInt32Size(2100, DynamicField); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static DynamicMessageType ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static DynamicMessageType ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static DynamicMessageType ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static DynamicMessageType ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static DynamicMessageType ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private DynamicMessageType MakeReadOnly() + { + return this; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasData) { - size += pb::CodedOutputStream.ComputeUInt64Size(1, Data); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static Uint64Message ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Uint64Message ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Uint64Message ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Uint64Message ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Uint64Message ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Uint64Message ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static Uint64Message ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static Uint64Message ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static Uint64Message ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Uint64Message ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private Uint64Message MakeReadOnly() { - return this; - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(DynamicMessageType prototype) + { + return new Builder(prototype); + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Uint64Message prototype) { - return new Builder(prototype); - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(DynamicMessageType cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Uint64Message cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Uint64Message result; - - private Uint64Message PrepareBuilder() { - if (resultIsReadOnly) { - Uint64Message original = result; - result = new Uint64Message(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Uint64Message MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.Uint64Message.Descriptor; } - } - - public override Uint64Message DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.Uint64Message.DefaultInstance; } - } - - public override Uint64Message BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is Uint64Message) { - return MergeFrom((Uint64Message) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(Uint64Message other) { - if (other == global::Google.ProtocolBuffers.TestProtos.Uint64Message.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasData) { - Data = other.Data; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_uint64MessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _uint64MessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasData = input.ReadUInt64(ref result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasData { - get { return result.hasData; } - } - [global::System.CLSCompliant(false)] - public ulong Data { - get { return result.Data; } - set { SetData(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetData(ulong value) { - PrepareBuilder(); - result.hasData = true; - result.data_ = value; - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.hasData = false; - result.data_ = 0UL; - return this; - } - } - static Uint64Message() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class BoolMessage : pb::GeneratedMessage { - private BoolMessage() { } - private static readonly BoolMessage defaultInstance = new BoolMessage().MakeReadOnly(); - private static readonly string[] _boolMessageFieldNames = new string[] { "data" }; - private static readonly uint[] _boolMessageFieldTags = new uint[] { 8 }; - public static BoolMessage DefaultInstance { - get { return defaultInstance; } - } + private bool resultIsReadOnly; + private DynamicMessageType result; + + private DynamicMessageType PrepareBuilder() + { + if (resultIsReadOnly) + { + DynamicMessageType original = result; + result = new DynamicMessageType(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public override BoolMessage DefaultInstanceForType { - get { return DefaultInstance; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - protected override BoolMessage ThisMessage { - get { return this; } - } + protected override DynamicMessageType MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BoolMessage__Descriptor; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BoolMessage__FieldAccessorTable; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public const int DataFieldNumber = 1; - private bool hasData; - private bool data_; - public bool HasData { - get { return hasData; } - } - public bool Data { - get { return data_; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Descriptor; } + } - public override bool IsInitialized { - get { - return true; - } - } + public override DynamicMessageType DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _boolMessageFieldNames; - if (hasData) { - output.WriteBool(1, field_names[0], Data); - } - UnknownFields.WriteTo(output); - } + public override DynamicMessageType BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is DynamicMessageType) + { + return MergeFrom((DynamicMessageType)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasData) { - size += pb::CodedOutputStream.ComputeBoolSize(1, Data); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static BoolMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BoolMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BoolMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BoolMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BoolMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BoolMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static BoolMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static BoolMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static BoolMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BoolMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private BoolMessage MakeReadOnly() { - return this; - } + public override Builder MergeFrom(DynamicMessageType other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasDynamicField) + { + DynamicField = other.DynamicField; + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(BoolMessage prototype) { - return new Builder(prototype); - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(BoolMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private BoolMessage result; - - private BoolMessage PrepareBuilder() { - if (resultIsReadOnly) { - BoolMessage original = result; - result = new BoolMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override BoolMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.BoolMessage.Descriptor; } - } - - public override BoolMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.BoolMessage.DefaultInstance; } - } - - public override BoolMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is BoolMessage) { - return MergeFrom((BoolMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(BoolMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.BoolMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasData) { - Data = other.Data; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_boolMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _boolMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasData = input.ReadBool(ref result.data_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasData { - get { return result.hasData; } - } - public bool Data { - get { return result.Data; } - set { SetData(value); } - } - public Builder SetData(bool value) { - PrepareBuilder(); - result.hasData = true; - result.data_ = value; - return this; - } - public Builder ClearData() { - PrepareBuilder(); - result.hasData = false; - result.data_ = false; - return this; - } - } - static BoolMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestOneof : pb::GeneratedMessage { - private TestOneof() { } - private static readonly TestOneof defaultInstance = new TestOneof().MakeReadOnly(); - private static readonly string[] _testOneofFieldNames = new string[] { "foo_int", "foo_message", "foo_string", "foogroup" }; - private static readonly uint[] _testOneofFieldTags = new uint[] { 8, 26, 18, 35 }; - public static TestOneof DefaultInstance { - get { return defaultInstance; } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_dynamicMessageTypeFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _dynamicMessageTypeFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 16800: + { + result.hasDynamicField = input.ReadInt32(ref result.dynamicField_); + break; + } + } + } - public override TestOneof DefaultInstanceForType { - get { return DefaultInstance; } - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - protected override TestOneof ThisMessage { - get { return this; } - } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof__Descriptor; } - } + public bool HasDynamicField + { + get { return result.hasDynamicField; } + } + public int DynamicField + { + get { return result.DynamicField; } + set { SetDynamicField(value); } + } + public Builder SetDynamicField(int value) + { + PrepareBuilder(); + result.hasDynamicField = true; + result.dynamicField_ = value; + return this; + } + public Builder ClearDynamicField() + { + PrepareBuilder(); + result.hasDynamicField = false; + result.dynamicField_ = 0; + return this; + } + } + static DynamicMessageType() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof__FieldAccessorTable; } - } + } + #endregion - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class FooGroup : pb::GeneratedMessage { - private FooGroup() { } - private static readonly FooGroup defaultInstance = new FooGroup().MakeReadOnly(); - private static readonly string[] _fooGroupFieldNames = new string[] { "a", "b" }; - private static readonly uint[] _fooGroupFieldTags = new uint[] { 40, 50 }; - public static FooGroup DefaultInstance { - get { return defaultInstance; } + public const int ScalarExtensionFieldNumber = 2000; + private bool hasScalarExtension; + private uint scalarExtension_; + public bool HasScalarExtension + { + get { return hasScalarExtension; } + } + [global::System.CLSCompliant(false)] + public uint ScalarExtension + { + get { return scalarExtension_; } } - public override FooGroup DefaultInstanceForType { - get { return DefaultInstance; } + public const int EnumExtensionFieldNumber = 2001; + private bool hasEnumExtension; + private global::Google.ProtocolBuffers.TestProtos.ForeignEnum enumExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + public bool HasEnumExtension + { + get { return hasEnumExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumExtension + { + get { return enumExtension_; } } - protected override FooGroup ThisMessage { - get { return this; } + public const int DynamicEnumExtensionFieldNumber = 2002; + private bool hasDynamicEnumExtension; + private global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType dynamicEnumExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType.DYNAMIC_FOO; + public bool HasDynamicEnumExtension + { + get { return hasDynamicEnumExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType DynamicEnumExtension + { + get { return dynamicEnumExtension_; } } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof_FooGroup__Descriptor; } + public const int MessageExtensionFieldNumber = 2003; + private bool hasMessageExtension; + private global::Google.ProtocolBuffers.TestProtos.ForeignMessage messageExtension_; + public bool HasMessageExtension + { + get { return hasMessageExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageExtension + { + get { return messageExtension_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof_FooGroup__FieldAccessorTable; } + public const int DynamicMessageExtensionFieldNumber = 2004; + private bool hasDynamicMessageExtension; + private global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType dynamicMessageExtension_; + public bool HasDynamicMessageExtension + { + get { return hasDynamicMessageExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType DynamicMessageExtension + { + get { return dynamicMessageExtension_ ?? global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance; } } - public const int AFieldNumber = 5; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } + public const int RepeatedExtensionFieldNumber = 2005; + private pbc::PopsicleList repeatedExtension_ = new pbc::PopsicleList(); + public scg::IList RepeatedExtensionList + { + get { return pbc::Lists.AsReadOnly(repeatedExtension_); } } - public int A { - get { return a_; } + public int RepeatedExtensionCount + { + get { return repeatedExtension_.Count; } + } + public string GetRepeatedExtension(int index) + { + return repeatedExtension_[index]; } - public const int BFieldNumber = 6; - private bool hasB; - private string b_ = ""; - public bool HasB { - get { return hasB; } + public const int PackedExtensionFieldNumber = 2006; + private int packedExtensionMemoizedSerializedSize; + private pbc::PopsicleList packedExtension_ = new pbc::PopsicleList(); + public scg::IList PackedExtensionList + { + get { return pbc::Lists.AsReadOnly(packedExtension_); } } - public string B { - get { return b_; } + public int PackedExtensionCount + { + get { return packedExtension_.Count; } + } + public int GetPackedExtension(int index) + { + return packedExtension_[index]; } - public override bool IsInitialized { - get { - return true; - } + public override bool IsInitialized + { + get + { + return true; + } } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooGroupFieldNames; - if (hasA) { - output.WriteInt32(5, field_names[0], A); - } - if (hasB) { - output.WriteString(6, field_names[1], B); - } - UnknownFields.WriteTo(output); + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testDynamicExtensionsFieldNames; + if (hasScalarExtension) + { + output.WriteFixed32(2000, field_names[6], ScalarExtension); + } + if (hasEnumExtension) + { + output.WriteEnum(2001, field_names[2], (int)EnumExtension, EnumExtension); + } + if (hasDynamicEnumExtension) + { + output.WriteEnum(2002, field_names[0], (int)DynamicEnumExtension, DynamicEnumExtension); + } + if (hasMessageExtension) + { + output.WriteMessage(2003, field_names[3], MessageExtension); + } + if (hasDynamicMessageExtension) + { + output.WriteMessage(2004, field_names[1], DynamicMessageExtension); + } + if (repeatedExtension_.Count > 0) + { + output.WriteStringArray(2005, field_names[5], repeatedExtension_); + } + if (packedExtension_.Count > 0) + { + output.WritePackedSInt32Array(2006, field_names[4], packedExtensionMemoizedSerializedSize, packedExtension_); + } + UnknownFields.WriteTo(output); } private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(5, A); - } - if (hasB) { - size += pb::CodedOutputStream.ComputeStringSize(6, B); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; + size = 0; + if (hasScalarExtension) + { + size += pb::CodedOutputStream.ComputeFixed32Size(2000, ScalarExtension); + } + if (hasEnumExtension) + { + size += pb::CodedOutputStream.ComputeEnumSize(2001, (int)EnumExtension); + } + if (hasDynamicEnumExtension) + { + size += pb::CodedOutputStream.ComputeEnumSize(2002, (int)DynamicEnumExtension); + } + if (hasMessageExtension) + { + size += pb::CodedOutputStream.ComputeMessageSize(2003, MessageExtension); + } + if (hasDynamicMessageExtension) + { + size += pb::CodedOutputStream.ComputeMessageSize(2004, DynamicMessageExtension); + } + { + int dataSize = 0; + foreach (string element in RepeatedExtensionList) + { + dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedExtension_.Count; + } + { + int dataSize = 0; + foreach (int element in PackedExtensionList) + { + dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); + } + size += dataSize; + if (packedExtension_.Count != 0) + { + size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); + } + packedExtensionMemoizedSerializedSize = dataSize; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; } - public static FooGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public static TestDynamicExtensions ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static FooGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public static TestDynamicExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public static FooGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public static TestDynamicExtensions ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static FooGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public static TestDynamicExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public static FooGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public static TestDynamicExtensions ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static FooGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public static TestDynamicExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + public static TestDynamicExtensions ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); } - public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + public static TestDynamicExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); } - public static FooGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public static TestDynamicExtensions ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static FooGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public static TestDynamicExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - private FooGroup MakeReadOnly() { - return this; + private TestDynamicExtensions MakeReadOnly() + { + repeatedExtension_.MakeReadOnly(); + packedExtension_.MakeReadOnly(); + return this; } public static Builder CreateBuilder() { return new Builder(); } public override Builder ToBuilder() { return CreateBuilder(this); } public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(FooGroup prototype) { - return new Builder(prototype); + public static Builder CreateBuilder(TestDynamicExtensions prototype) + { + return new Builder(prototype); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(FooGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private FooGroup result; - - private FooGroup PrepareBuilder() { - if (resultIsReadOnly) { - FooGroup original = result; - result = new FooGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override FooGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestDynamicExtensions cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.Descriptor; } - } - public override FooGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance; } - } + private bool resultIsReadOnly; + private TestDynamicExtensions result; - public override FooGroup BuildPartial() { - if (resultIsReadOnly) { - return result; + private TestDynamicExtensions PrepareBuilder() + { + if (resultIsReadOnly) + { + TestDynamicExtensions original = result; + result = new TestDynamicExtensions(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - public override Builder MergeFrom(pb::IMessage other) { - if (other is FooGroup) { - return MergeFrom((FooGroup) other); - } else { - base.MergeFrom(other); - return this; + public override bool IsInitialized + { + get { return result.IsInitialized; } } - } - public override Builder MergeFrom(FooGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; + protected override TestDynamicExtensions MessageBeingBuilt + { + get { return PrepareBuilder(); } } - if (other.HasB) { - B = other.B; + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooGroupFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 40: { - result.hasA = input.ReadInt32(ref result.a_); - break; + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); } - case 50: { - result.hasB = input.ReadString(ref result.b_); - break; + else + { + return new Builder().MergeFrom(result); } - } } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Descriptor; } } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - - public bool HasB { - get { return result.hasB; } - } - public string B { - get { return result.B; } - set { SetB(value); } - } - public Builder SetB(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasB = true; - result.b_ = value; - return this; - } - public Builder ClearB() { - PrepareBuilder(); - result.hasB = false; - result.b_ = ""; - return this; - } - } - static FooGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - } - #endregion + public override TestDynamicExtensions DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.DefaultInstance; } + } - public const int FooIntFieldNumber = 1; - private bool hasFooInt; - private int fooInt_; - public bool HasFooInt { - get { return hasFooInt; } - } - public int FooInt { - get { return fooInt_; } - } + public override TestDynamicExtensions BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public const int FooStringFieldNumber = 2; - private bool hasFooString; - private string fooString_ = ""; - public bool HasFooString { - get { return hasFooString; } - } - public string FooString { - get { return fooString_; } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestDynamicExtensions) + { + return MergeFrom((TestDynamicExtensions)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public const int FooMessageFieldNumber = 3; - private bool hasFooMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes fooMessage_; - public bool HasFooMessage { - get { return hasFooMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage { - get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } + public override Builder MergeFrom(TestDynamicExtensions other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasScalarExtension) + { + ScalarExtension = other.ScalarExtension; + } + if (other.HasEnumExtension) + { + EnumExtension = other.EnumExtension; + } + if (other.HasDynamicEnumExtension) + { + DynamicEnumExtension = other.DynamicEnumExtension; + } + if (other.HasMessageExtension) + { + MergeMessageExtension(other.MessageExtension); + } + if (other.HasDynamicMessageExtension) + { + MergeDynamicMessageExtension(other.DynamicMessageExtension); + } + if (other.repeatedExtension_.Count != 0) + { + result.repeatedExtension_.Add(other.repeatedExtension_); + } + if (other.packedExtension_.Count != 0) + { + result.packedExtension_.Add(other.packedExtension_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public const int FooGroupFieldNumber = 4; - private bool hasFooGroup; - private global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup fooGroup_; - public bool HasFooGroup { - get { return hasFooGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup FooGroup { - get { return fooGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance; } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public override bool IsInitialized { - get { - return true; - } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testDynamicExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testDynamicExtensionsFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 16005: + { + result.hasScalarExtension = input.ReadFixed32(ref result.scalarExtension_); + break; + } + case 16008: + { + object unknown; + if (input.ReadEnum(ref result.enumExtension_, out unknown)) + { + result.hasEnumExtension = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(2001, (ulong)(int)unknown); + } + break; + } + case 16016: + { + object unknown; + if (input.ReadEnum(ref result.dynamicEnumExtension_, out unknown)) + { + result.hasDynamicEnumExtension = true; + } + else if (unknown is int) + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + unknownFields.MergeVarintField(2002, (ulong)(int)unknown); + } + break; + } + case 16026: + { + global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); + if (result.hasMessageExtension) + { + subBuilder.MergeFrom(MessageExtension); + } + input.ReadMessage(subBuilder, extensionRegistry); + MessageExtension = subBuilder.BuildPartial(); + break; + } + case 16034: + { + global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.CreateBuilder(); + if (result.hasDynamicMessageExtension) + { + subBuilder.MergeFrom(DynamicMessageExtension); + } + input.ReadMessage(subBuilder, extensionRegistry); + DynamicMessageExtension = subBuilder.BuildPartial(); + break; + } + case 16042: + { + input.ReadStringArray(tag, field_name, result.repeatedExtension_); + break; + } + case 16050: + case 16048: + { + input.ReadSInt32Array(tag, field_name, result.packedExtension_); + break; + } + } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testOneofFieldNames; - if (hasFooInt) { - output.WriteInt32(1, field_names[0], FooInt); - } - if (hasFooString) { - output.WriteString(2, field_names[2], FooString); - } - if (hasFooMessage) { - output.WriteMessage(3, field_names[1], FooMessage); - } - if (hasFooGroup) { - output.WriteGroup(4, field_names[3], FooGroup); - } - UnknownFields.WriteTo(output); - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasFooInt) { - size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); - } - if (hasFooString) { - size += pb::CodedOutputStream.ComputeStringSize(2, FooString); - } - if (hasFooMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(3, FooMessage); - } - if (hasFooGroup) { - size += pb::CodedOutputStream.ComputeGroupSize(4, FooGroup); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestOneof ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestOneof ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestOneof ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestOneof ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestOneof ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestOneof ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestOneof ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestOneof ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestOneof ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestOneof ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestOneof MakeReadOnly() { - return this; - } + public bool HasScalarExtension + { + get { return result.hasScalarExtension; } + } + [global::System.CLSCompliant(false)] + public uint ScalarExtension + { + get { return result.ScalarExtension; } + set { SetScalarExtension(value); } + } + [global::System.CLSCompliant(false)] + public Builder SetScalarExtension(uint value) + { + PrepareBuilder(); + result.hasScalarExtension = true; + result.scalarExtension_ = value; + return this; + } + public Builder ClearScalarExtension() + { + PrepareBuilder(); + result.hasScalarExtension = false; + result.scalarExtension_ = 0; + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestOneof prototype) { - return new Builder(prototype); - } + public bool HasEnumExtension + { + get { return result.hasEnumExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumExtension + { + get { return result.EnumExtension; } + set { SetEnumExtension(value); } + } + public Builder SetEnumExtension(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) + { + PrepareBuilder(); + result.hasEnumExtension = true; + result.enumExtension_ = value; + return this; + } + public Builder ClearEnumExtension() + { + PrepareBuilder(); + result.hasEnumExtension = false; + result.enumExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; + return this; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestOneof cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestOneof result; - - private TestOneof PrepareBuilder() { - if (resultIsReadOnly) { - TestOneof original = result; - result = new TestOneof(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestOneof MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.Descriptor; } - } - - public override TestOneof DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneof.DefaultInstance; } - } - - public override TestOneof BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestOneof) { - return MergeFrom((TestOneof) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestOneof other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasFooInt) { - FooInt = other.FooInt; - } - if (other.HasFooString) { - FooString = other.FooString; - } - if (other.HasFooMessage) { - MergeFooMessage(other.FooMessage); - } - if (other.HasFooGroup) { - MergeFooGroup(other.FooGroup); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testOneofFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testOneofFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasFooInt = input.ReadInt32(ref result.fooInt_); - break; - } - case 18: { - result.hasFooString = input.ReadString(ref result.fooString_); - break; - } - case 26: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasFooMessage) { - subBuilder.MergeFrom(FooMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - FooMessage = subBuilder.BuildPartial(); - break; - } - case 35: { - global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.CreateBuilder(); - if (result.hasFooGroup) { - subBuilder.MergeFrom(FooGroup); - } - input.ReadGroup(4, subBuilder, extensionRegistry); - FooGroup = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasFooInt { - get { return result.hasFooInt; } - } - public int FooInt { - get { return result.FooInt; } - set { SetFooInt(value); } - } - public Builder SetFooInt(int value) { - PrepareBuilder(); - result.hasFooInt = true; - result.fooInt_ = value; - return this; - } - public Builder ClearFooInt() { - PrepareBuilder(); - result.hasFooInt = false; - result.fooInt_ = 0; - return this; - } - - public bool HasFooString { - get { return result.hasFooString; } - } - public string FooString { - get { return result.FooString; } - set { SetFooString(value); } - } - public Builder SetFooString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooString = true; - result.fooString_ = value; - return this; - } - public Builder ClearFooString() { - PrepareBuilder(); - result.hasFooString = false; - result.fooString_ = ""; - return this; - } - - public bool HasFooMessage { - get { return result.hasFooMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage { - get { return result.FooMessage; } - set { SetFooMessage(value); } - } - public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooMessage = true; - result.fooMessage_ = value; - return this; - } - public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasFooMessage = true; - result.fooMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasFooMessage && - result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); - } else { - result.fooMessage_ = value; - } - result.hasFooMessage = true; - return this; - } - public Builder ClearFooMessage() { - PrepareBuilder(); - result.hasFooMessage = false; - result.fooMessage_ = null; - return this; - } - - public bool HasFooGroup { - get { return result.hasFooGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup FooGroup { - get { return result.FooGroup; } - set { SetFooGroup(value); } - } - public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooGroup = true; - result.fooGroup_ = value; - return this; - } - public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasFooGroup = true; - result.fooGroup_ = builderForValue.Build(); - return this; - } - public Builder MergeFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasFooGroup && - result.fooGroup_ != global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.DefaultInstance) { - result.fooGroup_ = global::Google.ProtocolBuffers.TestProtos.TestOneof.Types.FooGroup.CreateBuilder(result.fooGroup_).MergeFrom(value).BuildPartial(); - } else { - result.fooGroup_ = value; - } - result.hasFooGroup = true; - return this; - } - public Builder ClearFooGroup() { - PrepareBuilder(); - result.hasFooGroup = false; - result.fooGroup_ = null; - return this; - } - } - static TestOneof() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestOneofBackwardsCompatible : pb::GeneratedMessage { - private TestOneofBackwardsCompatible() { } - private static readonly TestOneofBackwardsCompatible defaultInstance = new TestOneofBackwardsCompatible().MakeReadOnly(); - private static readonly string[] _testOneofBackwardsCompatibleFieldNames = new string[] { "foo_int", "foo_message", "foo_string", "foogroup" }; - private static readonly uint[] _testOneofBackwardsCompatibleFieldTags = new uint[] { 8, 26, 18, 35 }; - public static TestOneofBackwardsCompatible DefaultInstance { - get { return defaultInstance; } - } + public bool HasDynamicEnumExtension + { + get { return result.hasDynamicEnumExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType DynamicEnumExtension + { + get { return result.DynamicEnumExtension; } + set { SetDynamicEnumExtension(value); } + } + public Builder SetDynamicEnumExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType value) + { + PrepareBuilder(); + result.hasDynamicEnumExtension = true; + result.dynamicEnumExtension_ = value; + return this; + } + public Builder ClearDynamicEnumExtension() + { + PrepareBuilder(); + result.hasDynamicEnumExtension = false; + result.dynamicEnumExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType.DYNAMIC_FOO; + return this; + } - public override TestOneofBackwardsCompatible DefaultInstanceForType { - get { return DefaultInstance; } - } + public bool HasMessageExtension + { + get { return result.hasMessageExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageExtension + { + get { return result.MessageExtension; } + set { SetMessageExtension(value); } + } + public Builder SetMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasMessageExtension = true; + result.messageExtension_ = value; + return this; + } + public Builder SetMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasMessageExtension = true; + result.messageExtension_ = builderForValue.Build(); + return this; + } + public Builder MergeMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasMessageExtension && + result.messageExtension_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) + { + result.messageExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.messageExtension_).MergeFrom(value).BuildPartial(); + } + else + { + result.messageExtension_ = value; + } + result.hasMessageExtension = true; + return this; + } + public Builder ClearMessageExtension() + { + PrepareBuilder(); + result.hasMessageExtension = false; + result.messageExtension_ = null; + return this; + } - protected override TestOneofBackwardsCompatible ThisMessage { - get { return this; } - } + public bool HasDynamicMessageExtension + { + get { return result.hasDynamicMessageExtension; } + } + public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType DynamicMessageExtension + { + get { return result.DynamicMessageExtension; } + set { SetDynamicMessageExtension(value); } + } + public Builder SetDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasDynamicMessageExtension = true; + result.dynamicMessageExtension_ = value; + return this; + } + public Builder SetDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasDynamicMessageExtension = true; + result.dynamicMessageExtension_ = builderForValue.Build(); + return this; + } + public Builder MergeDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasDynamicMessageExtension && + result.dynamicMessageExtension_ != global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance) + { + result.dynamicMessageExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.CreateBuilder(result.dynamicMessageExtension_).MergeFrom(value).BuildPartial(); + } + else + { + result.dynamicMessageExtension_ = value; + } + result.hasDynamicMessageExtension = true; + return this; + } + public Builder ClearDynamicMessageExtension() + { + PrepareBuilder(); + result.hasDynamicMessageExtension = false; + result.dynamicMessageExtension_ = null; + return this; + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible__Descriptor; } - } + public pbc::IPopsicleList RepeatedExtensionList + { + get { return PrepareBuilder().repeatedExtension_; } + } + public int RepeatedExtensionCount + { + get { return result.RepeatedExtensionCount; } + } + public string GetRepeatedExtension(int index) + { + return result.GetRepeatedExtension(index); + } + public Builder SetRepeatedExtension(int index, string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedExtension_[index] = value; + return this; + } + public Builder AddRepeatedExtension(string value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedExtension_.Add(value); + return this; + } + public Builder AddRangeRepeatedExtension(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedExtension_.Add(values); + return this; + } + public Builder ClearRepeatedExtension() + { + PrepareBuilder(); + result.repeatedExtension_.Clear(); + return this; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible__FieldAccessorTable; } + public pbc::IPopsicleList PackedExtensionList + { + get { return PrepareBuilder().packedExtension_; } + } + public int PackedExtensionCount + { + get { return result.PackedExtensionCount; } + } + public int GetPackedExtension(int index) + { + return result.GetPackedExtension(index); + } + public Builder SetPackedExtension(int index, int value) + { + PrepareBuilder(); + result.packedExtension_[index] = value; + return this; + } + public Builder AddPackedExtension(int value) + { + PrepareBuilder(); + result.packedExtension_.Add(value); + return this; + } + public Builder AddRangePackedExtension(scg::IEnumerable values) + { + PrepareBuilder(); + result.packedExtension_.Add(values); + return this; + } + public Builder ClearPackedExtension() + { + PrepareBuilder(); + result.packedExtension_.Clear(); + return this; + } + } + static TestDynamicExtensions() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } - #region Nested types [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class FooGroup : pb::GeneratedMessage { - private FooGroup() { } - private static readonly FooGroup defaultInstance = new FooGroup().MakeReadOnly(); - private static readonly string[] _fooGroupFieldNames = new string[] { "a", "b" }; - private static readonly uint[] _fooGroupFieldTags = new uint[] { 40, 50 }; - public static FooGroup DefaultInstance { - get { return defaultInstance; } + public sealed partial class TestRepeatedScalarDifferentTagSizes : pb::GeneratedMessage + { + private TestRepeatedScalarDifferentTagSizes() { } + private static readonly TestRepeatedScalarDifferentTagSizes defaultInstance = new TestRepeatedScalarDifferentTagSizes().MakeReadOnly(); + private static readonly string[] _testRepeatedScalarDifferentTagSizesFieldNames = new string[] { "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_int32", "repeated_int64", "repeated_uint64" }; + private static readonly uint[] _testRepeatedScalarDifferentTagSizesFieldTags = new uint[] { 101, 16369, 2097141, 104, 16376, 2097144 }; + public static TestRepeatedScalarDifferentTagSizes DefaultInstance + { + get { return defaultInstance; } } - public override FooGroup DefaultInstanceForType { - get { return DefaultInstance; } + public override TestRepeatedScalarDifferentTagSizes DefaultInstanceForType + { + get { return DefaultInstance; } } - protected override FooGroup ThisMessage { - get { return this; } + protected override TestRepeatedScalarDifferentTagSizes ThisMessage + { + get { return this; } } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__Descriptor; } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor; } } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneofBackwardsCompatible_FooGroup__FieldAccessorTable; } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable; } } - public const int AFieldNumber = 5; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } + public const int RepeatedFixed32FieldNumber = 12; + private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedFixed32List + { + get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } } - public int A { - get { return a_; } - } - - public const int BFieldNumber = 6; - private bool hasB; - private string b_ = ""; - public bool HasB { - get { return hasB; } + public int RepeatedFixed32Count + { + get { return repeatedFixed32_.Count; } } - public string B { - get { return b_; } + [global::System.CLSCompliant(false)] + public uint GetRepeatedFixed32(int index) + { + return repeatedFixed32_[index]; } - public override bool IsInitialized { - get { - return true; - } + public const int RepeatedInt32FieldNumber = 13; + private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); + public scg::IList RepeatedInt32List + { + get { return pbc::Lists.AsReadOnly(repeatedInt32_); } } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooGroupFieldNames; - if (hasA) { - output.WriteInt32(5, field_names[0], A); - } - if (hasB) { - output.WriteString(6, field_names[1], B); - } - UnknownFields.WriteTo(output); + public int RepeatedInt32Count + { + get { return repeatedInt32_.Count; } } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } + public int GetRepeatedInt32(int index) + { + return repeatedInt32_[index]; } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(5, A); - } - if (hasB) { - size += pb::CodedOutputStream.ComputeStringSize(6, B); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; + public const int RepeatedFixed64FieldNumber = 2046; + private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedFixed64List + { + get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } } - public static FooGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public int RepeatedFixed64Count + { + get { return repeatedFixed64_.Count; } } - public static FooGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + [global::System.CLSCompliant(false)] + public ulong GetRepeatedFixed64(int index) + { + return repeatedFixed64_[index]; } - public static FooGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + + public const int RepeatedInt64FieldNumber = 2047; + private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); + public scg::IList RepeatedInt64List + { + get { return pbc::Lists.AsReadOnly(repeatedInt64_); } } - public static FooGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public int RepeatedInt64Count + { + get { return repeatedInt64_.Count; } } - public static FooGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public long GetRepeatedInt64(int index) + { + return repeatedInt64_[index]; } - public static FooGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + + public const int RepeatedFloatFieldNumber = 262142; + private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); + public scg::IList RepeatedFloatList + { + get { return pbc::Lists.AsReadOnly(repeatedFloat_); } } - public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + public int RepeatedFloatCount + { + get { return repeatedFloat_.Count; } } - public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + public float GetRepeatedFloat(int index) + { + return repeatedFloat_[index]; } - public static FooGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + + public const int RepeatedUint64FieldNumber = 262143; + private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); + [global::System.CLSCompliant(false)] + public scg::IList RepeatedUint64List + { + get { return pbc::Lists.AsReadOnly(repeatedUint64_); } } - public static FooGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public int RepeatedUint64Count + { + get { return repeatedUint64_.Count; } } - private FooGroup MakeReadOnly() { - return this; + [global::System.CLSCompliant(false)] + public ulong GetRepeatedUint64(int index) + { + return repeatedUint64_[index]; } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(FooGroup prototype) { - return new Builder(prototype); + public override bool IsInitialized + { + get + { + return true; + } } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(FooGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private FooGroup result; - - private FooGroup PrepareBuilder() { - if (resultIsReadOnly) { - FooGroup original = result; - result = new FooGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override FooGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testRepeatedScalarDifferentTagSizesFieldNames; + if (repeatedFixed32_.Count > 0) + { + output.WriteFixed32Array(12, field_names[0], repeatedFixed32_); } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.Descriptor; } - } - - public override FooGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance; } - } - - public override FooGroup BuildPartial() { - if (resultIsReadOnly) { - return result; + if (repeatedInt32_.Count > 0) + { + output.WriteInt32Array(13, field_names[3], repeatedInt32_); } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is FooGroup) { - return MergeFrom((FooGroup) other); - } else { - base.MergeFrom(other); - return this; + if (repeatedFixed64_.Count > 0) + { + output.WriteFixed64Array(2046, field_names[1], repeatedFixed64_); } - } - - public override Builder MergeFrom(FooGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; + if (repeatedInt64_.Count > 0) + { + output.WriteInt64Array(2047, field_names[4], repeatedInt64_); } - if (other.HasB) { - B = other.B; + if (repeatedFloat_.Count > 0) + { + output.WriteFloatArray(262142, field_names[2], repeatedFloat_); } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooGroupFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 40: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - case 50: { - result.hasB = input.ReadString(ref result.b_); - break; - } - } + if (repeatedUint64_.Count > 0) + { + output.WriteUInt64Array(262143, field_names[5], repeatedUint64_); } + UnknownFields.WriteTo(output); + } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - - public bool HasB { - get { return result.hasB; } - } - public string B { - get { return result.B; } - set { SetB(value); } - } - public Builder SetB(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasB = true; - result.b_ = value; - return this; - } - public Builder ClearB() { - PrepareBuilder(); - result.hasB = false; - result.b_ = ""; - return this; - } } - static FooGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - } - #endregion - - public const int FooIntFieldNumber = 1; - private bool hasFooInt; - private int fooInt_; - public bool HasFooInt { - get { return hasFooInt; } - } - public int FooInt { - get { return fooInt_; } - } - - public const int FooStringFieldNumber = 2; - private bool hasFooString; - private string fooString_ = ""; - public bool HasFooString { - get { return hasFooString; } - } - public string FooString { - get { return fooString_; } - } - - public const int FooMessageFieldNumber = 3; - private bool hasFooMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes fooMessage_; - public bool HasFooMessage { - get { return hasFooMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage { - get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } - - public const int FooGroupFieldNumber = 4; - private bool hasFooGroup; - private global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup fooGroup_; - public bool HasFooGroup { - get { return hasFooGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup FooGroup { - get { return fooGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance; } - } - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testOneofBackwardsCompatibleFieldNames; - if (hasFooInt) { - output.WriteInt32(1, field_names[0], FooInt); - } - if (hasFooString) { - output.WriteString(2, field_names[2], FooString); - } - if (hasFooMessage) { - output.WriteMessage(3, field_names[1], FooMessage); - } - if (hasFooGroup) { - output.WriteGroup(4, field_names[3], FooGroup); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasFooInt) { - size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); - } - if (hasFooString) { - size += pb::CodedOutputStream.ComputeStringSize(2, FooString); - } - if (hasFooMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(3, FooMessage); - } - if (hasFooGroup) { - size += pb::CodedOutputStream.ComputeGroupSize(4, FooGroup); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestOneofBackwardsCompatible ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestOneofBackwardsCompatible ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestOneofBackwardsCompatible ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestOneofBackwardsCompatible ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestOneofBackwardsCompatible ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestOneofBackwardsCompatible ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestOneofBackwardsCompatible ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestOneofBackwardsCompatible ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestOneofBackwardsCompatible ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestOneofBackwardsCompatible ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestOneofBackwardsCompatible MakeReadOnly() { - return this; - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestOneofBackwardsCompatible prototype) { - return new Builder(prototype); - } + size = 0; + { + int dataSize = 0; + dataSize = 4 * repeatedFixed32_.Count; + size += dataSize; + size += 1 * repeatedFixed32_.Count; + } + { + int dataSize = 0; + foreach (int element in RepeatedInt32List) + { + dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + } + size += dataSize; + size += 1 * repeatedInt32_.Count; + } + { + int dataSize = 0; + dataSize = 8 * repeatedFixed64_.Count; + size += dataSize; + size += 2 * repeatedFixed64_.Count; + } + { + int dataSize = 0; + foreach (long element in RepeatedInt64List) + { + dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); + } + size += dataSize; + size += 2 * repeatedInt64_.Count; + } + { + int dataSize = 0; + dataSize = 4 * repeatedFloat_.Count; + size += dataSize; + size += 3 * repeatedFloat_.Count; + } + { + int dataSize = 0; + foreach (ulong element in RepeatedUint64List) + { + dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); + } + size += dataSize; + size += 3 * repeatedUint64_.Count; + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestRepeatedScalarDifferentTagSizes MakeReadOnly() + { + repeatedFixed32_.MakeReadOnly(); + repeatedInt32_.MakeReadOnly(); + repeatedFixed64_.MakeReadOnly(); + repeatedInt64_.MakeReadOnly(); + repeatedFloat_.MakeReadOnly(); + repeatedUint64_.MakeReadOnly(); + return this; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestOneofBackwardsCompatible cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestOneofBackwardsCompatible result; - - private TestOneofBackwardsCompatible PrepareBuilder() { - if (resultIsReadOnly) { - TestOneofBackwardsCompatible original = result; - result = new TestOneofBackwardsCompatible(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestOneofBackwardsCompatible MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Descriptor; } - } - - public override TestOneofBackwardsCompatible DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.DefaultInstance; } - } - - public override TestOneofBackwardsCompatible BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestOneofBackwardsCompatible) { - return MergeFrom((TestOneofBackwardsCompatible) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestOneofBackwardsCompatible other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasFooInt) { - FooInt = other.FooInt; - } - if (other.HasFooString) { - FooString = other.FooString; - } - if (other.HasFooMessage) { - MergeFooMessage(other.FooMessage); - } - if (other.HasFooGroup) { - MergeFooGroup(other.FooGroup); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testOneofBackwardsCompatibleFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testOneofBackwardsCompatibleFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasFooInt = input.ReadInt32(ref result.fooInt_); - break; - } - case 18: { - result.hasFooString = input.ReadString(ref result.fooString_); - break; - } - case 26: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasFooMessage) { - subBuilder.MergeFrom(FooMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - FooMessage = subBuilder.BuildPartial(); - break; - } - case 35: { - global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.CreateBuilder(); - if (result.hasFooGroup) { - subBuilder.MergeFrom(FooGroup); - } - input.ReadGroup(4, subBuilder, extensionRegistry); - FooGroup = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasFooInt { - get { return result.hasFooInt; } - } - public int FooInt { - get { return result.FooInt; } - set { SetFooInt(value); } - } - public Builder SetFooInt(int value) { - PrepareBuilder(); - result.hasFooInt = true; - result.fooInt_ = value; - return this; - } - public Builder ClearFooInt() { - PrepareBuilder(); - result.hasFooInt = false; - result.fooInt_ = 0; - return this; - } - - public bool HasFooString { - get { return result.hasFooString; } - } - public string FooString { - get { return result.FooString; } - set { SetFooString(value); } - } - public Builder SetFooString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooString = true; - result.fooString_ = value; - return this; - } - public Builder ClearFooString() { - PrepareBuilder(); - result.hasFooString = false; - result.fooString_ = ""; - return this; - } - - public bool HasFooMessage { - get { return result.hasFooMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes FooMessage { - get { return result.FooMessage; } - set { SetFooMessage(value); } - } - public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooMessage = true; - result.fooMessage_ = value; - return this; - } - public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasFooMessage = true; - result.fooMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasFooMessage && - result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); - } else { - result.fooMessage_ = value; - } - result.hasFooMessage = true; - return this; - } - public Builder ClearFooMessage() { - PrepareBuilder(); - result.hasFooMessage = false; - result.fooMessage_ = null; - return this; - } - - public bool HasFooGroup { - get { return result.hasFooGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup FooGroup { - get { return result.FooGroup; } - set { SetFooGroup(value); } - } - public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooGroup = true; - result.fooGroup_ = value; - return this; - } - public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasFooGroup = true; - result.fooGroup_ = builderForValue.Build(); - return this; - } - public Builder MergeFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasFooGroup && - result.fooGroup_ != global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.DefaultInstance) { - result.fooGroup_ = global::Google.ProtocolBuffers.TestProtos.TestOneofBackwardsCompatible.Types.FooGroup.CreateBuilder(result.fooGroup_).MergeFrom(value).BuildPartial(); - } else { - result.fooGroup_ = value; - } - result.hasFooGroup = true; - return this; - } - public Builder ClearFooGroup() { - PrepareBuilder(); - result.hasFooGroup = false; - result.fooGroup_ = null; - return this; - } - } - static TestOneofBackwardsCompatible() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestOneof2 : pb::GeneratedMessage { - private TestOneof2() { } - private static readonly TestOneof2 defaultInstance = new TestOneof2().MakeReadOnly(); - private static readonly string[] _testOneof2FieldNames = new string[] { "bar_bytes", "bar_cord", "bar_enum", "bar_int", "bar_string", "bar_string_piece", "baz_int", "baz_string", "foo_bytes", "foo_cord", "foo_enum", "foo_int", "foo_lazy_message", "foo_message", "foo_string", "foo_string_piece", "foogroup" }; - private static readonly uint[] _testOneof2FieldTags = new uint[] { 130, 114, 136, 96, 106, 122, 144, 154, 42, 26, 48, 8, 90, 58, 18, 34, 67 }; - public static TestOneof2 DefaultInstance { - get { return defaultInstance; } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestRepeatedScalarDifferentTagSizes prototype) + { + return new Builder(prototype); + } - public override TestOneof2 DefaultInstanceForType { - get { return DefaultInstance; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestRepeatedScalarDifferentTagSizes cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - protected override TestOneof2 ThisMessage { - get { return this; } - } + private bool resultIsReadOnly; + private TestRepeatedScalarDifferentTagSizes result; - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2__Descriptor; } - } + private TestRepeatedScalarDifferentTagSizes PrepareBuilder() + { + if (resultIsReadOnly) + { + TestRepeatedScalarDifferentTagSizes original = result; + result = new TestRepeatedScalarDifferentTagSizes(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2__FieldAccessorTable; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - public enum NestedEnum { - FOO = 1, - BAR = 2, - BAZ = 3, - } + protected override TestRepeatedScalarDifferentTagSizes MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class FooGroup : pb::GeneratedMessage { - private FooGroup() { } - private static readonly FooGroup defaultInstance = new FooGroup().MakeReadOnly(); - private static readonly string[] _fooGroupFieldNames = new string[] { "a", "b" }; - private static readonly uint[] _fooGroupFieldTags = new uint[] { 72, 82 }; - public static FooGroup DefaultInstance { - get { return defaultInstance; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public override FooGroup DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - protected override FooGroup ThisMessage { - get { return this; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.Descriptor; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_FooGroup__Descriptor; } - } + public override TestRepeatedScalarDifferentTagSizes DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.DefaultInstance; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_FooGroup__FieldAccessorTable; } - } + public override TestRepeatedScalarDifferentTagSizes BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public const int AFieldNumber = 9; - private bool hasA; - private int a_; - public bool HasA { - get { return hasA; } - } - public int A { - get { return a_; } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestRepeatedScalarDifferentTagSizes) + { + return MergeFrom((TestRepeatedScalarDifferentTagSizes)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public const int BFieldNumber = 10; - private bool hasB; - private string b_ = ""; - public bool HasB { - get { return hasB; } - } - public string B { - get { return b_; } - } + public override Builder MergeFrom(TestRepeatedScalarDifferentTagSizes other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.DefaultInstance) return this; + PrepareBuilder(); + if (other.repeatedFixed32_.Count != 0) + { + result.repeatedFixed32_.Add(other.repeatedFixed32_); + } + if (other.repeatedInt32_.Count != 0) + { + result.repeatedInt32_.Add(other.repeatedInt32_); + } + if (other.repeatedFixed64_.Count != 0) + { + result.repeatedFixed64_.Add(other.repeatedFixed64_); + } + if (other.repeatedInt64_.Count != 0) + { + result.repeatedInt64_.Add(other.repeatedInt64_); + } + if (other.repeatedFloat_.Count != 0) + { + result.repeatedFloat_.Add(other.repeatedFloat_); + } + if (other.repeatedUint64_.Count != 0) + { + result.repeatedUint64_.Add(other.repeatedUint64_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public override bool IsInitialized { - get { - return true; - } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooGroupFieldNames; - if (hasA) { - output.WriteInt32(9, field_names[0], A); - } - if (hasB) { - output.WriteString(10, field_names[1], B); - } - UnknownFields.WriteTo(output); - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testRepeatedScalarDifferentTagSizesFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testRepeatedScalarDifferentTagSizesFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 98: + case 101: + { + input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); + break; + } + case 106: + case 104: + { + input.ReadInt32Array(tag, field_name, result.repeatedInt32_); + break; + } + case 16370: + case 16369: + { + input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); + break; + } + case 16378: + case 16376: + { + input.ReadInt64Array(tag, field_name, result.repeatedInt64_); + break; + } + case 2097138: + case 2097141: + { + input.ReadFloatArray(tag, field_name, result.repeatedFloat_); + break; + } + case 2097146: + case 2097144: + { + input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); + break; + } + } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeInt32Size(9, A); - } - if (hasB) { - size += pb::CodedOutputStream.ComputeStringSize(10, B); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static FooGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static FooGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static FooGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private FooGroup MakeReadOnly() { - return this; - } + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedFixed32List + { + get { return PrepareBuilder().repeatedFixed32_; } + } + public int RepeatedFixed32Count + { + get { return result.RepeatedFixed32Count; } + } + [global::System.CLSCompliant(false)] + public uint GetRepeatedFixed32(int index) + { + return result.GetRepeatedFixed32(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedFixed32(int index, uint value) + { + PrepareBuilder(); + result.repeatedFixed32_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedFixed32(uint value) + { + PrepareBuilder(); + result.repeatedFixed32_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedFixed32_.Add(values); + return this; + } + public Builder ClearRepeatedFixed32() + { + PrepareBuilder(); + result.repeatedFixed32_.Clear(); + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(FooGroup prototype) { - return new Builder(prototype); - } + public pbc::IPopsicleList RepeatedInt32List + { + get { return PrepareBuilder().repeatedInt32_; } + } + public int RepeatedInt32Count + { + get { return result.RepeatedInt32Count; } + } + public int GetRepeatedInt32(int index) + { + return result.GetRepeatedInt32(index); + } + public Builder SetRepeatedInt32(int index, int value) + { + PrepareBuilder(); + result.repeatedInt32_[index] = value; + return this; + } + public Builder AddRepeatedInt32(int value) + { + PrepareBuilder(); + result.repeatedInt32_.Add(value); + return this; + } + public Builder AddRangeRepeatedInt32(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedInt32_.Add(values); + return this; + } + public Builder ClearRepeatedInt32() + { + PrepareBuilder(); + result.repeatedInt32_.Clear(); + return this; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(FooGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private FooGroup result; - - private FooGroup PrepareBuilder() { - if (resultIsReadOnly) { - FooGroup original = result; - result = new FooGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override FooGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedFixed64List + { + get { return PrepareBuilder().repeatedFixed64_; } + } + public int RepeatedFixed64Count + { + get { return result.RepeatedFixed64Count; } + } + [global::System.CLSCompliant(false)] + public ulong GetRepeatedFixed64(int index) + { + return result.GetRepeatedFixed64(index); + } + [global::System.CLSCompliant(false)] + public Builder SetRepeatedFixed64(int index, ulong value) + { + PrepareBuilder(); + result.repeatedFixed64_[index] = value; + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRepeatedFixed64(ulong value) + { + PrepareBuilder(); + result.repeatedFixed64_.Add(value); + return this; + } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedFixed64_.Add(values); + return this; + } + public Builder ClearRepeatedFixed64() + { + PrepareBuilder(); + result.repeatedFixed64_.Clear(); + return this; + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public pbc::IPopsicleList RepeatedInt64List + { + get { return PrepareBuilder().repeatedInt64_; } + } + public int RepeatedInt64Count + { + get { return result.RepeatedInt64Count; } + } + public long GetRepeatedInt64(int index) + { + return result.GetRepeatedInt64(index); + } + public Builder SetRepeatedInt64(int index, long value) + { + PrepareBuilder(); + result.repeatedInt64_[index] = value; + return this; + } + public Builder AddRepeatedInt64(long value) + { + PrepareBuilder(); + result.repeatedInt64_.Add(value); + return this; + } + public Builder AddRangeRepeatedInt64(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedInt64_.Add(values); + return this; + } + public Builder ClearRepeatedInt64() + { + PrepareBuilder(); + result.repeatedInt64_.Clear(); + return this; } - } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.Descriptor; } - } - - public override FooGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance; } - } - - public override FooGroup BuildPartial() { - if (resultIsReadOnly) { - return result; + public pbc::IPopsicleList RepeatedFloatList + { + get { return PrepareBuilder().repeatedFloat_; } } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is FooGroup) { - return MergeFrom((FooGroup) other); - } else { - base.MergeFrom(other); - return this; + public int RepeatedFloatCount + { + get { return result.RepeatedFloatCount; } } - } - - public override Builder MergeFrom(FooGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; + public float GetRepeatedFloat(int index) + { + return result.GetRepeatedFloat(index); } - if (other.HasB) { - B = other.B; + public Builder SetRepeatedFloat(int index, float value) + { + PrepareBuilder(); + result.repeatedFloat_[index] = value; + return this; } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooGroupFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 72: { - result.hasA = input.ReadInt32(ref result.a_); - break; - } - case 82: { - result.hasB = input.ReadString(ref result.b_); - break; - } - } + public Builder AddRepeatedFloat(float value) + { + PrepareBuilder(); + result.repeatedFloat_.Add(value); + return this; } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + public Builder AddRangeRepeatedFloat(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedFloat_.Add(values); + return this; } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public int A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(int value) { - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = 0; - return this; - } - - public bool HasB { - get { return result.hasB; } - } - public string B { - get { return result.B; } - set { SetB(value); } - } - public Builder SetB(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasB = true; - result.b_ = value; - return this; - } - public Builder ClearB() { - PrepareBuilder(); - result.hasB = false; - result.b_ = ""; - return this; - } - } - static FooGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NestedMessage : pb::GeneratedMessage { - private NestedMessage() { } - private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); - private static readonly string[] _nestedMessageFieldNames = new string[] { "corge_int", "qux_int" }; - private static readonly uint[] _nestedMessageFieldTags = new uint[] { 16, 8 }; - public static NestedMessage DefaultInstance { - get { return defaultInstance; } - } - - public override NestedMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override NestedMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_NestedMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestOneof2_NestedMessage__FieldAccessorTable; } - } - - public const int QuxIntFieldNumber = 1; - private bool hasQuxInt; - private long quxInt_; - public bool HasQuxInt { - get { return hasQuxInt; } - } - public long QuxInt { - get { return quxInt_; } - } - - public const int CorgeIntFieldNumber = 2; - private pbc::PopsicleList corgeInt_ = new pbc::PopsicleList(); - public scg::IList CorgeIntList { - get { return pbc::Lists.AsReadOnly(corgeInt_); } - } - public int CorgeIntCount { - get { return corgeInt_.Count; } - } - public int GetCorgeInt(int index) { - return corgeInt_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _nestedMessageFieldNames; - if (hasQuxInt) { - output.WriteInt64(1, field_names[1], QuxInt); - } - if (corgeInt_.Count > 0) { - output.WriteInt32Array(2, field_names[0], corgeInt_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasQuxInt) { - size += pb::CodedOutputStream.ComputeInt64Size(1, QuxInt); - } - { - int dataSize = 0; - foreach (int element in CorgeIntList) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); + public Builder ClearRepeatedFloat() + { + PrepareBuilder(); + result.repeatedFloat_.Clear(); + return this; } - size += dataSize; - size += 1 * corgeInt_.Count; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static NestedMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NestedMessage MakeReadOnly() { - corgeInt_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NestedMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NestedMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NestedMessage result; - - private NestedMessage PrepareBuilder() { - if (resultIsReadOnly) { - NestedMessage original = result; - result = new NestedMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NestedMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + [global::System.CLSCompliant(false)] + public pbc::IPopsicleList RepeatedUint64List + { + get { return PrepareBuilder().repeatedUint64_; } } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Descriptor; } - } - - public override NestedMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance; } - } - - public override NestedMessage BuildPartial() { - if (resultIsReadOnly) { - return result; + public int RepeatedUint64Count + { + get { return result.RepeatedUint64Count; } } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is NestedMessage) { - return MergeFrom((NestedMessage) other); - } else { - base.MergeFrom(other); - return this; + [global::System.CLSCompliant(false)] + public ulong GetRepeatedUint64(int index) + { + return result.GetRepeatedUint64(index); } - } - - public override Builder MergeFrom(NestedMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasQuxInt) { - QuxInt = other.QuxInt; + [global::System.CLSCompliant(false)] + public Builder SetRepeatedUint64(int index, ulong value) + { + PrepareBuilder(); + result.repeatedUint64_[index] = value; + return this; } - if (other.corgeInt_.Count != 0) { - result.corgeInt_.Add(other.corgeInt_); + [global::System.CLSCompliant(false)] + public Builder AddRepeatedUint64(ulong value) + { + PrepareBuilder(); + result.repeatedUint64_.Add(value); + return this; } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _nestedMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasQuxInt = input.ReadInt64(ref result.quxInt_); - break; - } - case 18: - case 16: { - input.ReadInt32Array(tag, field_name, result.corgeInt_); - break; - } - } + [global::System.CLSCompliant(false)] + public Builder AddRangeRepeatedUint64(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedUint64_.Add(values); + return this; } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + public Builder ClearRepeatedUint64() + { + PrepareBuilder(); + result.repeatedUint64_.Clear(); + return this; } - return this; - } - - - public bool HasQuxInt { - get { return result.hasQuxInt; } - } - public long QuxInt { - get { return result.QuxInt; } - set { SetQuxInt(value); } - } - public Builder SetQuxInt(long value) { - PrepareBuilder(); - result.hasQuxInt = true; - result.quxInt_ = value; - return this; - } - public Builder ClearQuxInt() { - PrepareBuilder(); - result.hasQuxInt = false; - result.quxInt_ = 0L; - return this; - } - - public pbc::IPopsicleList CorgeIntList { - get { return PrepareBuilder().corgeInt_; } - } - public int CorgeIntCount { - get { return result.CorgeIntCount; } - } - public int GetCorgeInt(int index) { - return result.GetCorgeInt(index); - } - public Builder SetCorgeInt(int index, int value) { - PrepareBuilder(); - result.corgeInt_[index] = value; - return this; - } - public Builder AddCorgeInt(int value) { - PrepareBuilder(); - result.corgeInt_.Add(value); - return this; - } - public Builder AddRangeCorgeInt(scg::IEnumerable values) { - PrepareBuilder(); - result.corgeInt_.Add(values); - return this; - } - public Builder ClearCorgeInt() { - PrepareBuilder(); - result.corgeInt_.Clear(); - return this; - } } - static NestedMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + static TestRepeatedScalarDifferentTagSizes() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); } - } - - } - #endregion - - public const int FooIntFieldNumber = 1; - private bool hasFooInt; - private int fooInt_; - public bool HasFooInt { - get { return hasFooInt; } - } - public int FooInt { - get { return fooInt_; } - } - - public const int FooStringFieldNumber = 2; - private bool hasFooString; - private string fooString_ = ""; - public bool HasFooString { - get { return hasFooString; } - } - public string FooString { - get { return fooString_; } - } - - public const int FooCordFieldNumber = 3; - private bool hasFooCord; - private string fooCord_ = ""; - public bool HasFooCord { - get { return hasFooCord; } - } - public string FooCord { - get { return fooCord_; } - } - - public const int FooStringPieceFieldNumber = 4; - private bool hasFooStringPiece; - private string fooStringPiece_ = ""; - public bool HasFooStringPiece { - get { return hasFooStringPiece; } - } - public string FooStringPiece { - get { return fooStringPiece_; } - } - - public const int FooBytesFieldNumber = 5; - private bool hasFooBytes; - private pb::ByteString fooBytes_ = pb::ByteString.Empty; - public bool HasFooBytes { - get { return hasFooBytes; } - } - public pb::ByteString FooBytes { - get { return fooBytes_; } - } - - public const int FooEnumFieldNumber = 6; - private bool hasFooEnum; - private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum fooEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.FOO; - public bool HasFooEnum { - get { return hasFooEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum FooEnum { - get { return fooEnum_; } - } - - public const int FooMessageFieldNumber = 7; - private bool hasFooMessage; - private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage fooMessage_; - public bool HasFooMessage { - get { return hasFooMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooMessage { - get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance; } - } - - public const int FooGroupFieldNumber = 8; - private bool hasFooGroup; - private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup fooGroup_; - public bool HasFooGroup { - get { return hasFooGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup FooGroup { - get { return fooGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance; } } - public const int FooLazyMessageFieldNumber = 11; - private bool hasFooLazyMessage; - private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage fooLazyMessage_; - public bool HasFooLazyMessage { - get { return hasFooLazyMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooLazyMessage { - get { return fooLazyMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance; } - } - - public const int BarIntFieldNumber = 12; - private bool hasBarInt; - private int barInt_ = 5; - public bool HasBarInt { - get { return hasBarInt; } - } - public int BarInt { - get { return barInt_; } - } - - public const int BarStringFieldNumber = 13; - private bool hasBarString; - private string barString_ = "STRING"; - public bool HasBarString { - get { return hasBarString; } - } - public string BarString { - get { return barString_; } - } - - public const int BarCordFieldNumber = 14; - private bool hasBarCord; - private string barCord_ = "CORD"; - public bool HasBarCord { - get { return hasBarCord; } - } - public string BarCord { - get { return barCord_; } - } - - public const int BarStringPieceFieldNumber = 15; - private bool hasBarStringPiece; - private string barStringPiece_ = "SPIECE"; - public bool HasBarStringPiece { - get { return hasBarStringPiece; } - } - public string BarStringPiece { - get { return barStringPiece_; } - } - - public const int BarBytesFieldNumber = 16; - private bool hasBarBytes; - private pb::ByteString barBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestOneof2.Descriptor.Fields[13].DefaultValue; - public bool HasBarBytes { - get { return hasBarBytes; } - } - public pb::ByteString BarBytes { - get { return barBytes_; } - } - - public const int BarEnumFieldNumber = 17; - private bool hasBarEnum; - private global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum barEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.BAR; - public bool HasBarEnum { - get { return hasBarEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum BarEnum { - get { return barEnum_; } - } - - public const int BazIntFieldNumber = 18; - private bool hasBazInt; - private int bazInt_; - public bool HasBazInt { - get { return hasBazInt; } - } - public int BazInt { - get { return bazInt_; } - } - - public const int BazStringFieldNumber = 19; - private bool hasBazString; - private string bazString_ = "BAZ"; - public bool HasBazString { - get { return hasBazString; } - } - public string BazString { - get { return bazString_; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestParsingMerge : pb::ExtendableMessage + { + private TestParsingMerge() { } + private static readonly TestParsingMerge defaultInstance = new TestParsingMerge().MakeReadOnly(); + private static readonly string[] _testParsingMergeFieldNames = new string[] { "optional_all_types", "optionalgroup", "repeated_all_types", "repeatedgroup", "required_all_types" }; + private static readonly uint[] _testParsingMergeFieldTags = new uint[] { 18, 83, 26, 163, 10 }; + public static TestParsingMerge DefaultInstance + { + get { return defaultInstance; } + } - public override bool IsInitialized { - get { - return true; - } - } + public override TestParsingMerge DefaultInstanceForType + { + get { return DefaultInstance; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testOneof2FieldNames; - if (hasFooInt) { - output.WriteInt32(1, field_names[11], FooInt); - } - if (hasFooString) { - output.WriteString(2, field_names[14], FooString); - } - if (hasFooCord) { - output.WriteString(3, field_names[9], FooCord); - } - if (hasFooStringPiece) { - output.WriteString(4, field_names[15], FooStringPiece); - } - if (hasFooBytes) { - output.WriteBytes(5, field_names[8], FooBytes); - } - if (hasFooEnum) { - output.WriteEnum(6, field_names[10], (int) FooEnum, FooEnum); - } - if (hasFooMessage) { - output.WriteMessage(7, field_names[13], FooMessage); - } - if (hasFooGroup) { - output.WriteGroup(8, field_names[16], FooGroup); - } - if (hasFooLazyMessage) { - output.WriteMessage(11, field_names[12], FooLazyMessage); - } - if (hasBarInt) { - output.WriteInt32(12, field_names[3], BarInt); - } - if (hasBarString) { - output.WriteString(13, field_names[4], BarString); - } - if (hasBarCord) { - output.WriteString(14, field_names[1], BarCord); - } - if (hasBarStringPiece) { - output.WriteString(15, field_names[5], BarStringPiece); - } - if (hasBarBytes) { - output.WriteBytes(16, field_names[0], BarBytes); - } - if (hasBarEnum) { - output.WriteEnum(17, field_names[2], (int) BarEnum, BarEnum); - } - if (hasBazInt) { - output.WriteInt32(18, field_names[6], BazInt); - } - if (hasBazString) { - output.WriteString(19, field_names[7], BazString); - } - UnknownFields.WriteTo(output); - } + protected override TestParsingMerge ThisMessage + { + get { return this; } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge__Descriptor; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasFooInt) { - size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); - } - if (hasFooString) { - size += pb::CodedOutputStream.ComputeStringSize(2, FooString); - } - if (hasFooCord) { - size += pb::CodedOutputStream.ComputeStringSize(3, FooCord); - } - if (hasFooStringPiece) { - size += pb::CodedOutputStream.ComputeStringSize(4, FooStringPiece); - } - if (hasFooBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(5, FooBytes); - } - if (hasFooEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(6, (int) FooEnum); - } - if (hasFooMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(7, FooMessage); - } - if (hasFooGroup) { - size += pb::CodedOutputStream.ComputeGroupSize(8, FooGroup); - } - if (hasFooLazyMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(11, FooLazyMessage); - } - if (hasBarInt) { - size += pb::CodedOutputStream.ComputeInt32Size(12, BarInt); - } - if (hasBarString) { - size += pb::CodedOutputStream.ComputeStringSize(13, BarString); - } - if (hasBarCord) { - size += pb::CodedOutputStream.ComputeStringSize(14, BarCord); - } - if (hasBarStringPiece) { - size += pb::CodedOutputStream.ComputeStringSize(15, BarStringPiece); - } - if (hasBarBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(16, BarBytes); - } - if (hasBarEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(17, (int) BarEnum); - } - if (hasBazInt) { - size += pb::CodedOutputStream.ComputeInt32Size(18, BazInt); - } - if (hasBazString) { - size += pb::CodedOutputStream.ComputeStringSize(19, BazString); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestOneof2 ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestOneof2 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestOneof2 ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestOneof2 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestOneof2 ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestOneof2 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestOneof2 ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestOneof2 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestOneof2 ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestOneof2 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestOneof2 MakeReadOnly() { - return this; - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge__FieldAccessorTable; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestOneof2 prototype) { - return new Builder(prototype); - } + public const int OptionalExtFieldNumber = 1000; + public static pb::GeneratedExtensionBase OptionalExt; + public const int RepeatedExtFieldNumber = 1001; + public static pb::GeneratedExtensionBase> RepeatedExt; + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedFieldsGenerator : pb::GeneratedMessage + { + private RepeatedFieldsGenerator() { } + private static readonly RepeatedFieldsGenerator defaultInstance = new RepeatedFieldsGenerator().MakeReadOnly(); + private static readonly string[] _repeatedFieldsGeneratorFieldNames = new string[] { "ext1", "ext2", "field1", "field2", "field3", "group1", "group2" }; + private static readonly uint[] _repeatedFieldsGeneratorFieldTags = new uint[] { 8002, 8010, 10, 18, 26, 83, 163 }; + public static RepeatedFieldsGenerator DefaultInstance + { + get { return defaultInstance; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestOneof2 cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestOneof2 result; - - private TestOneof2 PrepareBuilder() { - if (resultIsReadOnly) { - TestOneof2 original = result; - result = new TestOneof2(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } + public override RepeatedFieldsGenerator DefaultInstanceForType + { + get { return DefaultInstance; } + } - public override bool IsInitialized { - get { return result.IsInitialized; } - } + protected override RepeatedFieldsGenerator ThisMessage + { + get { return this; } + } - protected override TestOneof2 MessageBeingBuilt { - get { return PrepareBuilder(); } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor; } + } - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.Descriptor; } - } - - public override TestOneof2 DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestOneof2.DefaultInstance; } - } - - public override TestOneof2 BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestOneof2) { - return MergeFrom((TestOneof2) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestOneof2 other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestOneof2.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasFooInt) { - FooInt = other.FooInt; - } - if (other.HasFooString) { - FooString = other.FooString; - } - if (other.HasFooCord) { - FooCord = other.FooCord; - } - if (other.HasFooStringPiece) { - FooStringPiece = other.FooStringPiece; - } - if (other.HasFooBytes) { - FooBytes = other.FooBytes; - } - if (other.HasFooEnum) { - FooEnum = other.FooEnum; - } - if (other.HasFooMessage) { - MergeFooMessage(other.FooMessage); - } - if (other.HasFooGroup) { - MergeFooGroup(other.FooGroup); - } - if (other.HasFooLazyMessage) { - MergeFooLazyMessage(other.FooLazyMessage); - } - if (other.HasBarInt) { - BarInt = other.BarInt; - } - if (other.HasBarString) { - BarString = other.BarString; - } - if (other.HasBarCord) { - BarCord = other.BarCord; - } - if (other.HasBarStringPiece) { - BarStringPiece = other.BarStringPiece; - } - if (other.HasBarBytes) { - BarBytes = other.BarBytes; - } - if (other.HasBarEnum) { - BarEnum = other.BarEnum; - } - if (other.HasBazInt) { - BazInt = other.BazInt; - } - if (other.HasBazString) { - BazString = other.BazString; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testOneof2FieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testOneof2FieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasFooInt = input.ReadInt32(ref result.fooInt_); - break; - } - case 18: { - result.hasFooString = input.ReadString(ref result.fooString_); - break; - } - case 26: { - result.hasFooCord = input.ReadString(ref result.fooCord_); - break; - } - case 34: { - result.hasFooStringPiece = input.ReadString(ref result.fooStringPiece_); - break; - } - case 42: { - result.hasFooBytes = input.ReadBytes(ref result.fooBytes_); - break; - } - case 48: { - object unknown; - if(input.ReadEnum(ref result.fooEnum_, out unknown)) { - result.hasFooEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(6, (ulong)(int)unknown); - } - break; - } - case 58: { - global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(); - if (result.hasFooMessage) { - subBuilder.MergeFrom(FooMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - FooMessage = subBuilder.BuildPartial(); - break; - } - case 67: { - global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.CreateBuilder(); - if (result.hasFooGroup) { - subBuilder.MergeFrom(FooGroup); - } - input.ReadGroup(8, subBuilder, extensionRegistry); - FooGroup = subBuilder.BuildPartial(); - break; - } - case 90: { - global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(); - if (result.hasFooLazyMessage) { - subBuilder.MergeFrom(FooLazyMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - FooLazyMessage = subBuilder.BuildPartial(); - break; - } - case 96: { - result.hasBarInt = input.ReadInt32(ref result.barInt_); - break; - } - case 106: { - result.hasBarString = input.ReadString(ref result.barString_); - break; - } - case 114: { - result.hasBarCord = input.ReadString(ref result.barCord_); - break; - } - case 122: { - result.hasBarStringPiece = input.ReadString(ref result.barStringPiece_); - break; - } - case 130: { - result.hasBarBytes = input.ReadBytes(ref result.barBytes_); - break; - } - case 136: { - object unknown; - if(input.ReadEnum(ref result.barEnum_, out unknown)) { - result.hasBarEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(17, (ulong)(int)unknown); - } - break; - } - case 144: { - result.hasBazInt = input.ReadInt32(ref result.bazInt_); - break; - } - case 154: { - result.hasBazString = input.ReadString(ref result.bazString_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasFooInt { - get { return result.hasFooInt; } - } - public int FooInt { - get { return result.FooInt; } - set { SetFooInt(value); } - } - public Builder SetFooInt(int value) { - PrepareBuilder(); - result.hasFooInt = true; - result.fooInt_ = value; - return this; - } - public Builder ClearFooInt() { - PrepareBuilder(); - result.hasFooInt = false; - result.fooInt_ = 0; - return this; - } - - public bool HasFooString { - get { return result.hasFooString; } - } - public string FooString { - get { return result.FooString; } - set { SetFooString(value); } - } - public Builder SetFooString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooString = true; - result.fooString_ = value; - return this; - } - public Builder ClearFooString() { - PrepareBuilder(); - result.hasFooString = false; - result.fooString_ = ""; - return this; - } - - public bool HasFooCord { - get { return result.hasFooCord; } - } - public string FooCord { - get { return result.FooCord; } - set { SetFooCord(value); } - } - public Builder SetFooCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooCord = true; - result.fooCord_ = value; - return this; - } - public Builder ClearFooCord() { - PrepareBuilder(); - result.hasFooCord = false; - result.fooCord_ = ""; - return this; - } - - public bool HasFooStringPiece { - get { return result.hasFooStringPiece; } - } - public string FooStringPiece { - get { return result.FooStringPiece; } - set { SetFooStringPiece(value); } - } - public Builder SetFooStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooStringPiece = true; - result.fooStringPiece_ = value; - return this; - } - public Builder ClearFooStringPiece() { - PrepareBuilder(); - result.hasFooStringPiece = false; - result.fooStringPiece_ = ""; - return this; - } - - public bool HasFooBytes { - get { return result.hasFooBytes; } - } - public pb::ByteString FooBytes { - get { return result.FooBytes; } - set { SetFooBytes(value); } - } - public Builder SetFooBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooBytes = true; - result.fooBytes_ = value; - return this; - } - public Builder ClearFooBytes() { - PrepareBuilder(); - result.hasFooBytes = false; - result.fooBytes_ = pb::ByteString.Empty; - return this; - } - - public bool HasFooEnum { - get { return result.hasFooEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum FooEnum { - get { return result.FooEnum; } - set { SetFooEnum(value); } - } - public Builder SetFooEnum(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum value) { - PrepareBuilder(); - result.hasFooEnum = true; - result.fooEnum_ = value; - return this; - } - public Builder ClearFooEnum() { - PrepareBuilder(); - result.hasFooEnum = false; - result.fooEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.FOO; - return this; - } - - public bool HasFooMessage { - get { return result.hasFooMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooMessage { - get { return result.FooMessage; } - set { SetFooMessage(value); } - } - public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooMessage = true; - result.fooMessage_ = value; - return this; - } - public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasFooMessage = true; - result.fooMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasFooMessage && - result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance) { - result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); - } else { - result.fooMessage_ = value; - } - result.hasFooMessage = true; - return this; - } - public Builder ClearFooMessage() { - PrepareBuilder(); - result.hasFooMessage = false; - result.fooMessage_ = null; - return this; - } - - public bool HasFooGroup { - get { return result.hasFooGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup FooGroup { - get { return result.FooGroup; } - set { SetFooGroup(value); } - } - public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooGroup = true; - result.fooGroup_ = value; - return this; - } - public Builder SetFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasFooGroup = true; - result.fooGroup_ = builderForValue.Build(); - return this; - } - public Builder MergeFooGroup(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasFooGroup && - result.fooGroup_ != global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.DefaultInstance) { - result.fooGroup_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.FooGroup.CreateBuilder(result.fooGroup_).MergeFrom(value).BuildPartial(); - } else { - result.fooGroup_ = value; - } - result.hasFooGroup = true; - return this; - } - public Builder ClearFooGroup() { - PrepareBuilder(); - result.hasFooGroup = false; - result.fooGroup_ = null; - return this; - } - - public bool HasFooLazyMessage { - get { return result.hasFooLazyMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage FooLazyMessage { - get { return result.FooLazyMessage; } - set { SetFooLazyMessage(value); } - } - public Builder SetFooLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooLazyMessage = true; - result.fooLazyMessage_ = value; - return this; - } - public Builder SetFooLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasFooLazyMessage = true; - result.fooLazyMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeFooLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasFooLazyMessage && - result.fooLazyMessage_ != global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.DefaultInstance) { - result.fooLazyMessage_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedMessage.CreateBuilder(result.fooLazyMessage_).MergeFrom(value).BuildPartial(); - } else { - result.fooLazyMessage_ = value; - } - result.hasFooLazyMessage = true; - return this; - } - public Builder ClearFooLazyMessage() { - PrepareBuilder(); - result.hasFooLazyMessage = false; - result.fooLazyMessage_ = null; - return this; - } - - public bool HasBarInt { - get { return result.hasBarInt; } - } - public int BarInt { - get { return result.BarInt; } - set { SetBarInt(value); } - } - public Builder SetBarInt(int value) { - PrepareBuilder(); - result.hasBarInt = true; - result.barInt_ = value; - return this; - } - public Builder ClearBarInt() { - PrepareBuilder(); - result.hasBarInt = false; - result.barInt_ = 5; - return this; - } - - public bool HasBarString { - get { return result.hasBarString; } - } - public string BarString { - get { return result.BarString; } - set { SetBarString(value); } - } - public Builder SetBarString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBarString = true; - result.barString_ = value; - return this; - } - public Builder ClearBarString() { - PrepareBuilder(); - result.hasBarString = false; - result.barString_ = "STRING"; - return this; - } - - public bool HasBarCord { - get { return result.hasBarCord; } - } - public string BarCord { - get { return result.BarCord; } - set { SetBarCord(value); } - } - public Builder SetBarCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBarCord = true; - result.barCord_ = value; - return this; - } - public Builder ClearBarCord() { - PrepareBuilder(); - result.hasBarCord = false; - result.barCord_ = "CORD"; - return this; - } - - public bool HasBarStringPiece { - get { return result.hasBarStringPiece; } - } - public string BarStringPiece { - get { return result.BarStringPiece; } - set { SetBarStringPiece(value); } - } - public Builder SetBarStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBarStringPiece = true; - result.barStringPiece_ = value; - return this; - } - public Builder ClearBarStringPiece() { - PrepareBuilder(); - result.hasBarStringPiece = false; - result.barStringPiece_ = "SPIECE"; - return this; - } - - public bool HasBarBytes { - get { return result.hasBarBytes; } - } - public pb::ByteString BarBytes { - get { return result.BarBytes; } - set { SetBarBytes(value); } - } - public Builder SetBarBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBarBytes = true; - result.barBytes_ = value; - return this; - } - public Builder ClearBarBytes() { - PrepareBuilder(); - result.hasBarBytes = false; - result.barBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestOneof2.Descriptor.Fields[13].DefaultValue; - return this; - } - - public bool HasBarEnum { - get { return result.hasBarEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum BarEnum { - get { return result.BarEnum; } - set { SetBarEnum(value); } - } - public Builder SetBarEnum(global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum value) { - PrepareBuilder(); - result.hasBarEnum = true; - result.barEnum_ = value; - return this; - } - public Builder ClearBarEnum() { - PrepareBuilder(); - result.hasBarEnum = false; - result.barEnum_ = global::Google.ProtocolBuffers.TestProtos.TestOneof2.Types.NestedEnum.BAR; - return this; - } - - public bool HasBazInt { - get { return result.hasBazInt; } - } - public int BazInt { - get { return result.BazInt; } - set { SetBazInt(value); } - } - public Builder SetBazInt(int value) { - PrepareBuilder(); - result.hasBazInt = true; - result.bazInt_ = value; - return this; - } - public Builder ClearBazInt() { - PrepareBuilder(); - result.hasBazInt = false; - result.bazInt_ = 0; - return this; - } - - public bool HasBazString { - get { return result.hasBazString; } - } - public string BazString { - get { return result.BazString; } - set { SetBazString(value); } - } - public Builder SetBazString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBazString = true; - result.bazString_ = value; - return this; - } - public Builder ClearBazString() { - PrepareBuilder(); - result.hasBazString = false; - result.bazString_ = "BAZ"; - return this; - } - } - static TestOneof2() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestRequiredOneof : pb::GeneratedMessage { - private TestRequiredOneof() { } - private static readonly TestRequiredOneof defaultInstance = new TestRequiredOneof().MakeReadOnly(); - private static readonly string[] _testRequiredOneofFieldNames = new string[] { "foo_int", "foo_message", "foo_string" }; - private static readonly uint[] _testRequiredOneofFieldTags = new uint[] { 8, 26, 18 }; - public static TestRequiredOneof DefaultInstance { - get { return defaultInstance; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__FieldAccessorTable; } + } - public override TestRequiredOneof DefaultInstanceForType { - get { return DefaultInstance; } - } + #region Nested types + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static partial class Types + { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Group1 : pb::GeneratedMessage + { + private Group1() { } + private static readonly Group1 defaultInstance = new Group1().MakeReadOnly(); + private static readonly string[] _group1FieldNames = new string[] { "field1" }; + private static readonly uint[] _group1FieldTags = new uint[] { 90 }; + public static Group1 DefaultInstance + { + get { return defaultInstance; } + } - protected override TestRequiredOneof ThisMessage { - get { return this; } - } + public override Group1 DefaultInstanceForType + { + get { return DefaultInstance; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof__Descriptor; } - } + protected override Group1 ThisMessage + { + get { return this; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof__FieldAccessorTable; } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor; } + } - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NestedMessage : pb::GeneratedMessage { - private NestedMessage() { } - private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); - private static readonly string[] _nestedMessageFieldNames = new string[] { "required_double" }; - private static readonly uint[] _nestedMessageFieldTags = new uint[] { 9 }; - public static NestedMessage DefaultInstance { - get { return defaultInstance; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__FieldAccessorTable; } + } - public override NestedMessage DefaultInstanceForType { - get { return DefaultInstance; } - } + public const int Field1FieldNumber = 11; + private bool hasField1; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes field1_; + public bool HasField1 + { + get { return hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 + { + get { return field1_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } - protected override NestedMessage ThisMessage { - get { return this; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__Descriptor; } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _group1FieldNames; + if (hasField1) + { + output.WriteMessage(11, field_names[0], Field1); + } + UnknownFields.WriteTo(output); + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRequiredOneof_NestedMessage__FieldAccessorTable; } - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public const int RequiredDoubleFieldNumber = 1; - private bool hasRequiredDouble; - private double requiredDouble_; - public bool HasRequiredDouble { - get { return hasRequiredDouble; } - } - public double RequiredDouble { - get { return requiredDouble_; } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasField1) + { + size += pb::CodedOutputStream.ComputeMessageSize(11, Field1); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Group1 ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group1 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group1 ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group1 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group1 ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group1 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Group1 ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Group1 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Group1 ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group1 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Group1 MakeReadOnly() + { + return this; + } - public override bool IsInitialized { - get { - if (!hasRequiredDouble) return false; - return true; - } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Group1 prototype) + { + return new Builder(prototype); + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _nestedMessageFieldNames; - if (hasRequiredDouble) { - output.WriteDouble(1, field_names[0], RequiredDouble); - } - UnknownFields.WriteTo(output); - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Group1 cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Group1 result; + + private Group1 PrepareBuilder() + { + if (resultIsReadOnly) + { + Group1 original = result; + result = new Group1(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override Group1 MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.Descriptor; } + } + + public override Group1 DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance; } + } + + public override Group1 BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is Group1) + { + return MergeFrom((Group1)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Group1 other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasField1) + { + MergeField1(other.Field1); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_group1FieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _group1FieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 90: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasField1) + { + subBuilder.MergeFrom(Field1); + } + input.ReadMessage(subBuilder, extensionRegistry); + Field1 = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasField1 + { + get { return result.hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 + { + get { return result.Field1; } + set { SetField1(value); } + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = value; + return this; + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = builderForValue.Build(); + return this; + } + public Builder MergeField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasField1 && + result.field1_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.field1_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.field1_).MergeFrom(value).BuildPartial(); + } + else + { + result.field1_ = value; + } + result.hasField1 = true; + return this; + } + public Builder ClearField1() + { + PrepareBuilder(); + result.hasField1 = false; + result.field1_ = null; + return this; + } + } + static Group1() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Group2 : pb::GeneratedMessage + { + private Group2() { } + private static readonly Group2 defaultInstance = new Group2().MakeReadOnly(); + private static readonly string[] _group2FieldNames = new string[] { "field1" }; + private static readonly uint[] _group2FieldTags = new uint[] { 170 }; + public static Group2 DefaultInstance + { + get { return defaultInstance; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public override Group2 DefaultInstanceForType + { + get { return DefaultInstance; } + } - size = 0; - if (hasRequiredDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(1, RequiredDouble); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static NestedMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NestedMessage MakeReadOnly() { - return this; - } + protected override Group2 ThisMessage + { + get { return this; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NestedMessage prototype) { - return new Builder(prototype); - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NestedMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NestedMessage result; - - private NestedMessage PrepareBuilder() { - if (resultIsReadOnly) { - NestedMessage original = result; - result = new NestedMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NestedMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__FieldAccessorTable; } + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } + public const int Field1FieldNumber = 21; + private bool hasField1; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes field1_; + public bool HasField1 + { + get { return hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 + { + get { return field1_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.Descriptor; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - public override NestedMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance; } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _group2FieldNames; + if (hasField1) + { + output.WriteMessage(21, field_names[0], Field1); + } + UnknownFields.WriteTo(output); + } - public override NestedMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public override Builder MergeFrom(pb::IMessage other) { - if (other is NestedMessage) { - return MergeFrom((NestedMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (hasField1) + { + size += pb::CodedOutputStream.ComputeMessageSize(21, Field1); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static Group2 ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group2 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group2 ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static Group2 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static Group2 ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group2 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static Group2 ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static Group2 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static Group2 ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static Group2 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private Group2 MakeReadOnly() + { + return this; + } - public override Builder MergeFrom(NestedMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasRequiredDouble) { - RequiredDouble = other.RequiredDouble; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _nestedMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(Group2 prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(Group2 cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private Group2 result; + + private Group2 PrepareBuilder() + { + if (resultIsReadOnly) + { + Group2 original = result; + result = new Group2(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override Group2 MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.Descriptor; } + } + + public override Group2 DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance; } + } + + public override Group2 BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is Group2) + { + return MergeFrom((Group2)other); + } + else + { + base.MergeFrom(other); + return this; + } + } + + public override Builder MergeFrom(Group2 other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasField1) + { + MergeField1(other.Field1); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_group2FieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _group2FieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 170: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasField1) + { + subBuilder.MergeFrom(Field1); + } + input.ReadMessage(subBuilder, extensionRegistry); + Field1 = subBuilder.BuildPartial(); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + + public bool HasField1 + { + get { return result.hasField1; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 + { + get { return result.Field1; } + set { SetField1(value); } + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = value; + return this; + } + public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasField1 = true; + result.field1_ = builderForValue.Build(); + return this; + } + public Builder MergeField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasField1 && + result.field1_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.field1_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.field1_).MergeFrom(value).BuildPartial(); + } + else + { + result.field1_ = value; + } + result.hasField1 = true; + return this; + } + public Builder ClearField1() + { + PrepareBuilder(); + result.hasField1 = false; + result.field1_ = null; + return this; + } + } + static Group2() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; + + } + #endregion + + public const int Field1FieldNumber = 1; + private pbc::PopsicleList field1_ = new pbc::PopsicleList(); + public scg::IList Field1List + { + get { return field1_; } } - case 9: { - result.hasRequiredDouble = input.ReadDouble(ref result.requiredDouble_); - break; + public int Field1Count + { + get { return field1_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField1(int index) + { + return field1_[index]; } - } - } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasRequiredDouble { - get { return result.hasRequiredDouble; } - } - public double RequiredDouble { - get { return result.RequiredDouble; } - set { SetRequiredDouble(value); } - } - public Builder SetRequiredDouble(double value) { - PrepareBuilder(); - result.hasRequiredDouble = true; - result.requiredDouble_ = value; - return this; - } - public Builder ClearRequiredDouble() { - PrepareBuilder(); - result.hasRequiredDouble = false; - result.requiredDouble_ = 0D; - return this; - } - } - static NestedMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } + public const int Field2FieldNumber = 2; + private pbc::PopsicleList field2_ = new pbc::PopsicleList(); + public scg::IList Field2List + { + get { return field2_; } + } + public int Field2Count + { + get { return field2_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField2(int index) + { + return field2_[index]; + } - } - #endregion + public const int Field3FieldNumber = 3; + private pbc::PopsicleList field3_ = new pbc::PopsicleList(); + public scg::IList Field3List + { + get { return field3_; } + } + public int Field3Count + { + get { return field3_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField3(int index) + { + return field3_[index]; + } - public const int FooIntFieldNumber = 1; - private bool hasFooInt; - private int fooInt_; - public bool HasFooInt { - get { return hasFooInt; } - } - public int FooInt { - get { return fooInt_; } - } + public const int Group1FieldNumber = 10; + private pbc::PopsicleList group1_ = new pbc::PopsicleList(); + public scg::IList Group1List + { + get { return group1_; } + } + public int Group1Count + { + get { return group1_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 GetGroup1(int index) + { + return group1_[index]; + } - public const int FooStringFieldNumber = 2; - private bool hasFooString; - private string fooString_ = ""; - public bool HasFooString { - get { return hasFooString; } - } - public string FooString { - get { return fooString_; } - } + public const int Group2FieldNumber = 20; + private pbc::PopsicleList group2_ = new pbc::PopsicleList(); + public scg::IList Group2List + { + get { return group2_; } + } + public int Group2Count + { + get { return group2_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 GetGroup2(int index) + { + return group2_[index]; + } - public const int FooMessageFieldNumber = 3; - private bool hasFooMessage; - private global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage fooMessage_; - public bool HasFooMessage { - get { return hasFooMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage FooMessage { - get { return fooMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance; } - } + public const int Ext1FieldNumber = 1000; + private pbc::PopsicleList ext1_ = new pbc::PopsicleList(); + public scg::IList Ext1List + { + get { return ext1_; } + } + public int Ext1Count + { + get { return ext1_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt1(int index) + { + return ext1_[index]; + } - public override bool IsInitialized { - get { - if (HasFooMessage) { - if (!FooMessage.IsInitialized) return false; - } - return true; - } - } + public const int Ext2FieldNumber = 1001; + private pbc::PopsicleList ext2_ = new pbc::PopsicleList(); + public scg::IList Ext2List + { + get { return ext2_; } + } + public int Ext2Count + { + get { return ext2_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt2(int index) + { + return ext2_[index]; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testRequiredOneofFieldNames; - if (hasFooInt) { - output.WriteInt32(1, field_names[0], FooInt); - } - if (hasFooString) { - output.WriteString(2, field_names[2], FooString); - } - if (hasFooMessage) { - output.WriteMessage(3, field_names[1], FooMessage); - } - UnknownFields.WriteTo(output); - } + public override bool IsInitialized + { + get + { + return true; + } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _repeatedFieldsGeneratorFieldNames; + if (field1_.Count > 0) + { + output.WriteMessageArray(1, field_names[2], field1_); + } + if (field2_.Count > 0) + { + output.WriteMessageArray(2, field_names[3], field2_); + } + if (field3_.Count > 0) + { + output.WriteMessageArray(3, field_names[4], field3_); + } + if (group1_.Count > 0) + { + output.WriteGroupArray(10, field_names[5], group1_); + } + if (group2_.Count > 0) + { + output.WriteGroupArray(20, field_names[6], group2_); + } + if (ext1_.Count > 0) + { + output.WriteMessageArray(1000, field_names[0], ext1_); + } + if (ext2_.Count > 0) + { + output.WriteMessageArray(1001, field_names[1], ext2_); + } + UnknownFields.WriteTo(output); + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasFooInt) { - size += pb::CodedOutputStream.ComputeInt32Size(1, FooInt); - } - if (hasFooString) { - size += pb::CodedOutputStream.ComputeStringSize(2, FooString); - } - if (hasFooMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(3, FooMessage); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestRequiredOneof ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequiredOneof ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequiredOneof ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRequiredOneof ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRequiredOneof ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequiredOneof ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestRequiredOneof ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestRequiredOneof ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestRequiredOneof ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRequiredOneof ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestRequiredOneof MakeReadOnly() { - return this; - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestRequiredOneof prototype) { - return new Builder(prototype); - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestRequiredOneof cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestRequiredOneof result; - - private TestRequiredOneof PrepareBuilder() { - if (resultIsReadOnly) { - TestRequiredOneof original = result; - result = new TestRequiredOneof(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestRequiredOneof MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Descriptor; } - } - - public override TestRequiredOneof DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.DefaultInstance; } - } - - public override TestRequiredOneof BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestRequiredOneof) { - return MergeFrom((TestRequiredOneof) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestRequiredOneof other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasFooInt) { - FooInt = other.FooInt; - } - if (other.HasFooString) { - FooString = other.FooString; - } - if (other.HasFooMessage) { - MergeFooMessage(other.FooMessage); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testRequiredOneofFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testRequiredOneofFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasFooInt = input.ReadInt32(ref result.fooInt_); - break; - } - case 18: { - result.hasFooString = input.ReadString(ref result.fooString_); - break; - } - case 26: { - global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.CreateBuilder(); - if (result.hasFooMessage) { - subBuilder.MergeFrom(FooMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - FooMessage = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasFooInt { - get { return result.hasFooInt; } - } - public int FooInt { - get { return result.FooInt; } - set { SetFooInt(value); } - } - public Builder SetFooInt(int value) { - PrepareBuilder(); - result.hasFooInt = true; - result.fooInt_ = value; - return this; - } - public Builder ClearFooInt() { - PrepareBuilder(); - result.hasFooInt = false; - result.fooInt_ = 0; - return this; - } - - public bool HasFooString { - get { return result.hasFooString; } - } - public string FooString { - get { return result.FooString; } - set { SetFooString(value); } - } - public Builder SetFooString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooString = true; - result.fooString_ = value; - return this; - } - public Builder ClearFooString() { - PrepareBuilder(); - result.hasFooString = false; - result.fooString_ = ""; - return this; - } - - public bool HasFooMessage { - get { return result.hasFooMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage FooMessage { - get { return result.FooMessage; } - set { SetFooMessage(value); } - } - public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasFooMessage = true; - result.fooMessage_ = value; - return this; - } - public Builder SetFooMessage(global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasFooMessage = true; - result.fooMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeFooMessage(global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasFooMessage && - result.fooMessage_ != global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.DefaultInstance) { - result.fooMessage_ = global::Google.ProtocolBuffers.TestProtos.TestRequiredOneof.Types.NestedMessage.CreateBuilder(result.fooMessage_).MergeFrom(value).BuildPartial(); - } else { - result.fooMessage_ = value; - } - result.hasFooMessage = true; - return this; - } - public Builder ClearFooMessage() { - PrepareBuilder(); - result.hasFooMessage = false; - result.fooMessage_ = null; - return this; - } - } - static TestRequiredOneof() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestPackedTypes : pb::GeneratedMessage { - private TestPackedTypes() { } - private static readonly TestPackedTypes defaultInstance = new TestPackedTypes().MakeReadOnly(); - private static readonly string[] _testPackedTypesFieldNames = new string[] { "packed_bool", "packed_double", "packed_enum", "packed_fixed32", "packed_fixed64", "packed_float", "packed_int32", "packed_int64", "packed_sfixed32", "packed_sfixed64", "packed_sint32", "packed_sint64", "packed_uint32", "packed_uint64" }; - private static readonly uint[] _testPackedTypesFieldTags = new uint[] { 818, 810, 826, 770, 778, 802, 722, 730, 786, 794, 754, 762, 738, 746 }; - public static TestPackedTypes DefaultInstance { - get { return defaultInstance; } - } + size = 0; + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Field1List) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Field2List) + { + size += pb::CodedOutputStream.ComputeMessageSize(2, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Field3List) + { + size += pb::CodedOutputStream.ComputeMessageSize(3, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 element in Group1List) + { + size += pb::CodedOutputStream.ComputeGroupSize(10, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 element in Group2List) + { + size += pb::CodedOutputStream.ComputeGroupSize(20, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Ext1List) + { + size += pb::CodedOutputStream.ComputeMessageSize(1000, element); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Ext2List) + { + size += pb::CodedOutputStream.ComputeMessageSize(1001, element); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static RepeatedFieldsGenerator ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedFieldsGenerator ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedFieldsGenerator MakeReadOnly() + { + field1_.MakeReadOnly(); + field2_.MakeReadOnly(); + field3_.MakeReadOnly(); + group1_.MakeReadOnly(); + group2_.MakeReadOnly(); + ext1_.MakeReadOnly(); + ext2_.MakeReadOnly(); + return this; + } - public override TestPackedTypes DefaultInstanceForType { - get { return DefaultInstance; } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedFieldsGenerator prototype) + { + return new Builder(prototype); + } - protected override TestPackedTypes ThisMessage { - get { return this; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedFieldsGenerator cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedTypes__Descriptor; } - } + private bool resultIsReadOnly; + private RepeatedFieldsGenerator result; + + private RepeatedFieldsGenerator PrepareBuilder() + { + if (resultIsReadOnly) + { + RepeatedFieldsGenerator original = result; + result = new RepeatedFieldsGenerator(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public const int PackedInt32FieldNumber = 90; - private int packedInt32MemoizedSerializedSize; - private pbc::PopsicleList packedInt32_ = new pbc::PopsicleList(); - public scg::IList PackedInt32List { - get { return pbc::Lists.AsReadOnly(packedInt32_); } - } - public int PackedInt32Count { - get { return packedInt32_.Count; } - } - public int GetPackedInt32(int index) { - return packedInt32_[index]; - } + protected override RepeatedFieldsGenerator MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public const int PackedInt64FieldNumber = 91; - private int packedInt64MemoizedSerializedSize; - private pbc::PopsicleList packedInt64_ = new pbc::PopsicleList(); - public scg::IList PackedInt64List { - get { return pbc::Lists.AsReadOnly(packedInt64_); } - } - public int PackedInt64Count { - get { return packedInt64_.Count; } - } - public long GetPackedInt64(int index) { - return packedInt64_[index]; - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public const int PackedUint32FieldNumber = 92; - private int packedUint32MemoizedSerializedSize; - private pbc::PopsicleList packedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedUint32List { - get { return pbc::Lists.AsReadOnly(packedUint32_); } - } - public int PackedUint32Count { - get { return packedUint32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedUint32(int index) { - return packedUint32_[index]; - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public const int PackedUint64FieldNumber = 93; - private int packedUint64MemoizedSerializedSize; - private pbc::PopsicleList packedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedUint64List { - get { return pbc::Lists.AsReadOnly(packedUint64_); } - } - public int PackedUint64Count { - get { return packedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedUint64(int index) { - return packedUint64_[index]; - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Descriptor; } + } - public const int PackedSint32FieldNumber = 94; - private int packedSint32MemoizedSerializedSize; - private pbc::PopsicleList packedSint32_ = new pbc::PopsicleList(); - public scg::IList PackedSint32List { - get { return pbc::Lists.AsReadOnly(packedSint32_); } - } - public int PackedSint32Count { - get { return packedSint32_.Count; } - } - public int GetPackedSint32(int index) { - return packedSint32_[index]; - } + public override RepeatedFieldsGenerator DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.DefaultInstance; } + } - public const int PackedSint64FieldNumber = 95; - private int packedSint64MemoizedSerializedSize; - private pbc::PopsicleList packedSint64_ = new pbc::PopsicleList(); - public scg::IList PackedSint64List { - get { return pbc::Lists.AsReadOnly(packedSint64_); } - } - public int PackedSint64Count { - get { return packedSint64_.Count; } - } - public long GetPackedSint64(int index) { - return packedSint64_[index]; - } + public override RepeatedFieldsGenerator BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public const int PackedFixed32FieldNumber = 96; - private int packedFixed32MemoizedSerializedSize; - private pbc::PopsicleList packedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedFixed32List { - get { return pbc::Lists.AsReadOnly(packedFixed32_); } - } - public int PackedFixed32Count { - get { return packedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedFixed32(int index) { - return packedFixed32_[index]; - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is RepeatedFieldsGenerator) + { + return MergeFrom((RepeatedFieldsGenerator)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public const int PackedFixed64FieldNumber = 97; - private int packedFixed64MemoizedSerializedSize; - private pbc::PopsicleList packedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList PackedFixed64List { - get { return pbc::Lists.AsReadOnly(packedFixed64_); } - } - public int PackedFixed64Count { - get { return packedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedFixed64(int index) { - return packedFixed64_[index]; - } + public override Builder MergeFrom(RepeatedFieldsGenerator other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.DefaultInstance) return this; + PrepareBuilder(); + if (other.field1_.Count != 0) + { + result.field1_.Add(other.field1_); + } + if (other.field2_.Count != 0) + { + result.field2_.Add(other.field2_); + } + if (other.field3_.Count != 0) + { + result.field3_.Add(other.field3_); + } + if (other.group1_.Count != 0) + { + result.group1_.Add(other.group1_); + } + if (other.group2_.Count != 0) + { + result.group2_.Add(other.group2_); + } + if (other.ext1_.Count != 0) + { + result.ext1_.Add(other.ext1_); + } + if (other.ext2_.Count != 0) + { + result.ext2_.Add(other.ext2_); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public const int PackedSfixed32FieldNumber = 98; - private int packedSfixed32MemoizedSerializedSize; - private pbc::PopsicleList packedSfixed32_ = new pbc::PopsicleList(); - public scg::IList PackedSfixed32List { - get { return pbc::Lists.AsReadOnly(packedSfixed32_); } - } - public int PackedSfixed32Count { - get { return packedSfixed32_.Count; } - } - public int GetPackedSfixed32(int index) { - return packedSfixed32_[index]; - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public const int PackedSfixed64FieldNumber = 99; - private int packedSfixed64MemoizedSerializedSize; - private pbc::PopsicleList packedSfixed64_ = new pbc::PopsicleList(); - public scg::IList PackedSfixed64List { - get { return pbc::Lists.AsReadOnly(packedSfixed64_); } - } - public int PackedSfixed64Count { - get { return packedSfixed64_.Count; } - } - public long GetPackedSfixed64(int index) { - return packedSfixed64_[index]; - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_repeatedFieldsGeneratorFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _repeatedFieldsGeneratorFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + input.ReadMessageArray(tag, field_name, result.field1_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + case 18: + { + input.ReadMessageArray(tag, field_name, result.field2_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + case 26: + { + input.ReadMessageArray(tag, field_name, result.field3_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + case 83: + { + input.ReadGroupArray(tag, field_name, result.group1_, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance, extensionRegistry); + break; + } + case 163: + { + input.ReadGroupArray(tag, field_name, result.group2_, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance, extensionRegistry); + break; + } + case 8002: + { + input.ReadMessageArray(tag, field_name, result.ext1_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + case 8010: + { + input.ReadMessageArray(tag, field_name, result.ext2_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + } + } - public const int PackedFloatFieldNumber = 100; - private int packedFloatMemoizedSerializedSize; - private pbc::PopsicleList packedFloat_ = new pbc::PopsicleList(); - public scg::IList PackedFloatList { - get { return pbc::Lists.AsReadOnly(packedFloat_); } - } - public int PackedFloatCount { - get { return packedFloat_.Count; } - } - public float GetPackedFloat(int index) { - return packedFloat_[index]; - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public const int PackedDoubleFieldNumber = 101; - private int packedDoubleMemoizedSerializedSize; - private pbc::PopsicleList packedDouble_ = new pbc::PopsicleList(); - public scg::IList PackedDoubleList { - get { return pbc::Lists.AsReadOnly(packedDouble_); } - } - public int PackedDoubleCount { - get { return packedDouble_.Count; } - } - public double GetPackedDouble(int index) { - return packedDouble_[index]; - } - public const int PackedBoolFieldNumber = 102; - private int packedBoolMemoizedSerializedSize; - private pbc::PopsicleList packedBool_ = new pbc::PopsicleList(); - public scg::IList PackedBoolList { - get { return pbc::Lists.AsReadOnly(packedBool_); } - } - public int PackedBoolCount { - get { return packedBool_.Count; } - } - public bool GetPackedBool(int index) { - return packedBool_[index]; - } + public pbc::IPopsicleList Field1List + { + get { return PrepareBuilder().field1_; } + } + public int Field1Count + { + get { return result.Field1Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField1(int index) + { + return result.GetField1(index); + } + public Builder SetField1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field1_[index] = value; + return this; + } + public Builder SetField1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field1_[index] = builderForValue.Build(); + return this; + } + public Builder AddField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field1_.Add(value); + return this; + } + public Builder AddField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field1_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeField1(scg::IEnumerable values) + { + PrepareBuilder(); + result.field1_.Add(values); + return this; + } + public Builder ClearField1() + { + PrepareBuilder(); + result.field1_.Clear(); + return this; + } - public const int PackedEnumFieldNumber = 103; - private int packedEnumMemoizedSerializedSize; - private pbc::PopsicleList packedEnum_ = new pbc::PopsicleList(); - public scg::IList PackedEnumList { - get { return pbc::Lists.AsReadOnly(packedEnum_); } - } - public int PackedEnumCount { - get { return packedEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetPackedEnum(int index) { - return packedEnum_[index]; - } + public pbc::IPopsicleList Field2List + { + get { return PrepareBuilder().field2_; } + } + public int Field2Count + { + get { return result.Field2Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField2(int index) + { + return result.GetField2(index); + } + public Builder SetField2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field2_[index] = value; + return this; + } + public Builder SetField2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field2_[index] = builderForValue.Build(); + return this; + } + public Builder AddField2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field2_.Add(value); + return this; + } + public Builder AddField2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field2_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeField2(scg::IEnumerable values) + { + PrepareBuilder(); + result.field2_.Add(values); + return this; + } + public Builder ClearField2() + { + PrepareBuilder(); + result.field2_.Clear(); + return this; + } - public override bool IsInitialized { - get { - return true; - } - } + public pbc::IPopsicleList Field3List + { + get { return PrepareBuilder().field3_; } + } + public int Field3Count + { + get { return result.Field3Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField3(int index) + { + return result.GetField3(index); + } + public Builder SetField3(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field3_[index] = value; + return this; + } + public Builder SetField3(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field3_[index] = builderForValue.Build(); + return this; + } + public Builder AddField3(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.field3_.Add(value); + return this; + } + public Builder AddField3(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.field3_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeField3(scg::IEnumerable values) + { + PrepareBuilder(); + result.field3_.Add(values); + return this; + } + public Builder ClearField3() + { + PrepareBuilder(); + result.field3_.Clear(); + return this; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testPackedTypesFieldNames; - if (packedInt32_.Count > 0) { - output.WritePackedInt32Array(90, field_names[6], packedInt32MemoizedSerializedSize, packedInt32_); - } - if (packedInt64_.Count > 0) { - output.WritePackedInt64Array(91, field_names[7], packedInt64MemoizedSerializedSize, packedInt64_); - } - if (packedUint32_.Count > 0) { - output.WritePackedUInt32Array(92, field_names[12], packedUint32MemoizedSerializedSize, packedUint32_); - } - if (packedUint64_.Count > 0) { - output.WritePackedUInt64Array(93, field_names[13], packedUint64MemoizedSerializedSize, packedUint64_); - } - if (packedSint32_.Count > 0) { - output.WritePackedSInt32Array(94, field_names[10], packedSint32MemoizedSerializedSize, packedSint32_); - } - if (packedSint64_.Count > 0) { - output.WritePackedSInt64Array(95, field_names[11], packedSint64MemoizedSerializedSize, packedSint64_); - } - if (packedFixed32_.Count > 0) { - output.WritePackedFixed32Array(96, field_names[3], packedFixed32MemoizedSerializedSize, packedFixed32_); - } - if (packedFixed64_.Count > 0) { - output.WritePackedFixed64Array(97, field_names[4], packedFixed64MemoizedSerializedSize, packedFixed64_); - } - if (packedSfixed32_.Count > 0) { - output.WritePackedSFixed32Array(98, field_names[8], packedSfixed32MemoizedSerializedSize, packedSfixed32_); - } - if (packedSfixed64_.Count > 0) { - output.WritePackedSFixed64Array(99, field_names[9], packedSfixed64MemoizedSerializedSize, packedSfixed64_); - } - if (packedFloat_.Count > 0) { - output.WritePackedFloatArray(100, field_names[5], packedFloatMemoizedSerializedSize, packedFloat_); - } - if (packedDouble_.Count > 0) { - output.WritePackedDoubleArray(101, field_names[1], packedDoubleMemoizedSerializedSize, packedDouble_); - } - if (packedBool_.Count > 0) { - output.WritePackedBoolArray(102, field_names[0], packedBoolMemoizedSerializedSize, packedBool_); - } - if (packedEnum_.Count > 0) { - output.WritePackedEnumArray(103, field_names[2], packedEnumMemoizedSerializedSize, packedEnum_); - } - UnknownFields.WriteTo(output); - } + public pbc::IPopsicleList Group1List + { + get { return PrepareBuilder().group1_; } + } + public int Group1Count + { + get { return result.Group1Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 GetGroup1(int index) + { + return result.GetGroup1(index); + } + public Builder SetGroup1(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group1_[index] = value; + return this; + } + public Builder SetGroup1(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group1_[index] = builderForValue.Build(); + return this; + } + public Builder AddGroup1(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group1_.Add(value); + return this; + } + public Builder AddGroup1(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group1_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeGroup1(scg::IEnumerable values) + { + PrepareBuilder(); + result.group1_.Add(values); + return this; + } + public Builder ClearGroup1() + { + PrepareBuilder(); + result.group1_.Clear(); + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public pbc::IPopsicleList Group2List + { + get { return PrepareBuilder().group2_; } + } + public int Group2Count + { + get { return result.Group2Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 GetGroup2(int index) + { + return result.GetGroup2(index); + } + public Builder SetGroup2(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group2_[index] = value; + return this; + } + public Builder SetGroup2(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group2_[index] = builderForValue.Build(); + return this; + } + public Builder AddGroup2(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.group2_.Add(value); + return this; + } + public Builder AddGroup2(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.group2_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeGroup2(scg::IEnumerable values) + { + PrepareBuilder(); + result.group2_.Add(values); + return this; + } + public Builder ClearGroup2() + { + PrepareBuilder(); + result.group2_.Clear(); + return this; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (int element in PackedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - if (packedInt32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedInt32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (long element in PackedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - if (packedInt64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedInt64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (uint element in PackedUint32List) { - dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); - } - size += dataSize; - if (packedUint32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedUint32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (ulong element in PackedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - if (packedUint64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedUint64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (int element in PackedSint32List) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - if (packedSint32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSint32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - foreach (long element in PackedSint64List) { - dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); - } - size += dataSize; - if (packedSint64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSint64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 4 * packedFixed32_.Count; - size += dataSize; - if (packedFixed32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedFixed32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 8 * packedFixed64_.Count; - size += dataSize; - if (packedFixed64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedFixed64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 4 * packedSfixed32_.Count; - size += dataSize; - if (packedSfixed32_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSfixed32MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 8 * packedSfixed64_.Count; - size += dataSize; - if (packedSfixed64_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedSfixed64MemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 4 * packedFloat_.Count; - size += dataSize; - if (packedFloat_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedFloatMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 8 * packedDouble_.Count; - size += dataSize; - if (packedDouble_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedDoubleMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - dataSize = 1 * packedBool_.Count; - size += dataSize; - if (packedBool_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedBoolMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - if (packedEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in packedEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2; - size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); - } - packedEnumMemoizedSerializedSize = dataSize; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestPackedTypes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestPackedTypes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestPackedTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestPackedTypes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestPackedTypes MakeReadOnly() { - packedInt32_.MakeReadOnly(); - packedInt64_.MakeReadOnly(); - packedUint32_.MakeReadOnly(); - packedUint64_.MakeReadOnly(); - packedSint32_.MakeReadOnly(); - packedSint64_.MakeReadOnly(); - packedFixed32_.MakeReadOnly(); - packedFixed64_.MakeReadOnly(); - packedSfixed32_.MakeReadOnly(); - packedSfixed64_.MakeReadOnly(); - packedFloat_.MakeReadOnly(); - packedDouble_.MakeReadOnly(); - packedBool_.MakeReadOnly(); - packedEnum_.MakeReadOnly(); - return this; - } + public pbc::IPopsicleList Ext1List + { + get { return PrepareBuilder().ext1_; } + } + public int Ext1Count + { + get { return result.Ext1Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt1(int index) + { + return result.GetExt1(index); + } + public Builder SetExt1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext1_[index] = value; + return this; + } + public Builder SetExt1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext1_[index] = builderForValue.Build(); + return this; + } + public Builder AddExt1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext1_.Add(value); + return this; + } + public Builder AddExt1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext1_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeExt1(scg::IEnumerable values) + { + PrepareBuilder(); + result.ext1_.Add(values); + return this; + } + public Builder ClearExt1() + { + PrepareBuilder(); + result.ext1_.Clear(); + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestPackedTypes prototype) { - return new Builder(prototype); - } + public pbc::IPopsicleList Ext2List + { + get { return PrepareBuilder().ext2_; } + } + public int Ext2Count + { + get { return result.Ext2Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt2(int index) + { + return result.GetExt2(index); + } + public Builder SetExt2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext2_[index] = value; + return this; + } + public Builder SetExt2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext2_[index] = builderForValue.Build(); + return this; + } + public Builder AddExt2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.ext2_.Add(value); + return this; + } + public Builder AddExt2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.ext2_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeExt2(scg::IEnumerable values) + { + PrepareBuilder(); + result.ext2_.Add(values); + return this; + } + public Builder ClearExt2() + { + PrepareBuilder(); + result.ext2_.Clear(); + return this; + } + } + static RepeatedFieldsGenerator() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestPackedTypes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestPackedTypes result; - - private TestPackedTypes PrepareBuilder() { - if (resultIsReadOnly) { - TestPackedTypes original = result; - result = new TestPackedTypes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class OptionalGroup : pb::GeneratedMessage + { + private OptionalGroup() { } + private static readonly OptionalGroup defaultInstance = new OptionalGroup().MakeReadOnly(); + private static readonly string[] _optionalGroupFieldNames = new string[] { "optional_group_all_types" }; + private static readonly uint[] _optionalGroupFieldTags = new uint[] { 90 }; + public static OptionalGroup DefaultInstance + { + get { return defaultInstance; } + } - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestPackedTypes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.Descriptor; } - } - - public override TestPackedTypes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.DefaultInstance; } - } - - public override TestPackedTypes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestPackedTypes) { - return MergeFrom((TestPackedTypes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestPackedTypes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.DefaultInstance) return this; - PrepareBuilder(); - if (other.packedInt32_.Count != 0) { - result.packedInt32_.Add(other.packedInt32_); - } - if (other.packedInt64_.Count != 0) { - result.packedInt64_.Add(other.packedInt64_); - } - if (other.packedUint32_.Count != 0) { - result.packedUint32_.Add(other.packedUint32_); - } - if (other.packedUint64_.Count != 0) { - result.packedUint64_.Add(other.packedUint64_); - } - if (other.packedSint32_.Count != 0) { - result.packedSint32_.Add(other.packedSint32_); - } - if (other.packedSint64_.Count != 0) { - result.packedSint64_.Add(other.packedSint64_); - } - if (other.packedFixed32_.Count != 0) { - result.packedFixed32_.Add(other.packedFixed32_); - } - if (other.packedFixed64_.Count != 0) { - result.packedFixed64_.Add(other.packedFixed64_); - } - if (other.packedSfixed32_.Count != 0) { - result.packedSfixed32_.Add(other.packedSfixed32_); - } - if (other.packedSfixed64_.Count != 0) { - result.packedSfixed64_.Add(other.packedSfixed64_); - } - if (other.packedFloat_.Count != 0) { - result.packedFloat_.Add(other.packedFloat_); - } - if (other.packedDouble_.Count != 0) { - result.packedDouble_.Add(other.packedDouble_); - } - if (other.packedBool_.Count != 0) { - result.packedBool_.Add(other.packedBool_); - } - if (other.packedEnum_.Count != 0) { - result.packedEnum_.Add(other.packedEnum_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testPackedTypesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testPackedTypesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 722: - case 720: { - input.ReadInt32Array(tag, field_name, result.packedInt32_); - break; - } - case 730: - case 728: { - input.ReadInt64Array(tag, field_name, result.packedInt64_); - break; - } - case 738: - case 736: { - input.ReadUInt32Array(tag, field_name, result.packedUint32_); - break; - } - case 746: - case 744: { - input.ReadUInt64Array(tag, field_name, result.packedUint64_); - break; - } - case 754: - case 752: { - input.ReadSInt32Array(tag, field_name, result.packedSint32_); - break; - } - case 762: - case 760: { - input.ReadSInt64Array(tag, field_name, result.packedSint64_); - break; - } - case 770: - case 773: { - input.ReadFixed32Array(tag, field_name, result.packedFixed32_); - break; - } - case 778: - case 777: { - input.ReadFixed64Array(tag, field_name, result.packedFixed64_); - break; - } - case 786: - case 789: { - input.ReadSFixed32Array(tag, field_name, result.packedSfixed32_); - break; - } - case 794: - case 793: { - input.ReadSFixed64Array(tag, field_name, result.packedSfixed64_); - break; - } - case 802: - case 805: { - input.ReadFloatArray(tag, field_name, result.packedFloat_); - break; - } - case 810: - case 809: { - input.ReadDoubleArray(tag, field_name, result.packedDouble_); - break; - } - case 818: - case 816: { - input.ReadBoolArray(tag, field_name, result.packedBool_); - break; - } - case 826: - case 824: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.packedEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(103, (ulong)(int)rawValue); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public pbc::IPopsicleList PackedInt32List { - get { return PrepareBuilder().packedInt32_; } - } - public int PackedInt32Count { - get { return result.PackedInt32Count; } - } - public int GetPackedInt32(int index) { - return result.GetPackedInt32(index); - } - public Builder SetPackedInt32(int index, int value) { - PrepareBuilder(); - result.packedInt32_[index] = value; - return this; - } - public Builder AddPackedInt32(int value) { - PrepareBuilder(); - result.packedInt32_.Add(value); - return this; - } - public Builder AddRangePackedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedInt32_.Add(values); - return this; - } - public Builder ClearPackedInt32() { - PrepareBuilder(); - result.packedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedInt64List { - get { return PrepareBuilder().packedInt64_; } - } - public int PackedInt64Count { - get { return result.PackedInt64Count; } - } - public long GetPackedInt64(int index) { - return result.GetPackedInt64(index); - } - public Builder SetPackedInt64(int index, long value) { - PrepareBuilder(); - result.packedInt64_[index] = value; - return this; - } - public Builder AddPackedInt64(long value) { - PrepareBuilder(); - result.packedInt64_.Add(value); - return this; - } - public Builder AddRangePackedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedInt64_.Add(values); - return this; - } - public Builder ClearPackedInt64() { - PrepareBuilder(); - result.packedInt64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedUint32List { - get { return PrepareBuilder().packedUint32_; } - } - public int PackedUint32Count { - get { return result.PackedUint32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedUint32(int index) { - return result.GetPackedUint32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedUint32(int index, uint value) { - PrepareBuilder(); - result.packedUint32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedUint32(uint value) { - PrepareBuilder(); - result.packedUint32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedUint32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedUint32_.Add(values); - return this; - } - public Builder ClearPackedUint32() { - PrepareBuilder(); - result.packedUint32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedUint64List { - get { return PrepareBuilder().packedUint64_; } - } - public int PackedUint64Count { - get { return result.PackedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedUint64(int index) { - return result.GetPackedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedUint64(int index, ulong value) { - PrepareBuilder(); - result.packedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedUint64(ulong value) { - PrepareBuilder(); - result.packedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedUint64_.Add(values); - return this; - } - public Builder ClearPackedUint64() { - PrepareBuilder(); - result.packedUint64_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSint32List { - get { return PrepareBuilder().packedSint32_; } - } - public int PackedSint32Count { - get { return result.PackedSint32Count; } - } - public int GetPackedSint32(int index) { - return result.GetPackedSint32(index); - } - public Builder SetPackedSint32(int index, int value) { - PrepareBuilder(); - result.packedSint32_[index] = value; - return this; - } - public Builder AddPackedSint32(int value) { - PrepareBuilder(); - result.packedSint32_.Add(value); - return this; - } - public Builder AddRangePackedSint32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSint32_.Add(values); - return this; - } - public Builder ClearPackedSint32() { - PrepareBuilder(); - result.packedSint32_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSint64List { - get { return PrepareBuilder().packedSint64_; } - } - public int PackedSint64Count { - get { return result.PackedSint64Count; } - } - public long GetPackedSint64(int index) { - return result.GetPackedSint64(index); - } - public Builder SetPackedSint64(int index, long value) { - PrepareBuilder(); - result.packedSint64_[index] = value; - return this; - } - public Builder AddPackedSint64(long value) { - PrepareBuilder(); - result.packedSint64_.Add(value); - return this; - } - public Builder AddRangePackedSint64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSint64_.Add(values); - return this; - } - public Builder ClearPackedSint64() { - PrepareBuilder(); - result.packedSint64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedFixed32List { - get { return PrepareBuilder().packedFixed32_; } - } - public int PackedFixed32Count { - get { return result.PackedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetPackedFixed32(int index) { - return result.GetPackedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedFixed32(int index, uint value) { - PrepareBuilder(); - result.packedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedFixed32(uint value) { - PrepareBuilder(); - result.packedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedFixed32_.Add(values); - return this; - } - public Builder ClearPackedFixed32() { - PrepareBuilder(); - result.packedFixed32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList PackedFixed64List { - get { return PrepareBuilder().packedFixed64_; } - } - public int PackedFixed64Count { - get { return result.PackedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetPackedFixed64(int index) { - return result.GetPackedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetPackedFixed64(int index, ulong value) { - PrepareBuilder(); - result.packedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddPackedFixed64(ulong value) { - PrepareBuilder(); - result.packedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangePackedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedFixed64_.Add(values); - return this; - } - public Builder ClearPackedFixed64() { - PrepareBuilder(); - result.packedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSfixed32List { - get { return PrepareBuilder().packedSfixed32_; } - } - public int PackedSfixed32Count { - get { return result.PackedSfixed32Count; } - } - public int GetPackedSfixed32(int index) { - return result.GetPackedSfixed32(index); - } - public Builder SetPackedSfixed32(int index, int value) { - PrepareBuilder(); - result.packedSfixed32_[index] = value; - return this; - } - public Builder AddPackedSfixed32(int value) { - PrepareBuilder(); - result.packedSfixed32_.Add(value); - return this; - } - public Builder AddRangePackedSfixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSfixed32_.Add(values); - return this; - } - public Builder ClearPackedSfixed32() { - PrepareBuilder(); - result.packedSfixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedSfixed64List { - get { return PrepareBuilder().packedSfixed64_; } - } - public int PackedSfixed64Count { - get { return result.PackedSfixed64Count; } - } - public long GetPackedSfixed64(int index) { - return result.GetPackedSfixed64(index); - } - public Builder SetPackedSfixed64(int index, long value) { - PrepareBuilder(); - result.packedSfixed64_[index] = value; - return this; - } - public Builder AddPackedSfixed64(long value) { - PrepareBuilder(); - result.packedSfixed64_.Add(value); - return this; - } - public Builder AddRangePackedSfixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.packedSfixed64_.Add(values); - return this; - } - public Builder ClearPackedSfixed64() { - PrepareBuilder(); - result.packedSfixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedFloatList { - get { return PrepareBuilder().packedFloat_; } - } - public int PackedFloatCount { - get { return result.PackedFloatCount; } - } - public float GetPackedFloat(int index) { - return result.GetPackedFloat(index); - } - public Builder SetPackedFloat(int index, float value) { - PrepareBuilder(); - result.packedFloat_[index] = value; - return this; - } - public Builder AddPackedFloat(float value) { - PrepareBuilder(); - result.packedFloat_.Add(value); - return this; - } - public Builder AddRangePackedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.packedFloat_.Add(values); - return this; - } - public Builder ClearPackedFloat() { - PrepareBuilder(); - result.packedFloat_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedDoubleList { - get { return PrepareBuilder().packedDouble_; } - } - public int PackedDoubleCount { - get { return result.PackedDoubleCount; } - } - public double GetPackedDouble(int index) { - return result.GetPackedDouble(index); - } - public Builder SetPackedDouble(int index, double value) { - PrepareBuilder(); - result.packedDouble_[index] = value; - return this; - } - public Builder AddPackedDouble(double value) { - PrepareBuilder(); - result.packedDouble_.Add(value); - return this; - } - public Builder AddRangePackedDouble(scg::IEnumerable values) { - PrepareBuilder(); - result.packedDouble_.Add(values); - return this; - } - public Builder ClearPackedDouble() { - PrepareBuilder(); - result.packedDouble_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedBoolList { - get { return PrepareBuilder().packedBool_; } - } - public int PackedBoolCount { - get { return result.PackedBoolCount; } - } - public bool GetPackedBool(int index) { - return result.GetPackedBool(index); - } - public Builder SetPackedBool(int index, bool value) { - PrepareBuilder(); - result.packedBool_[index] = value; - return this; - } - public Builder AddPackedBool(bool value) { - PrepareBuilder(); - result.packedBool_.Add(value); - return this; - } - public Builder AddRangePackedBool(scg::IEnumerable values) { - PrepareBuilder(); - result.packedBool_.Add(values); - return this; - } - public Builder ClearPackedBool() { - PrepareBuilder(); - result.packedBool_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedEnumList { - get { return PrepareBuilder().packedEnum_; } - } - public int PackedEnumCount { - get { return result.PackedEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetPackedEnum(int index) { - return result.GetPackedEnum(index); - } - public Builder SetPackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.packedEnum_[index] = value; - return this; - } - public Builder AddPackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.packedEnum_.Add(value); - return this; - } - public Builder AddRangePackedEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.packedEnum_.Add(values); - return this; - } - public Builder ClearPackedEnum() { - PrepareBuilder(); - result.packedEnum_.Clear(); - return this; - } - } - static TestPackedTypes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestUnpackedTypes : pb::GeneratedMessage { - private TestUnpackedTypes() { } - private static readonly TestUnpackedTypes defaultInstance = new TestUnpackedTypes().MakeReadOnly(); - private static readonly string[] _testUnpackedTypesFieldNames = new string[] { "unpacked_bool", "unpacked_double", "unpacked_enum", "unpacked_fixed32", "unpacked_fixed64", "unpacked_float", "unpacked_int32", "unpacked_int64", "unpacked_sfixed32", "unpacked_sfixed64", "unpacked_sint32", "unpacked_sint64", "unpacked_uint32", "unpacked_uint64" }; - private static readonly uint[] _testUnpackedTypesFieldTags = new uint[] { 816, 809, 824, 773, 777, 805, 720, 728, 789, 793, 752, 760, 736, 744 }; - public static TestUnpackedTypes DefaultInstance { - get { return defaultInstance; } - } + public override OptionalGroup DefaultInstanceForType + { + get { return DefaultInstance; } + } - public override TestUnpackedTypes DefaultInstanceForType { - get { return DefaultInstance; } - } + protected override OptionalGroup ThisMessage + { + get { return this; } + } - protected override TestUnpackedTypes ThisMessage { - get { return this; } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__FieldAccessorTable; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable; } - } + public const int OptionalGroupAllTypesFieldNumber = 11; + private bool hasOptionalGroupAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes optionalGroupAllTypes_; + public bool HasOptionalGroupAllTypes + { + get { return hasOptionalGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalGroupAllTypes + { + get { return optionalGroupAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } - public const int UnpackedInt32FieldNumber = 90; - private pbc::PopsicleList unpackedInt32_ = new pbc::PopsicleList(); - public scg::IList UnpackedInt32List { - get { return pbc::Lists.AsReadOnly(unpackedInt32_); } - } - public int UnpackedInt32Count { - get { return unpackedInt32_.Count; } - } - public int GetUnpackedInt32(int index) { - return unpackedInt32_[index]; - } + public override bool IsInitialized + { + get + { + return true; + } + } - public const int UnpackedInt64FieldNumber = 91; - private pbc::PopsicleList unpackedInt64_ = new pbc::PopsicleList(); - public scg::IList UnpackedInt64List { - get { return pbc::Lists.AsReadOnly(unpackedInt64_); } - } - public int UnpackedInt64Count { - get { return unpackedInt64_.Count; } - } - public long GetUnpackedInt64(int index) { - return unpackedInt64_[index]; - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _optionalGroupFieldNames; + if (hasOptionalGroupAllTypes) + { + output.WriteMessage(11, field_names[0], OptionalGroupAllTypes); + } + UnknownFields.WriteTo(output); + } - public const int UnpackedUint32FieldNumber = 92; - private pbc::PopsicleList unpackedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedUint32List { - get { return pbc::Lists.AsReadOnly(unpackedUint32_); } - } - public int UnpackedUint32Count { - get { return unpackedUint32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedUint32(int index) { - return unpackedUint32_[index]; - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - public const int UnpackedUint64FieldNumber = 93; - private pbc::PopsicleList unpackedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedUint64List { - get { return pbc::Lists.AsReadOnly(unpackedUint64_); } - } - public int UnpackedUint64Count { - get { return unpackedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedUint64(int index) { - return unpackedUint64_[index]; - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public const int UnpackedSint32FieldNumber = 94; - private pbc::PopsicleList unpackedSint32_ = new pbc::PopsicleList(); - public scg::IList UnpackedSint32List { - get { return pbc::Lists.AsReadOnly(unpackedSint32_); } - } - public int UnpackedSint32Count { - get { return unpackedSint32_.Count; } - } - public int GetUnpackedSint32(int index) { - return unpackedSint32_[index]; - } + size = 0; + if (hasOptionalGroupAllTypes) + { + size += pb::CodedOutputStream.ComputeMessageSize(11, OptionalGroupAllTypes); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static OptionalGroup ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private OptionalGroup MakeReadOnly() + { + return this; + } - public const int UnpackedSint64FieldNumber = 95; - private pbc::PopsicleList unpackedSint64_ = new pbc::PopsicleList(); - public scg::IList UnpackedSint64List { - get { return pbc::Lists.AsReadOnly(unpackedSint64_); } - } - public int UnpackedSint64Count { - get { return unpackedSint64_.Count; } - } - public long GetUnpackedSint64(int index) { - return unpackedSint64_[index]; - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(OptionalGroup prototype) + { + return new Builder(prototype); + } - public const int UnpackedFixed32FieldNumber = 96; - private pbc::PopsicleList unpackedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedFixed32List { - get { return pbc::Lists.AsReadOnly(unpackedFixed32_); } - } - public int UnpackedFixed32Count { - get { return unpackedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedFixed32(int index) { - return unpackedFixed32_[index]; - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(OptionalGroup cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - public const int UnpackedFixed64FieldNumber = 97; - private pbc::PopsicleList unpackedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList UnpackedFixed64List { - get { return pbc::Lists.AsReadOnly(unpackedFixed64_); } - } - public int UnpackedFixed64Count { - get { return unpackedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedFixed64(int index) { - return unpackedFixed64_[index]; - } + private bool resultIsReadOnly; + private OptionalGroup result; + + private OptionalGroup PrepareBuilder() + { + if (resultIsReadOnly) + { + OptionalGroup original = result; + result = new OptionalGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public const int UnpackedSfixed32FieldNumber = 98; - private pbc::PopsicleList unpackedSfixed32_ = new pbc::PopsicleList(); - public scg::IList UnpackedSfixed32List { - get { return pbc::Lists.AsReadOnly(unpackedSfixed32_); } - } - public int UnpackedSfixed32Count { - get { return unpackedSfixed32_.Count; } - } - public int GetUnpackedSfixed32(int index) { - return unpackedSfixed32_[index]; - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public const int UnpackedSfixed64FieldNumber = 99; - private pbc::PopsicleList unpackedSfixed64_ = new pbc::PopsicleList(); - public scg::IList UnpackedSfixed64List { - get { return pbc::Lists.AsReadOnly(unpackedSfixed64_); } - } - public int UnpackedSfixed64Count { - get { return unpackedSfixed64_.Count; } - } - public long GetUnpackedSfixed64(int index) { - return unpackedSfixed64_[index]; - } + protected override OptionalGroup MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public const int UnpackedFloatFieldNumber = 100; - private pbc::PopsicleList unpackedFloat_ = new pbc::PopsicleList(); - public scg::IList UnpackedFloatList { - get { return pbc::Lists.AsReadOnly(unpackedFloat_); } - } - public int UnpackedFloatCount { - get { return unpackedFloat_.Count; } - } - public float GetUnpackedFloat(int index) { - return unpackedFloat_[index]; - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public const int UnpackedDoubleFieldNumber = 101; - private pbc::PopsicleList unpackedDouble_ = new pbc::PopsicleList(); - public scg::IList UnpackedDoubleList { - get { return pbc::Lists.AsReadOnly(unpackedDouble_); } - } - public int UnpackedDoubleCount { - get { return unpackedDouble_.Count; } - } - public double GetUnpackedDouble(int index) { - return unpackedDouble_[index]; - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public const int UnpackedBoolFieldNumber = 102; - private pbc::PopsicleList unpackedBool_ = new pbc::PopsicleList(); - public scg::IList UnpackedBoolList { - get { return pbc::Lists.AsReadOnly(unpackedBool_); } - } - public int UnpackedBoolCount { - get { return unpackedBool_.Count; } - } - public bool GetUnpackedBool(int index) { - return unpackedBool_[index]; - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.Descriptor; } + } - public const int UnpackedEnumFieldNumber = 103; - private pbc::PopsicleList unpackedEnum_ = new pbc::PopsicleList(); - public scg::IList UnpackedEnumList { - get { return pbc::Lists.AsReadOnly(unpackedEnum_); } - } - public int UnpackedEnumCount { - get { return unpackedEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetUnpackedEnum(int index) { - return unpackedEnum_[index]; - } + public override OptionalGroup DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance; } + } - public override bool IsInitialized { - get { - return true; - } - } + public override OptionalGroup BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testUnpackedTypesFieldNames; - if (unpackedInt32_.Count > 0) { - output.WriteInt32Array(90, field_names[6], unpackedInt32_); - } - if (unpackedInt64_.Count > 0) { - output.WriteInt64Array(91, field_names[7], unpackedInt64_); - } - if (unpackedUint32_.Count > 0) { - output.WriteUInt32Array(92, field_names[12], unpackedUint32_); - } - if (unpackedUint64_.Count > 0) { - output.WriteUInt64Array(93, field_names[13], unpackedUint64_); - } - if (unpackedSint32_.Count > 0) { - output.WriteSInt32Array(94, field_names[10], unpackedSint32_); - } - if (unpackedSint64_.Count > 0) { - output.WriteSInt64Array(95, field_names[11], unpackedSint64_); - } - if (unpackedFixed32_.Count > 0) { - output.WriteFixed32Array(96, field_names[3], unpackedFixed32_); - } - if (unpackedFixed64_.Count > 0) { - output.WriteFixed64Array(97, field_names[4], unpackedFixed64_); - } - if (unpackedSfixed32_.Count > 0) { - output.WriteSFixed32Array(98, field_names[8], unpackedSfixed32_); - } - if (unpackedSfixed64_.Count > 0) { - output.WriteSFixed64Array(99, field_names[9], unpackedSfixed64_); - } - if (unpackedFloat_.Count > 0) { - output.WriteFloatArray(100, field_names[5], unpackedFloat_); - } - if (unpackedDouble_.Count > 0) { - output.WriteDoubleArray(101, field_names[1], unpackedDouble_); - } - if (unpackedBool_.Count > 0) { - output.WriteBoolArray(102, field_names[0], unpackedBool_); - } - if (unpackedEnum_.Count > 0) { - output.WriteEnumArray(103, field_names[2], unpackedEnum_); - } - UnknownFields.WriteTo(output); - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is OptionalGroup) + { + return MergeFrom((OptionalGroup)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override Builder MergeFrom(OptionalGroup other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasOptionalGroupAllTypes) + { + MergeOptionalGroupAllTypes(other.OptionalGroupAllTypes); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - foreach (int element in UnpackedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedInt32_.Count; - } - { - int dataSize = 0; - foreach (long element in UnpackedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedInt64_.Count; - } - { - int dataSize = 0; - foreach (uint element in UnpackedUint32List) { - dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedUint32_.Count; - } - { - int dataSize = 0; - foreach (ulong element in UnpackedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedUint64_.Count; - } - { - int dataSize = 0; - foreach (int element in UnpackedSint32List) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedSint32_.Count; - } - { - int dataSize = 0; - foreach (long element in UnpackedSint64List) { - dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * unpackedSint64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * unpackedFixed32_.Count; - size += dataSize; - size += 2 * unpackedFixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * unpackedFixed64_.Count; - size += dataSize; - size += 2 * unpackedFixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * unpackedSfixed32_.Count; - size += dataSize; - size += 2 * unpackedSfixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * unpackedSfixed64_.Count; - size += dataSize; - size += 2 * unpackedSfixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * unpackedFloat_.Count; - size += dataSize; - size += 2 * unpackedFloat_.Count; - } - { - int dataSize = 0; - dataSize = 8 * unpackedDouble_.Count; - size += dataSize; - size += 2 * unpackedDouble_.Count; - } - { - int dataSize = 0; - dataSize = 1 * unpackedBool_.Count; - size += dataSize; - size += 2 * unpackedBool_.Count; - } - { - int dataSize = 0; - if (unpackedEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in unpackedEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * unpackedEnum_.Count; - } - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestUnpackedTypes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedTypes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestUnpackedTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestUnpackedTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestUnpackedTypes MakeReadOnly() { - unpackedInt32_.MakeReadOnly(); - unpackedInt64_.MakeReadOnly(); - unpackedUint32_.MakeReadOnly(); - unpackedUint64_.MakeReadOnly(); - unpackedSint32_.MakeReadOnly(); - unpackedSint64_.MakeReadOnly(); - unpackedFixed32_.MakeReadOnly(); - unpackedFixed64_.MakeReadOnly(); - unpackedSfixed32_.MakeReadOnly(); - unpackedSfixed64_.MakeReadOnly(); - unpackedFloat_.MakeReadOnly(); - unpackedDouble_.MakeReadOnly(); - unpackedBool_.MakeReadOnly(); - unpackedEnum_.MakeReadOnly(); - return this; - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestUnpackedTypes prototype) { - return new Builder(prototype); - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _optionalGroupFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 90: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasOptionalGroupAllTypes) + { + subBuilder.MergeFrom(OptionalGroupAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalGroupAllTypes = subBuilder.BuildPartial(); + break; + } + } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestUnpackedTypes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestUnpackedTypes result; - - private TestUnpackedTypes PrepareBuilder() { - if (resultIsReadOnly) { - TestUnpackedTypes original = result; - result = new TestUnpackedTypes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestUnpackedTypes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.Descriptor; } - } - - public override TestUnpackedTypes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.DefaultInstance; } - } - - public override TestUnpackedTypes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestUnpackedTypes) { - return MergeFrom((TestUnpackedTypes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestUnpackedTypes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.DefaultInstance) return this; - PrepareBuilder(); - if (other.unpackedInt32_.Count != 0) { - result.unpackedInt32_.Add(other.unpackedInt32_); - } - if (other.unpackedInt64_.Count != 0) { - result.unpackedInt64_.Add(other.unpackedInt64_); - } - if (other.unpackedUint32_.Count != 0) { - result.unpackedUint32_.Add(other.unpackedUint32_); - } - if (other.unpackedUint64_.Count != 0) { - result.unpackedUint64_.Add(other.unpackedUint64_); - } - if (other.unpackedSint32_.Count != 0) { - result.unpackedSint32_.Add(other.unpackedSint32_); - } - if (other.unpackedSint64_.Count != 0) { - result.unpackedSint64_.Add(other.unpackedSint64_); - } - if (other.unpackedFixed32_.Count != 0) { - result.unpackedFixed32_.Add(other.unpackedFixed32_); - } - if (other.unpackedFixed64_.Count != 0) { - result.unpackedFixed64_.Add(other.unpackedFixed64_); - } - if (other.unpackedSfixed32_.Count != 0) { - result.unpackedSfixed32_.Add(other.unpackedSfixed32_); - } - if (other.unpackedSfixed64_.Count != 0) { - result.unpackedSfixed64_.Add(other.unpackedSfixed64_); - } - if (other.unpackedFloat_.Count != 0) { - result.unpackedFloat_.Add(other.unpackedFloat_); - } - if (other.unpackedDouble_.Count != 0) { - result.unpackedDouble_.Add(other.unpackedDouble_); - } - if (other.unpackedBool_.Count != 0) { - result.unpackedBool_.Add(other.unpackedBool_); - } - if (other.unpackedEnum_.Count != 0) { - result.unpackedEnum_.Add(other.unpackedEnum_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testUnpackedTypesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testUnpackedTypesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 722: - case 720: { - input.ReadInt32Array(tag, field_name, result.unpackedInt32_); - break; - } - case 730: - case 728: { - input.ReadInt64Array(tag, field_name, result.unpackedInt64_); - break; - } - case 738: - case 736: { - input.ReadUInt32Array(tag, field_name, result.unpackedUint32_); - break; - } - case 746: - case 744: { - input.ReadUInt64Array(tag, field_name, result.unpackedUint64_); - break; - } - case 754: - case 752: { - input.ReadSInt32Array(tag, field_name, result.unpackedSint32_); - break; - } - case 762: - case 760: { - input.ReadSInt64Array(tag, field_name, result.unpackedSint64_); - break; - } - case 770: - case 773: { - input.ReadFixed32Array(tag, field_name, result.unpackedFixed32_); - break; - } - case 778: - case 777: { - input.ReadFixed64Array(tag, field_name, result.unpackedFixed64_); - break; - } - case 786: - case 789: { - input.ReadSFixed32Array(tag, field_name, result.unpackedSfixed32_); - break; - } - case 794: - case 793: { - input.ReadSFixed64Array(tag, field_name, result.unpackedSfixed64_); - break; - } - case 802: - case 805: { - input.ReadFloatArray(tag, field_name, result.unpackedFloat_); - break; - } - case 810: - case 809: { - input.ReadDoubleArray(tag, field_name, result.unpackedDouble_); - break; - } - case 818: - case 816: { - input.ReadBoolArray(tag, field_name, result.unpackedBool_); - break; - } - case 826: - case 824: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.unpackedEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(103, (ulong)(int)rawValue); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public pbc::IPopsicleList UnpackedInt32List { - get { return PrepareBuilder().unpackedInt32_; } - } - public int UnpackedInt32Count { - get { return result.UnpackedInt32Count; } - } - public int GetUnpackedInt32(int index) { - return result.GetUnpackedInt32(index); - } - public Builder SetUnpackedInt32(int index, int value) { - PrepareBuilder(); - result.unpackedInt32_[index] = value; - return this; - } - public Builder AddUnpackedInt32(int value) { - PrepareBuilder(); - result.unpackedInt32_.Add(value); - return this; - } - public Builder AddRangeUnpackedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedInt32_.Add(values); - return this; - } - public Builder ClearUnpackedInt32() { - PrepareBuilder(); - result.unpackedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedInt64List { - get { return PrepareBuilder().unpackedInt64_; } - } - public int UnpackedInt64Count { - get { return result.UnpackedInt64Count; } - } - public long GetUnpackedInt64(int index) { - return result.GetUnpackedInt64(index); - } - public Builder SetUnpackedInt64(int index, long value) { - PrepareBuilder(); - result.unpackedInt64_[index] = value; - return this; - } - public Builder AddUnpackedInt64(long value) { - PrepareBuilder(); - result.unpackedInt64_.Add(value); - return this; - } - public Builder AddRangeUnpackedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedInt64_.Add(values); - return this; - } - public Builder ClearUnpackedInt64() { - PrepareBuilder(); - result.unpackedInt64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedUint32List { - get { return PrepareBuilder().unpackedUint32_; } - } - public int UnpackedUint32Count { - get { return result.UnpackedUint32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedUint32(int index) { - return result.GetUnpackedUint32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedUint32(int index, uint value) { - PrepareBuilder(); - result.unpackedUint32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedUint32(uint value) { - PrepareBuilder(); - result.unpackedUint32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedUint32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedUint32_.Add(values); - return this; - } - public Builder ClearUnpackedUint32() { - PrepareBuilder(); - result.unpackedUint32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedUint64List { - get { return PrepareBuilder().unpackedUint64_; } - } - public int UnpackedUint64Count { - get { return result.UnpackedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedUint64(int index) { - return result.GetUnpackedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedUint64(int index, ulong value) { - PrepareBuilder(); - result.unpackedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedUint64(ulong value) { - PrepareBuilder(); - result.unpackedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedUint64_.Add(values); - return this; - } - public Builder ClearUnpackedUint64() { - PrepareBuilder(); - result.unpackedUint64_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSint32List { - get { return PrepareBuilder().unpackedSint32_; } - } - public int UnpackedSint32Count { - get { return result.UnpackedSint32Count; } - } - public int GetUnpackedSint32(int index) { - return result.GetUnpackedSint32(index); - } - public Builder SetUnpackedSint32(int index, int value) { - PrepareBuilder(); - result.unpackedSint32_[index] = value; - return this; - } - public Builder AddUnpackedSint32(int value) { - PrepareBuilder(); - result.unpackedSint32_.Add(value); - return this; - } - public Builder AddRangeUnpackedSint32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSint32_.Add(values); - return this; - } - public Builder ClearUnpackedSint32() { - PrepareBuilder(); - result.unpackedSint32_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSint64List { - get { return PrepareBuilder().unpackedSint64_; } - } - public int UnpackedSint64Count { - get { return result.UnpackedSint64Count; } - } - public long GetUnpackedSint64(int index) { - return result.GetUnpackedSint64(index); - } - public Builder SetUnpackedSint64(int index, long value) { - PrepareBuilder(); - result.unpackedSint64_[index] = value; - return this; - } - public Builder AddUnpackedSint64(long value) { - PrepareBuilder(); - result.unpackedSint64_.Add(value); - return this; - } - public Builder AddRangeUnpackedSint64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSint64_.Add(values); - return this; - } - public Builder ClearUnpackedSint64() { - PrepareBuilder(); - result.unpackedSint64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedFixed32List { - get { return PrepareBuilder().unpackedFixed32_; } - } - public int UnpackedFixed32Count { - get { return result.UnpackedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetUnpackedFixed32(int index) { - return result.GetUnpackedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedFixed32(int index, uint value) { - PrepareBuilder(); - result.unpackedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedFixed32(uint value) { - PrepareBuilder(); - result.unpackedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedFixed32_.Add(values); - return this; - } - public Builder ClearUnpackedFixed32() { - PrepareBuilder(); - result.unpackedFixed32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList UnpackedFixed64List { - get { return PrepareBuilder().unpackedFixed64_; } - } - public int UnpackedFixed64Count { - get { return result.UnpackedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetUnpackedFixed64(int index) { - return result.GetUnpackedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetUnpackedFixed64(int index, ulong value) { - PrepareBuilder(); - result.unpackedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddUnpackedFixed64(ulong value) { - PrepareBuilder(); - result.unpackedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeUnpackedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedFixed64_.Add(values); - return this; - } - public Builder ClearUnpackedFixed64() { - PrepareBuilder(); - result.unpackedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSfixed32List { - get { return PrepareBuilder().unpackedSfixed32_; } - } - public int UnpackedSfixed32Count { - get { return result.UnpackedSfixed32Count; } - } - public int GetUnpackedSfixed32(int index) { - return result.GetUnpackedSfixed32(index); - } - public Builder SetUnpackedSfixed32(int index, int value) { - PrepareBuilder(); - result.unpackedSfixed32_[index] = value; - return this; - } - public Builder AddUnpackedSfixed32(int value) { - PrepareBuilder(); - result.unpackedSfixed32_.Add(value); - return this; - } - public Builder AddRangeUnpackedSfixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSfixed32_.Add(values); - return this; - } - public Builder ClearUnpackedSfixed32() { - PrepareBuilder(); - result.unpackedSfixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedSfixed64List { - get { return PrepareBuilder().unpackedSfixed64_; } - } - public int UnpackedSfixed64Count { - get { return result.UnpackedSfixed64Count; } - } - public long GetUnpackedSfixed64(int index) { - return result.GetUnpackedSfixed64(index); - } - public Builder SetUnpackedSfixed64(int index, long value) { - PrepareBuilder(); - result.unpackedSfixed64_[index] = value; - return this; - } - public Builder AddUnpackedSfixed64(long value) { - PrepareBuilder(); - result.unpackedSfixed64_.Add(value); - return this; - } - public Builder AddRangeUnpackedSfixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedSfixed64_.Add(values); - return this; - } - public Builder ClearUnpackedSfixed64() { - PrepareBuilder(); - result.unpackedSfixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedFloatList { - get { return PrepareBuilder().unpackedFloat_; } - } - public int UnpackedFloatCount { - get { return result.UnpackedFloatCount; } - } - public float GetUnpackedFloat(int index) { - return result.GetUnpackedFloat(index); - } - public Builder SetUnpackedFloat(int index, float value) { - PrepareBuilder(); - result.unpackedFloat_[index] = value; - return this; - } - public Builder AddUnpackedFloat(float value) { - PrepareBuilder(); - result.unpackedFloat_.Add(value); - return this; - } - public Builder AddRangeUnpackedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedFloat_.Add(values); - return this; - } - public Builder ClearUnpackedFloat() { - PrepareBuilder(); - result.unpackedFloat_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedDoubleList { - get { return PrepareBuilder().unpackedDouble_; } - } - public int UnpackedDoubleCount { - get { return result.UnpackedDoubleCount; } - } - public double GetUnpackedDouble(int index) { - return result.GetUnpackedDouble(index); - } - public Builder SetUnpackedDouble(int index, double value) { - PrepareBuilder(); - result.unpackedDouble_[index] = value; - return this; - } - public Builder AddUnpackedDouble(double value) { - PrepareBuilder(); - result.unpackedDouble_.Add(value); - return this; - } - public Builder AddRangeUnpackedDouble(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedDouble_.Add(values); - return this; - } - public Builder ClearUnpackedDouble() { - PrepareBuilder(); - result.unpackedDouble_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedBoolList { - get { return PrepareBuilder().unpackedBool_; } - } - public int UnpackedBoolCount { - get { return result.UnpackedBoolCount; } - } - public bool GetUnpackedBool(int index) { - return result.GetUnpackedBool(index); - } - public Builder SetUnpackedBool(int index, bool value) { - PrepareBuilder(); - result.unpackedBool_[index] = value; - return this; - } - public Builder AddUnpackedBool(bool value) { - PrepareBuilder(); - result.unpackedBool_.Add(value); - return this; - } - public Builder AddRangeUnpackedBool(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedBool_.Add(values); - return this; - } - public Builder ClearUnpackedBool() { - PrepareBuilder(); - result.unpackedBool_.Clear(); - return this; - } - - public pbc::IPopsicleList UnpackedEnumList { - get { return PrepareBuilder().unpackedEnum_; } - } - public int UnpackedEnumCount { - get { return result.UnpackedEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetUnpackedEnum(int index) { - return result.GetUnpackedEnum(index); - } - public Builder SetUnpackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.unpackedEnum_[index] = value; - return this; - } - public Builder AddUnpackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.unpackedEnum_.Add(value); - return this; - } - public Builder AddRangeUnpackedEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.unpackedEnum_.Add(values); - return this; - } - public Builder ClearUnpackedEnum() { - PrepareBuilder(); - result.unpackedEnum_.Clear(); - return this; - } - } - static TestUnpackedTypes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestPackedExtensions : pb::ExtendableMessage { - private TestPackedExtensions() { } - private static readonly TestPackedExtensions defaultInstance = new TestPackedExtensions().MakeReadOnly(); - private static readonly string[] _testPackedExtensionsFieldNames = new string[] { }; - private static readonly uint[] _testPackedExtensionsFieldTags = new uint[] { }; - public static TestPackedExtensions DefaultInstance { - get { return defaultInstance; } - } - public override TestPackedExtensions DefaultInstanceForType { - get { return DefaultInstance; } - } + public bool HasOptionalGroupAllTypes + { + get { return result.hasOptionalGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalGroupAllTypes + { + get { return result.OptionalGroupAllTypes; } + set { SetOptionalGroupAllTypes(value); } + } + public Builder SetOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalGroupAllTypes = true; + result.optionalGroupAllTypes_ = value; + return this; + } + public Builder SetOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalGroupAllTypes = true; + result.optionalGroupAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalGroupAllTypes && + result.optionalGroupAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.optionalGroupAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.optionalGroupAllTypes_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalGroupAllTypes_ = value; + } + result.hasOptionalGroupAllTypes = true; + return this; + } + public Builder ClearOptionalGroupAllTypes() + { + PrepareBuilder(); + result.hasOptionalGroupAllTypes = false; + result.optionalGroupAllTypes_ = null; + return this; + } + } + static OptionalGroup() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - protected override TestPackedExtensions ThisMessage { - get { return this; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class RepeatedGroup : pb::GeneratedMessage + { + private RepeatedGroup() { } + private static readonly RepeatedGroup defaultInstance = new RepeatedGroup().MakeReadOnly(); + private static readonly string[] _repeatedGroupFieldNames = new string[] { "repeated_group_all_types" }; + private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 170 }; + public static RepeatedGroup DefaultInstance + { + get { return defaultInstance; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedExtensions__Descriptor; } - } + public override RepeatedGroup DefaultInstanceForType + { + get { return DefaultInstance; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable; } - } + protected override RepeatedGroup ThisMessage + { + get { return this; } + } - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testPackedExtensionsFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(536870912, output); - UnknownFields.WriteTo(output); - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__FieldAccessorTable; } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public const int RepeatedGroupAllTypesFieldNumber = 21; + private bool hasRepeatedGroupAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes repeatedGroupAllTypes_; + public bool HasRepeatedGroupAllTypes + { + get { return hasRepeatedGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RepeatedGroupAllTypes + { + get { return repeatedGroupAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public override bool IsInitialized + { + get + { + return true; + } + } - size = 0; - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestPackedExtensions ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestPackedExtensions ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestPackedExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestPackedExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestPackedExtensions MakeReadOnly() { - return this; - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _repeatedGroupFieldNames; + if (hasRepeatedGroupAllTypes) + { + output.WriteMessage(21, field_names[0], RepeatedGroupAllTypes); + } + UnknownFields.WriteTo(output); + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestPackedExtensions prototype) { - return new Builder(prototype); - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestPackedExtensions cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestPackedExtensions result; - - private TestPackedExtensions PrepareBuilder() { - if (resultIsReadOnly) { - TestPackedExtensions original = result; - result = new TestPackedExtensions(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestPackedExtensions MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.Descriptor; } - } - - public override TestPackedExtensions DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.DefaultInstance; } - } - - public override TestPackedExtensions BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestPackedExtensions) { - return MergeFrom((TestPackedExtensions) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestPackedExtensions other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testPackedExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testPackedExtensionsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - } - static TestPackedExtensions() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestUnpackedExtensions : pb::ExtendableMessage { - private TestUnpackedExtensions() { } - private static readonly TestUnpackedExtensions defaultInstance = new TestUnpackedExtensions().MakeReadOnly(); - private static readonly string[] _testUnpackedExtensionsFieldNames = new string[] { }; - private static readonly uint[] _testUnpackedExtensionsFieldTags = new uint[] { }; - public static TestUnpackedExtensions DefaultInstance { - get { return defaultInstance; } - } + size = 0; + if (hasRepeatedGroupAllTypes) + { + size += pb::CodedOutputStream.ComputeMessageSize(21, RepeatedGroupAllTypes); + } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static RepeatedGroup ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private RepeatedGroup MakeReadOnly() + { + return this; + } - public override TestUnpackedExtensions DefaultInstanceForType { - get { return DefaultInstance; } - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(RepeatedGroup prototype) + { + return new Builder(prototype); + } - protected override TestUnpackedExtensions ThisMessage { - get { return this; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(RepeatedGroup cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor; } - } + private bool resultIsReadOnly; + private RepeatedGroup result; + + private RepeatedGroup PrepareBuilder() + { + if (resultIsReadOnly) + { + RepeatedGroup original = result; + result = new RepeatedGroup(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } + protected override RepeatedGroup MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testUnpackedExtensionsFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - extensionWriter.WriteUntil(536870912, output); - UnknownFields.WriteTo(output); - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.Descriptor; } + } - size = 0; - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestUnpackedExtensions ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestUnpackedExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedExtensions ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestUnpackedExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedExtensions ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestUnpackedExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestUnpackedExtensions ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestUnpackedExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestUnpackedExtensions ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestUnpackedExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestUnpackedExtensions MakeReadOnly() { - return this; - } + public override RepeatedGroup DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.DefaultInstance; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestUnpackedExtensions prototype) { - return new Builder(prototype); - } + public override RepeatedGroup BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestUnpackedExtensions cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestUnpackedExtensions result; - - private TestUnpackedExtensions PrepareBuilder() { - if (resultIsReadOnly) { - TestUnpackedExtensions original = result; - result = new TestUnpackedExtensions(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestUnpackedExtensions MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.Descriptor; } - } - - public override TestUnpackedExtensions DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.DefaultInstance; } - } - - public override TestUnpackedExtensions BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestUnpackedExtensions) { - return MergeFrom((TestUnpackedExtensions) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestUnpackedExtensions other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.DefaultInstance) return this; - PrepareBuilder(); - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testUnpackedExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testUnpackedExtensionsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is RepeatedGroup) + { + return MergeFrom((RepeatedGroup)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - } - static TestUnpackedExtensions() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestDynamicExtensions : pb::GeneratedMessage { - private TestDynamicExtensions() { } - private static readonly TestDynamicExtensions defaultInstance = new TestDynamicExtensions().MakeReadOnly(); - private static readonly string[] _testDynamicExtensionsFieldNames = new string[] { "dynamic_enum_extension", "dynamic_message_extension", "enum_extension", "message_extension", "packed_extension", "repeated_extension", "scalar_extension" }; - private static readonly uint[] _testDynamicExtensionsFieldTags = new uint[] { 16016, 16034, 16008, 16026, 16050, 16042, 16005 }; - public static TestDynamicExtensions DefaultInstance { - get { return defaultInstance; } - } + public override Builder MergeFrom(RepeatedGroup other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasRepeatedGroupAllTypes) + { + MergeRepeatedGroupAllTypes(other.RepeatedGroupAllTypes); + } + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public override TestDynamicExtensions DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - protected override TestDynamicExtensions ThisMessage { - get { return this; } - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _repeatedGroupFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 170: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasRepeatedGroupAllTypes) + { + subBuilder.MergeFrom(RepeatedGroupAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + RepeatedGroupAllTypes = subBuilder.BuildPartial(); + break; + } + } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor; } - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable; } - } - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - public enum DynamicEnumType { - DYNAMIC_FOO = 2200, - DYNAMIC_BAR = 2201, - DYNAMIC_BAZ = 2202, - } + public bool HasRepeatedGroupAllTypes + { + get { return result.hasRepeatedGroupAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RepeatedGroupAllTypes + { + get { return result.RepeatedGroupAllTypes; } + set { SetRepeatedGroupAllTypes(value); } + } + public Builder SetRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasRepeatedGroupAllTypes = true; + result.repeatedGroupAllTypes_ = value; + return this; + } + public Builder SetRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasRepeatedGroupAllTypes = true; + result.repeatedGroupAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasRepeatedGroupAllTypes && + result.repeatedGroupAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.repeatedGroupAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.repeatedGroupAllTypes_).MergeFrom(value).BuildPartial(); + } + else + { + result.repeatedGroupAllTypes_ = value; + } + result.hasRepeatedGroupAllTypes = true; + return this; + } + public Builder ClearRepeatedGroupAllTypes() + { + PrepareBuilder(); + result.hasRepeatedGroupAllTypes = false; + result.repeatedGroupAllTypes_ = null; + return this; + } + } + static RepeatedGroup() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class DynamicMessageType : pb::GeneratedMessage { - private DynamicMessageType() { } - private static readonly DynamicMessageType defaultInstance = new DynamicMessageType().MakeReadOnly(); - private static readonly string[] _dynamicMessageTypeFieldNames = new string[] { "dynamic_field" }; - private static readonly uint[] _dynamicMessageTypeFieldTags = new uint[] { 16800 }; - public static DynamicMessageType DefaultInstance { - get { return defaultInstance; } } + #endregion - public override DynamicMessageType DefaultInstanceForType { - get { return DefaultInstance; } + public const int RequiredAllTypesFieldNumber = 1; + private bool hasRequiredAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes requiredAllTypes_; + public bool HasRequiredAllTypes + { + get { return hasRequiredAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RequiredAllTypes + { + get { return requiredAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } } - protected override DynamicMessageType ThisMessage { - get { return this; } + public const int OptionalAllTypesFieldNumber = 2; + private bool hasOptionalAllTypes; + private global::Google.ProtocolBuffers.TestProtos.TestAllTypes optionalAllTypes_; + public bool HasOptionalAllTypes + { + get { return hasOptionalAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalAllTypes + { + get { return optionalAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor; } + public const int RepeatedAllTypesFieldNumber = 3; + private pbc::PopsicleList repeatedAllTypes_ = new pbc::PopsicleList(); + public scg::IList RepeatedAllTypesList + { + get { return repeatedAllTypes_; } + } + public int RepeatedAllTypesCount + { + get { return repeatedAllTypes_.Count; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetRepeatedAllTypes(int index) + { + return repeatedAllTypes_[index]; } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable; } + public const int OptionalGroupFieldNumber = 10; + private bool hasOptionalGroup; + private global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup optionalGroup_; + public bool HasOptionalGroup + { + get { return hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup OptionalGroup + { + get { return optionalGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance; } } - public const int DynamicFieldFieldNumber = 2100; - private bool hasDynamicField; - private int dynamicField_; - public bool HasDynamicField { - get { return hasDynamicField; } + public const int RepeatedGroupFieldNumber = 20; + private pbc::PopsicleList repeatedGroup_ = new pbc::PopsicleList(); + public scg::IList RepeatedGroupList + { + get { return repeatedGroup_; } + } + public int RepeatedGroupCount + { + get { return repeatedGroup_.Count; } } - public int DynamicField { - get { return dynamicField_; } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup GetRepeatedGroup(int index) + { + return repeatedGroup_[index]; } - public override bool IsInitialized { - get { - return true; - } + public override bool IsInitialized + { + get + { + if (!hasRequiredAllTypes) return false; + if (!ExtensionsAreInitialized) return false; + return true; + } } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _dynamicMessageTypeFieldNames; - if (hasDynamicField) { - output.WriteInt32(2100, field_names[0], DynamicField); - } - UnknownFields.WriteTo(output); + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testParsingMergeFieldNames; + pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); + if (hasRequiredAllTypes) + { + output.WriteMessage(1, field_names[4], RequiredAllTypes); + } + if (hasOptionalAllTypes) + { + output.WriteMessage(2, field_names[0], OptionalAllTypes); + } + if (repeatedAllTypes_.Count > 0) + { + output.WriteMessageArray(3, field_names[2], repeatedAllTypes_); + } + if (hasOptionalGroup) + { + output.WriteGroup(10, field_names[1], OptionalGroup); + } + if (repeatedGroup_.Count > 0) + { + output.WriteGroupArray(20, field_names[3], repeatedGroup_); + } + extensionWriter.WriteUntil(536870912, output); + UnknownFields.WriteTo(output); } private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - size = 0; - if (hasDynamicField) { - size += pb::CodedOutputStream.ComputeInt32Size(2100, DynamicField); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; + size = 0; + if (hasRequiredAllTypes) + { + size += pb::CodedOutputStream.ComputeMessageSize(1, RequiredAllTypes); + } + if (hasOptionalAllTypes) + { + size += pb::CodedOutputStream.ComputeMessageSize(2, OptionalAllTypes); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in RepeatedAllTypesList) + { + size += pb::CodedOutputStream.ComputeMessageSize(3, element); + } + if (hasOptionalGroup) + { + size += pb::CodedOutputStream.ComputeGroupSize(10, OptionalGroup); + } + foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup element in RepeatedGroupList) + { + size += pb::CodedOutputStream.ComputeGroupSize(20, element); + } + size += ExtensionsSerializedSize; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; } - public static DynamicMessageType ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public static TestParsingMerge ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static DynamicMessageType ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public static TestParsingMerge ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public static DynamicMessageType ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public static TestParsingMerge ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static DynamicMessageType ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public static TestParsingMerge ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public static DynamicMessageType ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public static TestParsingMerge ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static DynamicMessageType ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public static TestParsingMerge ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - public static DynamicMessageType ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + public static TestParsingMerge ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); } - public static DynamicMessageType ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + public static TestParsingMerge ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); } - public static DynamicMessageType ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public static TestParsingMerge ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static DynamicMessageType ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public static TestParsingMerge ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - private DynamicMessageType MakeReadOnly() { - return this; + private TestParsingMerge MakeReadOnly() + { + repeatedAllTypes_.MakeReadOnly(); + repeatedGroup_.MakeReadOnly(); + return this; } public static Builder CreateBuilder() { return new Builder(); } public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(DynamicMessageType prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(DynamicMessageType cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private DynamicMessageType result; - - private DynamicMessageType PrepareBuilder() { - if (resultIsReadOnly) { - DynamicMessageType original = result; - result = new DynamicMessageType(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override DynamicMessageType MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Descriptor; } - } - - public override DynamicMessageType DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance; } - } - - public override DynamicMessageType BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is DynamicMessageType) { - return MergeFrom((DynamicMessageType) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(DynamicMessageType other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasDynamicField) { - DynamicField = other.DynamicField; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_dynamicMessageTypeFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _dynamicMessageTypeFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 16800: { - result.hasDynamicField = input.ReadInt32(ref result.dynamicField_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasDynamicField { - get { return result.hasDynamicField; } - } - public int DynamicField { - get { return result.DynamicField; } - set { SetDynamicField(value); } - } - public Builder SetDynamicField(int value) { - PrepareBuilder(); - result.hasDynamicField = true; - result.dynamicField_ = value; - return this; - } - public Builder ClearDynamicField() { - PrepareBuilder(); - result.hasDynamicField = false; - result.dynamicField_ = 0; - return this; - } - } - static DynamicMessageType() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - } - #endregion - - public const int ScalarExtensionFieldNumber = 2000; - private bool hasScalarExtension; - private uint scalarExtension_; - public bool HasScalarExtension { - get { return hasScalarExtension; } - } - [global::System.CLSCompliant(false)] - public uint ScalarExtension { - get { return scalarExtension_; } - } - - public const int EnumExtensionFieldNumber = 2001; - private bool hasEnumExtension; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnum enumExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - public bool HasEnumExtension { - get { return hasEnumExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumExtension { - get { return enumExtension_; } - } - - public const int DynamicEnumExtensionFieldNumber = 2002; - private bool hasDynamicEnumExtension; - private global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType dynamicEnumExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType.DYNAMIC_FOO; - public bool HasDynamicEnumExtension { - get { return hasDynamicEnumExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType DynamicEnumExtension { - get { return dynamicEnumExtension_; } - } - - public const int MessageExtensionFieldNumber = 2003; - private bool hasMessageExtension; - private global::Google.ProtocolBuffers.TestProtos.ForeignMessage messageExtension_; - public bool HasMessageExtension { - get { return hasMessageExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageExtension { - get { return messageExtension_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } - } - - public const int DynamicMessageExtensionFieldNumber = 2004; - private bool hasDynamicMessageExtension; - private global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType dynamicMessageExtension_; - public bool HasDynamicMessageExtension { - get { return hasDynamicMessageExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType DynamicMessageExtension { - get { return dynamicMessageExtension_ ?? global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance; } - } - - public const int RepeatedExtensionFieldNumber = 2005; - private pbc::PopsicleList repeatedExtension_ = new pbc::PopsicleList(); - public scg::IList RepeatedExtensionList { - get { return pbc::Lists.AsReadOnly(repeatedExtension_); } - } - public int RepeatedExtensionCount { - get { return repeatedExtension_.Count; } - } - public string GetRepeatedExtension(int index) { - return repeatedExtension_[index]; - } - - public const int PackedExtensionFieldNumber = 2006; - private int packedExtensionMemoizedSerializedSize; - private pbc::PopsicleList packedExtension_ = new pbc::PopsicleList(); - public scg::IList PackedExtensionList { - get { return pbc::Lists.AsReadOnly(packedExtension_); } - } - public int PackedExtensionCount { - get { return packedExtension_.Count; } - } - public int GetPackedExtension(int index) { - return packedExtension_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testDynamicExtensionsFieldNames; - if (hasScalarExtension) { - output.WriteFixed32(2000, field_names[6], ScalarExtension); - } - if (hasEnumExtension) { - output.WriteEnum(2001, field_names[2], (int) EnumExtension, EnumExtension); - } - if (hasDynamicEnumExtension) { - output.WriteEnum(2002, field_names[0], (int) DynamicEnumExtension, DynamicEnumExtension); - } - if (hasMessageExtension) { - output.WriteMessage(2003, field_names[3], MessageExtension); - } - if (hasDynamicMessageExtension) { - output.WriteMessage(2004, field_names[1], DynamicMessageExtension); - } - if (repeatedExtension_.Count > 0) { - output.WriteStringArray(2005, field_names[5], repeatedExtension_); - } - if (packedExtension_.Count > 0) { - output.WritePackedSInt32Array(2006, field_names[4], packedExtensionMemoizedSerializedSize, packedExtension_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasScalarExtension) { - size += pb::CodedOutputStream.ComputeFixed32Size(2000, ScalarExtension); - } - if (hasEnumExtension) { - size += pb::CodedOutputStream.ComputeEnumSize(2001, (int) EnumExtension); - } - if (hasDynamicEnumExtension) { - size += pb::CodedOutputStream.ComputeEnumSize(2002, (int) DynamicEnumExtension); - } - if (hasMessageExtension) { - size += pb::CodedOutputStream.ComputeMessageSize(2003, MessageExtension); - } - if (hasDynamicMessageExtension) { - size += pb::CodedOutputStream.ComputeMessageSize(2004, DynamicMessageExtension); - } - { - int dataSize = 0; - foreach (string element in RepeatedExtensionList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedExtension_.Count; - } - { - int dataSize = 0; - foreach (int element in PackedExtensionList) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - if (packedExtension_.Count != 0) { - size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize); - } - packedExtensionMemoizedSerializedSize = dataSize; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestDynamicExtensions ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestDynamicExtensions ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestDynamicExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestDynamicExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestDynamicExtensions MakeReadOnly() { - repeatedExtension_.MakeReadOnly(); - packedExtension_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestDynamicExtensions prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestDynamicExtensions cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestDynamicExtensions result; - - private TestDynamicExtensions PrepareBuilder() { - if (resultIsReadOnly) { - TestDynamicExtensions original = result; - result = new TestDynamicExtensions(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestDynamicExtensions MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Descriptor; } - } - - public override TestDynamicExtensions DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.DefaultInstance; } - } - - public override TestDynamicExtensions BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestDynamicExtensions) { - return MergeFrom((TestDynamicExtensions) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestDynamicExtensions other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasScalarExtension) { - ScalarExtension = other.ScalarExtension; - } - if (other.HasEnumExtension) { - EnumExtension = other.EnumExtension; - } - if (other.HasDynamicEnumExtension) { - DynamicEnumExtension = other.DynamicEnumExtension; - } - if (other.HasMessageExtension) { - MergeMessageExtension(other.MessageExtension); - } - if (other.HasDynamicMessageExtension) { - MergeDynamicMessageExtension(other.DynamicMessageExtension); - } - if (other.repeatedExtension_.Count != 0) { - result.repeatedExtension_.Add(other.repeatedExtension_); - } - if (other.packedExtension_.Count != 0) { - result.packedExtension_.Add(other.packedExtension_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testDynamicExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testDynamicExtensionsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 16005: { - result.hasScalarExtension = input.ReadFixed32(ref result.scalarExtension_); - break; - } - case 16008: { - object unknown; - if(input.ReadEnum(ref result.enumExtension_, out unknown)) { - result.hasEnumExtension = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(2001, (ulong)(int)unknown); - } - break; - } - case 16016: { - object unknown; - if(input.ReadEnum(ref result.dynamicEnumExtension_, out unknown)) { - result.hasDynamicEnumExtension = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(2002, (ulong)(int)unknown); - } - break; - } - case 16026: { - global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); - if (result.hasMessageExtension) { - subBuilder.MergeFrom(MessageExtension); - } - input.ReadMessage(subBuilder, extensionRegistry); - MessageExtension = subBuilder.BuildPartial(); - break; - } - case 16034: { - global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.CreateBuilder(); - if (result.hasDynamicMessageExtension) { - subBuilder.MergeFrom(DynamicMessageExtension); - } - input.ReadMessage(subBuilder, extensionRegistry); - DynamicMessageExtension = subBuilder.BuildPartial(); - break; - } - case 16042: { - input.ReadStringArray(tag, field_name, result.repeatedExtension_); - break; - } - case 16050: - case 16048: { - input.ReadSInt32Array(tag, field_name, result.packedExtension_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasScalarExtension { - get { return result.hasScalarExtension; } - } - [global::System.CLSCompliant(false)] - public uint ScalarExtension { - get { return result.ScalarExtension; } - set { SetScalarExtension(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetScalarExtension(uint value) { - PrepareBuilder(); - result.hasScalarExtension = true; - result.scalarExtension_ = value; - return this; - } - public Builder ClearScalarExtension() { - PrepareBuilder(); - result.hasScalarExtension = false; - result.scalarExtension_ = 0; - return this; - } - - public bool HasEnumExtension { - get { return result.hasEnumExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumExtension { - get { return result.EnumExtension; } - set { SetEnumExtension(value); } - } - public Builder SetEnumExtension(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.hasEnumExtension = true; - result.enumExtension_ = value; - return this; - } - public Builder ClearEnumExtension() { - PrepareBuilder(); - result.hasEnumExtension = false; - result.enumExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - return this; - } - - public bool HasDynamicEnumExtension { - get { return result.hasDynamicEnumExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType DynamicEnumExtension { - get { return result.DynamicEnumExtension; } - set { SetDynamicEnumExtension(value); } - } - public Builder SetDynamicEnumExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType value) { - PrepareBuilder(); - result.hasDynamicEnumExtension = true; - result.dynamicEnumExtension_ = value; - return this; - } - public Builder ClearDynamicEnumExtension() { - PrepareBuilder(); - result.hasDynamicEnumExtension = false; - result.dynamicEnumExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType.DYNAMIC_FOO; - return this; - } - - public bool HasMessageExtension { - get { return result.hasMessageExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageExtension { - get { return result.MessageExtension; } - set { SetMessageExtension(value); } - } - public Builder SetMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasMessageExtension = true; - result.messageExtension_ = value; - return this; - } - public Builder SetMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasMessageExtension = true; - result.messageExtension_ = builderForValue.Build(); - return this; - } - public Builder MergeMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasMessageExtension && - result.messageExtension_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) { - result.messageExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.messageExtension_).MergeFrom(value).BuildPartial(); - } else { - result.messageExtension_ = value; - } - result.hasMessageExtension = true; - return this; - } - public Builder ClearMessageExtension() { - PrepareBuilder(); - result.hasMessageExtension = false; - result.messageExtension_ = null; - return this; - } - - public bool HasDynamicMessageExtension { - get { return result.hasDynamicMessageExtension; } - } - public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType DynamicMessageExtension { - get { return result.DynamicMessageExtension; } - set { SetDynamicMessageExtension(value); } - } - public Builder SetDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasDynamicMessageExtension = true; - result.dynamicMessageExtension_ = value; - return this; - } - public Builder SetDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasDynamicMessageExtension = true; - result.dynamicMessageExtension_ = builderForValue.Build(); - return this; - } - public Builder MergeDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasDynamicMessageExtension && - result.dynamicMessageExtension_ != global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance) { - result.dynamicMessageExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.CreateBuilder(result.dynamicMessageExtension_).MergeFrom(value).BuildPartial(); - } else { - result.dynamicMessageExtension_ = value; - } - result.hasDynamicMessageExtension = true; - return this; - } - public Builder ClearDynamicMessageExtension() { - PrepareBuilder(); - result.hasDynamicMessageExtension = false; - result.dynamicMessageExtension_ = null; - return this; - } - - public pbc::IPopsicleList RepeatedExtensionList { - get { return PrepareBuilder().repeatedExtension_; } - } - public int RepeatedExtensionCount { - get { return result.RepeatedExtensionCount; } - } - public string GetRepeatedExtension(int index) { - return result.GetRepeatedExtension(index); - } - public Builder SetRepeatedExtension(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedExtension_[index] = value; - return this; - } - public Builder AddRepeatedExtension(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedExtension_.Add(value); - return this; - } - public Builder AddRangeRepeatedExtension(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedExtension_.Add(values); - return this; - } - public Builder ClearRepeatedExtension() { - PrepareBuilder(); - result.repeatedExtension_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedExtensionList { - get { return PrepareBuilder().packedExtension_; } - } - public int PackedExtensionCount { - get { return result.PackedExtensionCount; } - } - public int GetPackedExtension(int index) { - return result.GetPackedExtension(index); - } - public Builder SetPackedExtension(int index, int value) { - PrepareBuilder(); - result.packedExtension_[index] = value; - return this; - } - public Builder AddPackedExtension(int value) { - PrepareBuilder(); - result.packedExtension_.Add(value); - return this; - } - public Builder AddRangePackedExtension(scg::IEnumerable values) { - PrepareBuilder(); - result.packedExtension_.Add(values); - return this; - } - public Builder ClearPackedExtension() { - PrepareBuilder(); - result.packedExtension_.Clear(); - return this; - } - } - static TestDynamicExtensions() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestRepeatedScalarDifferentTagSizes : pb::GeneratedMessage { - private TestRepeatedScalarDifferentTagSizes() { } - private static readonly TestRepeatedScalarDifferentTagSizes defaultInstance = new TestRepeatedScalarDifferentTagSizes().MakeReadOnly(); - private static readonly string[] _testRepeatedScalarDifferentTagSizesFieldNames = new string[] { "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_int32", "repeated_int64", "repeated_uint64" }; - private static readonly uint[] _testRepeatedScalarDifferentTagSizesFieldTags = new uint[] { 101, 16369, 2097141, 104, 16376, 2097144 }; - public static TestRepeatedScalarDifferentTagSizes DefaultInstance { - get { return defaultInstance; } - } - - public override TestRepeatedScalarDifferentTagSizes DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestRepeatedScalarDifferentTagSizes ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable; } - } - - public const int RepeatedFixed32FieldNumber = 12; - private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed32List { - get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } - } - public int RepeatedFixed32Count { - get { return repeatedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return repeatedFixed32_[index]; - } - - public const int RepeatedInt32FieldNumber = 13; - private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt32List { - get { return pbc::Lists.AsReadOnly(repeatedInt32_); } - } - public int RepeatedInt32Count { - get { return repeatedInt32_.Count; } - } - public int GetRepeatedInt32(int index) { - return repeatedInt32_[index]; - } - - public const int RepeatedFixed64FieldNumber = 2046; - private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed64List { - get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } - } - public int RepeatedFixed64Count { - get { return repeatedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return repeatedFixed64_[index]; - } - - public const int RepeatedInt64FieldNumber = 2047; - private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt64List { - get { return pbc::Lists.AsReadOnly(repeatedInt64_); } - } - public int RepeatedInt64Count { - get { return repeatedInt64_.Count; } - } - public long GetRepeatedInt64(int index) { - return repeatedInt64_[index]; - } - - public const int RepeatedFloatFieldNumber = 262142; - private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); - public scg::IList RepeatedFloatList { - get { return pbc::Lists.AsReadOnly(repeatedFloat_); } - } - public int RepeatedFloatCount { - get { return repeatedFloat_.Count; } - } - public float GetRepeatedFloat(int index) { - return repeatedFloat_[index]; - } - - public const int RepeatedUint64FieldNumber = 262143; - private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedUint64List { - get { return pbc::Lists.AsReadOnly(repeatedUint64_); } - } - public int RepeatedUint64Count { - get { return repeatedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return repeatedUint64_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testRepeatedScalarDifferentTagSizesFieldNames; - if (repeatedFixed32_.Count > 0) { - output.WriteFixed32Array(12, field_names[0], repeatedFixed32_); - } - if (repeatedInt32_.Count > 0) { - output.WriteInt32Array(13, field_names[3], repeatedInt32_); - } - if (repeatedFixed64_.Count > 0) { - output.WriteFixed64Array(2046, field_names[1], repeatedFixed64_); - } - if (repeatedInt64_.Count > 0) { - output.WriteInt64Array(2047, field_names[4], repeatedInt64_); - } - if (repeatedFloat_.Count > 0) { - output.WriteFloatArray(262142, field_names[2], repeatedFloat_); - } - if (repeatedUint64_.Count > 0) { - output.WriteUInt64Array(262143, field_names[5], repeatedUint64_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - dataSize = 4 * repeatedFixed32_.Count; - size += dataSize; - size += 1 * repeatedFixed32_.Count; - } - { - int dataSize = 0; - foreach (int element in RepeatedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 1 * repeatedInt32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedFixed64_.Count; - size += dataSize; - size += 2 * repeatedFixed64_.Count; - } - { - int dataSize = 0; - foreach (long element in RepeatedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedInt64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedFloat_.Count; - size += dataSize; - size += 3 * repeatedFloat_.Count; - } - { - int dataSize = 0; - foreach (ulong element in RepeatedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - size += 3 * repeatedUint64_.Count; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestRepeatedScalarDifferentTagSizes MakeReadOnly() { - repeatedFixed32_.MakeReadOnly(); - repeatedInt32_.MakeReadOnly(); - repeatedFixed64_.MakeReadOnly(); - repeatedInt64_.MakeReadOnly(); - repeatedFloat_.MakeReadOnly(); - repeatedUint64_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestRepeatedScalarDifferentTagSizes prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestRepeatedScalarDifferentTagSizes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestRepeatedScalarDifferentTagSizes result; - - private TestRepeatedScalarDifferentTagSizes PrepareBuilder() { - if (resultIsReadOnly) { - TestRepeatedScalarDifferentTagSizes original = result; - result = new TestRepeatedScalarDifferentTagSizes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestRepeatedScalarDifferentTagSizes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.Descriptor; } - } - - public override TestRepeatedScalarDifferentTagSizes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.DefaultInstance; } - } - - public override TestRepeatedScalarDifferentTagSizes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestRepeatedScalarDifferentTagSizes) { - return MergeFrom((TestRepeatedScalarDifferentTagSizes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestRepeatedScalarDifferentTagSizes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.DefaultInstance) return this; - PrepareBuilder(); - if (other.repeatedFixed32_.Count != 0) { - result.repeatedFixed32_.Add(other.repeatedFixed32_); - } - if (other.repeatedInt32_.Count != 0) { - result.repeatedInt32_.Add(other.repeatedInt32_); - } - if (other.repeatedFixed64_.Count != 0) { - result.repeatedFixed64_.Add(other.repeatedFixed64_); - } - if (other.repeatedInt64_.Count != 0) { - result.repeatedInt64_.Add(other.repeatedInt64_); - } - if (other.repeatedFloat_.Count != 0) { - result.repeatedFloat_.Add(other.repeatedFloat_); - } - if (other.repeatedUint64_.Count != 0) { - result.repeatedUint64_.Add(other.repeatedUint64_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testRepeatedScalarDifferentTagSizesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testRepeatedScalarDifferentTagSizesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 98: - case 101: { - input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); - break; - } - case 106: - case 104: { - input.ReadInt32Array(tag, field_name, result.repeatedInt32_); - break; - } - case 16370: - case 16369: { - input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); - break; - } - case 16378: - case 16376: { - input.ReadInt64Array(tag, field_name, result.repeatedInt64_); - break; - } - case 2097138: - case 2097141: { - input.ReadFloatArray(tag, field_name, result.repeatedFloat_); - break; - } - case 2097146: - case 2097144: { - input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed32List { - get { return PrepareBuilder().repeatedFixed32_; } - } - public int RepeatedFixed32Count { - get { return result.RepeatedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return result.GetRepeatedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed32(int index, uint value) { - PrepareBuilder(); - result.repeatedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed32(uint value) { - PrepareBuilder(); - result.repeatedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed32_.Add(values); - return this; - } - public Builder ClearRepeatedFixed32() { - PrepareBuilder(); - result.repeatedFixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedInt32List { - get { return PrepareBuilder().repeatedInt32_; } - } - public int RepeatedInt32Count { - get { return result.RepeatedInt32Count; } - } - public int GetRepeatedInt32(int index) { - return result.GetRepeatedInt32(index); - } - public Builder SetRepeatedInt32(int index, int value) { - PrepareBuilder(); - result.repeatedInt32_[index] = value; - return this; - } - public Builder AddRepeatedInt32(int value) { - PrepareBuilder(); - result.repeatedInt32_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt32_.Add(values); - return this; - } - public Builder ClearRepeatedInt32() { - PrepareBuilder(); - result.repeatedInt32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed64List { - get { return PrepareBuilder().repeatedFixed64_; } - } - public int RepeatedFixed64Count { - get { return result.RepeatedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return result.GetRepeatedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed64(int index, ulong value) { - PrepareBuilder(); - result.repeatedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed64(ulong value) { - PrepareBuilder(); - result.repeatedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed64_.Add(values); - return this; - } - public Builder ClearRepeatedFixed64() { - PrepareBuilder(); - result.repeatedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedInt64List { - get { return PrepareBuilder().repeatedInt64_; } - } - public int RepeatedInt64Count { - get { return result.RepeatedInt64Count; } - } - public long GetRepeatedInt64(int index) { - return result.GetRepeatedInt64(index); - } - public Builder SetRepeatedInt64(int index, long value) { - PrepareBuilder(); - result.repeatedInt64_[index] = value; - return this; - } - public Builder AddRepeatedInt64(long value) { - PrepareBuilder(); - result.repeatedInt64_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt64_.Add(values); - return this; - } - public Builder ClearRepeatedInt64() { - PrepareBuilder(); - result.repeatedInt64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedFloatList { - get { return PrepareBuilder().repeatedFloat_; } - } - public int RepeatedFloatCount { - get { return result.RepeatedFloatCount; } - } - public float GetRepeatedFloat(int index) { - return result.GetRepeatedFloat(index); - } - public Builder SetRepeatedFloat(int index, float value) { - PrepareBuilder(); - result.repeatedFloat_[index] = value; - return this; - } - public Builder AddRepeatedFloat(float value) { - PrepareBuilder(); - result.repeatedFloat_.Add(value); - return this; - } - public Builder AddRangeRepeatedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFloat_.Add(values); - return this; - } - public Builder ClearRepeatedFloat() { - PrepareBuilder(); - result.repeatedFloat_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedUint64List { - get { return PrepareBuilder().repeatedUint64_; } - } - public int RepeatedUint64Count { - get { return result.RepeatedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return result.GetRepeatedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedUint64(int index, ulong value) { - PrepareBuilder(); - result.repeatedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedUint64(ulong value) { - PrepareBuilder(); - result.repeatedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedUint64_.Add(values); - return this; - } - public Builder ClearRepeatedUint64() { - PrepareBuilder(); - result.repeatedUint64_.Clear(); - return this; - } - } - static TestRepeatedScalarDifferentTagSizes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestParsingMerge : pb::ExtendableMessage { - private TestParsingMerge() { } - private static readonly TestParsingMerge defaultInstance = new TestParsingMerge().MakeReadOnly(); - private static readonly string[] _testParsingMergeFieldNames = new string[] { "optional_all_types", "optionalgroup", "repeated_all_types", "repeatedgroup", "required_all_types" }; - private static readonly uint[] _testParsingMergeFieldTags = new uint[] { 18, 83, 26, 163, 10 }; - public static TestParsingMerge DefaultInstance { - get { return defaultInstance; } - } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestParsingMerge prototype) + { + return new Builder(prototype); + } - public override TestParsingMerge DefaultInstanceForType { - get { return DefaultInstance; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::ExtendableBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(TestParsingMerge cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - protected override TestParsingMerge ThisMessage { - get { return this; } - } + private bool resultIsReadOnly; + private TestParsingMerge result; - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge__Descriptor; } - } + private TestParsingMerge PrepareBuilder() + { + if (resultIsReadOnly) + { + TestParsingMerge original = result; + result = new TestParsingMerge(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge__FieldAccessorTable; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public const int OptionalExtFieldNumber = 1000; - public static pb::GeneratedExtensionBase OptionalExt; - public const int RepeatedExtFieldNumber = 1001; - public static pb::GeneratedExtensionBase> RepeatedExt; - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class RepeatedFieldsGenerator : pb::GeneratedMessage { - private RepeatedFieldsGenerator() { } - private static readonly RepeatedFieldsGenerator defaultInstance = new RepeatedFieldsGenerator().MakeReadOnly(); - private static readonly string[] _repeatedFieldsGeneratorFieldNames = new string[] { "ext1", "ext2", "field1", "field2", "field3", "group1", "group2" }; - private static readonly uint[] _repeatedFieldsGeneratorFieldTags = new uint[] { 8002, 8010, 10, 18, 26, 83, 163 }; - public static RepeatedFieldsGenerator DefaultInstance { - get { return defaultInstance; } - } + protected override TestParsingMerge MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public override RepeatedFieldsGenerator DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - protected override RepeatedFieldsGenerator ThisMessage { - get { return this; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__Descriptor; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Descriptor; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator__FieldAccessorTable; } - } + public override TestParsingMerge DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.DefaultInstance; } + } - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Group1 : pb::GeneratedMessage { - private Group1() { } - private static readonly Group1 defaultInstance = new Group1().MakeReadOnly(); - private static readonly string[] _group1FieldNames = new string[] { "field1" }; - private static readonly uint[] _group1FieldTags = new uint[] { 90 }; - public static Group1 DefaultInstance { - get { return defaultInstance; } + public override TestParsingMerge BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); } - public override Group1 DefaultInstanceForType { - get { return DefaultInstance; } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestParsingMerge) + { + return MergeFrom((TestParsingMerge)other); + } + else + { + base.MergeFrom(other); + return this; + } } - protected override Group1 ThisMessage { - get { return this; } + public override Builder MergeFrom(TestParsingMerge other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.DefaultInstance) return this; + PrepareBuilder(); + if (other.HasRequiredAllTypes) + { + MergeRequiredAllTypes(other.RequiredAllTypes); + } + if (other.HasOptionalAllTypes) + { + MergeOptionalAllTypes(other.OptionalAllTypes); + } + if (other.repeatedAllTypes_.Count != 0) + { + result.repeatedAllTypes_.Add(other.repeatedAllTypes_); + } + if (other.HasOptionalGroup) + { + MergeOptionalGroup(other.OptionalGroup); + } + if (other.repeatedGroup_.Count != 0) + { + result.repeatedGroup_.Add(other.repeatedGroup_); + } + this.MergeExtensionFields(other); + this.MergeUnknownFields(other.UnknownFields); + return this; } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__Descriptor; } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group1__FieldAccessorTable; } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testParsingMergeFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testParsingMergeFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasRequiredAllTypes) + { + subBuilder.MergeFrom(RequiredAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + RequiredAllTypes = subBuilder.BuildPartial(); + break; + } + case 18: + { + global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); + if (result.hasOptionalAllTypes) + { + subBuilder.MergeFrom(OptionalAllTypes); + } + input.ReadMessage(subBuilder, extensionRegistry); + OptionalAllTypes = subBuilder.BuildPartial(); + break; + } + case 26: + { + input.ReadMessageArray(tag, field_name, result.repeatedAllTypes_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); + break; + } + case 83: + { + global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.CreateBuilder(); + if (result.hasOptionalGroup) + { + subBuilder.MergeFrom(OptionalGroup); + } + input.ReadGroup(10, subBuilder, extensionRegistry); + OptionalGroup = subBuilder.BuildPartial(); + break; + } + case 163: + { + input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.DefaultInstance, extensionRegistry); + break; + } + } + } + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; } - public const int Field1FieldNumber = 11; - private bool hasField1; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes field1_; - public bool HasField1 { - get { return hasField1; } + + public bool HasRequiredAllTypes + { + get { return result.hasRequiredAllTypes; } } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 { - get { return field1_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RequiredAllTypes + { + get { return result.RequiredAllTypes; } + set { SetRequiredAllTypes(value); } } - - public override bool IsInitialized { - get { - return true; - } + public Builder SetRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasRequiredAllTypes = true; + result.requiredAllTypes_ = value; + return this; + } + public Builder SetRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasRequiredAllTypes = true; + result.requiredAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasRequiredAllTypes && + result.requiredAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.requiredAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.requiredAllTypes_).MergeFrom(value).BuildPartial(); + } + else + { + result.requiredAllTypes_ = value; + } + result.hasRequiredAllTypes = true; + return this; + } + public Builder ClearRequiredAllTypes() + { + PrepareBuilder(); + result.hasRequiredAllTypes = false; + result.requiredAllTypes_ = null; + return this; } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _group1FieldNames; - if (hasField1) { - output.WriteMessage(11, field_names[0], Field1); - } - UnknownFields.WriteTo(output); + public bool HasOptionalAllTypes + { + get { return result.hasOptionalAllTypes; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalAllTypes + { + get { return result.OptionalAllTypes; } + set { SetOptionalAllTypes(value); } + } + public Builder SetOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalAllTypes = true; + result.optionalAllTypes_ = value; + return this; + } + public Builder SetOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalAllTypes = true; + result.optionalAllTypes_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalAllTypes && + result.optionalAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) + { + result.optionalAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.optionalAllTypes_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalAllTypes_ = value; + } + result.hasOptionalAllTypes = true; + return this; + } + public Builder ClearOptionalAllTypes() + { + PrepareBuilder(); + result.hasOptionalAllTypes = false; + result.optionalAllTypes_ = null; + return this; } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } + public pbc::IPopsicleList RepeatedAllTypesList + { + get { return PrepareBuilder().repeatedAllTypes_; } + } + public int RepeatedAllTypesCount + { + get { return result.RepeatedAllTypesCount; } + } + public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetRepeatedAllTypes(int index) + { + return result.GetRepeatedAllTypes(index); + } + public Builder SetRepeatedAllTypes(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedAllTypes_[index] = value; + return this; + } + public Builder SetRepeatedAllTypes(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedAllTypes_[index] = builderForValue.Build(); + return this; + } + public Builder AddRepeatedAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedAllTypes_.Add(value); + return this; + } + public Builder AddRepeatedAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedAllTypes_.Add(builderForValue.Build()); + return this; + } + public Builder AddRangeRepeatedAllTypes(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedAllTypes_.Add(values); + return this; + } + public Builder ClearRepeatedAllTypes() + { + PrepareBuilder(); + result.repeatedAllTypes_.Clear(); + return this; } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public bool HasOptionalGroup + { + get { return result.hasOptionalGroup; } + } + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup OptionalGroup + { + get { return result.OptionalGroup; } + set { SetOptionalGroup(value); } + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = value; + return this; + } + public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.hasOptionalGroup = true; + result.optionalGroup_ = builderForValue.Build(); + return this; + } + public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + if (result.hasOptionalGroup && + result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance) + { + result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial(); + } + else + { + result.optionalGroup_ = value; + } + result.hasOptionalGroup = true; + return this; + } + public Builder ClearOptionalGroup() + { + PrepareBuilder(); + result.hasOptionalGroup = false; + result.optionalGroup_ = null; + return this; + } - size = 0; - if (hasField1) { - size += pb::CodedOutputStream.ComputeMessageSize(11, Field1); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; + public pbc::IPopsicleList RepeatedGroupList + { + get { return PrepareBuilder().repeatedGroup_; } } - public static Group1 ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public int RepeatedGroupCount + { + get { return result.RepeatedGroupCount; } } - public static Group1 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup GetRepeatedGroup(int index) + { + return result.GetRepeatedGroup(index); } - public static Group1 ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_[index] = value; + return this; } - public static Group1 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_[index] = builderForValue.Build(); + return this; } - public static Group1 ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup value) + { + pb::ThrowHelper.ThrowIfNull(value, "value"); + PrepareBuilder(); + result.repeatedGroup_.Add(value); + return this; } - public static Group1 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.Builder builderForValue) + { + pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); + PrepareBuilder(); + result.repeatedGroup_.Add(builderForValue.Build()); + return this; } - public static Group1 ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + public Builder AddRangeRepeatedGroup(scg::IEnumerable values) + { + PrepareBuilder(); + result.repeatedGroup_.Add(values); + return this; } - public static Group1 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + public Builder ClearRepeatedGroup() + { + PrepareBuilder(); + result.repeatedGroup_.Clear(); + return this; } - public static Group1 ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + } + static TestParsingMerge() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class TestCommentInjectionMessage : pb::GeneratedMessage + { + private TestCommentInjectionMessage() { } + private static readonly TestCommentInjectionMessage defaultInstance = new TestCommentInjectionMessage().MakeReadOnly(); + private static readonly string[] _testCommentInjectionMessageFieldNames = new string[] { "a" }; + private static readonly uint[] _testCommentInjectionMessageFieldTags = new uint[] { 10 }; + public static TestCommentInjectionMessage DefaultInstance + { + get { return defaultInstance; } + } + + public override TestCommentInjectionMessage DefaultInstanceForType + { + get { return DefaultInstance; } + } + + protected override TestCommentInjectionMessage ThisMessage + { + get { return this; } + } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor; } + } + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCommentInjectionMessage__FieldAccessorTable; } + } + + public const int AFieldNumber = 1; + private bool hasA; + private string a_ = "*/ <- Neither should this."; + public bool HasA + { + get { return hasA; } + } + public string A + { + get { return a_; } + } + + public override bool IsInitialized + { + get + { + return true; } - public static Group1 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _testCommentInjectionMessageFieldNames; + if (hasA) + { + output.WriteString(1, field_names[0], A); } - private Group1 MakeReadOnly() { - return this; + UnknownFields.WriteTo(output); + } + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); } + } + + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Group1 prototype) { - return new Builder(prototype); + size = 0; + if (hasA) + { + size += pb::CodedOutputStream.ComputeStringSize(1, A); } + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static TestCommentInjectionMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static TestCommentInjectionMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static TestCommentInjectionMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private TestCommentInjectionMessage MakeReadOnly() + { + return this; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(TestCommentInjectionMessage prototype) + { + return new Builder(prototype); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { get { return this; } - } - public Builder() { + } + public Builder() + { result = DefaultInstance; resultIsReadOnly = true; - } - internal Builder(Group1 cloneFrom) { + } + internal Builder(TestCommentInjectionMessage cloneFrom) + { result = cloneFrom; resultIsReadOnly = true; - } + } - private bool resultIsReadOnly; - private Group1 result; + private bool resultIsReadOnly; + private TestCommentInjectionMessage result; - private Group1 PrepareBuilder() { - if (resultIsReadOnly) { - Group1 original = result; - result = new Group1(); - resultIsReadOnly = false; - MergeFrom(original); + private TestCommentInjectionMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + TestCommentInjectionMessage original = result; + result = new TestCommentInjectionMessage(); + resultIsReadOnly = false; + MergeFrom(original); } return result; - } + } - public override bool IsInitialized { + public override bool IsInitialized + { get { return result.IsInitialized; } - } + } - protected override Group1 MessageBeingBuilt { + protected override TestCommentInjectionMessage MessageBeingBuilt + { get { return PrepareBuilder(); } - } + } - public override Builder Clear() { + public override Builder Clear() + { result = DefaultInstance; resultIsReadOnly = true; return this; - } + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); } - } + } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.Descriptor; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestCommentInjectionMessage.Descriptor; } + } - public override Group1 DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance; } - } + public override TestCommentInjectionMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.TestCommentInjectionMessage.DefaultInstance; } + } - public override Group1 BuildPartial() { - if (resultIsReadOnly) { - return result; + public override TestCommentInjectionMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; } resultIsReadOnly = true; return result.MakeReadOnly(); - } + } - public override Builder MergeFrom(pb::IMessage other) { - if (other is Group1) { - return MergeFrom((Group1) other); - } else { - base.MergeFrom(other); - return this; + public override Builder MergeFrom(pb::IMessage other) + { + if (other is TestCommentInjectionMessage) + { + return MergeFrom((TestCommentInjectionMessage)other); + } + else + { + base.MergeFrom(other); + return this; } - } + } - public override Builder MergeFrom(Group1 other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance) return this; + public override Builder MergeFrom(TestCommentInjectionMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.TestCommentInjectionMessage.DefaultInstance) return this; PrepareBuilder(); - if (other.HasField1) { - MergeField1(other.Field1); + if (other.HasA) + { + A = other.A; } this.MergeUnknownFields(other.UnknownFields); return this; - } + } - public override Builder MergeFrom(pb::ICodedInputStream input) { + public override Builder MergeFrom(pb::ICodedInputStream input) + { return MergeFrom(input, pb::ExtensionRegistry.Empty); - } + } - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { PrepareBuilder(); pb::UnknownFieldSet.Builder unknownFields = null; uint tag; string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_group1FieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _group1FieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_testCommentInjectionMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _testCommentInjectionMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; } - case 90: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasField1) { - subBuilder.MergeFrom(Field1); - } - input.ReadMessage(subBuilder, extensionRegistry); - Field1 = subBuilder.BuildPartial(); - break; + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + case 10: + { + result.hasA = input.ReadString(ref result.a_); + break; + } } - } } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); } return this; - } + } - public bool HasField1 { - get { return result.hasField1; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 { - get { return result.Field1; } - set { SetField1(value); } - } - public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasField1 = true; - result.field1_ = value; - return this; - } - public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasField1 = true; - result.field1_ = builderForValue.Build(); - return this; - } - public Builder MergeField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { + public bool HasA + { + get { return result.hasA; } + } + public string A + { + get { return result.A; } + set { SetA(value); } + } + public Builder SetA(string value) + { pb::ThrowHelper.ThrowIfNull(value, "value"); PrepareBuilder(); - if (result.hasField1 && - result.field1_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.field1_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.field1_).MergeFrom(value).BuildPartial(); - } else { - result.field1_ = value; - } - result.hasField1 = true; + result.hasA = true; + result.a_ = value; return this; - } - public Builder ClearField1() { + } + public Builder ClearA() + { PrepareBuilder(); - result.hasField1 = false; - result.field1_ = null; + result.hasA = false; + result.a_ = "*/ <- Neither should this."; return this; - } - } - static Group1() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Group2 : pb::GeneratedMessage { - private Group2() { } - private static readonly Group2 defaultInstance = new Group2().MakeReadOnly(); - private static readonly string[] _group2FieldNames = new string[] { "field1" }; - private static readonly uint[] _group2FieldTags = new uint[] { 170 }; - public static Group2 DefaultInstance { - get { return defaultInstance; } } + } + static TestCommentInjectionMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } + } - public override Group2 DefaultInstanceForType { - get { return DefaultInstance; } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooRequest : pb::GeneratedMessage + { + private FooRequest() { } + private static readonly FooRequest defaultInstance = new FooRequest().MakeReadOnly(); + private static readonly string[] _fooRequestFieldNames = new string[] { }; + private static readonly uint[] _fooRequestFieldTags = new uint[] { }; + public static FooRequest DefaultInstance + { + get { return defaultInstance; } + } - protected override Group2 ThisMessage { - get { return this; } - } + public override FooRequest DefaultInstanceForType + { + get { return DefaultInstance; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__Descriptor; } - } + protected override FooRequest ThisMessage + { + get { return this; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedFieldsGenerator_Group2__FieldAccessorTable; } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooRequest__Descriptor; } + } - public const int Field1FieldNumber = 21; - private bool hasField1; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes field1_; - public bool HasField1 { - get { return hasField1; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 { - get { return field1_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooRequest__FieldAccessorTable; } + } - public override bool IsInitialized { - get { + public override bool IsInitialized + { + get + { return true; - } } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _group2FieldNames; - if (hasField1) { - output.WriteMessage(21, field_names[0], Field1); - } - UnknownFields.WriteTo(output); - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _fooRequestFieldNames; + UnknownFields.WriteTo(output); + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { int size = memoizedSerializedSize; if (size != -1) return size; return CalcSerializedSize(); - } } + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - size = 0; - if (hasField1) { - size += pb::CodedOutputStream.ComputeMessageSize(21, Field1); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static Group2 ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Group2 ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Group2 ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Group2 ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Group2 ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Group2 ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static Group2 ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static Group2 ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static Group2 ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Group2 ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private Group2 MakeReadOnly() { - return this; - } + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static FooRequest ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooRequest ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static FooRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static FooRequest ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static FooRequest ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static FooRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static FooRequest ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static FooRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private FooRequest MakeReadOnly() + { + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Group2 prototype) { - return new Builder(prototype); - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(FooRequest prototype) + { + return new Builder(prototype); + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { get { return this; } - } - public Builder() { + } + public Builder() + { result = DefaultInstance; resultIsReadOnly = true; - } - internal Builder(Group2 cloneFrom) { + } + internal Builder(FooRequest cloneFrom) + { result = cloneFrom; resultIsReadOnly = true; - } + } - private bool resultIsReadOnly; - private Group2 result; + private bool resultIsReadOnly; + private FooRequest result; - private Group2 PrepareBuilder() { - if (resultIsReadOnly) { - Group2 original = result; - result = new Group2(); - resultIsReadOnly = false; - MergeFrom(original); + private FooRequest PrepareBuilder() + { + if (resultIsReadOnly) + { + FooRequest original = result; + result = new FooRequest(); + resultIsReadOnly = false; + MergeFrom(original); } return result; - } + } - public override bool IsInitialized { + public override bool IsInitialized + { get { return result.IsInitialized; } - } + } - protected override Group2 MessageBeingBuilt { + protected override FooRequest MessageBeingBuilt + { get { return PrepareBuilder(); } - } + } - public override Builder Clear() { + public override Builder Clear() + { result = DefaultInstance; resultIsReadOnly = true; return this; - } + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); } - } + else + { + return new Builder().MergeFrom(result); + } + } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.Descriptor; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.FooRequest.Descriptor; } + } - public override Group2 DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance; } - } + public override FooRequest DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.FooRequest.DefaultInstance; } + } - public override Group2 BuildPartial() { - if (resultIsReadOnly) { - return result; + public override FooRequest BuildPartial() + { + if (resultIsReadOnly) + { + return result; } resultIsReadOnly = true; return result.MakeReadOnly(); - } + } - public override Builder MergeFrom(pb::IMessage other) { - if (other is Group2) { - return MergeFrom((Group2) other); - } else { - base.MergeFrom(other); - return this; + public override Builder MergeFrom(pb::IMessage other) + { + if (other is FooRequest) + { + return MergeFrom((FooRequest)other); + } + else + { + base.MergeFrom(other); + return this; } - } + } - public override Builder MergeFrom(Group2 other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance) return this; + public override Builder MergeFrom(FooRequest other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.FooRequest.DefaultInstance) return this; PrepareBuilder(); - if (other.HasField1) { - MergeField1(other.Field1); - } this.MergeUnknownFields(other.UnknownFields); return this; - } + } - public override Builder MergeFrom(pb::ICodedInputStream input) { + public override Builder MergeFrom(pb::ICodedInputStream input) + { return MergeFrom(input, pb::ExtensionRegistry.Empty); - } + } - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { PrepareBuilder(); pb::UnknownFieldSet.Builder unknownFields = null; uint tag; string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_group2FieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _group2FieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_fooRequestFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _fooRequestFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; } - case 170: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasField1) { - subBuilder.MergeFrom(Field1); - } - input.ReadMessage(subBuilder, extensionRegistry); - Field1 = subBuilder.BuildPartial(); - break; + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } } - } } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasField1 { - get { return result.hasField1; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes Field1 { - get { return result.Field1; } - set { SetField1(value); } - } - public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasField1 = true; - result.field1_ = value; - return this; - } - public Builder SetField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasField1 = true; - result.field1_ = builderForValue.Build(); - return this; - } - public Builder MergeField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasField1 && - result.field1_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.field1_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.field1_).MergeFrom(value).BuildPartial(); - } else { - result.field1_ = value; + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); } - result.hasField1 = true; return this; - } - public Builder ClearField1() { - PrepareBuilder(); - result.hasField1 = false; - result.field1_ = null; - return this; - } } - static Group2() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - } - #endregion - public const int Field1FieldNumber = 1; - private pbc::PopsicleList field1_ = new pbc::PopsicleList(); - public scg::IList Field1List { - get { return field1_; } } - public int Field1Count { - get { return field1_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField1(int index) { - return field1_[index]; + static FooRequest() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); } + } - public const int Field2FieldNumber = 2; - private pbc::PopsicleList field2_ = new pbc::PopsicleList(); - public scg::IList Field2List { - get { return field2_; } - } - public int Field2Count { - get { return field2_.Count; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooResponse : pb::GeneratedMessage + { + private FooResponse() { } + private static readonly FooResponse defaultInstance = new FooResponse().MakeReadOnly(); + private static readonly string[] _fooResponseFieldNames = new string[] { }; + private static readonly uint[] _fooResponseFieldTags = new uint[] { }; + public static FooResponse DefaultInstance + { + get { return defaultInstance; } } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField2(int index) { - return field2_[index]; + + public override FooResponse DefaultInstanceForType + { + get { return DefaultInstance; } } - public const int Field3FieldNumber = 3; - private pbc::PopsicleList field3_ = new pbc::PopsicleList(); - public scg::IList Field3List { - get { return field3_; } + protected override FooResponse ThisMessage + { + get { return this; } } - public int Field3Count { - get { return field3_.Count; } + + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooResponse__Descriptor; } } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField3(int index) { - return field3_[index]; + + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooResponse__FieldAccessorTable; } } - public const int Group1FieldNumber = 10; - private pbc::PopsicleList group1_ = new pbc::PopsicleList(); - public scg::IList Group1List { - get { return group1_; } + public override bool IsInitialized + { + get + { + return true; + } } - public int Group1Count { - get { return group1_.Count; } + + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _fooResponseFieldNames; + UnknownFields.WriteTo(output); } - public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 GetGroup1(int index) { - return group1_[index]; + + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } } - public const int Group2FieldNumber = 20; - private pbc::PopsicleList group2_ = new pbc::PopsicleList(); - public scg::IList Group2List { - get { return group2_; } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; } - public int Group2Count { - get { return group2_.Count; } + public static FooResponse ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 GetGroup2(int index) { - return group2_[index]; + public static FooResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - - public const int Ext1FieldNumber = 1000; - private pbc::PopsicleList ext1_ = new pbc::PopsicleList(); - public scg::IList Ext1List { - get { return ext1_; } + public static FooResponse ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public int Ext1Count { - get { return ext1_.Count; } + public static FooResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt1(int index) { - return ext1_[index]; + public static FooResponse ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - - public const int Ext2FieldNumber = 1001; - private pbc::PopsicleList ext2_ = new pbc::PopsicleList(); - public scg::IList Ext2List { - get { return ext2_; } + public static FooResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - public int Ext2Count { - get { return ext2_.Count; } + public static FooResponse ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt2(int index) { - return ext2_[index]; + public static FooResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); } - - public override bool IsInitialized { - get { - return true; - } + public static FooResponse ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _repeatedFieldsGeneratorFieldNames; - if (field1_.Count > 0) { - output.WriteMessageArray(1, field_names[2], field1_); - } - if (field2_.Count > 0) { - output.WriteMessageArray(2, field_names[3], field2_); - } - if (field3_.Count > 0) { - output.WriteMessageArray(3, field_names[4], field3_); - } - if (group1_.Count > 0) { - output.WriteGroupArray(10, field_names[5], group1_); - } - if (group2_.Count > 0) { - output.WriteGroupArray(20, field_names[6], group2_); - } - if (ext1_.Count > 0) { - output.WriteMessageArray(1000, field_names[0], ext1_); - } - if (ext2_.Count > 0) { - output.WriteMessageArray(1001, field_names[1], ext2_); - } - UnknownFields.WriteTo(output); + public static FooResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Field1List) { - size += pb::CodedOutputStream.ComputeMessageSize(1, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Field2List) { - size += pb::CodedOutputStream.ComputeMessageSize(2, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Field3List) { - size += pb::CodedOutputStream.ComputeMessageSize(3, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 element in Group1List) { - size += pb::CodedOutputStream.ComputeGroupSize(10, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 element in Group2List) { - size += pb::CodedOutputStream.ComputeGroupSize(20, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Ext1List) { - size += pb::CodedOutputStream.ComputeMessageSize(1000, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in Ext2List) { - size += pb::CodedOutputStream.ComputeMessageSize(1001, element); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static RepeatedFieldsGenerator ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedFieldsGenerator ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedFieldsGenerator ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static RepeatedFieldsGenerator ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static RepeatedFieldsGenerator ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedFieldsGenerator ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static RepeatedFieldsGenerator ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static RepeatedFieldsGenerator ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static RepeatedFieldsGenerator ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static RepeatedFieldsGenerator ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private RepeatedFieldsGenerator MakeReadOnly() { - field1_.MakeReadOnly(); - field2_.MakeReadOnly(); - field3_.MakeReadOnly(); - group1_.MakeReadOnly(); - group2_.MakeReadOnly(); - ext1_.MakeReadOnly(); - ext2_.MakeReadOnly(); - return this; + private FooResponse MakeReadOnly() + { + return this; } public static Builder CreateBuilder() { return new Builder(); } public override Builder ToBuilder() { return CreateBuilder(this); } public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(RepeatedFieldsGenerator prototype) { - return new Builder(prototype); + public static Builder CreateBuilder(FooResponse prototype) + { + return new Builder(prototype); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(RepeatedFieldsGenerator cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private RepeatedFieldsGenerator result; - - private RepeatedFieldsGenerator PrepareBuilder() { - if (resultIsReadOnly) { - RepeatedFieldsGenerator original = result; - result = new RepeatedFieldsGenerator(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override RepeatedFieldsGenerator MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooResponse cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; } - } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Descriptor; } - } + private bool resultIsReadOnly; + private FooResponse result; + + private FooResponse PrepareBuilder() + { + if (resultIsReadOnly) + { + FooResponse original = result; + result = new FooResponse(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public override RepeatedFieldsGenerator DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.DefaultInstance; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - public override RepeatedFieldsGenerator BuildPartial() { - if (resultIsReadOnly) { - return result; + protected override FooResponse MessageBeingBuilt + { + get { return PrepareBuilder(); } } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - public override Builder MergeFrom(pb::IMessage other) { - if (other is RepeatedFieldsGenerator) { - return MergeFrom((RepeatedFieldsGenerator) other); - } else { - base.MergeFrom(other); - return this; + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; } - } - public override Builder MergeFrom(RepeatedFieldsGenerator other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.DefaultInstance) return this; - PrepareBuilder(); - if (other.field1_.Count != 0) { - result.field1_.Add(other.field1_); + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } } - if (other.field2_.Count != 0) { - result.field2_.Add(other.field2_); + + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.FooResponse.Descriptor; } } - if (other.field3_.Count != 0) { - result.field3_.Add(other.field3_); + + public override FooResponse DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.FooResponse.DefaultInstance; } } - if (other.group1_.Count != 0) { - result.group1_.Add(other.group1_); + + public override FooResponse BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); } - if (other.group2_.Count != 0) { - result.group2_.Add(other.group2_); + + public override Builder MergeFrom(pb::IMessage other) + { + if (other is FooResponse) + { + return MergeFrom((FooResponse)other); + } + else + { + base.MergeFrom(other); + return this; + } } - if (other.ext1_.Count != 0) { - result.ext1_.Add(other.ext1_); + + public override Builder MergeFrom(FooResponse other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.FooResponse.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; } - if (other.ext2_.Count != 0) { - result.ext2_.Add(other.ext2_); + + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_repeatedFieldsGeneratorFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _repeatedFieldsGeneratorFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_fooResponseFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _fooResponseFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - input.ReadMessageArray(tag, field_name, result.field1_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); - break; - } - case 18: { - input.ReadMessageArray(tag, field_name, result.field2_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); - break; - } - case 26: { - input.ReadMessageArray(tag, field_name, result.field3_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); - break; - } - case 83: { - input.ReadGroupArray(tag, field_name, result.group1_, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.DefaultInstance, extensionRegistry); - break; - } - case 163: { - input.ReadGroupArray(tag, field_name, result.group2_, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.DefaultInstance, extensionRegistry); - break; - } - case 8002: { - input.ReadMessageArray(tag, field_name, result.ext1_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); - break; } - case 8010: { - input.ReadMessageArray(tag, field_name, result.ext2_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); - break; + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); } - } + return this; } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public pbc::IPopsicleList Field1List { - get { return PrepareBuilder().field1_; } - } - public int Field1Count { - get { return result.Field1Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField1(int index) { - return result.GetField1(index); - } - public Builder SetField1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.field1_[index] = value; - return this; - } - public Builder SetField1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.field1_[index] = builderForValue.Build(); - return this; - } - public Builder AddField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.field1_.Add(value); - return this; - } - public Builder AddField1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.field1_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeField1(scg::IEnumerable values) { - PrepareBuilder(); - result.field1_.Add(values); - return this; - } - public Builder ClearField1() { - PrepareBuilder(); - result.field1_.Clear(); - return this; - } - - public pbc::IPopsicleList Field2List { - get { return PrepareBuilder().field2_; } - } - public int Field2Count { - get { return result.Field2Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField2(int index) { - return result.GetField2(index); - } - public Builder SetField2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.field2_[index] = value; - return this; - } - public Builder SetField2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.field2_[index] = builderForValue.Build(); - return this; - } - public Builder AddField2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.field2_.Add(value); - return this; - } - public Builder AddField2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.field2_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeField2(scg::IEnumerable values) { - PrepareBuilder(); - result.field2_.Add(values); - return this; - } - public Builder ClearField2() { - PrepareBuilder(); - result.field2_.Clear(); - return this; - } - - public pbc::IPopsicleList Field3List { - get { return PrepareBuilder().field3_; } - } - public int Field3Count { - get { return result.Field3Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetField3(int index) { - return result.GetField3(index); - } - public Builder SetField3(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.field3_[index] = value; - return this; - } - public Builder SetField3(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.field3_[index] = builderForValue.Build(); - return this; - } - public Builder AddField3(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.field3_.Add(value); - return this; - } - public Builder AddField3(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.field3_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeField3(scg::IEnumerable values) { - PrepareBuilder(); - result.field3_.Add(values); - return this; - } - public Builder ClearField3() { - PrepareBuilder(); - result.field3_.Clear(); - return this; - } - - public pbc::IPopsicleList Group1List { - get { return PrepareBuilder().group1_; } - } - public int Group1Count { - get { return result.Group1Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 GetGroup1(int index) { - return result.GetGroup1(index); - } - public Builder SetGroup1(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.group1_[index] = value; - return this; - } - public Builder SetGroup1(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.group1_[index] = builderForValue.Build(); - return this; - } - public Builder AddGroup1(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1 value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.group1_.Add(value); - return this; - } - public Builder AddGroup1(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group1.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.group1_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeGroup1(scg::IEnumerable values) { - PrepareBuilder(); - result.group1_.Add(values); - return this; - } - public Builder ClearGroup1() { - PrepareBuilder(); - result.group1_.Clear(); - return this; - } - - public pbc::IPopsicleList Group2List { - get { return PrepareBuilder().group2_; } - } - public int Group2Count { - get { return result.Group2Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 GetGroup2(int index) { - return result.GetGroup2(index); - } - public Builder SetGroup2(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.group2_[index] = value; - return this; - } - public Builder SetGroup2(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.group2_[index] = builderForValue.Build(); - return this; - } - public Builder AddGroup2(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2 value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.group2_.Add(value); - return this; - } - public Builder AddGroup2(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedFieldsGenerator.Types.Group2.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.group2_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeGroup2(scg::IEnumerable values) { - PrepareBuilder(); - result.group2_.Add(values); - return this; - } - public Builder ClearGroup2() { - PrepareBuilder(); - result.group2_.Clear(); - return this; - } - - public pbc::IPopsicleList Ext1List { - get { return PrepareBuilder().ext1_; } - } - public int Ext1Count { - get { return result.Ext1Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt1(int index) { - return result.GetExt1(index); - } - public Builder SetExt1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.ext1_[index] = value; - return this; - } - public Builder SetExt1(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.ext1_[index] = builderForValue.Build(); - return this; - } - public Builder AddExt1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.ext1_.Add(value); - return this; - } - public Builder AddExt1(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.ext1_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeExt1(scg::IEnumerable values) { - PrepareBuilder(); - result.ext1_.Add(values); - return this; - } - public Builder ClearExt1() { - PrepareBuilder(); - result.ext1_.Clear(); - return this; - } - - public pbc::IPopsicleList Ext2List { - get { return PrepareBuilder().ext2_; } - } - public int Ext2Count { - get { return result.Ext2Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetExt2(int index) { - return result.GetExt2(index); - } - public Builder SetExt2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.ext2_[index] = value; - return this; - } - public Builder SetExt2(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.ext2_[index] = builderForValue.Build(); - return this; - } - public Builder AddExt2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.ext2_.Add(value); - return this; - } - public Builder AddExt2(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.ext2_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeExt2(scg::IEnumerable values) { - PrepareBuilder(); - result.ext2_.Add(values); - return this; - } - public Builder ClearExt2() { - PrepareBuilder(); - result.ext2_.Clear(); - return this; - } } - static RepeatedFieldsGenerator() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + static FooResponse() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); } - } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class OptionalGroup : pb::GeneratedMessage { - private OptionalGroup() { } - private static readonly OptionalGroup defaultInstance = new OptionalGroup().MakeReadOnly(); - private static readonly string[] _optionalGroupFieldNames = new string[] { "optional_group_all_types" }; - private static readonly uint[] _optionalGroupFieldTags = new uint[] { 90 }; - public static OptionalGroup DefaultInstance { - get { return defaultInstance; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooClientMessage : pb::GeneratedMessage + { + private FooClientMessage() { } + private static readonly FooClientMessage defaultInstance = new FooClientMessage().MakeReadOnly(); + private static readonly string[] _fooClientMessageFieldNames = new string[] { }; + private static readonly uint[] _fooClientMessageFieldTags = new uint[] { }; + public static FooClientMessage DefaultInstance + { + get { return defaultInstance; } } - public override OptionalGroup DefaultInstanceForType { - get { return DefaultInstance; } + public override FooClientMessage DefaultInstanceForType + { + get { return DefaultInstance; } } - protected override OptionalGroup ThisMessage { - get { return this; } + protected override FooClientMessage ThisMessage + { + get { return this; } } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__Descriptor; } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooClientMessage__Descriptor; } } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_OptionalGroup__FieldAccessorTable; } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooClientMessage__FieldAccessorTable; } } - public const int OptionalGroupAllTypesFieldNumber = 11; - private bool hasOptionalGroupAllTypes; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes optionalGroupAllTypes_; - public bool HasOptionalGroupAllTypes { - get { return hasOptionalGroupAllTypes; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalGroupAllTypes { - get { return optionalGroupAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + public override bool IsInitialized + { + get + { + return true; + } } - public override bool IsInitialized { - get { - return true; - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _fooClientMessageFieldNames; + UnknownFields.WriteTo(output); } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _optionalGroupFieldNames; - if (hasOptionalGroupAllTypes) { - output.WriteMessage(11, field_names[0], OptionalGroupAllTypes); - } - UnknownFields.WriteTo(output); + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { + private int CalcSerializedSize() + { int size = memoizedSerializedSize; if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - size = 0; - if (hasOptionalGroupAllTypes) { - size += pb::CodedOutputStream.ComputeMessageSize(11, OptionalGroupAllTypes); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; } - public static OptionalGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public static FooClientMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public static FooClientMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public static OptionalGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public static FooClientMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public static FooClientMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public static OptionalGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public static FooClientMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public static FooClientMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + public static FooClientMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); } - public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + public static FooClientMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); } - public static OptionalGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public static FooClientMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public static FooClientMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - private OptionalGroup MakeReadOnly() { - return this; + private FooClientMessage MakeReadOnly() + { + return this; } public static Builder CreateBuilder() { return new Builder(); } public override Builder ToBuilder() { return CreateBuilder(this); } public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(OptionalGroup prototype) { - return new Builder(prototype); + public static Builder CreateBuilder(FooClientMessage prototype) + { + return new Builder(prototype); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(OptionalGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private OptionalGroup result; - - private OptionalGroup PrepareBuilder() { - if (resultIsReadOnly) { - OptionalGroup original = result; - result = new OptionalGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override OptionalGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooClientMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } + + private bool resultIsReadOnly; + private FooClientMessage result; + + private FooClientMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + FooClientMessage original = result; + result = new FooClientMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } + + public override bool IsInitialized + { + get { return result.IsInitialized; } + } + + protected override FooClientMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } + } + + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.FooClientMessage.Descriptor; } } - } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.Descriptor; } - } + public override FooClientMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.FooClientMessage.DefaultInstance; } + } - public override OptionalGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance; } - } + public override FooClientMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public override OptionalGroup BuildPartial() { - if (resultIsReadOnly) { - return result; + public override Builder MergeFrom(pb::IMessage other) + { + if (other is FooClientMessage) + { + return MergeFrom((FooClientMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - public override Builder MergeFrom(pb::IMessage other) { - if (other is OptionalGroup) { - return MergeFrom((OptionalGroup) other); - } else { - base.MergeFrom(other); - return this; + public override Builder MergeFrom(FooClientMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.FooClientMessage.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; } - } - public override Builder MergeFrom(OptionalGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasOptionalGroupAllTypes) { - MergeOptionalGroupAllTypes(other.OptionalGroupAllTypes); + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _optionalGroupFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_fooClientMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _fooClientMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; } - case 90: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasOptionalGroupAllTypes) { - subBuilder.MergeFrom(OptionalGroupAllTypes); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalGroupAllTypes = subBuilder.BuildPartial(); - break; + + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); } - } + return this; } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasOptionalGroupAllTypes { - get { return result.hasOptionalGroupAllTypes; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalGroupAllTypes { - get { return result.OptionalGroupAllTypes; } - set { SetOptionalGroupAllTypes(value); } - } - public Builder SetOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalGroupAllTypes = true; - result.optionalGroupAllTypes_ = value; - return this; - } - public Builder SetOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalGroupAllTypes = true; - result.optionalGroupAllTypes_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalGroupAllTypes && - result.optionalGroupAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.optionalGroupAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.optionalGroupAllTypes_).MergeFrom(value).BuildPartial(); - } else { - result.optionalGroupAllTypes_ = value; - } - result.hasOptionalGroupAllTypes = true; - return this; - } - public Builder ClearOptionalGroupAllTypes() { - PrepareBuilder(); - result.hasOptionalGroupAllTypes = false; - result.optionalGroupAllTypes_ = null; - return this; - } } - static OptionalGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + static FooClientMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); } - } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class RepeatedGroup : pb::GeneratedMessage { - private RepeatedGroup() { } - private static readonly RepeatedGroup defaultInstance = new RepeatedGroup().MakeReadOnly(); - private static readonly string[] _repeatedGroupFieldNames = new string[] { "repeated_group_all_types" }; - private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 170 }; - public static RepeatedGroup DefaultInstance { - get { return defaultInstance; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class FooServerMessage : pb::GeneratedMessage + { + private FooServerMessage() { } + private static readonly FooServerMessage defaultInstance = new FooServerMessage().MakeReadOnly(); + private static readonly string[] _fooServerMessageFieldNames = new string[] { }; + private static readonly uint[] _fooServerMessageFieldTags = new uint[] { }; + public static FooServerMessage DefaultInstance + { + get { return defaultInstance; } } - public override RepeatedGroup DefaultInstanceForType { - get { return DefaultInstance; } + public override FooServerMessage DefaultInstanceForType + { + get { return DefaultInstance; } } - protected override RepeatedGroup ThisMessage { - get { return this; } + protected override FooServerMessage ThisMessage + { + get { return this; } } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__Descriptor; } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooServerMessage__Descriptor; } } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestParsingMerge_RepeatedGroup__FieldAccessorTable; } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooServerMessage__FieldAccessorTable; } } - public const int RepeatedGroupAllTypesFieldNumber = 21; - private bool hasRepeatedGroupAllTypes; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes repeatedGroupAllTypes_; - public bool HasRepeatedGroupAllTypes { - get { return hasRepeatedGroupAllTypes; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RepeatedGroupAllTypes { - get { return repeatedGroupAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } + public override bool IsInitialized + { + get + { + return true; + } } - public override bool IsInitialized { - get { - return true; - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _fooServerMessageFieldNames; + UnknownFields.WriteTo(output); } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _repeatedGroupFieldNames; - if (hasRepeatedGroupAllTypes) { - output.WriteMessage(21, field_names[0], RepeatedGroupAllTypes); - } - UnknownFields.WriteTo(output); + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { + private int CalcSerializedSize() + { int size = memoizedSerializedSize; if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - size = 0; - if (hasRepeatedGroupAllTypes) { - size += pb::CodedOutputStream.ComputeMessageSize(21, RepeatedGroupAllTypes); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; } - public static RepeatedGroup ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public static FooServerMessage ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public static FooServerMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public static RepeatedGroup ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); + public static FooServerMessage ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + public static FooServerMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); } - public static RepeatedGroup ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public static FooServerMessage ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public static FooServerMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + public static FooServerMessage ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); } - public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + public static FooServerMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); } - public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); + public static FooServerMessage ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + public static FooServerMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); } - private RepeatedGroup MakeReadOnly() { - return this; + private FooServerMessage MakeReadOnly() + { + return this; } public static Builder CreateBuilder() { return new Builder(); } public override Builder ToBuilder() { return CreateBuilder(this); } public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(RepeatedGroup prototype) { - return new Builder(prototype); + public static Builder CreateBuilder(FooServerMessage prototype) + { + return new Builder(prototype); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(RepeatedGroup cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private RepeatedGroup result; - - private RepeatedGroup PrepareBuilder() { - if (resultIsReadOnly) { - RepeatedGroup original = result; - result = new RepeatedGroup(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override RepeatedGroup MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(FooServerMessage cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; } - } - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.Descriptor; } - } + private bool resultIsReadOnly; + private FooServerMessage result; - public override RepeatedGroup DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.DefaultInstance; } - } + private FooServerMessage PrepareBuilder() + { + if (resultIsReadOnly) + { + FooServerMessage original = result; + result = new FooServerMessage(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public override RepeatedGroup BuildPartial() { - if (resultIsReadOnly) { - return result; + public override bool IsInitialized + { + get { return result.IsInitialized; } } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - public override Builder MergeFrom(pb::IMessage other) { - if (other is RepeatedGroup) { - return MergeFrom((RepeatedGroup) other); - } else { - base.MergeFrom(other); - return this; + protected override FooServerMessage MessageBeingBuilt + { + get { return PrepareBuilder(); } } - } - public override Builder MergeFrom(RepeatedGroup other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasRepeatedGroupAllTypes) { - MergeRepeatedGroupAllTypes(other.RepeatedGroupAllTypes); + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _repeatedGroupFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; + + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); } - case 170: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasRepeatedGroupAllTypes) { - subBuilder.MergeFrom(RepeatedGroupAllTypes); - } - input.ReadMessage(subBuilder, extensionRegistry); - RepeatedGroupAllTypes = subBuilder.BuildPartial(); - break; + else + { + return new Builder().MergeFrom(result); } - } } - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.FooServerMessage.Descriptor; } } - return this; - } - - - public bool HasRepeatedGroupAllTypes { - get { return result.hasRepeatedGroupAllTypes; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RepeatedGroupAllTypes { - get { return result.RepeatedGroupAllTypes; } - set { SetRepeatedGroupAllTypes(value); } - } - public Builder SetRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasRepeatedGroupAllTypes = true; - result.repeatedGroupAllTypes_ = value; - return this; - } - public Builder SetRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasRepeatedGroupAllTypes = true; - result.repeatedGroupAllTypes_ = builderForValue.Build(); - return this; - } - public Builder MergeRepeatedGroupAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasRepeatedGroupAllTypes && - result.repeatedGroupAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.repeatedGroupAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.repeatedGroupAllTypes_).MergeFrom(value).BuildPartial(); - } else { - result.repeatedGroupAllTypes_ = value; - } - result.hasRepeatedGroupAllTypes = true; - return this; - } - public Builder ClearRepeatedGroupAllTypes() { - PrepareBuilder(); - result.hasRepeatedGroupAllTypes = false; - result.repeatedGroupAllTypes_ = null; - return this; - } - } - static RepeatedGroup() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - } - #endregion - - public const int RequiredAllTypesFieldNumber = 1; - private bool hasRequiredAllTypes; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes requiredAllTypes_; - public bool HasRequiredAllTypes { - get { return hasRequiredAllTypes; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RequiredAllTypes { - get { return requiredAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } - - public const int OptionalAllTypesFieldNumber = 2; - private bool hasOptionalAllTypes; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes optionalAllTypes_; - public bool HasOptionalAllTypes { - get { return hasOptionalAllTypes; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalAllTypes { - get { return optionalAllTypes_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } - - public const int RepeatedAllTypesFieldNumber = 3; - private pbc::PopsicleList repeatedAllTypes_ = new pbc::PopsicleList(); - public scg::IList RepeatedAllTypesList { - get { return repeatedAllTypes_; } - } - public int RepeatedAllTypesCount { - get { return repeatedAllTypes_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetRepeatedAllTypes(int index) { - return repeatedAllTypes_[index]; - } - - public const int OptionalGroupFieldNumber = 10; - private bool hasOptionalGroup; - private global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup optionalGroup_; - public bool HasOptionalGroup { - get { return hasOptionalGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup OptionalGroup { - get { return optionalGroup_ ?? global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance; } - } - - public const int RepeatedGroupFieldNumber = 20; - private pbc::PopsicleList repeatedGroup_ = new pbc::PopsicleList(); - public scg::IList RepeatedGroupList { - get { return repeatedGroup_; } - } - public int RepeatedGroupCount { - get { return repeatedGroup_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup GetRepeatedGroup(int index) { - return repeatedGroup_[index]; - } - - public override bool IsInitialized { - get { - if (!hasRequiredAllTypes) return false; - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testParsingMergeFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - if (hasRequiredAllTypes) { - output.WriteMessage(1, field_names[4], RequiredAllTypes); - } - if (hasOptionalAllTypes) { - output.WriteMessage(2, field_names[0], OptionalAllTypes); - } - if (repeatedAllTypes_.Count > 0) { - output.WriteMessageArray(3, field_names[2], repeatedAllTypes_); - } - if (hasOptionalGroup) { - output.WriteGroup(10, field_names[1], OptionalGroup); - } - if (repeatedGroup_.Count > 0) { - output.WriteGroupArray(20, field_names[3], repeatedGroup_); - } - extensionWriter.WriteUntil(536870912, output); - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasRequiredAllTypes) { - size += pb::CodedOutputStream.ComputeMessageSize(1, RequiredAllTypes); - } - if (hasOptionalAllTypes) { - size += pb::CodedOutputStream.ComputeMessageSize(2, OptionalAllTypes); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in RepeatedAllTypesList) { - size += pb::CodedOutputStream.ComputeMessageSize(3, element); - } - if (hasOptionalGroup) { - size += pb::CodedOutputStream.ComputeGroupSize(10, OptionalGroup); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup element in RepeatedGroupList) { - size += pb::CodedOutputStream.ComputeGroupSize(20, element); - } - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestParsingMerge ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestParsingMerge ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestParsingMerge ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestParsingMerge ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestParsingMerge ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestParsingMerge ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestParsingMerge ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestParsingMerge ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestParsingMerge ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestParsingMerge ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestParsingMerge MakeReadOnly() { - repeatedAllTypes_.MakeReadOnly(); - repeatedGroup_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestParsingMerge prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestParsingMerge cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestParsingMerge result; - - private TestParsingMerge PrepareBuilder() { - if (resultIsReadOnly) { - TestParsingMerge original = result; - result = new TestParsingMerge(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestParsingMerge MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Descriptor; } - } - - public override TestParsingMerge DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.DefaultInstance; } - } - - public override TestParsingMerge BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestParsingMerge) { - return MergeFrom((TestParsingMerge) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestParsingMerge other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasRequiredAllTypes) { - MergeRequiredAllTypes(other.RequiredAllTypes); - } - if (other.HasOptionalAllTypes) { - MergeOptionalAllTypes(other.OptionalAllTypes); - } - if (other.repeatedAllTypes_.Count != 0) { - result.repeatedAllTypes_.Add(other.repeatedAllTypes_); - } - if (other.HasOptionalGroup) { - MergeOptionalGroup(other.OptionalGroup); - } - if (other.repeatedGroup_.Count != 0) { - result.repeatedGroup_.Add(other.repeatedGroup_); - } - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testParsingMergeFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testParsingMergeFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasRequiredAllTypes) { - subBuilder.MergeFrom(RequiredAllTypes); - } - input.ReadMessage(subBuilder, extensionRegistry); - RequiredAllTypes = subBuilder.BuildPartial(); - break; - } - case 18: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasOptionalAllTypes) { - subBuilder.MergeFrom(OptionalAllTypes); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalAllTypes = subBuilder.BuildPartial(); - break; - } - case 26: { - input.ReadMessageArray(tag, field_name, result.repeatedAllTypes_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); - break; - } - case 83: { - global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.CreateBuilder(); - if (result.hasOptionalGroup) { - subBuilder.MergeFrom(OptionalGroup); - } - input.ReadGroup(10, subBuilder, extensionRegistry); - OptionalGroup = subBuilder.BuildPartial(); - break; - } - case 163: { - input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.DefaultInstance, extensionRegistry); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasRequiredAllTypes { - get { return result.hasRequiredAllTypes; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes RequiredAllTypes { - get { return result.RequiredAllTypes; } - set { SetRequiredAllTypes(value); } - } - public Builder SetRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasRequiredAllTypes = true; - result.requiredAllTypes_ = value; - return this; - } - public Builder SetRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasRequiredAllTypes = true; - result.requiredAllTypes_ = builderForValue.Build(); - return this; - } - public Builder MergeRequiredAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasRequiredAllTypes && - result.requiredAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.requiredAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.requiredAllTypes_).MergeFrom(value).BuildPartial(); - } else { - result.requiredAllTypes_ = value; - } - result.hasRequiredAllTypes = true; - return this; - } - public Builder ClearRequiredAllTypes() { - PrepareBuilder(); - result.hasRequiredAllTypes = false; - result.requiredAllTypes_ = null; - return this; - } - - public bool HasOptionalAllTypes { - get { return result.hasOptionalAllTypes; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalAllTypes { - get { return result.OptionalAllTypes; } - set { SetOptionalAllTypes(value); } - } - public Builder SetOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalAllTypes = true; - result.optionalAllTypes_ = value; - return this; - } - public Builder SetOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalAllTypes = true; - result.optionalAllTypes_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalAllTypes && - result.optionalAllTypes_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.optionalAllTypes_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.optionalAllTypes_).MergeFrom(value).BuildPartial(); - } else { - result.optionalAllTypes_ = value; - } - result.hasOptionalAllTypes = true; - return this; - } - public Builder ClearOptionalAllTypes() { - PrepareBuilder(); - result.hasOptionalAllTypes = false; - result.optionalAllTypes_ = null; - return this; - } - - public pbc::IPopsicleList RepeatedAllTypesList { - get { return PrepareBuilder().repeatedAllTypes_; } - } - public int RepeatedAllTypesCount { - get { return result.RepeatedAllTypesCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetRepeatedAllTypes(int index) { - return result.GetRepeatedAllTypes(index); - } - public Builder SetRepeatedAllTypes(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedAllTypes_[index] = value; - return this; - } - public Builder SetRepeatedAllTypes(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedAllTypes_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedAllTypes_.Add(value); - return this; - } - public Builder AddRepeatedAllTypes(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedAllTypes_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedAllTypes(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedAllTypes_.Add(values); - return this; - } - public Builder ClearRepeatedAllTypes() { - PrepareBuilder(); - result.repeatedAllTypes_.Clear(); - return this; - } - - public bool HasOptionalGroup { - get { return result.hasOptionalGroup; } - } - public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup OptionalGroup { - get { return result.OptionalGroup; } - set { SetOptionalGroup(value); } - } - public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalGroup = true; - result.optionalGroup_ = value; - return this; - } - public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalGroup = true; - result.optionalGroup_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalGroup && - result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.DefaultInstance) { - result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial(); - } else { - result.optionalGroup_ = value; - } - result.hasOptionalGroup = true; - return this; - } - public Builder ClearOptionalGroup() { - PrepareBuilder(); - result.hasOptionalGroup = false; - result.optionalGroup_ = null; - return this; - } - - public pbc::IPopsicleList RepeatedGroupList { - get { return PrepareBuilder().repeatedGroup_; } - } - public int RepeatedGroupCount { - get { return result.RepeatedGroupCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup GetRepeatedGroup(int index) { - return result.GetRepeatedGroup(index); - } - public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedGroup_[index] = value; - return this; - } - public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedGroup_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedGroup_.Add(value); - return this; - } - public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestParsingMerge.Types.RepeatedGroup.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedGroup_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedGroup(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedGroup_.Add(values); - return this; - } - public Builder ClearRepeatedGroup() { - PrepareBuilder(); - result.repeatedGroup_.Clear(); - return this; - } - } - static TestParsingMerge() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestCommentInjectionMessage : pb::GeneratedMessage { - private TestCommentInjectionMessage() { } - private static readonly TestCommentInjectionMessage defaultInstance = new TestCommentInjectionMessage().MakeReadOnly(); - private static readonly string[] _testCommentInjectionMessageFieldNames = new string[] { "a" }; - private static readonly uint[] _testCommentInjectionMessageFieldTags = new uint[] { 10 }; - public static TestCommentInjectionMessage DefaultInstance { - get { return defaultInstance; } - } - - public override TestCommentInjectionMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestCommentInjectionMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCommentInjectionMessage__Descriptor; } - } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_TestCommentInjectionMessage__FieldAccessorTable; } - } - - public const int AFieldNumber = 1; - private bool hasA; - private string a_ = "*/ <- Neither should this."; - public bool HasA { - get { return hasA; } - } - public string A { - get { return a_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testCommentInjectionMessageFieldNames; - if (hasA) { - output.WriteString(1, field_names[0], A); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA) { - size += pb::CodedOutputStream.ComputeStringSize(1, A); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestCommentInjectionMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestCommentInjectionMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestCommentInjectionMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestCommentInjectionMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestCommentInjectionMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestCommentInjectionMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestCommentInjectionMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestCommentInjectionMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestCommentInjectionMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestCommentInjectionMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestCommentInjectionMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestCommentInjectionMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestCommentInjectionMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestCommentInjectionMessage result; - - private TestCommentInjectionMessage PrepareBuilder() { - if (resultIsReadOnly) { - TestCommentInjectionMessage original = result; - result = new TestCommentInjectionMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestCommentInjectionMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestCommentInjectionMessage.Descriptor; } - } - - public override TestCommentInjectionMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestCommentInjectionMessage.DefaultInstance; } - } - - public override TestCommentInjectionMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestCommentInjectionMessage) { - return MergeFrom((TestCommentInjectionMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestCommentInjectionMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestCommentInjectionMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA) { - A = other.A; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testCommentInjectionMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testCommentInjectionMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - result.hasA = input.ReadString(ref result.a_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA { - get { return result.hasA; } - } - public string A { - get { return result.A; } - set { SetA(value); } - } - public Builder SetA(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasA = true; - result.a_ = value; - return this; - } - public Builder ClearA() { - PrepareBuilder(); - result.hasA = false; - result.a_ = "*/ <- Neither should this."; - return this; - } - } - static TestCommentInjectionMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class FooRequest : pb::GeneratedMessage { - private FooRequest() { } - private static readonly FooRequest defaultInstance = new FooRequest().MakeReadOnly(); - private static readonly string[] _fooRequestFieldNames = new string[] { }; - private static readonly uint[] _fooRequestFieldTags = new uint[] { }; - public static FooRequest DefaultInstance { - get { return defaultInstance; } - } - - public override FooRequest DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override FooRequest ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooRequest__Descriptor; } - } + public override FooServerMessage DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.FooServerMessage.DefaultInstance; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooRequest__FieldAccessorTable; } - } + public override FooServerMessage BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public override bool IsInitialized { - get { - return true; - } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is FooServerMessage) + { + return MergeFrom((FooServerMessage)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooRequestFieldNames; - UnknownFields.WriteTo(output); - } + public override Builder MergeFrom(FooServerMessage other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.FooServerMessage.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_fooServerMessageFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _fooServerMessageFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static FooRequest ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooRequest ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooRequest ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static FooRequest ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static FooRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static FooRequest ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private FooRequest MakeReadOnly() { - return this; - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(FooRequest prototype) { - return new Builder(prototype); + } + static FooServerMessage() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(FooRequest cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private FooRequest result; - - private FooRequest PrepareBuilder() { - if (resultIsReadOnly) { - FooRequest original = result; - result = new FooRequest(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override FooRequest MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooRequest.Descriptor; } - } - - public override FooRequest DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooRequest.DefaultInstance; } - } - - public override FooRequest BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is FooRequest) { - return MergeFrom((FooRequest) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(FooRequest other) { - if (other == global::Google.ProtocolBuffers.TestProtos.FooRequest.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooRequestFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooRequestFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static FooRequest() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class FooResponse : pb::GeneratedMessage { - private FooResponse() { } - private static readonly FooResponse defaultInstance = new FooResponse().MakeReadOnly(); - private static readonly string[] _fooResponseFieldNames = new string[] { }; - private static readonly uint[] _fooResponseFieldTags = new uint[] { }; - public static FooResponse DefaultInstance { - get { return defaultInstance; } - } - - public override FooResponse DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override FooResponse ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooResponse__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooResponse__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooResponseFieldNames; - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public sealed partial class BarRequest : pb::GeneratedMessage + { + private BarRequest() { } + private static readonly BarRequest defaultInstance = new BarRequest().MakeReadOnly(); + private static readonly string[] _barRequestFieldNames = new string[] { }; + private static readonly uint[] _barRequestFieldTags = new uint[] { }; + public static BarRequest DefaultInstance + { + get { return defaultInstance; } + } - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static FooResponse ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooResponse ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooResponse ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static FooResponse ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static FooResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static FooResponse ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private FooResponse MakeReadOnly() { - return this; - } + public override BarRequest DefaultInstanceForType + { + get { return DefaultInstance; } + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(FooResponse prototype) { - return new Builder(prototype); - } + protected override BarRequest ThisMessage + { + get { return this; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(FooResponse cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private FooResponse result; - - private FooResponse PrepareBuilder() { - if (resultIsReadOnly) { - FooResponse original = result; - result = new FooResponse(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override FooResponse MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooResponse.Descriptor; } - } - - public override FooResponse DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooResponse.DefaultInstance; } - } - - public override FooResponse BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is FooResponse) { - return MergeFrom((FooResponse) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(FooResponse other) { - if (other == global::Google.ProtocolBuffers.TestProtos.FooResponse.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooResponseFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooResponseFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarRequest__Descriptor; } + } - } - static FooResponse() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class FooClientMessage : pb::GeneratedMessage { - private FooClientMessage() { } - private static readonly FooClientMessage defaultInstance = new FooClientMessage().MakeReadOnly(); - private static readonly string[] _fooClientMessageFieldNames = new string[] { }; - private static readonly uint[] _fooClientMessageFieldTags = new uint[] { }; - public static FooClientMessage DefaultInstance { - get { return defaultInstance; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarRequest__FieldAccessorTable; } + } - public override FooClientMessage DefaultInstanceForType { - get { return DefaultInstance; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - protected override FooClientMessage ThisMessage { - get { return this; } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _barRequestFieldNames; + UnknownFields.WriteTo(output); + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooClientMessage__Descriptor; } - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooClientMessage__FieldAccessorTable; } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - public override bool IsInitialized { - get { - return true; - } - } + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static BarRequest ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BarRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BarRequest ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BarRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BarRequest ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BarRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static BarRequest ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static BarRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static BarRequest ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BarRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private BarRequest MakeReadOnly() + { + return this; + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooClientMessageFieldNames; - UnknownFields.WriteTo(output); - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(BarRequest prototype) + { + return new Builder(prototype); + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(BarRequest cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + private bool resultIsReadOnly; + private BarRequest result; - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static FooClientMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooClientMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooClientMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooClientMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooClientMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooClientMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static FooClientMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static FooClientMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static FooClientMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooClientMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private FooClientMessage MakeReadOnly() { - return this; - } + private BarRequest PrepareBuilder() + { + if (resultIsReadOnly) + { + BarRequest original = result; + result = new BarRequest(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(FooClientMessage prototype) { - return new Builder(prototype); - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(FooClientMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private FooClientMessage result; - - private FooClientMessage PrepareBuilder() { - if (resultIsReadOnly) { - FooClientMessage original = result; - result = new FooClientMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override FooClientMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooClientMessage.Descriptor; } - } - - public override FooClientMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooClientMessage.DefaultInstance; } - } - - public override FooClientMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is FooClientMessage) { - return MergeFrom((FooClientMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(FooClientMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.FooClientMessage.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooClientMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooClientMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + protected override BarRequest MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - } - static FooClientMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class FooServerMessage : pb::GeneratedMessage { - private FooServerMessage() { } - private static readonly FooServerMessage defaultInstance = new FooServerMessage().MakeReadOnly(); - private static readonly string[] _fooServerMessageFieldNames = new string[] { }; - private static readonly uint[] _fooServerMessageFieldTags = new uint[] { }; - public static FooServerMessage DefaultInstance { - get { return defaultInstance; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - public override FooServerMessage DefaultInstanceForType { - get { return DefaultInstance; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - protected override FooServerMessage ThisMessage { - get { return this; } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.BarRequest.Descriptor; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooServerMessage__Descriptor; } - } + public override BarRequest DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.BarRequest.DefaultInstance; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_FooServerMessage__FieldAccessorTable; } - } + public override BarRequest BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - public override bool IsInitialized { - get { - return true; - } - } + public override Builder MergeFrom(pb::IMessage other) + { + if (other is BarRequest) + { + return MergeFrom((BarRequest)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _fooServerMessageFieldNames; - UnknownFields.WriteTo(output); - } + public override Builder MergeFrom(BarRequest other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.BarRequest.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_barRequestFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _barRequestFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static FooServerMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooServerMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooServerMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static FooServerMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static FooServerMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooServerMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static FooServerMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static FooServerMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static FooServerMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static FooServerMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private FooServerMessage MakeReadOnly() { - return this; - } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(FooServerMessage prototype) { - return new Builder(prototype); + } + static BarRequest() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(FooServerMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private FooServerMessage result; - - private FooServerMessage PrepareBuilder() { - if (resultIsReadOnly) { - FooServerMessage original = result; - result = new FooServerMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override FooServerMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooServerMessage.Descriptor; } - } - - public override FooServerMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.FooServerMessage.DefaultInstance; } - } - - public override FooServerMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is FooServerMessage) { - return MergeFrom((FooServerMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(FooServerMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.FooServerMessage.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_fooServerMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _fooServerMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + public sealed partial class BarResponse : pb::GeneratedMessage + { + private BarResponse() { } + private static readonly BarResponse defaultInstance = new BarResponse().MakeReadOnly(); + private static readonly string[] _barResponseFieldNames = new string[] { }; + private static readonly uint[] _barResponseFieldTags = new uint[] { }; + public static BarResponse DefaultInstance + { + get { return defaultInstance; } + } - } - static FooServerMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class BarRequest : pb::GeneratedMessage { - private BarRequest() { } - private static readonly BarRequest defaultInstance = new BarRequest().MakeReadOnly(); - private static readonly string[] _barRequestFieldNames = new string[] { }; - private static readonly uint[] _barRequestFieldTags = new uint[] { }; - public static BarRequest DefaultInstance { - get { return defaultInstance; } - } + public override BarResponse DefaultInstanceForType + { + get { return DefaultInstance; } + } - public override BarRequest DefaultInstanceForType { - get { return DefaultInstance; } - } + protected override BarResponse ThisMessage + { + get { return this; } + } - protected override BarRequest ThisMessage { - get { return this; } - } + public static pbd::MessageDescriptor Descriptor + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarResponse__Descriptor; } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarRequest__Descriptor; } - } + protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors + { + get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarResponse__FieldAccessorTable; } + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarRequest__FieldAccessorTable; } - } + public override bool IsInitialized + { + get + { + return true; + } + } - public override bool IsInitialized { - get { - return true; - } - } + public override void WriteTo(pb::ICodedOutputStream output) + { + CalcSerializedSize(); + string[] field_names = _barResponseFieldNames; + UnknownFields.WriteTo(output); + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _barRequestFieldNames; - UnknownFields.WriteTo(output); - } + private int memoizedSerializedSize = -1; + public override int SerializedSize + { + get + { + int size = memoizedSerializedSize; + if (size != -1) return size; + return CalcSerializedSize(); + } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + private int CalcSerializedSize() + { + int size = memoizedSerializedSize; + if (size != -1) return size; - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + size = 0; + size += UnknownFields.SerializedSize; + memoizedSerializedSize = size; + return size; + } + public static BarResponse ParseFrom(pb::ByteString data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BarResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BarResponse ParseFrom(byte[] data) + { + return ((Builder)CreateBuilder().MergeFrom(data)).BuildParsed(); + } + public static BarResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); + } + public static BarResponse ParseFrom(global::System.IO.Stream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BarResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + public static BarResponse ParseDelimitedFrom(global::System.IO.Stream input) + { + return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); + } + public static BarResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) + { + return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); + } + public static BarResponse ParseFrom(pb::ICodedInputStream input) + { + return ((Builder)CreateBuilder().MergeFrom(input)).BuildParsed(); + } + public static BarResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + return ((Builder)CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); + } + private BarResponse MakeReadOnly() + { + return this; + } - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static BarRequest ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BarRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BarRequest ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BarRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BarRequest ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BarRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static BarRequest ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static BarRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static BarRequest ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BarRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private BarRequest MakeReadOnly() { - return this; - } + public static Builder CreateBuilder() { return new Builder(); } + public override Builder ToBuilder() { return CreateBuilder(this); } + public override Builder CreateBuilderForType() { return new Builder(); } + public static Builder CreateBuilder(BarResponse prototype) + { + return new Builder(prototype); + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(BarRequest prototype) { - return new Builder(prototype); - } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public sealed partial class Builder : pb::GeneratedBuilder + { + protected override Builder ThisBuilder + { + get { return this; } + } + public Builder() + { + result = DefaultInstance; + resultIsReadOnly = true; + } + internal Builder(BarResponse cloneFrom) + { + result = cloneFrom; + resultIsReadOnly = true; + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(BarRequest cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private BarRequest result; - - private BarRequest PrepareBuilder() { - if (resultIsReadOnly) { - BarRequest original = result; - result = new BarRequest(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override BarRequest MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.BarRequest.Descriptor; } - } - - public override BarRequest DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.BarRequest.DefaultInstance; } - } - - public override BarRequest BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is BarRequest) { - return MergeFrom((BarRequest) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(BarRequest other) { - if (other == global::Google.ProtocolBuffers.TestProtos.BarRequest.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_barRequestFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _barRequestFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + private bool resultIsReadOnly; + private BarResponse result; - } - static BarRequest() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class BarResponse : pb::GeneratedMessage { - private BarResponse() { } - private static readonly BarResponse defaultInstance = new BarResponse().MakeReadOnly(); - private static readonly string[] _barResponseFieldNames = new string[] { }; - private static readonly uint[] _barResponseFieldTags = new uint[] { }; - public static BarResponse DefaultInstance { - get { return defaultInstance; } - } + private BarResponse PrepareBuilder() + { + if (resultIsReadOnly) + { + BarResponse original = result; + result = new BarResponse(); + resultIsReadOnly = false; + MergeFrom(original); + } + return result; + } - public override BarResponse DefaultInstanceForType { - get { return DefaultInstance; } - } + public override bool IsInitialized + { + get { return result.IsInitialized; } + } - protected override BarResponse ThisMessage { - get { return this; } - } + protected override BarResponse MessageBeingBuilt + { + get { return PrepareBuilder(); } + } - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarResponse__Descriptor; } - } + public override Builder Clear() + { + result = DefaultInstance; + resultIsReadOnly = true; + return this; + } - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.Unittest.internal__static_protobuf_unittest_BarResponse__FieldAccessorTable; } - } + public override Builder Clone() + { + if (resultIsReadOnly) + { + return new Builder(result); + } + else + { + return new Builder().MergeFrom(result); + } + } - public override bool IsInitialized { - get { - return true; - } - } + public override pbd::MessageDescriptor DescriptorForType + { + get { return global::Google.ProtocolBuffers.TestProtos.BarResponse.Descriptor; } + } - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _barResponseFieldNames; - UnknownFields.WriteTo(output); - } + public override BarResponse DefaultInstanceForType + { + get { return global::Google.ProtocolBuffers.TestProtos.BarResponse.DefaultInstance; } + } - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } + public override BarResponse BuildPartial() + { + if (resultIsReadOnly) + { + return result; + } + resultIsReadOnly = true; + return result.MakeReadOnly(); + } - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; + public override Builder MergeFrom(pb::IMessage other) + { + if (other is BarResponse) + { + return MergeFrom((BarResponse)other); + } + else + { + base.MergeFrom(other); + return this; + } + } - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static BarResponse ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BarResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BarResponse ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static BarResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static BarResponse ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BarResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static BarResponse ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static BarResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static BarResponse ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static BarResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private BarResponse MakeReadOnly() { - return this; - } + public override Builder MergeFrom(BarResponse other) + { + if (other == global::Google.ProtocolBuffers.TestProtos.BarResponse.DefaultInstance) return this; + PrepareBuilder(); + this.MergeUnknownFields(other.UnknownFields); + return this; + } - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(BarResponse prototype) { - return new Builder(prototype); - } + public override Builder MergeFrom(pb::ICodedInputStream input) + { + return MergeFrom(input, pb::ExtensionRegistry.Empty); + } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(BarResponse cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private BarResponse result; - - private BarResponse PrepareBuilder() { - if (resultIsReadOnly) { - BarResponse original = result; - result = new BarResponse(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override BarResponse MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.BarResponse.Descriptor; } - } - - public override BarResponse DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.BarResponse.DefaultInstance; } - } - - public override BarResponse BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is BarResponse) { - return MergeFrom((BarResponse) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(BarResponse other) { - if (other == global::Google.ProtocolBuffers.TestProtos.BarResponse.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_barResponseFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _barResponseFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } + public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) + { + PrepareBuilder(); + pb::UnknownFieldSet.Builder unknownFields = null; + uint tag; + string field_name; + while (input.ReadTag(out tag, out field_name)) + { + if (tag == 0 && field_name != null) + { + int field_ordinal = global::System.Array.BinarySearch(_barResponseFieldNames, field_name, global::System.StringComparer.Ordinal); + if (field_ordinal >= 0) + tag = _barResponseFieldTags[field_ordinal]; + else + { + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + continue; + } + } + switch (tag) + { + case 0: + { + throw pb::InvalidProtocolBufferException.InvalidTag(); + } + default: + { + if (pb::WireFormat.IsEndGroupTag(tag)) + { + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + if (unknownFields == null) + { + unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); + } + ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); + break; + } + } + } + if (unknownFields != null) + { + this.UnknownFields = unknownFields.Build(); + } + return this; + } + + } + static BarResponse() + { + object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); + } } - static BarResponse() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, null); - } - } - #endregion + #endregion } -- cgit v1.2.3 From 385afba572b6541286976f463e6240f2ca45ea11 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 12 May 2015 21:09:49 -0700 Subject: Regenerate some proto files after ClsCompliance has been dropped --- .../ProtocolBuffers.Test/TestProtos/GoogleSize.cs | 22 ---------------------- .../ProtocolBuffers.Test/TestProtos/GoogleSpeed.cs | 22 ---------------------- .../TestProtos/UnittestExtrasFull.cs | 3 --- 3 files changed, 47 deletions(-) (limited to 'csharp/src/ProtocolBuffersLite.Test/TestProtos') diff --git a/csharp/src/ProtocolBuffers.Test/TestProtos/GoogleSize.cs b/csharp/src/ProtocolBuffers.Test/TestProtos/GoogleSize.cs index 06f2c0ca..92309e92 100644 --- a/csharp/src/ProtocolBuffers.Test/TestProtos/GoogleSize.cs +++ b/csharp/src/ProtocolBuffers.Test/TestProtos/GoogleSize.cs @@ -265,14 +265,12 @@ namespace Google.ProtocolBuffers.TestProtos { public const int Field5FieldNumber = 5; private pbc::PopsicleList field5_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] public scg::IList Field5List { get { return pbc::Lists.AsReadOnly(field5_); } } public int Field5Count { get { return field5_.Count; } } - [global::System.CLSCompliant(false)] public ulong GetField5(int index) { return field5_[index]; } @@ -899,30 +897,25 @@ namespace Google.ProtocolBuffers.TestProtos { return this; } - [global::System.CLSCompliant(false)] public pbc::IPopsicleList Field5List { get { return PrepareBuilder().field5_; } } public int Field5Count { get { return result.Field5Count; } } - [global::System.CLSCompliant(false)] public ulong GetField5(int index) { return result.GetField5(index); } - [global::System.CLSCompliant(false)] public Builder SetField5(int index, ulong value) { PrepareBuilder(); result.field5_[index] = value; return this; } - [global::System.CLSCompliant(false)] public Builder AddField5(ulong value) { PrepareBuilder(); result.field5_.Add(value); return this; } - [global::System.CLSCompliant(false)] public Builder AddRangeField5(scg::IEnumerable values) { PrepareBuilder(); result.field5_.Add(values); @@ -1683,7 +1676,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField21 { get { return hasField21; } } - [global::System.CLSCompliant(false)] public ulong Field21 { get { return field21_; } } @@ -1724,7 +1716,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField203 { get { return hasField203; } } - [global::System.CLSCompliant(false)] public uint Field203 { get { return field203_; } } @@ -1755,7 +1746,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField207 { get { return hasField207; } } - [global::System.CLSCompliant(false)] public ulong Field207 { get { return field207_; } } @@ -1766,7 +1756,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField300 { get { return hasField300; } } - [global::System.CLSCompliant(false)] public ulong Field300 { get { return field300_; } } @@ -2102,12 +2091,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField21 { get { return result.hasField21; } } - [global::System.CLSCompliant(false)] public ulong Field21 { get { return result.Field21; } set { SetField21(value); } } - [global::System.CLSCompliant(false)] public Builder SetField21(ulong value) { PrepareBuilder(); result.hasField21 = true; @@ -2184,12 +2171,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField203 { get { return result.hasField203; } } - [global::System.CLSCompliant(false)] public uint Field203 { get { return result.Field203; } set { SetField203(value); } } - [global::System.CLSCompliant(false)] public Builder SetField203(uint value) { PrepareBuilder(); result.hasField203 = true; @@ -2247,12 +2232,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField207 { get { return result.hasField207; } } - [global::System.CLSCompliant(false)] public ulong Field207 { get { return result.Field207; } set { SetField207(value); } } - [global::System.CLSCompliant(false)] public Builder SetField207(ulong value) { PrepareBuilder(); result.hasField207 = true; @@ -2269,12 +2252,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField300 { get { return result.hasField300; } } - [global::System.CLSCompliant(false)] public ulong Field300 { get { return result.Field300; } set { SetField300(value); } } - [global::System.CLSCompliant(false)] public Builder SetField300(ulong value) { PrepareBuilder(); result.hasField300 = true; @@ -2402,7 +2383,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField15 { get { return hasField15; } } - [global::System.CLSCompliant(false)] public ulong Field15 { get { return field15_; } } @@ -2738,12 +2718,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField15 { get { return result.hasField15; } } - [global::System.CLSCompliant(false)] public ulong Field15 { get { return result.Field15; } set { SetField15(value); } } - [global::System.CLSCompliant(false)] public Builder SetField15(ulong value) { PrepareBuilder(); result.hasField15 = true; diff --git a/csharp/src/ProtocolBuffers.Test/TestProtos/GoogleSpeed.cs b/csharp/src/ProtocolBuffers.Test/TestProtos/GoogleSpeed.cs index 13e684a5..aa9b90f0 100644 --- a/csharp/src/ProtocolBuffers.Test/TestProtos/GoogleSpeed.cs +++ b/csharp/src/ProtocolBuffers.Test/TestProtos/GoogleSpeed.cs @@ -267,14 +267,12 @@ namespace Google.ProtocolBuffers.TestProtos { public const int Field5FieldNumber = 5; private pbc::PopsicleList field5_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] public scg::IList Field5List { get { return pbc::Lists.AsReadOnly(field5_); } } public int Field5Count { get { return field5_.Count; } } - [global::System.CLSCompliant(false)] public ulong GetField5(int index) { return field5_[index]; } @@ -1540,30 +1538,25 @@ namespace Google.ProtocolBuffers.TestProtos { return this; } - [global::System.CLSCompliant(false)] public pbc::IPopsicleList Field5List { get { return PrepareBuilder().field5_; } } public int Field5Count { get { return result.Field5Count; } } - [global::System.CLSCompliant(false)] public ulong GetField5(int index) { return result.GetField5(index); } - [global::System.CLSCompliant(false)] public Builder SetField5(int index, ulong value) { PrepareBuilder(); result.field5_[index] = value; return this; } - [global::System.CLSCompliant(false)] public Builder AddField5(ulong value) { PrepareBuilder(); result.field5_.Add(value); return this; } - [global::System.CLSCompliant(false)] public Builder AddRangeField5(scg::IEnumerable values) { PrepareBuilder(); result.field5_.Add(values); @@ -2326,7 +2319,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField21 { get { return hasField21; } } - [global::System.CLSCompliant(false)] public ulong Field21 { get { return field21_; } } @@ -2367,7 +2359,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField203 { get { return hasField203; } } - [global::System.CLSCompliant(false)] public uint Field203 { get { return field203_; } } @@ -2398,7 +2389,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField207 { get { return hasField207; } } - [global::System.CLSCompliant(false)] public ulong Field207 { get { return field207_; } } @@ -2409,7 +2399,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField300 { get { return hasField300; } } - [global::System.CLSCompliant(false)] public ulong Field300 { get { return field300_; } } @@ -3099,12 +3088,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField21 { get { return result.hasField21; } } - [global::System.CLSCompliant(false)] public ulong Field21 { get { return result.Field21; } set { SetField21(value); } } - [global::System.CLSCompliant(false)] public Builder SetField21(ulong value) { PrepareBuilder(); result.hasField21 = true; @@ -3181,12 +3168,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField203 { get { return result.hasField203; } } - [global::System.CLSCompliant(false)] public uint Field203 { get { return result.Field203; } set { SetField203(value); } } - [global::System.CLSCompliant(false)] public Builder SetField203(uint value) { PrepareBuilder(); result.hasField203 = true; @@ -3244,12 +3229,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField207 { get { return result.hasField207; } } - [global::System.CLSCompliant(false)] public ulong Field207 { get { return result.Field207; } set { SetField207(value); } } - [global::System.CLSCompliant(false)] public Builder SetField207(ulong value) { PrepareBuilder(); result.hasField207 = true; @@ -3266,12 +3249,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField300 { get { return result.hasField300; } } - [global::System.CLSCompliant(false)] public ulong Field300 { get { return result.Field300; } set { SetField300(value); } } - [global::System.CLSCompliant(false)] public Builder SetField300(ulong value) { PrepareBuilder(); result.hasField300 = true; @@ -3403,7 +3384,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField15 { get { return hasField15; } } - [global::System.CLSCompliant(false)] public ulong Field15 { get { return field15_; } } @@ -4064,12 +4044,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasField15 { get { return result.hasField15; } } - [global::System.CLSCompliant(false)] public ulong Field15 { get { return result.Field15; } set { SetField15(value); } } - [global::System.CLSCompliant(false)] public Builder SetField15(ulong value) { PrepareBuilder(); result.hasField15 = true; diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasFull.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasFull.cs index 3eed99f1..827bedef 100644 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasFull.cs +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasFull.cs @@ -420,7 +420,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasZip { get { return hasZip; } } - [global::System.CLSCompliant(false)] public uint Zip { get { return zip_; } } @@ -619,12 +618,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasZip { get { return result.hasZip; } } - [global::System.CLSCompliant(false)] public uint Zip { get { return result.Zip; } set { SetZip(value); } } - [global::System.CLSCompliant(false)] public Builder SetZip(uint value) { PrepareBuilder(); result.hasZip = true; -- cgit v1.2.3 From 766036f231afb3789292adedd3d1a3e41079b1ea Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 12 May 2015 21:33:40 -0700 Subject: remove C# files not referenced in any project --- .../TestProtos/UnittestNoFieldPresence.cs | 4065 -------------------- .../TestProtos/UnittestPreserveUnknownEnum.cs | 1320 ------- .../TestProtos/UnittestPreserveUnknownEnum2.cs | 684 ---- .../TestProtos/UnittestExtrasXmltest.cs | 2277 ----------- .../TestProtos/UnittestIssues.cs | 3437 ----------------- 5 files changed, 11783 deletions(-) delete mode 100644 csharp/src/ProtocolBuffers.Test/TestProtos/UnittestNoFieldPresence.cs delete mode 100644 csharp/src/ProtocolBuffers.Test/TestProtos/UnittestPreserveUnknownEnum.cs delete mode 100644 csharp/src/ProtocolBuffers.Test/TestProtos/UnittestPreserveUnknownEnum2.cs delete mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasXmltest.cs delete mode 100644 csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestIssues.cs (limited to 'csharp/src/ProtocolBuffersLite.Test/TestProtos') diff --git a/csharp/src/ProtocolBuffers.Test/TestProtos/UnittestNoFieldPresence.cs b/csharp/src/ProtocolBuffers.Test/TestProtos/UnittestNoFieldPresence.cs deleted file mode 100644 index 654c2e50..00000000 --- a/csharp/src/ProtocolBuffers.Test/TestProtos/UnittestNoFieldPresence.cs +++ /dev/null @@ -1,4065 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/protobuf/unittest_no_field_presence.proto -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnittestNoFieldPresence { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - } - #endregion - #region Static variables - internal static pbd::MessageDescriptor internal__static_proto2_nofieldpresence_unittest_TestAllTypes__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_proto2_nofieldpresence_unittest_TestAllTypes__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_proto2_nofieldpresence_unittest_TestAllTypes_NestedMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_proto2_nofieldpresence_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_proto2_nofieldpresence_unittest_TestProto2Required__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_proto2_nofieldpresence_unittest_TestProto2Required__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_proto2_nofieldpresence_unittest_ForeignMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_proto2_nofieldpresence_unittest_ForeignMessage__FieldAccessorTable; - #endregion - #region Descriptor - public static pbd::FileDescriptor Descriptor { - get { return descriptor; } - } - private static pbd::FileDescriptor descriptor; - - static UnittestNoFieldPresence() { - byte[] descriptorData = global::System.Convert.FromBase64String( - string.Concat( - "CjBnb29nbGUvcHJvdG9idWYvdW5pdHRlc3Rfbm9fZmllbGRfcHJlc2VuY2Uu", - "cHJvdG8SH3Byb3RvMl9ub2ZpZWxkcHJlc2VuY2VfdW5pdHRlc3QaHmdvb2ds", - "ZS9wcm90b2J1Zi91bml0dGVzdC5wcm90byKaEQoMVGVzdEFsbFR5cGVzEhYK", - "Dm9wdGlvbmFsX2ludDMyGAEgASgFEhYKDm9wdGlvbmFsX2ludDY0GAIgASgD", - "EhcKD29wdGlvbmFsX3VpbnQzMhgDIAEoDRIXCg9vcHRpb25hbF91aW50NjQY", - "BCABKAQSFwoPb3B0aW9uYWxfc2ludDMyGAUgASgREhcKD29wdGlvbmFsX3Np", - "bnQ2NBgGIAEoEhIYChBvcHRpb25hbF9maXhlZDMyGAcgASgHEhgKEG9wdGlv", - "bmFsX2ZpeGVkNjQYCCABKAYSGQoRb3B0aW9uYWxfc2ZpeGVkMzIYCSABKA8S", - "GQoRb3B0aW9uYWxfc2ZpeGVkNjQYCiABKBASFgoOb3B0aW9uYWxfZmxvYXQY", - "CyABKAISFwoPb3B0aW9uYWxfZG91YmxlGAwgASgBEhUKDW9wdGlvbmFsX2Jv", - "b2wYDSABKAgSFwoPb3B0aW9uYWxfc3RyaW5nGA4gASgJEhYKDm9wdGlvbmFs", - "X2J5dGVzGA8gASgMElwKF29wdGlvbmFsX25lc3RlZF9tZXNzYWdlGBIgASgL", - "MjsucHJvdG8yX25vZmllbGRwcmVzZW5jZV91bml0dGVzdC5UZXN0QWxsVHlw", - "ZXMuTmVzdGVkTWVzc2FnZRJRChhvcHRpb25hbF9mb3JlaWduX21lc3NhZ2UY", - "EyABKAsyLy5wcm90bzJfbm9maWVsZHByZXNlbmNlX3VuaXR0ZXN0LkZvcmVp", - "Z25NZXNzYWdlEkAKF29wdGlvbmFsX3Byb3RvMl9tZXNzYWdlGBQgASgLMh8u", - "cHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzElYKFG9wdGlvbmFsX25l", - "c3RlZF9lbnVtGBUgASgOMjgucHJvdG8yX25vZmllbGRwcmVzZW5jZV91bml0", - "dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkRW51bRJLChVvcHRpb25hbF9mb3Jl", - "aWduX2VudW0YFiABKA4yLC5wcm90bzJfbm9maWVsZHByZXNlbmNlX3VuaXR0", - "ZXN0LkZvcmVpZ25FbnVtEiEKFW9wdGlvbmFsX3N0cmluZ19waWVjZRgYIAEo", - "CUICCAISGQoNb3B0aW9uYWxfY29yZBgZIAEoCUICCAESXgoVb3B0aW9uYWxf", - "bGF6eV9tZXNzYWdlGB4gASgLMjsucHJvdG8yX25vZmllbGRwcmVzZW5jZV91", - "bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkTWVzc2FnZUICKAESFgoOcmVw", - "ZWF0ZWRfaW50MzIYHyADKAUSFgoOcmVwZWF0ZWRfaW50NjQYICADKAMSFwoP", - "cmVwZWF0ZWRfdWludDMyGCEgAygNEhcKD3JlcGVhdGVkX3VpbnQ2NBgiIAMo", - "BBIXCg9yZXBlYXRlZF9zaW50MzIYIyADKBESFwoPcmVwZWF0ZWRfc2ludDY0", - "GCQgAygSEhgKEHJlcGVhdGVkX2ZpeGVkMzIYJSADKAcSGAoQcmVwZWF0ZWRf", - "Zml4ZWQ2NBgmIAMoBhIZChFyZXBlYXRlZF9zZml4ZWQzMhgnIAMoDxIZChFy", - "ZXBlYXRlZF9zZml4ZWQ2NBgoIAMoEBIWCg5yZXBlYXRlZF9mbG9hdBgpIAMo", - "AhIXCg9yZXBlYXRlZF9kb3VibGUYKiADKAESFQoNcmVwZWF0ZWRfYm9vbBgr", - "IAMoCBIXCg9yZXBlYXRlZF9zdHJpbmcYLCADKAkSFgoOcmVwZWF0ZWRfYnl0", - "ZXMYLSADKAwSXAoXcmVwZWF0ZWRfbmVzdGVkX21lc3NhZ2UYMCADKAsyOy5w", - "cm90bzJfbm9maWVsZHByZXNlbmNlX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5O", - "ZXN0ZWRNZXNzYWdlElEKGHJlcGVhdGVkX2ZvcmVpZ25fbWVzc2FnZRgxIAMo", - "CzIvLnByb3RvMl9ub2ZpZWxkcHJlc2VuY2VfdW5pdHRlc3QuRm9yZWlnbk1l", - "c3NhZ2USQAoXcmVwZWF0ZWRfcHJvdG8yX21lc3NhZ2UYMiADKAsyHy5wcm90", - "b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMSVgoUcmVwZWF0ZWRfbmVzdGVk", - "X2VudW0YMyADKA4yOC5wcm90bzJfbm9maWVsZHByZXNlbmNlX3VuaXR0ZXN0", - "LlRlc3RBbGxUeXBlcy5OZXN0ZWRFbnVtEksKFXJlcGVhdGVkX2ZvcmVpZ25f", - "ZW51bRg0IAMoDjIsLnByb3RvMl9ub2ZpZWxkcHJlc2VuY2VfdW5pdHRlc3Qu", - "Rm9yZWlnbkVudW0SIQoVcmVwZWF0ZWRfc3RyaW5nX3BpZWNlGDYgAygJQgII", - "AhIZCg1yZXBlYXRlZF9jb3JkGDcgAygJQgIIARJeChVyZXBlYXRlZF9sYXp5", - "X21lc3NhZ2UYOSADKAsyOy5wcm90bzJfbm9maWVsZHByZXNlbmNlX3VuaXR0", - "ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdlQgIoARIWCgxvbmVvZl91", - "aW50MzIYbyABKA1IABJbChRvbmVvZl9uZXN0ZWRfbWVzc2FnZRhwIAEoCzI7", - "LnByb3RvMl9ub2ZpZWxkcHJlc2VuY2VfdW5pdHRlc3QuVGVzdEFsbFR5cGVz", - "Lk5lc3RlZE1lc3NhZ2VIABIWCgxvbmVvZl9zdHJpbmcYcSABKAlIABJOCgpv", - "bmVvZl9lbnVtGHIgASgOMjgucHJvdG8yX25vZmllbGRwcmVzZW5jZV91bml0", - "dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkRW51bUgAGhsKDU5lc3RlZE1lc3Nh", - "Z2USCgoCYmIYASABKAUiJwoKTmVzdGVkRW51bRIHCgNGT08QABIHCgNCQVIQ", - "ARIHCgNCQVoQAkINCgtvbmVvZl9maWVsZCJFChJUZXN0UHJvdG8yUmVxdWly", - "ZWQSLwoGcHJvdG8yGAEgASgLMh8ucHJvdG9idWZfdW5pdHRlc3QuVGVzdFJl", - "cXVpcmVkIhsKDkZvcmVpZ25NZXNzYWdlEgkKAWMYASABKAUqQAoLRm9yZWln", - "bkVudW0SDwoLRk9SRUlHTl9GT08QABIPCgtGT1JFSUdOX0JBUhABEg8KC0ZP", - "UkVJR05fQkFaEAJCJKoCIUdvb2dsZS5Qcm90b2NvbEJ1ZmZlcnMuVGVzdFBy", - "b3Rvc2IGcHJvdG8z")); - pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { - descriptor = root; - internal__static_proto2_nofieldpresence_unittest_TestAllTypes__Descriptor = Descriptor.MessageTypes[0]; - internal__static_proto2_nofieldpresence_unittest_TestAllTypes__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_proto2_nofieldpresence_unittest_TestAllTypes__Descriptor, - new string[] { "OptionalInt32", "OptionalInt64", "OptionalUint32", "OptionalUint64", "OptionalSint32", "OptionalSint64", "OptionalFixed32", "OptionalFixed64", "OptionalSfixed32", "OptionalSfixed64", "OptionalFloat", "OptionalDouble", "OptionalBool", "OptionalString", "OptionalBytes", "OptionalNestedMessage", "OptionalForeignMessage", "OptionalProto2Message", "OptionalNestedEnum", "OptionalForeignEnum", "OptionalStringPiece", "OptionalCord", "OptionalLazyMessage", "RepeatedInt32", "RepeatedInt64", "RepeatedUint32", "RepeatedUint64", "RepeatedSint32", "RepeatedSint64", "RepeatedFixed32", "RepeatedFixed64", "RepeatedSfixed32", "RepeatedSfixed64", "RepeatedFloat", "RepeatedDouble", "RepeatedBool", "RepeatedString", "RepeatedBytes", "RepeatedNestedMessage", "RepeatedForeignMessage", "RepeatedProto2Message", "RepeatedNestedEnum", "RepeatedForeignEnum", "RepeatedStringPiece", "RepeatedCord", "RepeatedLazyMessage", "OneofUint32", "OneofNestedMessage", "OneofString", "OneofEnum", }); - internal__static_proto2_nofieldpresence_unittest_TestAllTypes_NestedMessage__Descriptor = internal__static_proto2_nofieldpresence_unittest_TestAllTypes__Descriptor.NestedTypes[0]; - internal__static_proto2_nofieldpresence_unittest_TestAllTypes_NestedMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_proto2_nofieldpresence_unittest_TestAllTypes_NestedMessage__Descriptor, - new string[] { "Bb", }); - internal__static_proto2_nofieldpresence_unittest_TestProto2Required__Descriptor = Descriptor.MessageTypes[1]; - internal__static_proto2_nofieldpresence_unittest_TestProto2Required__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_proto2_nofieldpresence_unittest_TestProto2Required__Descriptor, - new string[] { "Proto2", }); - internal__static_proto2_nofieldpresence_unittest_ForeignMessage__Descriptor = Descriptor.MessageTypes[2]; - internal__static_proto2_nofieldpresence_unittest_ForeignMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_proto2_nofieldpresence_unittest_ForeignMessage__Descriptor, - new string[] { "C", }); - pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); - RegisterAllExtensions(registry); - global::Google.ProtocolBuffers.TestProtos.Unittest.RegisterAllExtensions(registry); - return registry; - }; - pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, - new pbd::FileDescriptor[] { - global::Google.ProtocolBuffers.TestProtos.Unittest.Descriptor, - }, assigner); - } - #endregion - - } - #region Enums - public enum ForeignEnum { - FOREIGN_FOO = 0, - FOREIGN_BAR = 1, - FOREIGN_BAZ = 2, - } - - #endregion - - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestAllTypes : pb::GeneratedMessage { - private TestAllTypes() { } - private static readonly TestAllTypes defaultInstance = new TestAllTypes().MakeReadOnly(); - private static readonly string[] _testAllTypesFieldNames = new string[] { "oneof_enum", "oneof_nested_message", "oneof_string", "oneof_uint32", "optional_bool", "optional_bytes", "optional_cord", "optional_double", "optional_fixed32", "optional_fixed64", "optional_float", "optional_foreign_enum", "optional_foreign_message", "optional_int32", "optional_int64", "optional_lazy_message", "optional_nested_enum", "optional_nested_message", "optional_proto2_message", "optional_sfixed32", "optional_sfixed64", "optional_sint32", "optional_sint64", "optional_string", "optional_string_piece", "optional_uint32", "optional_uint64", "repeated_bool", "repeated_bytes", "repeated_cord", "repeated_double", "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_foreign_enum", "repeated_foreign_message", "repeated_int32", "repeated_int64", "repeated_lazy_message", "repeated_nested_enum", "repeated_nested_message", "repeated_proto2_message", "repeated_sfixed32", "repeated_sfixed64", "repeated_sint32", "repeated_sint64", "repeated_string", "repeated_string_piece", "repeated_uint32", "repeated_uint64" }; - private static readonly uint[] _testAllTypesFieldTags = new uint[] { 912, 898, 906, 888, 104, 122, 202, 97, 61, 65, 93, 176, 154, 8, 16, 242, 168, 146, 162, 77, 81, 40, 48, 114, 194, 24, 32, 344, 362, 442, 337, 301, 305, 333, 416, 394, 248, 256, 458, 408, 386, 402, 317, 321, 280, 288, 354, 434, 264, 272 }; - public static TestAllTypes DefaultInstance { - get { return defaultInstance; } - } - - public override TestAllTypes DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestAllTypes ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.internal__static_proto2_nofieldpresence_unittest_TestAllTypes__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.internal__static_proto2_nofieldpresence_unittest_TestAllTypes__FieldAccessorTable; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - public enum NestedEnum { - FOO = 0, - BAR = 1, - BAZ = 2, - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NestedMessage : pb::GeneratedMessage { - private NestedMessage() { } - private static readonly NestedMessage defaultInstance = new NestedMessage().MakeReadOnly(); - private static readonly string[] _nestedMessageFieldNames = new string[] { "bb" }; - private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8 }; - public static NestedMessage DefaultInstance { - get { return defaultInstance; } - } - - public override NestedMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override NestedMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.internal__static_proto2_nofieldpresence_unittest_TestAllTypes_NestedMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.internal__static_proto2_nofieldpresence_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; } - } - - public const int BbFieldNumber = 1; - private bool hasBb; - private int bb_; - public bool HasBb { - get { return hasBb; } - } - public int Bb { - get { return bb_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _nestedMessageFieldNames; - if (hasBb) { - output.WriteInt32(1, field_names[0], Bb); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasBb) { - size += pb::CodedOutputStream.ComputeInt32Size(1, Bb); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static NestedMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NestedMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NestedMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NestedMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NestedMessage result; - - private NestedMessage PrepareBuilder() { - if (resultIsReadOnly) { - NestedMessage original = result; - result = new NestedMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NestedMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Descriptor; } - } - - public override NestedMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } - - public override NestedMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is NestedMessage) { - return MergeFrom((NestedMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(NestedMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasBb) { - Bb = other.Bb; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _nestedMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasBb = input.ReadInt32(ref result.bb_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasBb { - get { return result.hasBb; } - } - public int Bb { - get { return result.Bb; } - set { SetBb(value); } - } - public Builder SetBb(int value) { - PrepareBuilder(); - result.hasBb = true; - result.bb_ = value; - return this; - } - public Builder ClearBb() { - PrepareBuilder(); - result.hasBb = false; - result.bb_ = 0; - return this; - } - } - static NestedMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.Descriptor, null); - } - } - - } - #endregion - - public const int OptionalInt32FieldNumber = 1; - private bool hasOptionalInt32; - private int optionalInt32_; - public bool HasOptionalInt32 { - get { return hasOptionalInt32; } - } - public int OptionalInt32 { - get { return optionalInt32_; } - } - - public const int OptionalInt64FieldNumber = 2; - private bool hasOptionalInt64; - private long optionalInt64_; - public bool HasOptionalInt64 { - get { return hasOptionalInt64; } - } - public long OptionalInt64 { - get { return optionalInt64_; } - } - - public const int OptionalUint32FieldNumber = 3; - private bool hasOptionalUint32; - private uint optionalUint32_; - public bool HasOptionalUint32 { - get { return hasOptionalUint32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalUint32 { - get { return optionalUint32_; } - } - - public const int OptionalUint64FieldNumber = 4; - private bool hasOptionalUint64; - private ulong optionalUint64_; - public bool HasOptionalUint64 { - get { return hasOptionalUint64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalUint64 { - get { return optionalUint64_; } - } - - public const int OptionalSint32FieldNumber = 5; - private bool hasOptionalSint32; - private int optionalSint32_; - public bool HasOptionalSint32 { - get { return hasOptionalSint32; } - } - public int OptionalSint32 { - get { return optionalSint32_; } - } - - public const int OptionalSint64FieldNumber = 6; - private bool hasOptionalSint64; - private long optionalSint64_; - public bool HasOptionalSint64 { - get { return hasOptionalSint64; } - } - public long OptionalSint64 { - get { return optionalSint64_; } - } - - public const int OptionalFixed32FieldNumber = 7; - private bool hasOptionalFixed32; - private uint optionalFixed32_; - public bool HasOptionalFixed32 { - get { return hasOptionalFixed32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalFixed32 { - get { return optionalFixed32_; } - } - - public const int OptionalFixed64FieldNumber = 8; - private bool hasOptionalFixed64; - private ulong optionalFixed64_; - public bool HasOptionalFixed64 { - get { return hasOptionalFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalFixed64 { - get { return optionalFixed64_; } - } - - public const int OptionalSfixed32FieldNumber = 9; - private bool hasOptionalSfixed32; - private int optionalSfixed32_; - public bool HasOptionalSfixed32 { - get { return hasOptionalSfixed32; } - } - public int OptionalSfixed32 { - get { return optionalSfixed32_; } - } - - public const int OptionalSfixed64FieldNumber = 10; - private bool hasOptionalSfixed64; - private long optionalSfixed64_; - public bool HasOptionalSfixed64 { - get { return hasOptionalSfixed64; } - } - public long OptionalSfixed64 { - get { return optionalSfixed64_; } - } - - public const int OptionalFloatFieldNumber = 11; - private bool hasOptionalFloat; - private float optionalFloat_; - public bool HasOptionalFloat { - get { return hasOptionalFloat; } - } - public float OptionalFloat { - get { return optionalFloat_; } - } - - public const int OptionalDoubleFieldNumber = 12; - private bool hasOptionalDouble; - private double optionalDouble_; - public bool HasOptionalDouble { - get { return hasOptionalDouble; } - } - public double OptionalDouble { - get { return optionalDouble_; } - } - - public const int OptionalBoolFieldNumber = 13; - private bool hasOptionalBool; - private bool optionalBool_; - public bool HasOptionalBool { - get { return hasOptionalBool; } - } - public bool OptionalBool { - get { return optionalBool_; } - } - - public const int OptionalStringFieldNumber = 14; - private bool hasOptionalString; - private string optionalString_ = ""; - public bool HasOptionalString { - get { return hasOptionalString; } - } - public string OptionalString { - get { return optionalString_; } - } - - public const int OptionalBytesFieldNumber = 15; - private bool hasOptionalBytes; - private pb::ByteString optionalBytes_ = pb::ByteString.Empty; - public bool HasOptionalBytes { - get { return hasOptionalBytes; } - } - public pb::ByteString OptionalBytes { - get { return optionalBytes_; } - } - - public const int OptionalNestedMessageFieldNumber = 18; - private bool hasOptionalNestedMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage optionalNestedMessage_; - public bool HasOptionalNestedMessage { - get { return hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage { - get { return optionalNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } - - public const int OptionalForeignMessageFieldNumber = 19; - private bool hasOptionalForeignMessage; - private global::Google.ProtocolBuffers.TestProtos.ForeignMessage optionalForeignMessage_; - public bool HasOptionalForeignMessage { - get { return hasOptionalForeignMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage { - get { return optionalForeignMessage_ ?? global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } - } - - public const int OptionalProto2MessageFieldNumber = 20; - private bool hasOptionalProto2Message; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes optionalProto2Message_; - public bool HasOptionalProto2Message { - get { return hasOptionalProto2Message; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalProto2Message { - get { return optionalProto2Message_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } - - public const int OptionalNestedEnumFieldNumber = 21; - private bool hasOptionalNestedEnum; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; - public bool HasOptionalNestedEnum { - get { return hasOptionalNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum { - get { return optionalNestedEnum_; } - } - - public const int OptionalForeignEnumFieldNumber = 22; - private bool hasOptionalForeignEnum; - private global::Google.ProtocolBuffers.TestProtos.ForeignEnum optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - public bool HasOptionalForeignEnum { - get { return hasOptionalForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum { - get { return optionalForeignEnum_; } - } - - public const int OptionalStringPieceFieldNumber = 24; - private bool hasOptionalStringPiece; - private string optionalStringPiece_ = ""; - public bool HasOptionalStringPiece { - get { return hasOptionalStringPiece; } - } - public string OptionalStringPiece { - get { return optionalStringPiece_; } - } - - public const int OptionalCordFieldNumber = 25; - private bool hasOptionalCord; - private string optionalCord_ = ""; - public bool HasOptionalCord { - get { return hasOptionalCord; } - } - public string OptionalCord { - get { return optionalCord_; } - } - - public const int OptionalLazyMessageFieldNumber = 30; - private bool hasOptionalLazyMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage optionalLazyMessage_; - public bool HasOptionalLazyMessage { - get { return hasOptionalLazyMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalLazyMessage { - get { return optionalLazyMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } - - public const int RepeatedInt32FieldNumber = 31; - private pbc::PopsicleList repeatedInt32_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt32List { - get { return pbc::Lists.AsReadOnly(repeatedInt32_); } - } - public int RepeatedInt32Count { - get { return repeatedInt32_.Count; } - } - public int GetRepeatedInt32(int index) { - return repeatedInt32_[index]; - } - - public const int RepeatedInt64FieldNumber = 32; - private pbc::PopsicleList repeatedInt64_ = new pbc::PopsicleList(); - public scg::IList RepeatedInt64List { - get { return pbc::Lists.AsReadOnly(repeatedInt64_); } - } - public int RepeatedInt64Count { - get { return repeatedInt64_.Count; } - } - public long GetRepeatedInt64(int index) { - return repeatedInt64_[index]; - } - - public const int RepeatedUint32FieldNumber = 33; - private pbc::PopsicleList repeatedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedUint32List { - get { return pbc::Lists.AsReadOnly(repeatedUint32_); } - } - public int RepeatedUint32Count { - get { return repeatedUint32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedUint32(int index) { - return repeatedUint32_[index]; - } - - public const int RepeatedUint64FieldNumber = 34; - private pbc::PopsicleList repeatedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedUint64List { - get { return pbc::Lists.AsReadOnly(repeatedUint64_); } - } - public int RepeatedUint64Count { - get { return repeatedUint64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return repeatedUint64_[index]; - } - - public const int RepeatedSint32FieldNumber = 35; - private pbc::PopsicleList repeatedSint32_ = new pbc::PopsicleList(); - public scg::IList RepeatedSint32List { - get { return pbc::Lists.AsReadOnly(repeatedSint32_); } - } - public int RepeatedSint32Count { - get { return repeatedSint32_.Count; } - } - public int GetRepeatedSint32(int index) { - return repeatedSint32_[index]; - } - - public const int RepeatedSint64FieldNumber = 36; - private pbc::PopsicleList repeatedSint64_ = new pbc::PopsicleList(); - public scg::IList RepeatedSint64List { - get { return pbc::Lists.AsReadOnly(repeatedSint64_); } - } - public int RepeatedSint64Count { - get { return repeatedSint64_.Count; } - } - public long GetRepeatedSint64(int index) { - return repeatedSint64_[index]; - } - - public const int RepeatedFixed32FieldNumber = 37; - private pbc::PopsicleList repeatedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed32List { - get { return pbc::Lists.AsReadOnly(repeatedFixed32_); } - } - public int RepeatedFixed32Count { - get { return repeatedFixed32_.Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return repeatedFixed32_[index]; - } - - public const int RepeatedFixed64FieldNumber = 38; - private pbc::PopsicleList repeatedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] - public scg::IList RepeatedFixed64List { - get { return pbc::Lists.AsReadOnly(repeatedFixed64_); } - } - public int RepeatedFixed64Count { - get { return repeatedFixed64_.Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return repeatedFixed64_[index]; - } - - public const int RepeatedSfixed32FieldNumber = 39; - private pbc::PopsicleList repeatedSfixed32_ = new pbc::PopsicleList(); - public scg::IList RepeatedSfixed32List { - get { return pbc::Lists.AsReadOnly(repeatedSfixed32_); } - } - public int RepeatedSfixed32Count { - get { return repeatedSfixed32_.Count; } - } - public int GetRepeatedSfixed32(int index) { - return repeatedSfixed32_[index]; - } - - public const int RepeatedSfixed64FieldNumber = 40; - private pbc::PopsicleList repeatedSfixed64_ = new pbc::PopsicleList(); - public scg::IList RepeatedSfixed64List { - get { return pbc::Lists.AsReadOnly(repeatedSfixed64_); } - } - public int RepeatedSfixed64Count { - get { return repeatedSfixed64_.Count; } - } - public long GetRepeatedSfixed64(int index) { - return repeatedSfixed64_[index]; - } - - public const int RepeatedFloatFieldNumber = 41; - private pbc::PopsicleList repeatedFloat_ = new pbc::PopsicleList(); - public scg::IList RepeatedFloatList { - get { return pbc::Lists.AsReadOnly(repeatedFloat_); } - } - public int RepeatedFloatCount { - get { return repeatedFloat_.Count; } - } - public float GetRepeatedFloat(int index) { - return repeatedFloat_[index]; - } - - public const int RepeatedDoubleFieldNumber = 42; - private pbc::PopsicleList repeatedDouble_ = new pbc::PopsicleList(); - public scg::IList RepeatedDoubleList { - get { return pbc::Lists.AsReadOnly(repeatedDouble_); } - } - public int RepeatedDoubleCount { - get { return repeatedDouble_.Count; } - } - public double GetRepeatedDouble(int index) { - return repeatedDouble_[index]; - } - - public const int RepeatedBoolFieldNumber = 43; - private pbc::PopsicleList repeatedBool_ = new pbc::PopsicleList(); - public scg::IList RepeatedBoolList { - get { return pbc::Lists.AsReadOnly(repeatedBool_); } - } - public int RepeatedBoolCount { - get { return repeatedBool_.Count; } - } - public bool GetRepeatedBool(int index) { - return repeatedBool_[index]; - } - - public const int RepeatedStringFieldNumber = 44; - private pbc::PopsicleList repeatedString_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringList { - get { return pbc::Lists.AsReadOnly(repeatedString_); } - } - public int RepeatedStringCount { - get { return repeatedString_.Count; } - } - public string GetRepeatedString(int index) { - return repeatedString_[index]; - } - - public const int RepeatedBytesFieldNumber = 45; - private pbc::PopsicleList repeatedBytes_ = new pbc::PopsicleList(); - public scg::IList RepeatedBytesList { - get { return pbc::Lists.AsReadOnly(repeatedBytes_); } - } - public int RepeatedBytesCount { - get { return repeatedBytes_.Count; } - } - public pb::ByteString GetRepeatedBytes(int index) { - return repeatedBytes_[index]; - } - - public const int RepeatedNestedMessageFieldNumber = 48; - private pbc::PopsicleList repeatedNestedMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedNestedMessageList { - get { return repeatedNestedMessage_; } - } - public int RepeatedNestedMessageCount { - get { return repeatedNestedMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) { - return repeatedNestedMessage_[index]; - } - - public const int RepeatedForeignMessageFieldNumber = 49; - private pbc::PopsicleList repeatedForeignMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedForeignMessageList { - get { return repeatedForeignMessage_; } - } - public int RepeatedForeignMessageCount { - get { return repeatedForeignMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) { - return repeatedForeignMessage_[index]; - } - - public const int RepeatedProto2MessageFieldNumber = 50; - private pbc::PopsicleList repeatedProto2Message_ = new pbc::PopsicleList(); - public scg::IList RepeatedProto2MessageList { - get { return repeatedProto2Message_; } - } - public int RepeatedProto2MessageCount { - get { return repeatedProto2Message_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetRepeatedProto2Message(int index) { - return repeatedProto2Message_[index]; - } - - public const int RepeatedNestedEnumFieldNumber = 51; - private pbc::PopsicleList repeatedNestedEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedNestedEnumList { - get { return pbc::Lists.AsReadOnly(repeatedNestedEnum_); } - } - public int RepeatedNestedEnumCount { - get { return repeatedNestedEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) { - return repeatedNestedEnum_[index]; - } - - public const int RepeatedForeignEnumFieldNumber = 52; - private pbc::PopsicleList repeatedForeignEnum_ = new pbc::PopsicleList(); - public scg::IList RepeatedForeignEnumList { - get { return pbc::Lists.AsReadOnly(repeatedForeignEnum_); } - } - public int RepeatedForeignEnumCount { - get { return repeatedForeignEnum_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) { - return repeatedForeignEnum_[index]; - } - - public const int RepeatedStringPieceFieldNumber = 54; - private pbc::PopsicleList repeatedStringPiece_ = new pbc::PopsicleList(); - public scg::IList RepeatedStringPieceList { - get { return pbc::Lists.AsReadOnly(repeatedStringPiece_); } - } - public int RepeatedStringPieceCount { - get { return repeatedStringPiece_.Count; } - } - public string GetRepeatedStringPiece(int index) { - return repeatedStringPiece_[index]; - } - - public const int RepeatedCordFieldNumber = 55; - private pbc::PopsicleList repeatedCord_ = new pbc::PopsicleList(); - public scg::IList RepeatedCordList { - get { return pbc::Lists.AsReadOnly(repeatedCord_); } - } - public int RepeatedCordCount { - get { return repeatedCord_.Count; } - } - public string GetRepeatedCord(int index) { - return repeatedCord_[index]; - } - - public const int RepeatedLazyMessageFieldNumber = 57; - private pbc::PopsicleList repeatedLazyMessage_ = new pbc::PopsicleList(); - public scg::IList RepeatedLazyMessageList { - get { return repeatedLazyMessage_; } - } - public int RepeatedLazyMessageCount { - get { return repeatedLazyMessage_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedLazyMessage(int index) { - return repeatedLazyMessage_[index]; - } - - public const int OneofUint32FieldNumber = 111; - private bool hasOneofUint32; - private uint oneofUint32_; - public bool HasOneofUint32 { - get { return hasOneofUint32; } - } - [global::System.CLSCompliant(false)] - public uint OneofUint32 { - get { return oneofUint32_; } - } - - public const int OneofNestedMessageFieldNumber = 112; - private bool hasOneofNestedMessage; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage oneofNestedMessage_; - public bool HasOneofNestedMessage { - get { return hasOneofNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OneofNestedMessage { - get { return oneofNestedMessage_ ?? global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; } - } - - public const int OneofStringFieldNumber = 113; - private bool hasOneofString; - private string oneofString_ = ""; - public bool HasOneofString { - get { return hasOneofString; } - } - public string OneofString { - get { return oneofString_; } - } - - public const int OneofEnumFieldNumber = 114; - private bool hasOneofEnum; - private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum oneofEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; - public bool HasOneofEnum { - get { return hasOneofEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OneofEnum { - get { return oneofEnum_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testAllTypesFieldNames; - if (hasOptionalInt32) { - output.WriteInt32(1, field_names[13], OptionalInt32); - } - if (hasOptionalInt64) { - output.WriteInt64(2, field_names[14], OptionalInt64); - } - if (hasOptionalUint32) { - output.WriteUInt32(3, field_names[25], OptionalUint32); - } - if (hasOptionalUint64) { - output.WriteUInt64(4, field_names[26], OptionalUint64); - } - if (hasOptionalSint32) { - output.WriteSInt32(5, field_names[21], OptionalSint32); - } - if (hasOptionalSint64) { - output.WriteSInt64(6, field_names[22], OptionalSint64); - } - if (hasOptionalFixed32) { - output.WriteFixed32(7, field_names[8], OptionalFixed32); - } - if (hasOptionalFixed64) { - output.WriteFixed64(8, field_names[9], OptionalFixed64); - } - if (hasOptionalSfixed32) { - output.WriteSFixed32(9, field_names[19], OptionalSfixed32); - } - if (hasOptionalSfixed64) { - output.WriteSFixed64(10, field_names[20], OptionalSfixed64); - } - if (hasOptionalFloat) { - output.WriteFloat(11, field_names[10], OptionalFloat); - } - if (hasOptionalDouble) { - output.WriteDouble(12, field_names[7], OptionalDouble); - } - if (hasOptionalBool) { - output.WriteBool(13, field_names[4], OptionalBool); - } - if (hasOptionalString) { - output.WriteString(14, field_names[23], OptionalString); - } - if (hasOptionalBytes) { - output.WriteBytes(15, field_names[5], OptionalBytes); - } - if (hasOptionalNestedMessage) { - output.WriteMessage(18, field_names[17], OptionalNestedMessage); - } - if (hasOptionalForeignMessage) { - output.WriteMessage(19, field_names[12], OptionalForeignMessage); - } - if (hasOptionalProto2Message) { - output.WriteMessage(20, field_names[18], OptionalProto2Message); - } - if (hasOptionalNestedEnum) { - output.WriteEnum(21, field_names[16], (int) OptionalNestedEnum, OptionalNestedEnum); - } - if (hasOptionalForeignEnum) { - output.WriteEnum(22, field_names[11], (int) OptionalForeignEnum, OptionalForeignEnum); - } - if (hasOptionalStringPiece) { - output.WriteString(24, field_names[24], OptionalStringPiece); - } - if (hasOptionalCord) { - output.WriteString(25, field_names[6], OptionalCord); - } - if (hasOptionalLazyMessage) { - output.WriteMessage(30, field_names[15], OptionalLazyMessage); - } - if (repeatedInt32_.Count > 0) { - output.WriteInt32Array(31, field_names[36], repeatedInt32_); - } - if (repeatedInt64_.Count > 0) { - output.WriteInt64Array(32, field_names[37], repeatedInt64_); - } - if (repeatedUint32_.Count > 0) { - output.WriteUInt32Array(33, field_names[48], repeatedUint32_); - } - if (repeatedUint64_.Count > 0) { - output.WriteUInt64Array(34, field_names[49], repeatedUint64_); - } - if (repeatedSint32_.Count > 0) { - output.WriteSInt32Array(35, field_names[44], repeatedSint32_); - } - if (repeatedSint64_.Count > 0) { - output.WriteSInt64Array(36, field_names[45], repeatedSint64_); - } - if (repeatedFixed32_.Count > 0) { - output.WriteFixed32Array(37, field_names[31], repeatedFixed32_); - } - if (repeatedFixed64_.Count > 0) { - output.WriteFixed64Array(38, field_names[32], repeatedFixed64_); - } - if (repeatedSfixed32_.Count > 0) { - output.WriteSFixed32Array(39, field_names[42], repeatedSfixed32_); - } - if (repeatedSfixed64_.Count > 0) { - output.WriteSFixed64Array(40, field_names[43], repeatedSfixed64_); - } - if (repeatedFloat_.Count > 0) { - output.WriteFloatArray(41, field_names[33], repeatedFloat_); - } - if (repeatedDouble_.Count > 0) { - output.WriteDoubleArray(42, field_names[30], repeatedDouble_); - } - if (repeatedBool_.Count > 0) { - output.WriteBoolArray(43, field_names[27], repeatedBool_); - } - if (repeatedString_.Count > 0) { - output.WriteStringArray(44, field_names[46], repeatedString_); - } - if (repeatedBytes_.Count > 0) { - output.WriteBytesArray(45, field_names[28], repeatedBytes_); - } - if (repeatedNestedMessage_.Count > 0) { - output.WriteMessageArray(48, field_names[40], repeatedNestedMessage_); - } - if (repeatedForeignMessage_.Count > 0) { - output.WriteMessageArray(49, field_names[35], repeatedForeignMessage_); - } - if (repeatedProto2Message_.Count > 0) { - output.WriteMessageArray(50, field_names[41], repeatedProto2Message_); - } - if (repeatedNestedEnum_.Count > 0) { - output.WriteEnumArray(51, field_names[39], repeatedNestedEnum_); - } - if (repeatedForeignEnum_.Count > 0) { - output.WriteEnumArray(52, field_names[34], repeatedForeignEnum_); - } - if (repeatedStringPiece_.Count > 0) { - output.WriteStringArray(54, field_names[47], repeatedStringPiece_); - } - if (repeatedCord_.Count > 0) { - output.WriteStringArray(55, field_names[29], repeatedCord_); - } - if (repeatedLazyMessage_.Count > 0) { - output.WriteMessageArray(57, field_names[38], repeatedLazyMessage_); - } - if (hasOneofUint32) { - output.WriteUInt32(111, field_names[3], OneofUint32); - } - if (hasOneofNestedMessage) { - output.WriteMessage(112, field_names[1], OneofNestedMessage); - } - if (hasOneofString) { - output.WriteString(113, field_names[2], OneofString); - } - if (hasOneofEnum) { - output.WriteEnum(114, field_names[0], (int) OneofEnum, OneofEnum); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasOptionalInt32) { - size += pb::CodedOutputStream.ComputeInt32Size(1, OptionalInt32); - } - if (hasOptionalInt64) { - size += pb::CodedOutputStream.ComputeInt64Size(2, OptionalInt64); - } - if (hasOptionalUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(3, OptionalUint32); - } - if (hasOptionalUint64) { - size += pb::CodedOutputStream.ComputeUInt64Size(4, OptionalUint64); - } - if (hasOptionalSint32) { - size += pb::CodedOutputStream.ComputeSInt32Size(5, OptionalSint32); - } - if (hasOptionalSint64) { - size += pb::CodedOutputStream.ComputeSInt64Size(6, OptionalSint64); - } - if (hasOptionalFixed32) { - size += pb::CodedOutputStream.ComputeFixed32Size(7, OptionalFixed32); - } - if (hasOptionalFixed64) { - size += pb::CodedOutputStream.ComputeFixed64Size(8, OptionalFixed64); - } - if (hasOptionalSfixed32) { - size += pb::CodedOutputStream.ComputeSFixed32Size(9, OptionalSfixed32); - } - if (hasOptionalSfixed64) { - size += pb::CodedOutputStream.ComputeSFixed64Size(10, OptionalSfixed64); - } - if (hasOptionalFloat) { - size += pb::CodedOutputStream.ComputeFloatSize(11, OptionalFloat); - } - if (hasOptionalDouble) { - size += pb::CodedOutputStream.ComputeDoubleSize(12, OptionalDouble); - } - if (hasOptionalBool) { - size += pb::CodedOutputStream.ComputeBoolSize(13, OptionalBool); - } - if (hasOptionalString) { - size += pb::CodedOutputStream.ComputeStringSize(14, OptionalString); - } - if (hasOptionalBytes) { - size += pb::CodedOutputStream.ComputeBytesSize(15, OptionalBytes); - } - if (hasOptionalNestedMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(18, OptionalNestedMessage); - } - if (hasOptionalForeignMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(19, OptionalForeignMessage); - } - if (hasOptionalProto2Message) { - size += pb::CodedOutputStream.ComputeMessageSize(20, OptionalProto2Message); - } - if (hasOptionalNestedEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(21, (int) OptionalNestedEnum); - } - if (hasOptionalForeignEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(22, (int) OptionalForeignEnum); - } - if (hasOptionalStringPiece) { - size += pb::CodedOutputStream.ComputeStringSize(24, OptionalStringPiece); - } - if (hasOptionalCord) { - size += pb::CodedOutputStream.ComputeStringSize(25, OptionalCord); - } - if (hasOptionalLazyMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(30, OptionalLazyMessage); - } - { - int dataSize = 0; - foreach (int element in RepeatedInt32List) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedInt32_.Count; - } - { - int dataSize = 0; - foreach (long element in RepeatedInt64List) { - dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedInt64_.Count; - } - { - int dataSize = 0; - foreach (uint element in RepeatedUint32List) { - dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedUint32_.Count; - } - { - int dataSize = 0; - foreach (ulong element in RepeatedUint64List) { - dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedUint64_.Count; - } - { - int dataSize = 0; - foreach (int element in RepeatedSint32List) { - dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedSint32_.Count; - } - { - int dataSize = 0; - foreach (long element in RepeatedSint64List) { - dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedSint64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedFixed32_.Count; - size += dataSize; - size += 2 * repeatedFixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedFixed64_.Count; - size += dataSize; - size += 2 * repeatedFixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedSfixed32_.Count; - size += dataSize; - size += 2 * repeatedSfixed32_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedSfixed64_.Count; - size += dataSize; - size += 2 * repeatedSfixed64_.Count; - } - { - int dataSize = 0; - dataSize = 4 * repeatedFloat_.Count; - size += dataSize; - size += 2 * repeatedFloat_.Count; - } - { - int dataSize = 0; - dataSize = 8 * repeatedDouble_.Count; - size += dataSize; - size += 2 * repeatedDouble_.Count; - } - { - int dataSize = 0; - dataSize = 1 * repeatedBool_.Count; - size += dataSize; - size += 2 * repeatedBool_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedStringList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedString_.Count; - } - { - int dataSize = 0; - foreach (pb::ByteString element in RepeatedBytesList) { - dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedBytes_.Count; - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage element in RepeatedNestedMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(48, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedForeignMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(49, element); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes element in RepeatedProto2MessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(50, element); - } - { - int dataSize = 0; - if (repeatedNestedEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum element in repeatedNestedEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedNestedEnum_.Count; - } - } - { - int dataSize = 0; - if (repeatedForeignEnum_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedForeignEnum_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 2 * repeatedForeignEnum_.Count; - } - } - { - int dataSize = 0; - foreach (string element in RepeatedStringPieceList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedStringPiece_.Count; - } - { - int dataSize = 0; - foreach (string element in RepeatedCordList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * repeatedCord_.Count; - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage element in RepeatedLazyMessageList) { - size += pb::CodedOutputStream.ComputeMessageSize(57, element); - } - if (hasOneofUint32) { - size += pb::CodedOutputStream.ComputeUInt32Size(111, OneofUint32); - } - if (hasOneofNestedMessage) { - size += pb::CodedOutputStream.ComputeMessageSize(112, OneofNestedMessage); - } - if (hasOneofString) { - size += pb::CodedOutputStream.ComputeStringSize(113, OneofString); - } - if (hasOneofEnum) { - size += pb::CodedOutputStream.ComputeEnumSize(114, (int) OneofEnum); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestAllTypes ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllTypes ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestAllTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestAllTypes ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestAllTypes ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestAllTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestAllTypes MakeReadOnly() { - repeatedInt32_.MakeReadOnly(); - repeatedInt64_.MakeReadOnly(); - repeatedUint32_.MakeReadOnly(); - repeatedUint64_.MakeReadOnly(); - repeatedSint32_.MakeReadOnly(); - repeatedSint64_.MakeReadOnly(); - repeatedFixed32_.MakeReadOnly(); - repeatedFixed64_.MakeReadOnly(); - repeatedSfixed32_.MakeReadOnly(); - repeatedSfixed64_.MakeReadOnly(); - repeatedFloat_.MakeReadOnly(); - repeatedDouble_.MakeReadOnly(); - repeatedBool_.MakeReadOnly(); - repeatedString_.MakeReadOnly(); - repeatedBytes_.MakeReadOnly(); - repeatedNestedMessage_.MakeReadOnly(); - repeatedForeignMessage_.MakeReadOnly(); - repeatedProto2Message_.MakeReadOnly(); - repeatedNestedEnum_.MakeReadOnly(); - repeatedForeignEnum_.MakeReadOnly(); - repeatedStringPiece_.MakeReadOnly(); - repeatedCord_.MakeReadOnly(); - repeatedLazyMessage_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestAllTypes prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestAllTypes cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestAllTypes result; - - private TestAllTypes PrepareBuilder() { - if (resultIsReadOnly) { - TestAllTypes original = result; - result = new TestAllTypes(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestAllTypes MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor; } - } - - public override TestAllTypes DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; } - } - - public override TestAllTypes BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestAllTypes) { - return MergeFrom((TestAllTypes) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestAllTypes other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasOptionalInt32) { - OptionalInt32 = other.OptionalInt32; - } - if (other.HasOptionalInt64) { - OptionalInt64 = other.OptionalInt64; - } - if (other.HasOptionalUint32) { - OptionalUint32 = other.OptionalUint32; - } - if (other.HasOptionalUint64) { - OptionalUint64 = other.OptionalUint64; - } - if (other.HasOptionalSint32) { - OptionalSint32 = other.OptionalSint32; - } - if (other.HasOptionalSint64) { - OptionalSint64 = other.OptionalSint64; - } - if (other.HasOptionalFixed32) { - OptionalFixed32 = other.OptionalFixed32; - } - if (other.HasOptionalFixed64) { - OptionalFixed64 = other.OptionalFixed64; - } - if (other.HasOptionalSfixed32) { - OptionalSfixed32 = other.OptionalSfixed32; - } - if (other.HasOptionalSfixed64) { - OptionalSfixed64 = other.OptionalSfixed64; - } - if (other.HasOptionalFloat) { - OptionalFloat = other.OptionalFloat; - } - if (other.HasOptionalDouble) { - OptionalDouble = other.OptionalDouble; - } - if (other.HasOptionalBool) { - OptionalBool = other.OptionalBool; - } - if (other.HasOptionalString) { - OptionalString = other.OptionalString; - } - if (other.HasOptionalBytes) { - OptionalBytes = other.OptionalBytes; - } - if (other.HasOptionalNestedMessage) { - MergeOptionalNestedMessage(other.OptionalNestedMessage); - } - if (other.HasOptionalForeignMessage) { - MergeOptionalForeignMessage(other.OptionalForeignMessage); - } - if (other.HasOptionalProto2Message) { - MergeOptionalProto2Message(other.OptionalProto2Message); - } - if (other.HasOptionalNestedEnum) { - OptionalNestedEnum = other.OptionalNestedEnum; - } - if (other.HasOptionalForeignEnum) { - OptionalForeignEnum = other.OptionalForeignEnum; - } - if (other.HasOptionalStringPiece) { - OptionalStringPiece = other.OptionalStringPiece; - } - if (other.HasOptionalCord) { - OptionalCord = other.OptionalCord; - } - if (other.HasOptionalLazyMessage) { - MergeOptionalLazyMessage(other.OptionalLazyMessage); - } - if (other.repeatedInt32_.Count != 0) { - result.repeatedInt32_.Add(other.repeatedInt32_); - } - if (other.repeatedInt64_.Count != 0) { - result.repeatedInt64_.Add(other.repeatedInt64_); - } - if (other.repeatedUint32_.Count != 0) { - result.repeatedUint32_.Add(other.repeatedUint32_); - } - if (other.repeatedUint64_.Count != 0) { - result.repeatedUint64_.Add(other.repeatedUint64_); - } - if (other.repeatedSint32_.Count != 0) { - result.repeatedSint32_.Add(other.repeatedSint32_); - } - if (other.repeatedSint64_.Count != 0) { - result.repeatedSint64_.Add(other.repeatedSint64_); - } - if (other.repeatedFixed32_.Count != 0) { - result.repeatedFixed32_.Add(other.repeatedFixed32_); - } - if (other.repeatedFixed64_.Count != 0) { - result.repeatedFixed64_.Add(other.repeatedFixed64_); - } - if (other.repeatedSfixed32_.Count != 0) { - result.repeatedSfixed32_.Add(other.repeatedSfixed32_); - } - if (other.repeatedSfixed64_.Count != 0) { - result.repeatedSfixed64_.Add(other.repeatedSfixed64_); - } - if (other.repeatedFloat_.Count != 0) { - result.repeatedFloat_.Add(other.repeatedFloat_); - } - if (other.repeatedDouble_.Count != 0) { - result.repeatedDouble_.Add(other.repeatedDouble_); - } - if (other.repeatedBool_.Count != 0) { - result.repeatedBool_.Add(other.repeatedBool_); - } - if (other.repeatedString_.Count != 0) { - result.repeatedString_.Add(other.repeatedString_); - } - if (other.repeatedBytes_.Count != 0) { - result.repeatedBytes_.Add(other.repeatedBytes_); - } - if (other.repeatedNestedMessage_.Count != 0) { - result.repeatedNestedMessage_.Add(other.repeatedNestedMessage_); - } - if (other.repeatedForeignMessage_.Count != 0) { - result.repeatedForeignMessage_.Add(other.repeatedForeignMessage_); - } - if (other.repeatedProto2Message_.Count != 0) { - result.repeatedProto2Message_.Add(other.repeatedProto2Message_); - } - if (other.repeatedNestedEnum_.Count != 0) { - result.repeatedNestedEnum_.Add(other.repeatedNestedEnum_); - } - if (other.repeatedForeignEnum_.Count != 0) { - result.repeatedForeignEnum_.Add(other.repeatedForeignEnum_); - } - if (other.repeatedStringPiece_.Count != 0) { - result.repeatedStringPiece_.Add(other.repeatedStringPiece_); - } - if (other.repeatedCord_.Count != 0) { - result.repeatedCord_.Add(other.repeatedCord_); - } - if (other.repeatedLazyMessage_.Count != 0) { - result.repeatedLazyMessage_.Add(other.repeatedLazyMessage_); - } - if (other.HasOneofUint32) { - OneofUint32 = other.OneofUint32; - } - if (other.HasOneofNestedMessage) { - MergeOneofNestedMessage(other.OneofNestedMessage); - } - if (other.HasOneofString) { - OneofString = other.OneofString; - } - if (other.HasOneofEnum) { - OneofEnum = other.OneofEnum; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testAllTypesFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testAllTypesFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_); - break; - } - case 16: { - result.hasOptionalInt64 = input.ReadInt64(ref result.optionalInt64_); - break; - } - case 24: { - result.hasOptionalUint32 = input.ReadUInt32(ref result.optionalUint32_); - break; - } - case 32: { - result.hasOptionalUint64 = input.ReadUInt64(ref result.optionalUint64_); - break; - } - case 40: { - result.hasOptionalSint32 = input.ReadSInt32(ref result.optionalSint32_); - break; - } - case 48: { - result.hasOptionalSint64 = input.ReadSInt64(ref result.optionalSint64_); - break; - } - case 61: { - result.hasOptionalFixed32 = input.ReadFixed32(ref result.optionalFixed32_); - break; - } - case 65: { - result.hasOptionalFixed64 = input.ReadFixed64(ref result.optionalFixed64_); - break; - } - case 77: { - result.hasOptionalSfixed32 = input.ReadSFixed32(ref result.optionalSfixed32_); - break; - } - case 81: { - result.hasOptionalSfixed64 = input.ReadSFixed64(ref result.optionalSfixed64_); - break; - } - case 93: { - result.hasOptionalFloat = input.ReadFloat(ref result.optionalFloat_); - break; - } - case 97: { - result.hasOptionalDouble = input.ReadDouble(ref result.optionalDouble_); - break; - } - case 104: { - result.hasOptionalBool = input.ReadBool(ref result.optionalBool_); - break; - } - case 114: { - result.hasOptionalString = input.ReadString(ref result.optionalString_); - break; - } - case 122: { - result.hasOptionalBytes = input.ReadBytes(ref result.optionalBytes_); - break; - } - case 146: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); - if (result.hasOptionalNestedMessage) { - subBuilder.MergeFrom(OptionalNestedMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalNestedMessage = subBuilder.BuildPartial(); - break; - } - case 154: { - global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(); - if (result.hasOptionalForeignMessage) { - subBuilder.MergeFrom(OptionalForeignMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalForeignMessage = subBuilder.BuildPartial(); - break; - } - case 162: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(); - if (result.hasOptionalProto2Message) { - subBuilder.MergeFrom(OptionalProto2Message); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalProto2Message = subBuilder.BuildPartial(); - break; - } - case 168: { - object unknown; - if(input.ReadEnum(ref result.optionalNestedEnum_, out unknown)) { - result.hasOptionalNestedEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(21, (ulong)(int)unknown); - } - break; - } - case 176: { - object unknown; - if(input.ReadEnum(ref result.optionalForeignEnum_, out unknown)) { - result.hasOptionalForeignEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(22, (ulong)(int)unknown); - } - break; - } - case 194: { - result.hasOptionalStringPiece = input.ReadString(ref result.optionalStringPiece_); - break; - } - case 202: { - result.hasOptionalCord = input.ReadString(ref result.optionalCord_); - break; - } - case 242: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); - if (result.hasOptionalLazyMessage) { - subBuilder.MergeFrom(OptionalLazyMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OptionalLazyMessage = subBuilder.BuildPartial(); - break; - } - case 250: - case 248: { - input.ReadInt32Array(tag, field_name, result.repeatedInt32_); - break; - } - case 258: - case 256: { - input.ReadInt64Array(tag, field_name, result.repeatedInt64_); - break; - } - case 266: - case 264: { - input.ReadUInt32Array(tag, field_name, result.repeatedUint32_); - break; - } - case 274: - case 272: { - input.ReadUInt64Array(tag, field_name, result.repeatedUint64_); - break; - } - case 282: - case 280: { - input.ReadSInt32Array(tag, field_name, result.repeatedSint32_); - break; - } - case 290: - case 288: { - input.ReadSInt64Array(tag, field_name, result.repeatedSint64_); - break; - } - case 298: - case 301: { - input.ReadFixed32Array(tag, field_name, result.repeatedFixed32_); - break; - } - case 306: - case 305: { - input.ReadFixed64Array(tag, field_name, result.repeatedFixed64_); - break; - } - case 314: - case 317: { - input.ReadSFixed32Array(tag, field_name, result.repeatedSfixed32_); - break; - } - case 322: - case 321: { - input.ReadSFixed64Array(tag, field_name, result.repeatedSfixed64_); - break; - } - case 330: - case 333: { - input.ReadFloatArray(tag, field_name, result.repeatedFloat_); - break; - } - case 338: - case 337: { - input.ReadDoubleArray(tag, field_name, result.repeatedDouble_); - break; - } - case 346: - case 344: { - input.ReadBoolArray(tag, field_name, result.repeatedBool_); - break; - } - case 354: { - input.ReadStringArray(tag, field_name, result.repeatedString_); - break; - } - case 362: { - input.ReadBytesArray(tag, field_name, result.repeatedBytes_); - break; - } - case 386: { - input.ReadMessageArray(tag, field_name, result.repeatedNestedMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance, extensionRegistry); - break; - } - case 394: { - input.ReadMessageArray(tag, field_name, result.repeatedForeignMessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry); - break; - } - case 402: { - input.ReadMessageArray(tag, field_name, result.repeatedProto2Message_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance, extensionRegistry); - break; - } - case 410: - case 408: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedNestedEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(51, (ulong)(int)rawValue); - } - break; - } - case 418: - case 416: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedForeignEnum_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(52, (ulong)(int)rawValue); - } - break; - } - case 434: { - input.ReadStringArray(tag, field_name, result.repeatedStringPiece_); - break; - } - case 442: { - input.ReadStringArray(tag, field_name, result.repeatedCord_); - break; - } - case 458: { - input.ReadMessageArray(tag, field_name, result.repeatedLazyMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance, extensionRegistry); - break; - } - case 888: { - result.hasOneofUint32 = input.ReadUInt32(ref result.oneofUint32_); - break; - } - case 898: { - global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(); - if (result.hasOneofNestedMessage) { - subBuilder.MergeFrom(OneofNestedMessage); - } - input.ReadMessage(subBuilder, extensionRegistry); - OneofNestedMessage = subBuilder.BuildPartial(); - break; - } - case 906: { - result.hasOneofString = input.ReadString(ref result.oneofString_); - break; - } - case 912: { - object unknown; - if(input.ReadEnum(ref result.oneofEnum_, out unknown)) { - result.hasOneofEnum = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(114, (ulong)(int)unknown); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasOptionalInt32 { - get { return result.hasOptionalInt32; } - } - public int OptionalInt32 { - get { return result.OptionalInt32; } - set { SetOptionalInt32(value); } - } - public Builder SetOptionalInt32(int value) { - PrepareBuilder(); - result.hasOptionalInt32 = true; - result.optionalInt32_ = value; - return this; - } - public Builder ClearOptionalInt32() { - PrepareBuilder(); - result.hasOptionalInt32 = false; - result.optionalInt32_ = 0; - return this; - } - - public bool HasOptionalInt64 { - get { return result.hasOptionalInt64; } - } - public long OptionalInt64 { - get { return result.OptionalInt64; } - set { SetOptionalInt64(value); } - } - public Builder SetOptionalInt64(long value) { - PrepareBuilder(); - result.hasOptionalInt64 = true; - result.optionalInt64_ = value; - return this; - } - public Builder ClearOptionalInt64() { - PrepareBuilder(); - result.hasOptionalInt64 = false; - result.optionalInt64_ = 0L; - return this; - } - - public bool HasOptionalUint32 { - get { return result.hasOptionalUint32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalUint32 { - get { return result.OptionalUint32; } - set { SetOptionalUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalUint32(uint value) { - PrepareBuilder(); - result.hasOptionalUint32 = true; - result.optionalUint32_ = value; - return this; - } - public Builder ClearOptionalUint32() { - PrepareBuilder(); - result.hasOptionalUint32 = false; - result.optionalUint32_ = 0; - return this; - } - - public bool HasOptionalUint64 { - get { return result.hasOptionalUint64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalUint64 { - get { return result.OptionalUint64; } - set { SetOptionalUint64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalUint64(ulong value) { - PrepareBuilder(); - result.hasOptionalUint64 = true; - result.optionalUint64_ = value; - return this; - } - public Builder ClearOptionalUint64() { - PrepareBuilder(); - result.hasOptionalUint64 = false; - result.optionalUint64_ = 0UL; - return this; - } - - public bool HasOptionalSint32 { - get { return result.hasOptionalSint32; } - } - public int OptionalSint32 { - get { return result.OptionalSint32; } - set { SetOptionalSint32(value); } - } - public Builder SetOptionalSint32(int value) { - PrepareBuilder(); - result.hasOptionalSint32 = true; - result.optionalSint32_ = value; - return this; - } - public Builder ClearOptionalSint32() { - PrepareBuilder(); - result.hasOptionalSint32 = false; - result.optionalSint32_ = 0; - return this; - } - - public bool HasOptionalSint64 { - get { return result.hasOptionalSint64; } - } - public long OptionalSint64 { - get { return result.OptionalSint64; } - set { SetOptionalSint64(value); } - } - public Builder SetOptionalSint64(long value) { - PrepareBuilder(); - result.hasOptionalSint64 = true; - result.optionalSint64_ = value; - return this; - } - public Builder ClearOptionalSint64() { - PrepareBuilder(); - result.hasOptionalSint64 = false; - result.optionalSint64_ = 0L; - return this; - } - - public bool HasOptionalFixed32 { - get { return result.hasOptionalFixed32; } - } - [global::System.CLSCompliant(false)] - public uint OptionalFixed32 { - get { return result.OptionalFixed32; } - set { SetOptionalFixed32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalFixed32(uint value) { - PrepareBuilder(); - result.hasOptionalFixed32 = true; - result.optionalFixed32_ = value; - return this; - } - public Builder ClearOptionalFixed32() { - PrepareBuilder(); - result.hasOptionalFixed32 = false; - result.optionalFixed32_ = 0; - return this; - } - - public bool HasOptionalFixed64 { - get { return result.hasOptionalFixed64; } - } - [global::System.CLSCompliant(false)] - public ulong OptionalFixed64 { - get { return result.OptionalFixed64; } - set { SetOptionalFixed64(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOptionalFixed64(ulong value) { - PrepareBuilder(); - result.hasOptionalFixed64 = true; - result.optionalFixed64_ = value; - return this; - } - public Builder ClearOptionalFixed64() { - PrepareBuilder(); - result.hasOptionalFixed64 = false; - result.optionalFixed64_ = 0UL; - return this; - } - - public bool HasOptionalSfixed32 { - get { return result.hasOptionalSfixed32; } - } - public int OptionalSfixed32 { - get { return result.OptionalSfixed32; } - set { SetOptionalSfixed32(value); } - } - public Builder SetOptionalSfixed32(int value) { - PrepareBuilder(); - result.hasOptionalSfixed32 = true; - result.optionalSfixed32_ = value; - return this; - } - public Builder ClearOptionalSfixed32() { - PrepareBuilder(); - result.hasOptionalSfixed32 = false; - result.optionalSfixed32_ = 0; - return this; - } - - public bool HasOptionalSfixed64 { - get { return result.hasOptionalSfixed64; } - } - public long OptionalSfixed64 { - get { return result.OptionalSfixed64; } - set { SetOptionalSfixed64(value); } - } - public Builder SetOptionalSfixed64(long value) { - PrepareBuilder(); - result.hasOptionalSfixed64 = true; - result.optionalSfixed64_ = value; - return this; - } - public Builder ClearOptionalSfixed64() { - PrepareBuilder(); - result.hasOptionalSfixed64 = false; - result.optionalSfixed64_ = 0L; - return this; - } - - public bool HasOptionalFloat { - get { return result.hasOptionalFloat; } - } - public float OptionalFloat { - get { return result.OptionalFloat; } - set { SetOptionalFloat(value); } - } - public Builder SetOptionalFloat(float value) { - PrepareBuilder(); - result.hasOptionalFloat = true; - result.optionalFloat_ = value; - return this; - } - public Builder ClearOptionalFloat() { - PrepareBuilder(); - result.hasOptionalFloat = false; - result.optionalFloat_ = 0F; - return this; - } - - public bool HasOptionalDouble { - get { return result.hasOptionalDouble; } - } - public double OptionalDouble { - get { return result.OptionalDouble; } - set { SetOptionalDouble(value); } - } - public Builder SetOptionalDouble(double value) { - PrepareBuilder(); - result.hasOptionalDouble = true; - result.optionalDouble_ = value; - return this; - } - public Builder ClearOptionalDouble() { - PrepareBuilder(); - result.hasOptionalDouble = false; - result.optionalDouble_ = 0D; - return this; - } - - public bool HasOptionalBool { - get { return result.hasOptionalBool; } - } - public bool OptionalBool { - get { return result.OptionalBool; } - set { SetOptionalBool(value); } - } - public Builder SetOptionalBool(bool value) { - PrepareBuilder(); - result.hasOptionalBool = true; - result.optionalBool_ = value; - return this; - } - public Builder ClearOptionalBool() { - PrepareBuilder(); - result.hasOptionalBool = false; - result.optionalBool_ = false; - return this; - } - - public bool HasOptionalString { - get { return result.hasOptionalString; } - } - public string OptionalString { - get { return result.OptionalString; } - set { SetOptionalString(value); } - } - public Builder SetOptionalString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalString = true; - result.optionalString_ = value; - return this; - } - public Builder ClearOptionalString() { - PrepareBuilder(); - result.hasOptionalString = false; - result.optionalString_ = ""; - return this; - } - - public bool HasOptionalBytes { - get { return result.hasOptionalBytes; } - } - public pb::ByteString OptionalBytes { - get { return result.OptionalBytes; } - set { SetOptionalBytes(value); } - } - public Builder SetOptionalBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalBytes = true; - result.optionalBytes_ = value; - return this; - } - public Builder ClearOptionalBytes() { - PrepareBuilder(); - result.hasOptionalBytes = false; - result.optionalBytes_ = pb::ByteString.Empty; - return this; - } - - public bool HasOptionalNestedMessage { - get { return result.hasOptionalNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage { - get { return result.OptionalNestedMessage; } - set { SetOptionalNestedMessage(value); } - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = value; - return this; - } - public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalNestedMessage = true; - result.optionalNestedMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalNestedMessage && - result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { - result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalNestedMessage_ = value; - } - result.hasOptionalNestedMessage = true; - return this; - } - public Builder ClearOptionalNestedMessage() { - PrepareBuilder(); - result.hasOptionalNestedMessage = false; - result.optionalNestedMessage_ = null; - return this; - } - - public bool HasOptionalForeignMessage { - get { return result.hasOptionalForeignMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage { - get { return result.OptionalForeignMessage; } - set { SetOptionalForeignMessage(value); } - } - public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalForeignMessage = true; - result.optionalForeignMessage_ = value; - return this; - } - public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalForeignMessage = true; - result.optionalForeignMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalForeignMessage && - result.optionalForeignMessage_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) { - result.optionalForeignMessage_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.optionalForeignMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalForeignMessage_ = value; - } - result.hasOptionalForeignMessage = true; - return this; - } - public Builder ClearOptionalForeignMessage() { - PrepareBuilder(); - result.hasOptionalForeignMessage = false; - result.optionalForeignMessage_ = null; - return this; - } - - public bool HasOptionalProto2Message { - get { return result.hasOptionalProto2Message; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes OptionalProto2Message { - get { return result.OptionalProto2Message; } - set { SetOptionalProto2Message(value); } - } - public Builder SetOptionalProto2Message(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalProto2Message = true; - result.optionalProto2Message_ = value; - return this; - } - public Builder SetOptionalProto2Message(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalProto2Message = true; - result.optionalProto2Message_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalProto2Message(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalProto2Message && - result.optionalProto2Message_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) { - result.optionalProto2Message_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.CreateBuilder(result.optionalProto2Message_).MergeFrom(value).BuildPartial(); - } else { - result.optionalProto2Message_ = value; - } - result.hasOptionalProto2Message = true; - return this; - } - public Builder ClearOptionalProto2Message() { - PrepareBuilder(); - result.hasOptionalProto2Message = false; - result.optionalProto2Message_ = null; - return this; - } - - public bool HasOptionalNestedEnum { - get { return result.hasOptionalNestedEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum { - get { return result.OptionalNestedEnum; } - set { SetOptionalNestedEnum(value); } - } - public Builder SetOptionalNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.hasOptionalNestedEnum = true; - result.optionalNestedEnum_ = value; - return this; - } - public Builder ClearOptionalNestedEnum() { - PrepareBuilder(); - result.hasOptionalNestedEnum = false; - result.optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; - return this; - } - - public bool HasOptionalForeignEnum { - get { return result.hasOptionalForeignEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum { - get { return result.OptionalForeignEnum; } - set { SetOptionalForeignEnum(value); } - } - public Builder SetOptionalForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.hasOptionalForeignEnum = true; - result.optionalForeignEnum_ = value; - return this; - } - public Builder ClearOptionalForeignEnum() { - PrepareBuilder(); - result.hasOptionalForeignEnum = false; - result.optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO; - return this; - } - - public bool HasOptionalStringPiece { - get { return result.hasOptionalStringPiece; } - } - public string OptionalStringPiece { - get { return result.OptionalStringPiece; } - set { SetOptionalStringPiece(value); } - } - public Builder SetOptionalStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalStringPiece = true; - result.optionalStringPiece_ = value; - return this; - } - public Builder ClearOptionalStringPiece() { - PrepareBuilder(); - result.hasOptionalStringPiece = false; - result.optionalStringPiece_ = ""; - return this; - } - - public bool HasOptionalCord { - get { return result.hasOptionalCord; } - } - public string OptionalCord { - get { return result.OptionalCord; } - set { SetOptionalCord(value); } - } - public Builder SetOptionalCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalCord = true; - result.optionalCord_ = value; - return this; - } - public Builder ClearOptionalCord() { - PrepareBuilder(); - result.hasOptionalCord = false; - result.optionalCord_ = ""; - return this; - } - - public bool HasOptionalLazyMessage { - get { return result.hasOptionalLazyMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalLazyMessage { - get { return result.OptionalLazyMessage; } - set { SetOptionalLazyMessage(value); } - } - public Builder SetOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOptionalLazyMessage = true; - result.optionalLazyMessage_ = value; - return this; - } - public Builder SetOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOptionalLazyMessage = true; - result.optionalLazyMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOptionalLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOptionalLazyMessage && - result.optionalLazyMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { - result.optionalLazyMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.optionalLazyMessage_).MergeFrom(value).BuildPartial(); - } else { - result.optionalLazyMessage_ = value; - } - result.hasOptionalLazyMessage = true; - return this; - } - public Builder ClearOptionalLazyMessage() { - PrepareBuilder(); - result.hasOptionalLazyMessage = false; - result.optionalLazyMessage_ = null; - return this; - } - - public pbc::IPopsicleList RepeatedInt32List { - get { return PrepareBuilder().repeatedInt32_; } - } - public int RepeatedInt32Count { - get { return result.RepeatedInt32Count; } - } - public int GetRepeatedInt32(int index) { - return result.GetRepeatedInt32(index); - } - public Builder SetRepeatedInt32(int index, int value) { - PrepareBuilder(); - result.repeatedInt32_[index] = value; - return this; - } - public Builder AddRepeatedInt32(int value) { - PrepareBuilder(); - result.repeatedInt32_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt32_.Add(values); - return this; - } - public Builder ClearRepeatedInt32() { - PrepareBuilder(); - result.repeatedInt32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedInt64List { - get { return PrepareBuilder().repeatedInt64_; } - } - public int RepeatedInt64Count { - get { return result.RepeatedInt64Count; } - } - public long GetRepeatedInt64(int index) { - return result.GetRepeatedInt64(index); - } - public Builder SetRepeatedInt64(int index, long value) { - PrepareBuilder(); - result.repeatedInt64_[index] = value; - return this; - } - public Builder AddRepeatedInt64(long value) { - PrepareBuilder(); - result.repeatedInt64_.Add(value); - return this; - } - public Builder AddRangeRepeatedInt64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedInt64_.Add(values); - return this; - } - public Builder ClearRepeatedInt64() { - PrepareBuilder(); - result.repeatedInt64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedUint32List { - get { return PrepareBuilder().repeatedUint32_; } - } - public int RepeatedUint32Count { - get { return result.RepeatedUint32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedUint32(int index) { - return result.GetRepeatedUint32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedUint32(int index, uint value) { - PrepareBuilder(); - result.repeatedUint32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedUint32(uint value) { - PrepareBuilder(); - result.repeatedUint32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedUint32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedUint32_.Add(values); - return this; - } - public Builder ClearRepeatedUint32() { - PrepareBuilder(); - result.repeatedUint32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedUint64List { - get { return PrepareBuilder().repeatedUint64_; } - } - public int RepeatedUint64Count { - get { return result.RepeatedUint64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedUint64(int index) { - return result.GetRepeatedUint64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedUint64(int index, ulong value) { - PrepareBuilder(); - result.repeatedUint64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedUint64(ulong value) { - PrepareBuilder(); - result.repeatedUint64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedUint64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedUint64_.Add(values); - return this; - } - public Builder ClearRepeatedUint64() { - PrepareBuilder(); - result.repeatedUint64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSint32List { - get { return PrepareBuilder().repeatedSint32_; } - } - public int RepeatedSint32Count { - get { return result.RepeatedSint32Count; } - } - public int GetRepeatedSint32(int index) { - return result.GetRepeatedSint32(index); - } - public Builder SetRepeatedSint32(int index, int value) { - PrepareBuilder(); - result.repeatedSint32_[index] = value; - return this; - } - public Builder AddRepeatedSint32(int value) { - PrepareBuilder(); - result.repeatedSint32_.Add(value); - return this; - } - public Builder AddRangeRepeatedSint32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSint32_.Add(values); - return this; - } - public Builder ClearRepeatedSint32() { - PrepareBuilder(); - result.repeatedSint32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSint64List { - get { return PrepareBuilder().repeatedSint64_; } - } - public int RepeatedSint64Count { - get { return result.RepeatedSint64Count; } - } - public long GetRepeatedSint64(int index) { - return result.GetRepeatedSint64(index); - } - public Builder SetRepeatedSint64(int index, long value) { - PrepareBuilder(); - result.repeatedSint64_[index] = value; - return this; - } - public Builder AddRepeatedSint64(long value) { - PrepareBuilder(); - result.repeatedSint64_.Add(value); - return this; - } - public Builder AddRangeRepeatedSint64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSint64_.Add(values); - return this; - } - public Builder ClearRepeatedSint64() { - PrepareBuilder(); - result.repeatedSint64_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed32List { - get { return PrepareBuilder().repeatedFixed32_; } - } - public int RepeatedFixed32Count { - get { return result.RepeatedFixed32Count; } - } - [global::System.CLSCompliant(false)] - public uint GetRepeatedFixed32(int index) { - return result.GetRepeatedFixed32(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed32(int index, uint value) { - PrepareBuilder(); - result.repeatedFixed32_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed32(uint value) { - PrepareBuilder(); - result.repeatedFixed32_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed32_.Add(values); - return this; - } - public Builder ClearRepeatedFixed32() { - PrepareBuilder(); - result.repeatedFixed32_.Clear(); - return this; - } - - [global::System.CLSCompliant(false)] - public pbc::IPopsicleList RepeatedFixed64List { - get { return PrepareBuilder().repeatedFixed64_; } - } - public int RepeatedFixed64Count { - get { return result.RepeatedFixed64Count; } - } - [global::System.CLSCompliant(false)] - public ulong GetRepeatedFixed64(int index) { - return result.GetRepeatedFixed64(index); - } - [global::System.CLSCompliant(false)] - public Builder SetRepeatedFixed64(int index, ulong value) { - PrepareBuilder(); - result.repeatedFixed64_[index] = value; - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRepeatedFixed64(ulong value) { - PrepareBuilder(); - result.repeatedFixed64_.Add(value); - return this; - } - [global::System.CLSCompliant(false)] - public Builder AddRangeRepeatedFixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFixed64_.Add(values); - return this; - } - public Builder ClearRepeatedFixed64() { - PrepareBuilder(); - result.repeatedFixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSfixed32List { - get { return PrepareBuilder().repeatedSfixed32_; } - } - public int RepeatedSfixed32Count { - get { return result.RepeatedSfixed32Count; } - } - public int GetRepeatedSfixed32(int index) { - return result.GetRepeatedSfixed32(index); - } - public Builder SetRepeatedSfixed32(int index, int value) { - PrepareBuilder(); - result.repeatedSfixed32_[index] = value; - return this; - } - public Builder AddRepeatedSfixed32(int value) { - PrepareBuilder(); - result.repeatedSfixed32_.Add(value); - return this; - } - public Builder AddRangeRepeatedSfixed32(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSfixed32_.Add(values); - return this; - } - public Builder ClearRepeatedSfixed32() { - PrepareBuilder(); - result.repeatedSfixed32_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedSfixed64List { - get { return PrepareBuilder().repeatedSfixed64_; } - } - public int RepeatedSfixed64Count { - get { return result.RepeatedSfixed64Count; } - } - public long GetRepeatedSfixed64(int index) { - return result.GetRepeatedSfixed64(index); - } - public Builder SetRepeatedSfixed64(int index, long value) { - PrepareBuilder(); - result.repeatedSfixed64_[index] = value; - return this; - } - public Builder AddRepeatedSfixed64(long value) { - PrepareBuilder(); - result.repeatedSfixed64_.Add(value); - return this; - } - public Builder AddRangeRepeatedSfixed64(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedSfixed64_.Add(values); - return this; - } - public Builder ClearRepeatedSfixed64() { - PrepareBuilder(); - result.repeatedSfixed64_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedFloatList { - get { return PrepareBuilder().repeatedFloat_; } - } - public int RepeatedFloatCount { - get { return result.RepeatedFloatCount; } - } - public float GetRepeatedFloat(int index) { - return result.GetRepeatedFloat(index); - } - public Builder SetRepeatedFloat(int index, float value) { - PrepareBuilder(); - result.repeatedFloat_[index] = value; - return this; - } - public Builder AddRepeatedFloat(float value) { - PrepareBuilder(); - result.repeatedFloat_.Add(value); - return this; - } - public Builder AddRangeRepeatedFloat(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedFloat_.Add(values); - return this; - } - public Builder ClearRepeatedFloat() { - PrepareBuilder(); - result.repeatedFloat_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedDoubleList { - get { return PrepareBuilder().repeatedDouble_; } - } - public int RepeatedDoubleCount { - get { return result.RepeatedDoubleCount; } - } - public double GetRepeatedDouble(int index) { - return result.GetRepeatedDouble(index); - } - public Builder SetRepeatedDouble(int index, double value) { - PrepareBuilder(); - result.repeatedDouble_[index] = value; - return this; - } - public Builder AddRepeatedDouble(double value) { - PrepareBuilder(); - result.repeatedDouble_.Add(value); - return this; - } - public Builder AddRangeRepeatedDouble(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedDouble_.Add(values); - return this; - } - public Builder ClearRepeatedDouble() { - PrepareBuilder(); - result.repeatedDouble_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedBoolList { - get { return PrepareBuilder().repeatedBool_; } - } - public int RepeatedBoolCount { - get { return result.RepeatedBoolCount; } - } - public bool GetRepeatedBool(int index) { - return result.GetRepeatedBool(index); - } - public Builder SetRepeatedBool(int index, bool value) { - PrepareBuilder(); - result.repeatedBool_[index] = value; - return this; - } - public Builder AddRepeatedBool(bool value) { - PrepareBuilder(); - result.repeatedBool_.Add(value); - return this; - } - public Builder AddRangeRepeatedBool(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedBool_.Add(values); - return this; - } - public Builder ClearRepeatedBool() { - PrepareBuilder(); - result.repeatedBool_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringList { - get { return PrepareBuilder().repeatedString_; } - } - public int RepeatedStringCount { - get { return result.RepeatedStringCount; } - } - public string GetRepeatedString(int index) { - return result.GetRepeatedString(index); - } - public Builder SetRepeatedString(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedString_[index] = value; - return this; - } - public Builder AddRepeatedString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedString_.Add(value); - return this; - } - public Builder AddRangeRepeatedString(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedString_.Add(values); - return this; - } - public Builder ClearRepeatedString() { - PrepareBuilder(); - result.repeatedString_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedBytesList { - get { return PrepareBuilder().repeatedBytes_; } - } - public int RepeatedBytesCount { - get { return result.RepeatedBytesCount; } - } - public pb::ByteString GetRepeatedBytes(int index) { - return result.GetRepeatedBytes(index); - } - public Builder SetRepeatedBytes(int index, pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedBytes_[index] = value; - return this; - } - public Builder AddRepeatedBytes(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedBytes_.Add(value); - return this; - } - public Builder AddRangeRepeatedBytes(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedBytes_.Add(values); - return this; - } - public Builder ClearRepeatedBytes() { - PrepareBuilder(); - result.repeatedBytes_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedNestedMessageList { - get { return PrepareBuilder().repeatedNestedMessage_; } - } - public int RepeatedNestedMessageCount { - get { return result.RepeatedNestedMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) { - return result.GetRepeatedNestedMessage(index); - } - public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedNestedMessage_[index] = value; - return this; - } - public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedNestedMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedNestedMessage_.Add(value); - return this; - } - public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedNestedMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedNestedMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedNestedMessage_.Add(values); - return this; - } - public Builder ClearRepeatedNestedMessage() { - PrepareBuilder(); - result.repeatedNestedMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedForeignMessageList { - get { return PrepareBuilder().repeatedForeignMessage_; } - } - public int RepeatedForeignMessageCount { - get { return result.RepeatedForeignMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) { - return result.GetRepeatedForeignMessage(index); - } - public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedForeignMessage_[index] = value; - return this; - } - public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedForeignMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedForeignMessage_.Add(value); - return this; - } - public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedForeignMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedForeignMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedForeignMessage_.Add(values); - return this; - } - public Builder ClearRepeatedForeignMessage() { - PrepareBuilder(); - result.repeatedForeignMessage_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedProto2MessageList { - get { return PrepareBuilder().repeatedProto2Message_; } - } - public int RepeatedProto2MessageCount { - get { return result.RepeatedProto2MessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes GetRepeatedProto2Message(int index) { - return result.GetRepeatedProto2Message(index); - } - public Builder SetRepeatedProto2Message(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedProto2Message_[index] = value; - return this; - } - public Builder SetRepeatedProto2Message(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedProto2Message_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedProto2Message(global::Google.ProtocolBuffers.TestProtos.TestAllTypes value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedProto2Message_.Add(value); - return this; - } - public Builder AddRepeatedProto2Message(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedProto2Message_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedProto2Message(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedProto2Message_.Add(values); - return this; - } - public Builder ClearRepeatedProto2Message() { - PrepareBuilder(); - result.repeatedProto2Message_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedNestedEnumList { - get { return PrepareBuilder().repeatedNestedEnum_; } - } - public int RepeatedNestedEnumCount { - get { return result.RepeatedNestedEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) { - return result.GetRepeatedNestedEnum(index); - } - public Builder SetRepeatedNestedEnum(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.repeatedNestedEnum_[index] = value; - return this; - } - public Builder AddRepeatedNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.repeatedNestedEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedNestedEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedNestedEnum_.Add(values); - return this; - } - public Builder ClearRepeatedNestedEnum() { - PrepareBuilder(); - result.repeatedNestedEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedForeignEnumList { - get { return PrepareBuilder().repeatedForeignEnum_; } - } - public int RepeatedForeignEnumCount { - get { return result.RepeatedForeignEnumCount; } - } - public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) { - return result.GetRepeatedForeignEnum(index); - } - public Builder SetRepeatedForeignEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.repeatedForeignEnum_[index] = value; - return this; - } - public Builder AddRepeatedForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) { - PrepareBuilder(); - result.repeatedForeignEnum_.Add(value); - return this; - } - public Builder AddRangeRepeatedForeignEnum(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedForeignEnum_.Add(values); - return this; - } - public Builder ClearRepeatedForeignEnum() { - PrepareBuilder(); - result.repeatedForeignEnum_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedStringPieceList { - get { return PrepareBuilder().repeatedStringPiece_; } - } - public int RepeatedStringPieceCount { - get { return result.RepeatedStringPieceCount; } - } - public string GetRepeatedStringPiece(int index) { - return result.GetRepeatedStringPiece(index); - } - public Builder SetRepeatedStringPiece(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPiece_[index] = value; - return this; - } - public Builder AddRepeatedStringPiece(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedStringPiece_.Add(value); - return this; - } - public Builder AddRangeRepeatedStringPiece(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedStringPiece_.Add(values); - return this; - } - public Builder ClearRepeatedStringPiece() { - PrepareBuilder(); - result.repeatedStringPiece_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedCordList { - get { return PrepareBuilder().repeatedCord_; } - } - public int RepeatedCordCount { - get { return result.RepeatedCordCount; } - } - public string GetRepeatedCord(int index) { - return result.GetRepeatedCord(index); - } - public Builder SetRepeatedCord(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCord_[index] = value; - return this; - } - public Builder AddRepeatedCord(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedCord_.Add(value); - return this; - } - public Builder AddRangeRepeatedCord(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedCord_.Add(values); - return this; - } - public Builder ClearRepeatedCord() { - PrepareBuilder(); - result.repeatedCord_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedLazyMessageList { - get { return PrepareBuilder().repeatedLazyMessage_; } - } - public int RepeatedLazyMessageCount { - get { return result.RepeatedLazyMessageCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedLazyMessage(int index) { - return result.GetRepeatedLazyMessage(index); - } - public Builder SetRepeatedLazyMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedLazyMessage_[index] = value; - return this; - } - public Builder SetRepeatedLazyMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedLazyMessage_[index] = builderForValue.Build(); - return this; - } - public Builder AddRepeatedLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.repeatedLazyMessage_.Add(value); - return this; - } - public Builder AddRepeatedLazyMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.repeatedLazyMessage_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeRepeatedLazyMessage(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedLazyMessage_.Add(values); - return this; - } - public Builder ClearRepeatedLazyMessage() { - PrepareBuilder(); - result.repeatedLazyMessage_.Clear(); - return this; - } - - public bool HasOneofUint32 { - get { return result.hasOneofUint32; } - } - [global::System.CLSCompliant(false)] - public uint OneofUint32 { - get { return result.OneofUint32; } - set { SetOneofUint32(value); } - } - [global::System.CLSCompliant(false)] - public Builder SetOneofUint32(uint value) { - PrepareBuilder(); - result.hasOneofUint32 = true; - result.oneofUint32_ = value; - return this; - } - public Builder ClearOneofUint32() { - PrepareBuilder(); - result.hasOneofUint32 = false; - result.oneofUint32_ = 0; - return this; - } - - public bool HasOneofNestedMessage { - get { return result.hasOneofNestedMessage; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OneofNestedMessage { - get { return result.OneofNestedMessage; } - set { SetOneofNestedMessage(value); } - } - public Builder SetOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOneofNestedMessage = true; - result.oneofNestedMessage_ = value; - return this; - } - public Builder SetOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasOneofNestedMessage = true; - result.oneofNestedMessage_ = builderForValue.Build(); - return this; - } - public Builder MergeOneofNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasOneofNestedMessage && - result.oneofNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) { - result.oneofNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.oneofNestedMessage_).MergeFrom(value).BuildPartial(); - } else { - result.oneofNestedMessage_ = value; - } - result.hasOneofNestedMessage = true; - return this; - } - public Builder ClearOneofNestedMessage() { - PrepareBuilder(); - result.hasOneofNestedMessage = false; - result.oneofNestedMessage_ = null; - return this; - } - - public bool HasOneofString { - get { return result.hasOneofString; } - } - public string OneofString { - get { return result.OneofString; } - set { SetOneofString(value); } - } - public Builder SetOneofString(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasOneofString = true; - result.oneofString_ = value; - return this; - } - public Builder ClearOneofString() { - PrepareBuilder(); - result.hasOneofString = false; - result.oneofString_ = ""; - return this; - } - - public bool HasOneofEnum { - get { return result.hasOneofEnum; } - } - public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OneofEnum { - get { return result.OneofEnum; } - set { SetOneofEnum(value); } - } - public Builder SetOneofEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) { - PrepareBuilder(); - result.hasOneofEnum = true; - result.oneofEnum_ = value; - return this; - } - public Builder ClearOneofEnum() { - PrepareBuilder(); - result.hasOneofEnum = false; - result.oneofEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO; - return this; - } - } - static TestAllTypes() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestProto2Required : pb::GeneratedMessage { - private TestProto2Required() { } - private static readonly TestProto2Required defaultInstance = new TestProto2Required().MakeReadOnly(); - private static readonly string[] _testProto2RequiredFieldNames = new string[] { "proto2" }; - private static readonly uint[] _testProto2RequiredFieldTags = new uint[] { 10 }; - public static TestProto2Required DefaultInstance { - get { return defaultInstance; } - } - - public override TestProto2Required DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestProto2Required ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.internal__static_proto2_nofieldpresence_unittest_TestProto2Required__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.internal__static_proto2_nofieldpresence_unittest_TestProto2Required__FieldAccessorTable; } - } - - public const int Proto2FieldNumber = 1; - private bool hasProto2; - private global::Google.ProtocolBuffers.TestProtos.TestRequired proto2_; - public bool HasProto2 { - get { return hasProto2; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequired Proto2 { - get { return proto2_ ?? global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance; } - } - - public override bool IsInitialized { - get { - if (HasProto2) { - if (!Proto2.IsInitialized) return false; - } - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testProto2RequiredFieldNames; - if (hasProto2) { - output.WriteMessage(1, field_names[0], Proto2); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasProto2) { - size += pb::CodedOutputStream.ComputeMessageSize(1, Proto2); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestProto2Required ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestProto2Required ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestProto2Required ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestProto2Required ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestProto2Required ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestProto2Required ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestProto2Required ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestProto2Required ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestProto2Required ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestProto2Required ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestProto2Required MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestProto2Required prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestProto2Required cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestProto2Required result; - - private TestProto2Required PrepareBuilder() { - if (resultIsReadOnly) { - TestProto2Required original = result; - result = new TestProto2Required(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestProto2Required MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestProto2Required.Descriptor; } - } - - public override TestProto2Required DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestProto2Required.DefaultInstance; } - } - - public override TestProto2Required BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestProto2Required) { - return MergeFrom((TestProto2Required) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestProto2Required other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestProto2Required.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasProto2) { - MergeProto2(other.Proto2); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testProto2RequiredFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testProto2RequiredFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(); - if (result.hasProto2) { - subBuilder.MergeFrom(Proto2); - } - input.ReadMessage(subBuilder, extensionRegistry); - Proto2 = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasProto2 { - get { return result.hasProto2; } - } - public global::Google.ProtocolBuffers.TestProtos.TestRequired Proto2 { - get { return result.Proto2; } - set { SetProto2(value); } - } - public Builder SetProto2(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasProto2 = true; - result.proto2_ = value; - return this; - } - public Builder SetProto2(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasProto2 = true; - result.proto2_ = builderForValue.Build(); - return this; - } - public Builder MergeProto2(global::Google.ProtocolBuffers.TestProtos.TestRequired value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasProto2 && - result.proto2_ != global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) { - result.proto2_ = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(result.proto2_).MergeFrom(value).BuildPartial(); - } else { - result.proto2_ = value; - } - result.hasProto2 = true; - return this; - } - public Builder ClearProto2() { - PrepareBuilder(); - result.hasProto2 = false; - result.proto2_ = null; - return this; - } - } - static TestProto2Required() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class ForeignMessage : pb::GeneratedMessage { - private ForeignMessage() { } - private static readonly ForeignMessage defaultInstance = new ForeignMessage().MakeReadOnly(); - private static readonly string[] _foreignMessageFieldNames = new string[] { "c" }; - private static readonly uint[] _foreignMessageFieldTags = new uint[] { 8 }; - public static ForeignMessage DefaultInstance { - get { return defaultInstance; } - } - - public override ForeignMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override ForeignMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.internal__static_proto2_nofieldpresence_unittest_ForeignMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.internal__static_proto2_nofieldpresence_unittest_ForeignMessage__FieldAccessorTable; } - } - - public const int CFieldNumber = 1; - private bool hasC; - private int c_; - public bool HasC { - get { return hasC; } - } - public int C { - get { return c_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _foreignMessageFieldNames; - if (hasC) { - output.WriteInt32(1, field_names[0], C); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasC) { - size += pb::CodedOutputStream.ComputeInt32Size(1, C); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static ForeignMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ForeignMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ForeignMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ForeignMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ForeignMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ForeignMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static ForeignMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ForeignMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private ForeignMessage MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(ForeignMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(ForeignMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private ForeignMessage result; - - private ForeignMessage PrepareBuilder() { - if (resultIsReadOnly) { - ForeignMessage original = result; - result = new ForeignMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override ForeignMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Descriptor; } - } - - public override ForeignMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; } - } - - public override ForeignMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is ForeignMessage) { - return MergeFrom((ForeignMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(ForeignMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasC) { - C = other.C; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_foreignMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _foreignMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasC = input.ReadInt32(ref result.c_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasC { - get { return result.hasC; } - } - public int C { - get { return result.C; } - set { SetC(value); } - } - public Builder SetC(int value) { - PrepareBuilder(); - result.hasC = true; - result.c_ = value; - return this; - } - public Builder ClearC() { - PrepareBuilder(); - result.hasC = false; - result.c_ = 0; - return this; - } - } - static ForeignMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestNoFieldPresence.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffers.Test/TestProtos/UnittestPreserveUnknownEnum.cs b/csharp/src/ProtocolBuffers.Test/TestProtos/UnittestPreserveUnknownEnum.cs deleted file mode 100644 index c0f4995e..00000000 --- a/csharp/src/ProtocolBuffers.Test/TestProtos/UnittestPreserveUnknownEnum.cs +++ /dev/null @@ -1,1320 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/protobuf/unittest_preserve_unknown_enum.proto -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnittestPreserveUnknownEnum { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - } - #endregion - #region Static variables - internal static pbd::MessageDescriptor internal__static_proto3_preserve_unknown_enum_unittest_MyMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_proto3_preserve_unknown_enum_unittest_MyMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_proto3_preserve_unknown_enum_unittest_MyMessagePlusExtra__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_proto3_preserve_unknown_enum_unittest_MyMessagePlusExtra__FieldAccessorTable; - #endregion - #region Descriptor - public static pbd::FileDescriptor Descriptor { - get { return descriptor; } - } - private static pbd::FileDescriptor descriptor; - - static UnittestPreserveUnknownEnum() { - byte[] descriptorData = global::System.Convert.FromBase64String( - string.Concat( - "CjRnb29nbGUvcHJvdG9idWYvdW5pdHRlc3RfcHJlc2VydmVfdW5rbm93bl9l", - "bnVtLnByb3RvEiVwcm90bzNfcHJlc2VydmVfdW5rbm93bl9lbnVtX3VuaXR0", - "ZXN0IsEDCglNeU1lc3NhZ2USOAoBZRgBIAEoDjItLnByb3RvM19wcmVzZXJ2", - "ZV91bmtub3duX2VudW1fdW5pdHRlc3QuTXlFbnVtEkEKCnJlcGVhdGVkX2UY", - "AiADKA4yLS5wcm90bzNfcHJlc2VydmVfdW5rbm93bl9lbnVtX3VuaXR0ZXN0", - "Lk15RW51bRJMChFyZXBlYXRlZF9wYWNrZWRfZRgDIAMoDjItLnByb3RvM19w", - "cmVzZXJ2ZV91bmtub3duX2VudW1fdW5pdHRlc3QuTXlFbnVtQgIQARJcChxy", - "ZXBlYXRlZF9wYWNrZWRfdW5leHBlY3RlZF9lGAQgAygOMjYucHJvdG8zX3By", - "ZXNlcnZlX3Vua25vd25fZW51bV91bml0dGVzdC5NeUVudW1QbHVzRXh0cmES", - "QgoJb25lb2ZfZV8xGAUgASgOMi0ucHJvdG8zX3ByZXNlcnZlX3Vua25vd25f", - "ZW51bV91bml0dGVzdC5NeUVudW1IABJCCglvbmVvZl9lXzIYBiABKA4yLS5w", - "cm90bzNfcHJlc2VydmVfdW5rbm93bl9lbnVtX3VuaXR0ZXN0Lk15RW51bUgA", - "QgMKAW8i+wMKEk15TWVzc2FnZVBsdXNFeHRyYRJBCgFlGAEgASgOMjYucHJv", - "dG8zX3ByZXNlcnZlX3Vua25vd25fZW51bV91bml0dGVzdC5NeUVudW1QbHVz", - "RXh0cmESSgoKcmVwZWF0ZWRfZRgCIAMoDjI2LnByb3RvM19wcmVzZXJ2ZV91", - "bmtub3duX2VudW1fdW5pdHRlc3QuTXlFbnVtUGx1c0V4dHJhElUKEXJlcGVh", - "dGVkX3BhY2tlZF9lGAMgAygOMjYucHJvdG8zX3ByZXNlcnZlX3Vua25vd25f", - "ZW51bV91bml0dGVzdC5NeUVudW1QbHVzRXh0cmFCAhABEmAKHHJlcGVhdGVk", - "X3BhY2tlZF91bmV4cGVjdGVkX2UYBCADKA4yNi5wcm90bzNfcHJlc2VydmVf", - "dW5rbm93bl9lbnVtX3VuaXR0ZXN0Lk15RW51bVBsdXNFeHRyYUICEAESSwoJ", - "b25lb2ZfZV8xGAUgASgOMjYucHJvdG8zX3ByZXNlcnZlX3Vua25vd25fZW51", - "bV91bml0dGVzdC5NeUVudW1QbHVzRXh0cmFIABJLCglvbmVvZl9lXzIYBiAB", - "KA4yNi5wcm90bzNfcHJlc2VydmVfdW5rbm93bl9lbnVtX3VuaXR0ZXN0Lk15", - "RW51bVBsdXNFeHRyYUgAQgMKAW8qIwoGTXlFbnVtEgcKA0ZPTxAAEgcKA0JB", - "UhABEgcKA0JBWhACKj8KD015RW51bVBsdXNFeHRyYRIJCgVFX0ZPTxAAEgkK", - "BUVfQkFSEAESCQoFRV9CQVoQAhILCgdFX0VYVFJBEANCJKoCIUdvb2dsZS5Q", - "cm90b2NvbEJ1ZmZlcnMuVGVzdFByb3Rvc2IGcHJvdG8z")); - pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { - descriptor = root; - internal__static_proto3_preserve_unknown_enum_unittest_MyMessage__Descriptor = Descriptor.MessageTypes[0]; - internal__static_proto3_preserve_unknown_enum_unittest_MyMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_proto3_preserve_unknown_enum_unittest_MyMessage__Descriptor, - new string[] { "E", "RepeatedE", "RepeatedPackedE", "RepeatedPackedUnexpectedE", "OneofE1", "OneofE2", }); - internal__static_proto3_preserve_unknown_enum_unittest_MyMessagePlusExtra__Descriptor = Descriptor.MessageTypes[1]; - internal__static_proto3_preserve_unknown_enum_unittest_MyMessagePlusExtra__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_proto3_preserve_unknown_enum_unittest_MyMessagePlusExtra__Descriptor, - new string[] { "E", "RepeatedE", "RepeatedPackedE", "RepeatedPackedUnexpectedE", "OneofE1", "OneofE2", }); - pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); - RegisterAllExtensions(registry); - return registry; - }; - pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, - new pbd::FileDescriptor[] { - }, assigner); - } - #endregion - - } - #region Enums - public enum MyEnum { - FOO = 0, - BAR = 1, - BAZ = 2, - } - - public enum MyEnumPlusExtra { - E_FOO = 0, - E_BAR = 1, - E_BAZ = 2, - E_EXTRA = 3, - } - - #endregion - - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class MyMessage : pb::GeneratedMessage { - private MyMessage() { } - private static readonly MyMessage defaultInstance = new MyMessage().MakeReadOnly(); - private static readonly string[] _myMessageFieldNames = new string[] { "e", "oneof_e_1", "oneof_e_2", "repeated_e", "repeated_packed_e", "repeated_packed_unexpected_e" }; - private static readonly uint[] _myMessageFieldTags = new uint[] { 8, 40, 48, 16, 26, 32 }; - public static MyMessage DefaultInstance { - get { return defaultInstance; } - } - - public override MyMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override MyMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestPreserveUnknownEnum.internal__static_proto3_preserve_unknown_enum_unittest_MyMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestPreserveUnknownEnum.internal__static_proto3_preserve_unknown_enum_unittest_MyMessage__FieldAccessorTable; } - } - - public const int EFieldNumber = 1; - private bool hasE; - private global::Google.ProtocolBuffers.TestProtos.MyEnum e_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - public bool HasE { - get { return hasE; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum E { - get { return e_; } - } - - public const int RepeatedEFieldNumber = 2; - private pbc::PopsicleList repeatedE_ = new pbc::PopsicleList(); - public scg::IList RepeatedEList { - get { return pbc::Lists.AsReadOnly(repeatedE_); } - } - public int RepeatedECount { - get { return repeatedE_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum GetRepeatedE(int index) { - return repeatedE_[index]; - } - - public const int RepeatedPackedEFieldNumber = 3; - private int repeatedPackedEMemoizedSerializedSize; - private pbc::PopsicleList repeatedPackedE_ = new pbc::PopsicleList(); - public scg::IList RepeatedPackedEList { - get { return pbc::Lists.AsReadOnly(repeatedPackedE_); } - } - public int RepeatedPackedECount { - get { return repeatedPackedE_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum GetRepeatedPackedE(int index) { - return repeatedPackedE_[index]; - } - - public const int RepeatedPackedUnexpectedEFieldNumber = 4; - private pbc::PopsicleList repeatedPackedUnexpectedE_ = new pbc::PopsicleList(); - public scg::IList RepeatedPackedUnexpectedEList { - get { return pbc::Lists.AsReadOnly(repeatedPackedUnexpectedE_); } - } - public int RepeatedPackedUnexpectedECount { - get { return repeatedPackedUnexpectedE_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra GetRepeatedPackedUnexpectedE(int index) { - return repeatedPackedUnexpectedE_[index]; - } - - public const int OneofE1FieldNumber = 5; - private bool hasOneofE1; - private global::Google.ProtocolBuffers.TestProtos.MyEnum oneofE1_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - public bool HasOneofE1 { - get { return hasOneofE1; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum OneofE1 { - get { return oneofE1_; } - } - - public const int OneofE2FieldNumber = 6; - private bool hasOneofE2; - private global::Google.ProtocolBuffers.TestProtos.MyEnum oneofE2_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - public bool HasOneofE2 { - get { return hasOneofE2; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum OneofE2 { - get { return oneofE2_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _myMessageFieldNames; - if (hasE) { - output.WriteEnum(1, field_names[0], (int) E, E); - } - if (repeatedE_.Count > 0) { - output.WriteEnumArray(2, field_names[3], repeatedE_); - } - if (repeatedPackedE_.Count > 0) { - output.WritePackedEnumArray(3, field_names[4], repeatedPackedEMemoizedSerializedSize, repeatedPackedE_); - } - if (repeatedPackedUnexpectedE_.Count > 0) { - output.WriteEnumArray(4, field_names[5], repeatedPackedUnexpectedE_); - } - if (hasOneofE1) { - output.WriteEnum(5, field_names[1], (int) OneofE1, OneofE1); - } - if (hasOneofE2) { - output.WriteEnum(6, field_names[2], (int) OneofE2, OneofE2); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasE) { - size += pb::CodedOutputStream.ComputeEnumSize(1, (int) E); - } - { - int dataSize = 0; - if (repeatedE_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.MyEnum element in repeatedE_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * repeatedE_.Count; - } - } - { - int dataSize = 0; - if (repeatedPackedE_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.MyEnum element in repeatedPackedE_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1; - size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); - } - repeatedPackedEMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - if (repeatedPackedUnexpectedE_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra element in repeatedPackedUnexpectedE_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * repeatedPackedUnexpectedE_.Count; - } - } - if (hasOneofE1) { - size += pb::CodedOutputStream.ComputeEnumSize(5, (int) OneofE1); - } - if (hasOneofE2) { - size += pb::CodedOutputStream.ComputeEnumSize(6, (int) OneofE2); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static MyMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MyMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MyMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MyMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MyMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MyMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static MyMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static MyMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static MyMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MyMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private MyMessage MakeReadOnly() { - repeatedE_.MakeReadOnly(); - repeatedPackedE_.MakeReadOnly(); - repeatedPackedUnexpectedE_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(MyMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(MyMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private MyMessage result; - - private MyMessage PrepareBuilder() { - if (resultIsReadOnly) { - MyMessage original = result; - result = new MyMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override MyMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.MyMessage.Descriptor; } - } - - public override MyMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.MyMessage.DefaultInstance; } - } - - public override MyMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is MyMessage) { - return MergeFrom((MyMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(MyMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.MyMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasE) { - E = other.E; - } - if (other.repeatedE_.Count != 0) { - result.repeatedE_.Add(other.repeatedE_); - } - if (other.repeatedPackedE_.Count != 0) { - result.repeatedPackedE_.Add(other.repeatedPackedE_); - } - if (other.repeatedPackedUnexpectedE_.Count != 0) { - result.repeatedPackedUnexpectedE_.Add(other.repeatedPackedUnexpectedE_); - } - if (other.HasOneofE1) { - OneofE1 = other.OneofE1; - } - if (other.HasOneofE2) { - OneofE2 = other.OneofE2; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_myMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _myMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - object unknown; - if(input.ReadEnum(ref result.e_, out unknown)) { - result.hasE = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(1, (ulong)(int)unknown); - } - break; - } - case 18: - case 16: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedE_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(2, (ulong)(int)rawValue); - } - break; - } - case 26: - case 24: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedPackedE_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(3, (ulong)(int)rawValue); - } - break; - } - case 34: - case 32: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedPackedUnexpectedE_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(4, (ulong)(int)rawValue); - } - break; - } - case 40: { - object unknown; - if(input.ReadEnum(ref result.oneofE1_, out unknown)) { - result.hasOneofE1 = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(5, (ulong)(int)unknown); - } - break; - } - case 48: { - object unknown; - if(input.ReadEnum(ref result.oneofE2_, out unknown)) { - result.hasOneofE2 = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(6, (ulong)(int)unknown); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasE { - get { return result.hasE; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum E { - get { return result.E; } - set { SetE(value); } - } - public Builder SetE(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.hasE = true; - result.e_ = value; - return this; - } - public Builder ClearE() { - PrepareBuilder(); - result.hasE = false; - result.e_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - return this; - } - - public pbc::IPopsicleList RepeatedEList { - get { return PrepareBuilder().repeatedE_; } - } - public int RepeatedECount { - get { return result.RepeatedECount; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum GetRepeatedE(int index) { - return result.GetRepeatedE(index); - } - public Builder SetRepeatedE(int index, global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.repeatedE_[index] = value; - return this; - } - public Builder AddRepeatedE(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.repeatedE_.Add(value); - return this; - } - public Builder AddRangeRepeatedE(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedE_.Add(values); - return this; - } - public Builder ClearRepeatedE() { - PrepareBuilder(); - result.repeatedE_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedPackedEList { - get { return PrepareBuilder().repeatedPackedE_; } - } - public int RepeatedPackedECount { - get { return result.RepeatedPackedECount; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum GetRepeatedPackedE(int index) { - return result.GetRepeatedPackedE(index); - } - public Builder SetRepeatedPackedE(int index, global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.repeatedPackedE_[index] = value; - return this; - } - public Builder AddRepeatedPackedE(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.repeatedPackedE_.Add(value); - return this; - } - public Builder AddRangeRepeatedPackedE(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedPackedE_.Add(values); - return this; - } - public Builder ClearRepeatedPackedE() { - PrepareBuilder(); - result.repeatedPackedE_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedPackedUnexpectedEList { - get { return PrepareBuilder().repeatedPackedUnexpectedE_; } - } - public int RepeatedPackedUnexpectedECount { - get { return result.RepeatedPackedUnexpectedECount; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra GetRepeatedPackedUnexpectedE(int index) { - return result.GetRepeatedPackedUnexpectedE(index); - } - public Builder SetRepeatedPackedUnexpectedE(int index, global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_[index] = value; - return this; - } - public Builder AddRepeatedPackedUnexpectedE(global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_.Add(value); - return this; - } - public Builder AddRangeRepeatedPackedUnexpectedE(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_.Add(values); - return this; - } - public Builder ClearRepeatedPackedUnexpectedE() { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_.Clear(); - return this; - } - - public bool HasOneofE1 { - get { return result.hasOneofE1; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum OneofE1 { - get { return result.OneofE1; } - set { SetOneofE1(value); } - } - public Builder SetOneofE1(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.hasOneofE1 = true; - result.oneofE1_ = value; - return this; - } - public Builder ClearOneofE1() { - PrepareBuilder(); - result.hasOneofE1 = false; - result.oneofE1_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - return this; - } - - public bool HasOneofE2 { - get { return result.hasOneofE2; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum OneofE2 { - get { return result.OneofE2; } - set { SetOneofE2(value); } - } - public Builder SetOneofE2(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.hasOneofE2 = true; - result.oneofE2_ = value; - return this; - } - public Builder ClearOneofE2() { - PrepareBuilder(); - result.hasOneofE2 = false; - result.oneofE2_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - return this; - } - } - static MyMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestPreserveUnknownEnum.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class MyMessagePlusExtra : pb::GeneratedMessage { - private MyMessagePlusExtra() { } - private static readonly MyMessagePlusExtra defaultInstance = new MyMessagePlusExtra().MakeReadOnly(); - private static readonly string[] _myMessagePlusExtraFieldNames = new string[] { "e", "oneof_e_1", "oneof_e_2", "repeated_e", "repeated_packed_e", "repeated_packed_unexpected_e" }; - private static readonly uint[] _myMessagePlusExtraFieldTags = new uint[] { 8, 40, 48, 16, 26, 34 }; - public static MyMessagePlusExtra DefaultInstance { - get { return defaultInstance; } - } - - public override MyMessagePlusExtra DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override MyMessagePlusExtra ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestPreserveUnknownEnum.internal__static_proto3_preserve_unknown_enum_unittest_MyMessagePlusExtra__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestPreserveUnknownEnum.internal__static_proto3_preserve_unknown_enum_unittest_MyMessagePlusExtra__FieldAccessorTable; } - } - - public const int EFieldNumber = 1; - private bool hasE; - private global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra e_ = global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra.E_FOO; - public bool HasE { - get { return hasE; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra E { - get { return e_; } - } - - public const int RepeatedEFieldNumber = 2; - private pbc::PopsicleList repeatedE_ = new pbc::PopsicleList(); - public scg::IList RepeatedEList { - get { return pbc::Lists.AsReadOnly(repeatedE_); } - } - public int RepeatedECount { - get { return repeatedE_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra GetRepeatedE(int index) { - return repeatedE_[index]; - } - - public const int RepeatedPackedEFieldNumber = 3; - private int repeatedPackedEMemoizedSerializedSize; - private pbc::PopsicleList repeatedPackedE_ = new pbc::PopsicleList(); - public scg::IList RepeatedPackedEList { - get { return pbc::Lists.AsReadOnly(repeatedPackedE_); } - } - public int RepeatedPackedECount { - get { return repeatedPackedE_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra GetRepeatedPackedE(int index) { - return repeatedPackedE_[index]; - } - - public const int RepeatedPackedUnexpectedEFieldNumber = 4; - private int repeatedPackedUnexpectedEMemoizedSerializedSize; - private pbc::PopsicleList repeatedPackedUnexpectedE_ = new pbc::PopsicleList(); - public scg::IList RepeatedPackedUnexpectedEList { - get { return pbc::Lists.AsReadOnly(repeatedPackedUnexpectedE_); } - } - public int RepeatedPackedUnexpectedECount { - get { return repeatedPackedUnexpectedE_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra GetRepeatedPackedUnexpectedE(int index) { - return repeatedPackedUnexpectedE_[index]; - } - - public const int OneofE1FieldNumber = 5; - private bool hasOneofE1; - private global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra oneofE1_ = global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra.E_FOO; - public bool HasOneofE1 { - get { return hasOneofE1; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra OneofE1 { - get { return oneofE1_; } - } - - public const int OneofE2FieldNumber = 6; - private bool hasOneofE2; - private global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra oneofE2_ = global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra.E_FOO; - public bool HasOneofE2 { - get { return hasOneofE2; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra OneofE2 { - get { return oneofE2_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _myMessagePlusExtraFieldNames; - if (hasE) { - output.WriteEnum(1, field_names[0], (int) E, E); - } - if (repeatedE_.Count > 0) { - output.WriteEnumArray(2, field_names[3], repeatedE_); - } - if (repeatedPackedE_.Count > 0) { - output.WritePackedEnumArray(3, field_names[4], repeatedPackedEMemoizedSerializedSize, repeatedPackedE_); - } - if (repeatedPackedUnexpectedE_.Count > 0) { - output.WritePackedEnumArray(4, field_names[5], repeatedPackedUnexpectedEMemoizedSerializedSize, repeatedPackedUnexpectedE_); - } - if (hasOneofE1) { - output.WriteEnum(5, field_names[1], (int) OneofE1, OneofE1); - } - if (hasOneofE2) { - output.WriteEnum(6, field_names[2], (int) OneofE2, OneofE2); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasE) { - size += pb::CodedOutputStream.ComputeEnumSize(1, (int) E); - } - { - int dataSize = 0; - if (repeatedE_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra element in repeatedE_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * repeatedE_.Count; - } - } - { - int dataSize = 0; - if (repeatedPackedE_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra element in repeatedPackedE_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1; - size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); - } - repeatedPackedEMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - if (repeatedPackedUnexpectedE_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra element in repeatedPackedUnexpectedE_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1; - size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); - } - repeatedPackedUnexpectedEMemoizedSerializedSize = dataSize; - } - if (hasOneofE1) { - size += pb::CodedOutputStream.ComputeEnumSize(5, (int) OneofE1); - } - if (hasOneofE2) { - size += pb::CodedOutputStream.ComputeEnumSize(6, (int) OneofE2); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static MyMessagePlusExtra ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MyMessagePlusExtra ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MyMessagePlusExtra ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MyMessagePlusExtra ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MyMessagePlusExtra ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MyMessagePlusExtra ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static MyMessagePlusExtra ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static MyMessagePlusExtra ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static MyMessagePlusExtra ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MyMessagePlusExtra ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private MyMessagePlusExtra MakeReadOnly() { - repeatedE_.MakeReadOnly(); - repeatedPackedE_.MakeReadOnly(); - repeatedPackedUnexpectedE_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(MyMessagePlusExtra prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(MyMessagePlusExtra cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private MyMessagePlusExtra result; - - private MyMessagePlusExtra PrepareBuilder() { - if (resultIsReadOnly) { - MyMessagePlusExtra original = result; - result = new MyMessagePlusExtra(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override MyMessagePlusExtra MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.MyMessagePlusExtra.Descriptor; } - } - - public override MyMessagePlusExtra DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.MyMessagePlusExtra.DefaultInstance; } - } - - public override MyMessagePlusExtra BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is MyMessagePlusExtra) { - return MergeFrom((MyMessagePlusExtra) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(MyMessagePlusExtra other) { - if (other == global::Google.ProtocolBuffers.TestProtos.MyMessagePlusExtra.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasE) { - E = other.E; - } - if (other.repeatedE_.Count != 0) { - result.repeatedE_.Add(other.repeatedE_); - } - if (other.repeatedPackedE_.Count != 0) { - result.repeatedPackedE_.Add(other.repeatedPackedE_); - } - if (other.repeatedPackedUnexpectedE_.Count != 0) { - result.repeatedPackedUnexpectedE_.Add(other.repeatedPackedUnexpectedE_); - } - if (other.HasOneofE1) { - OneofE1 = other.OneofE1; - } - if (other.HasOneofE2) { - OneofE2 = other.OneofE2; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_myMessagePlusExtraFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _myMessagePlusExtraFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - object unknown; - if(input.ReadEnum(ref result.e_, out unknown)) { - result.hasE = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(1, (ulong)(int)unknown); - } - break; - } - case 18: - case 16: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedE_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(2, (ulong)(int)rawValue); - } - break; - } - case 26: - case 24: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedPackedE_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(3, (ulong)(int)rawValue); - } - break; - } - case 34: - case 32: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedPackedUnexpectedE_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(4, (ulong)(int)rawValue); - } - break; - } - case 40: { - object unknown; - if(input.ReadEnum(ref result.oneofE1_, out unknown)) { - result.hasOneofE1 = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(5, (ulong)(int)unknown); - } - break; - } - case 48: { - object unknown; - if(input.ReadEnum(ref result.oneofE2_, out unknown)) { - result.hasOneofE2 = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(6, (ulong)(int)unknown); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasE { - get { return result.hasE; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra E { - get { return result.E; } - set { SetE(value); } - } - public Builder SetE(global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.hasE = true; - result.e_ = value; - return this; - } - public Builder ClearE() { - PrepareBuilder(); - result.hasE = false; - result.e_ = global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra.E_FOO; - return this; - } - - public pbc::IPopsicleList RepeatedEList { - get { return PrepareBuilder().repeatedE_; } - } - public int RepeatedECount { - get { return result.RepeatedECount; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra GetRepeatedE(int index) { - return result.GetRepeatedE(index); - } - public Builder SetRepeatedE(int index, global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.repeatedE_[index] = value; - return this; - } - public Builder AddRepeatedE(global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.repeatedE_.Add(value); - return this; - } - public Builder AddRangeRepeatedE(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedE_.Add(values); - return this; - } - public Builder ClearRepeatedE() { - PrepareBuilder(); - result.repeatedE_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedPackedEList { - get { return PrepareBuilder().repeatedPackedE_; } - } - public int RepeatedPackedECount { - get { return result.RepeatedPackedECount; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra GetRepeatedPackedE(int index) { - return result.GetRepeatedPackedE(index); - } - public Builder SetRepeatedPackedE(int index, global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.repeatedPackedE_[index] = value; - return this; - } - public Builder AddRepeatedPackedE(global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.repeatedPackedE_.Add(value); - return this; - } - public Builder AddRangeRepeatedPackedE(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedPackedE_.Add(values); - return this; - } - public Builder ClearRepeatedPackedE() { - PrepareBuilder(); - result.repeatedPackedE_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedPackedUnexpectedEList { - get { return PrepareBuilder().repeatedPackedUnexpectedE_; } - } - public int RepeatedPackedUnexpectedECount { - get { return result.RepeatedPackedUnexpectedECount; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra GetRepeatedPackedUnexpectedE(int index) { - return result.GetRepeatedPackedUnexpectedE(index); - } - public Builder SetRepeatedPackedUnexpectedE(int index, global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_[index] = value; - return this; - } - public Builder AddRepeatedPackedUnexpectedE(global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_.Add(value); - return this; - } - public Builder AddRangeRepeatedPackedUnexpectedE(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_.Add(values); - return this; - } - public Builder ClearRepeatedPackedUnexpectedE() { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_.Clear(); - return this; - } - - public bool HasOneofE1 { - get { return result.hasOneofE1; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra OneofE1 { - get { return result.OneofE1; } - set { SetOneofE1(value); } - } - public Builder SetOneofE1(global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.hasOneofE1 = true; - result.oneofE1_ = value; - return this; - } - public Builder ClearOneofE1() { - PrepareBuilder(); - result.hasOneofE1 = false; - result.oneofE1_ = global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra.E_FOO; - return this; - } - - public bool HasOneofE2 { - get { return result.hasOneofE2; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra OneofE2 { - get { return result.OneofE2; } - set { SetOneofE2(value); } - } - public Builder SetOneofE2(global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra value) { - PrepareBuilder(); - result.hasOneofE2 = true; - result.oneofE2_ = value; - return this; - } - public Builder ClearOneofE2() { - PrepareBuilder(); - result.hasOneofE2 = false; - result.oneofE2_ = global::Google.ProtocolBuffers.TestProtos.MyEnumPlusExtra.E_FOO; - return this; - } - } - static MyMessagePlusExtra() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestPreserveUnknownEnum.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffers.Test/TestProtos/UnittestPreserveUnknownEnum2.cs b/csharp/src/ProtocolBuffers.Test/TestProtos/UnittestPreserveUnknownEnum2.cs deleted file mode 100644 index b7ab97d9..00000000 --- a/csharp/src/ProtocolBuffers.Test/TestProtos/UnittestPreserveUnknownEnum2.cs +++ /dev/null @@ -1,684 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/protobuf/unittest_preserve_unknown_enum2.proto -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnittestPreserveUnknownEnum2 { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - } - #endregion - #region Static variables - internal static pbd::MessageDescriptor internal__static_proto2_preserve_unknown_enum_unittest_MyMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_proto2_preserve_unknown_enum_unittest_MyMessage__FieldAccessorTable; - #endregion - #region Descriptor - public static pbd::FileDescriptor Descriptor { - get { return descriptor; } - } - private static pbd::FileDescriptor descriptor; - - static UnittestPreserveUnknownEnum2() { - byte[] descriptorData = global::System.Convert.FromBase64String( - string.Concat( - "CjVnb29nbGUvcHJvdG9idWYvdW5pdHRlc3RfcHJlc2VydmVfdW5rbm93bl9l", - "bnVtMi5wcm90bxIlcHJvdG8yX3ByZXNlcnZlX3Vua25vd25fZW51bV91bml0", - "dGVzdCK4AwoJTXlNZXNzYWdlEjgKAWUYASABKA4yLS5wcm90bzJfcHJlc2Vy", - "dmVfdW5rbm93bl9lbnVtX3VuaXR0ZXN0Lk15RW51bRJBCgpyZXBlYXRlZF9l", - "GAIgAygOMi0ucHJvdG8yX3ByZXNlcnZlX3Vua25vd25fZW51bV91bml0dGVz", - "dC5NeUVudW0STAoRcmVwZWF0ZWRfcGFja2VkX2UYAyADKA4yLS5wcm90bzJf", - "cHJlc2VydmVfdW5rbm93bl9lbnVtX3VuaXR0ZXN0Lk15RW51bUICEAESUwoc", - "cmVwZWF0ZWRfcGFja2VkX3VuZXhwZWN0ZWRfZRgEIAMoDjItLnByb3RvMl9w", - "cmVzZXJ2ZV91bmtub3duX2VudW1fdW5pdHRlc3QuTXlFbnVtEkIKCW9uZW9m", - "X2VfMRgFIAEoDjItLnByb3RvMl9wcmVzZXJ2ZV91bmtub3duX2VudW1fdW5p", - "dHRlc3QuTXlFbnVtSAASQgoJb25lb2ZfZV8yGAYgASgOMi0ucHJvdG8yX3By", - "ZXNlcnZlX3Vua25vd25fZW51bV91bml0dGVzdC5NeUVudW1IAEIDCgFvKiMK", - "Bk15RW51bRIHCgNGT08QABIHCgNCQVIQARIHCgNCQVoQAkIkqgIhR29vZ2xl", - "LlByb3RvY29sQnVmZmVycy5UZXN0UHJvdG9z")); - pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { - descriptor = root; - internal__static_proto2_preserve_unknown_enum_unittest_MyMessage__Descriptor = Descriptor.MessageTypes[0]; - internal__static_proto2_preserve_unknown_enum_unittest_MyMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_proto2_preserve_unknown_enum_unittest_MyMessage__Descriptor, - new string[] { "E", "RepeatedE", "RepeatedPackedE", "RepeatedPackedUnexpectedE", "OneofE1", "OneofE2", }); - pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); - RegisterAllExtensions(registry); - return registry; - }; - pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, - new pbd::FileDescriptor[] { - }, assigner); - } - #endregion - - } - #region Enums - public enum MyEnum { - FOO = 0, - BAR = 1, - BAZ = 2, - } - - #endregion - - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class MyMessage : pb::GeneratedMessage { - private MyMessage() { } - private static readonly MyMessage defaultInstance = new MyMessage().MakeReadOnly(); - private static readonly string[] _myMessageFieldNames = new string[] { "e", "oneof_e_1", "oneof_e_2", "repeated_e", "repeated_packed_e", "repeated_packed_unexpected_e" }; - private static readonly uint[] _myMessageFieldTags = new uint[] { 8, 40, 48, 16, 26, 32 }; - public static MyMessage DefaultInstance { - get { return defaultInstance; } - } - - public override MyMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override MyMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestPreserveUnknownEnum2.internal__static_proto2_preserve_unknown_enum_unittest_MyMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestPreserveUnknownEnum2.internal__static_proto2_preserve_unknown_enum_unittest_MyMessage__FieldAccessorTable; } - } - - public const int EFieldNumber = 1; - private bool hasE; - private global::Google.ProtocolBuffers.TestProtos.MyEnum e_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - public bool HasE { - get { return hasE; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum E { - get { return e_; } - } - - public const int RepeatedEFieldNumber = 2; - private pbc::PopsicleList repeatedE_ = new pbc::PopsicleList(); - public scg::IList RepeatedEList { - get { return pbc::Lists.AsReadOnly(repeatedE_); } - } - public int RepeatedECount { - get { return repeatedE_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum GetRepeatedE(int index) { - return repeatedE_[index]; - } - - public const int RepeatedPackedEFieldNumber = 3; - private int repeatedPackedEMemoizedSerializedSize; - private pbc::PopsicleList repeatedPackedE_ = new pbc::PopsicleList(); - public scg::IList RepeatedPackedEList { - get { return pbc::Lists.AsReadOnly(repeatedPackedE_); } - } - public int RepeatedPackedECount { - get { return repeatedPackedE_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum GetRepeatedPackedE(int index) { - return repeatedPackedE_[index]; - } - - public const int RepeatedPackedUnexpectedEFieldNumber = 4; - private pbc::PopsicleList repeatedPackedUnexpectedE_ = new pbc::PopsicleList(); - public scg::IList RepeatedPackedUnexpectedEList { - get { return pbc::Lists.AsReadOnly(repeatedPackedUnexpectedE_); } - } - public int RepeatedPackedUnexpectedECount { - get { return repeatedPackedUnexpectedE_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum GetRepeatedPackedUnexpectedE(int index) { - return repeatedPackedUnexpectedE_[index]; - } - - public const int OneofE1FieldNumber = 5; - private bool hasOneofE1; - private global::Google.ProtocolBuffers.TestProtos.MyEnum oneofE1_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - public bool HasOneofE1 { - get { return hasOneofE1; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum OneofE1 { - get { return oneofE1_; } - } - - public const int OneofE2FieldNumber = 6; - private bool hasOneofE2; - private global::Google.ProtocolBuffers.TestProtos.MyEnum oneofE2_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - public bool HasOneofE2 { - get { return hasOneofE2; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum OneofE2 { - get { return oneofE2_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _myMessageFieldNames; - if (hasE) { - output.WriteEnum(1, field_names[0], (int) E, E); - } - if (repeatedE_.Count > 0) { - output.WriteEnumArray(2, field_names[3], repeatedE_); - } - if (repeatedPackedE_.Count > 0) { - output.WritePackedEnumArray(3, field_names[4], repeatedPackedEMemoizedSerializedSize, repeatedPackedE_); - } - if (repeatedPackedUnexpectedE_.Count > 0) { - output.WriteEnumArray(4, field_names[5], repeatedPackedUnexpectedE_); - } - if (hasOneofE1) { - output.WriteEnum(5, field_names[1], (int) OneofE1, OneofE1); - } - if (hasOneofE2) { - output.WriteEnum(6, field_names[2], (int) OneofE2, OneofE2); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasE) { - size += pb::CodedOutputStream.ComputeEnumSize(1, (int) E); - } - { - int dataSize = 0; - if (repeatedE_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.MyEnum element in repeatedE_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * repeatedE_.Count; - } - } - { - int dataSize = 0; - if (repeatedPackedE_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.MyEnum element in repeatedPackedE_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1; - size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); - } - repeatedPackedEMemoizedSerializedSize = dataSize; - } - { - int dataSize = 0; - if (repeatedPackedUnexpectedE_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.MyEnum element in repeatedPackedUnexpectedE_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * repeatedPackedUnexpectedE_.Count; - } - } - if (hasOneofE1) { - size += pb::CodedOutputStream.ComputeEnumSize(5, (int) OneofE1); - } - if (hasOneofE2) { - size += pb::CodedOutputStream.ComputeEnumSize(6, (int) OneofE2); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static MyMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MyMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MyMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MyMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MyMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MyMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static MyMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static MyMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static MyMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MyMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private MyMessage MakeReadOnly() { - repeatedE_.MakeReadOnly(); - repeatedPackedE_.MakeReadOnly(); - repeatedPackedUnexpectedE_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(MyMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(MyMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private MyMessage result; - - private MyMessage PrepareBuilder() { - if (resultIsReadOnly) { - MyMessage original = result; - result = new MyMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override MyMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.MyMessage.Descriptor; } - } - - public override MyMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.MyMessage.DefaultInstance; } - } - - public override MyMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is MyMessage) { - return MergeFrom((MyMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(MyMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.MyMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasE) { - E = other.E; - } - if (other.repeatedE_.Count != 0) { - result.repeatedE_.Add(other.repeatedE_); - } - if (other.repeatedPackedE_.Count != 0) { - result.repeatedPackedE_.Add(other.repeatedPackedE_); - } - if (other.repeatedPackedUnexpectedE_.Count != 0) { - result.repeatedPackedUnexpectedE_.Add(other.repeatedPackedUnexpectedE_); - } - if (other.HasOneofE1) { - OneofE1 = other.OneofE1; - } - if (other.HasOneofE2) { - OneofE2 = other.OneofE2; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_myMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _myMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - object unknown; - if(input.ReadEnum(ref result.e_, out unknown)) { - result.hasE = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(1, (ulong)(int)unknown); - } - break; - } - case 18: - case 16: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedE_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(2, (ulong)(int)rawValue); - } - break; - } - case 26: - case 24: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedPackedE_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(3, (ulong)(int)rawValue); - } - break; - } - case 34: - case 32: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.repeatedPackedUnexpectedE_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(4, (ulong)(int)rawValue); - } - break; - } - case 40: { - object unknown; - if(input.ReadEnum(ref result.oneofE1_, out unknown)) { - result.hasOneofE1 = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(5, (ulong)(int)unknown); - } - break; - } - case 48: { - object unknown; - if(input.ReadEnum(ref result.oneofE2_, out unknown)) { - result.hasOneofE2 = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(6, (ulong)(int)unknown); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasE { - get { return result.hasE; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum E { - get { return result.E; } - set { SetE(value); } - } - public Builder SetE(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.hasE = true; - result.e_ = value; - return this; - } - public Builder ClearE() { - PrepareBuilder(); - result.hasE = false; - result.e_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - return this; - } - - public pbc::IPopsicleList RepeatedEList { - get { return PrepareBuilder().repeatedE_; } - } - public int RepeatedECount { - get { return result.RepeatedECount; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum GetRepeatedE(int index) { - return result.GetRepeatedE(index); - } - public Builder SetRepeatedE(int index, global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.repeatedE_[index] = value; - return this; - } - public Builder AddRepeatedE(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.repeatedE_.Add(value); - return this; - } - public Builder AddRangeRepeatedE(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedE_.Add(values); - return this; - } - public Builder ClearRepeatedE() { - PrepareBuilder(); - result.repeatedE_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedPackedEList { - get { return PrepareBuilder().repeatedPackedE_; } - } - public int RepeatedPackedECount { - get { return result.RepeatedPackedECount; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum GetRepeatedPackedE(int index) { - return result.GetRepeatedPackedE(index); - } - public Builder SetRepeatedPackedE(int index, global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.repeatedPackedE_[index] = value; - return this; - } - public Builder AddRepeatedPackedE(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.repeatedPackedE_.Add(value); - return this; - } - public Builder AddRangeRepeatedPackedE(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedPackedE_.Add(values); - return this; - } - public Builder ClearRepeatedPackedE() { - PrepareBuilder(); - result.repeatedPackedE_.Clear(); - return this; - } - - public pbc::IPopsicleList RepeatedPackedUnexpectedEList { - get { return PrepareBuilder().repeatedPackedUnexpectedE_; } - } - public int RepeatedPackedUnexpectedECount { - get { return result.RepeatedPackedUnexpectedECount; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum GetRepeatedPackedUnexpectedE(int index) { - return result.GetRepeatedPackedUnexpectedE(index); - } - public Builder SetRepeatedPackedUnexpectedE(int index, global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_[index] = value; - return this; - } - public Builder AddRepeatedPackedUnexpectedE(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_.Add(value); - return this; - } - public Builder AddRangeRepeatedPackedUnexpectedE(scg::IEnumerable values) { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_.Add(values); - return this; - } - public Builder ClearRepeatedPackedUnexpectedE() { - PrepareBuilder(); - result.repeatedPackedUnexpectedE_.Clear(); - return this; - } - - public bool HasOneofE1 { - get { return result.hasOneofE1; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum OneofE1 { - get { return result.OneofE1; } - set { SetOneofE1(value); } - } - public Builder SetOneofE1(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.hasOneofE1 = true; - result.oneofE1_ = value; - return this; - } - public Builder ClearOneofE1() { - PrepareBuilder(); - result.hasOneofE1 = false; - result.oneofE1_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - return this; - } - - public bool HasOneofE2 { - get { return result.hasOneofE2; } - } - public global::Google.ProtocolBuffers.TestProtos.MyEnum OneofE2 { - get { return result.OneofE2; } - set { SetOneofE2(value); } - } - public Builder SetOneofE2(global::Google.ProtocolBuffers.TestProtos.MyEnum value) { - PrepareBuilder(); - result.hasOneofE2 = true; - result.oneofE2_ = value; - return this; - } - public Builder ClearOneofE2() { - PrepareBuilder(); - result.hasOneofE2 = false; - result.oneofE2_ = global::Google.ProtocolBuffers.TestProtos.MyEnum.FOO; - return this; - } - } - static MyMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestPreserveUnknownEnum2.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasXmltest.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasXmltest.cs deleted file mode 100644 index 70bdbfa9..00000000 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasXmltest.cs +++ /dev/null @@ -1,2277 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: unittest_extras_xmltest.proto -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace Google.ProtocolBuffers.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnittestExtrasXmltest { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionEnum); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionText); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionNumber); - registry.Add(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionMessage); - } - #endregion - #region Extensions - public const int ExtensionEnumFieldNumber = 101; - public static pb::GeneratedExtensionBase ExtensionEnum; - public const int ExtensionTextFieldNumber = 102; - public static pb::GeneratedExtensionBase ExtensionText; - public const int ExtensionNumberFieldNumber = 103; - public static pb::GeneratedExtensionBase> ExtensionNumber; - public const int ExtensionMessageFieldNumber = 199; - public static pb::GeneratedExtensionBase ExtensionMessage; - #endregion - - #region Static variables - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlChild__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlChild__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlNoFields__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlNoFields__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlRescursive__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlRescursive__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlMessage_Children__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlMessage_Children__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_protobuf_unittest_extra_TestXmlExtension__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_extra_TestXmlExtension__FieldAccessorTable; - #endregion - #region Descriptor - public static pbd::FileDescriptor Descriptor { - get { return descriptor; } - } - private static pbd::FileDescriptor descriptor; - - static UnittestExtrasXmltest() { - byte[] descriptorData = global::System.Convert.FromBase64String( - string.Concat( - "Ch11bml0dGVzdF9leHRyYXNfeG1sdGVzdC5wcm90bxIXcHJvdG9idWZfdW5p", - "dHRlc3RfZXh0cmEiVQoMVGVzdFhtbENoaWxkEjUKB29wdGlvbnMYAyADKA4y", - "JC5wcm90b2J1Zl91bml0dGVzdF9leHRyYS5FbnVtT3B0aW9ucxIOCgZiaW5h", - "cnkYBCABKAwiEQoPVGVzdFhtbE5vRmllbGRzIk4KEVRlc3RYbWxSZXNjdXJz", - "aXZlEjkKBWNoaWxkGAEgASgLMioucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEu", - "VGVzdFhtbFJlc2N1cnNpdmUitwIKDlRlc3RYbWxNZXNzYWdlEg4KBm51bWJl", - "chgGIAEoAxIPCgdudW1iZXJzGAIgAygFEgwKBHRleHQYAyABKAkSEgoJdGV4", - "dGxpbmVzGLwFIAMoCRINCgV2YWxpZBgFIAEoCBI0CgVjaGlsZBgBIAEoCzIl", - "LnByb3RvYnVmX3VuaXR0ZXN0X2V4dHJhLlRlc3RYbWxDaGlsZBJDCghjaGls", - "ZHJlbhiRAyADKAoyMC5wcm90b2J1Zl91bml0dGVzdF9leHRyYS5UZXN0WG1s", - "TWVzc2FnZS5DaGlsZHJlbhpRCghDaGlsZHJlbhI1CgdvcHRpb25zGAMgAygO", - "MiQucHJvdG9idWZfdW5pdHRlc3RfZXh0cmEuRW51bU9wdGlvbnMSDgoGYmlu", - "YXJ5GAQgASgMKgUIZBDIASIiChBUZXN0WG1sRXh0ZW5zaW9uEg4KBm51bWJl", - "chgBIAIoBSoqCgtFbnVtT3B0aW9ucxIHCgNPTkUQABIHCgNUV08QARIJCgVU", - "SFJFRRACOmUKDmV4dGVuc2lvbl9lbnVtEicucHJvdG9idWZfdW5pdHRlc3Rf", - "ZXh0cmEuVGVzdFhtbE1lc3NhZ2UYZSABKA4yJC5wcm90b2J1Zl91bml0dGVz", - "dF9leHRyYS5FbnVtT3B0aW9uczo/Cg5leHRlbnNpb25fdGV4dBInLnByb3Rv", - "YnVmX3VuaXR0ZXN0X2V4dHJhLlRlc3RYbWxNZXNzYWdlGGYgASgJOkUKEGV4", - "dGVuc2lvbl9udW1iZXISJy5wcm90b2J1Zl91bml0dGVzdF9leHRyYS5UZXN0", - "WG1sTWVzc2FnZRhnIAMoBUICEAE6bgoRZXh0ZW5zaW9uX21lc3NhZ2USJy5w", - "cm90b2J1Zl91bml0dGVzdF9leHRyYS5UZXN0WG1sTWVzc2FnZRjHASABKAsy", - "KS5wcm90b2J1Zl91bml0dGVzdF9leHRyYS5UZXN0WG1sRXh0ZW5zaW9uQiZI", - "AaoCIUdvb2dsZS5Qcm90b2NvbEJ1ZmZlcnMuVGVzdFByb3Rvcw==")); - pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { - descriptor = root; - internal__static_protobuf_unittest_extra_TestXmlChild__Descriptor = Descriptor.MessageTypes[0]; - internal__static_protobuf_unittest_extra_TestXmlChild__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlChild__Descriptor, - new string[] { "Options", "Binary", }); - internal__static_protobuf_unittest_extra_TestXmlNoFields__Descriptor = Descriptor.MessageTypes[1]; - internal__static_protobuf_unittest_extra_TestXmlNoFields__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlNoFields__Descriptor, - new string[] { }); - internal__static_protobuf_unittest_extra_TestXmlRescursive__Descriptor = Descriptor.MessageTypes[2]; - internal__static_protobuf_unittest_extra_TestXmlRescursive__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlRescursive__Descriptor, - new string[] { "Child", }); - internal__static_protobuf_unittest_extra_TestXmlMessage__Descriptor = Descriptor.MessageTypes[3]; - internal__static_protobuf_unittest_extra_TestXmlMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlMessage__Descriptor, - new string[] { "Number", "Numbers", "Text", "Textlines", "Valid", "Child", "Children", }); - internal__static_protobuf_unittest_extra_TestXmlMessage_Children__Descriptor = internal__static_protobuf_unittest_extra_TestXmlMessage__Descriptor.NestedTypes[0]; - internal__static_protobuf_unittest_extra_TestXmlMessage_Children__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlMessage_Children__Descriptor, - new string[] { "Options", "Binary", }); - internal__static_protobuf_unittest_extra_TestXmlExtension__Descriptor = Descriptor.MessageTypes[4]; - internal__static_protobuf_unittest_extra_TestXmlExtension__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_extra_TestXmlExtension__Descriptor, - new string[] { "Number", }); - global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionEnum = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor.Extensions[0]); - global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionText = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor.Extensions[1]); - global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionNumber = pb::GeneratedRepeatExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor.Extensions[2]); - global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.ExtensionMessage = pb::GeneratedSingleExtension.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor.Extensions[3]); - pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); - RegisterAllExtensions(registry); - return registry; - }; - pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, - new pbd::FileDescriptor[] { - }, assigner); - } - #endregion - - } - #region Enums - public enum EnumOptions { - ONE = 0, - TWO = 1, - THREE = 2, - } - - #endregion - - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestXmlChild : pb::GeneratedMessage { - private TestXmlChild() { } - private static readonly TestXmlChild defaultInstance = new TestXmlChild().MakeReadOnly(); - private static readonly string[] _testXmlChildFieldNames = new string[] { "binary", "options" }; - private static readonly uint[] _testXmlChildFieldTags = new uint[] { 34, 24 }; - public static TestXmlChild DefaultInstance { - get { return defaultInstance; } - } - - public override TestXmlChild DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestXmlChild ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlChild__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlChild__FieldAccessorTable; } - } - - public const int OptionsFieldNumber = 3; - private pbc::PopsicleList options_ = new pbc::PopsicleList(); - public scg::IList OptionsList { - get { return pbc::Lists.AsReadOnly(options_); } - } - public int OptionsCount { - get { return options_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.EnumOptions GetOptions(int index) { - return options_[index]; - } - - public const int BinaryFieldNumber = 4; - private bool hasBinary; - private pb::ByteString binary_ = pb::ByteString.Empty; - public bool HasBinary { - get { return hasBinary; } - } - public pb::ByteString Binary { - get { return binary_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testXmlChildFieldNames; - if (options_.Count > 0) { - output.WriteEnumArray(3, field_names[1], options_); - } - if (hasBinary) { - output.WriteBytes(4, field_names[0], Binary); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - if (options_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.EnumOptions element in options_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * options_.Count; - } - } - if (hasBinary) { - size += pb::CodedOutputStream.ComputeBytesSize(4, Binary); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestXmlChild ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestXmlChild ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestXmlChild ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestXmlChild ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestXmlChild ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestXmlChild ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestXmlChild ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestXmlChild ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestXmlChild ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestXmlChild ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestXmlChild MakeReadOnly() { - options_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestXmlChild prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestXmlChild cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestXmlChild result; - - private TestXmlChild PrepareBuilder() { - if (resultIsReadOnly) { - TestXmlChild original = result; - result = new TestXmlChild(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestXmlChild MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlChild.Descriptor; } - } - - public override TestXmlChild DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlChild.DefaultInstance; } - } - - public override TestXmlChild BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestXmlChild) { - return MergeFrom((TestXmlChild) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestXmlChild other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlChild.DefaultInstance) return this; - PrepareBuilder(); - if (other.options_.Count != 0) { - result.options_.Add(other.options_); - } - if (other.HasBinary) { - Binary = other.Binary; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testXmlChildFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testXmlChildFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 26: - case 24: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.options_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(3, (ulong)(int)rawValue); - } - break; - } - case 34: { - result.hasBinary = input.ReadBytes(ref result.binary_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public pbc::IPopsicleList OptionsList { - get { return PrepareBuilder().options_; } - } - public int OptionsCount { - get { return result.OptionsCount; } - } - public global::Google.ProtocolBuffers.TestProtos.EnumOptions GetOptions(int index) { - return result.GetOptions(index); - } - public Builder SetOptions(int index, global::Google.ProtocolBuffers.TestProtos.EnumOptions value) { - PrepareBuilder(); - result.options_[index] = value; - return this; - } - public Builder AddOptions(global::Google.ProtocolBuffers.TestProtos.EnumOptions value) { - PrepareBuilder(); - result.options_.Add(value); - return this; - } - public Builder AddRangeOptions(scg::IEnumerable values) { - PrepareBuilder(); - result.options_.Add(values); - return this; - } - public Builder ClearOptions() { - PrepareBuilder(); - result.options_.Clear(); - return this; - } - - public bool HasBinary { - get { return result.hasBinary; } - } - public pb::ByteString Binary { - get { return result.Binary; } - set { SetBinary(value); } - } - public Builder SetBinary(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBinary = true; - result.binary_ = value; - return this; - } - public Builder ClearBinary() { - PrepareBuilder(); - result.hasBinary = false; - result.binary_ = pb::ByteString.Empty; - return this; - } - } - static TestXmlChild() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestXmlNoFields : pb::GeneratedMessage { - private TestXmlNoFields() { } - private static readonly TestXmlNoFields defaultInstance = new TestXmlNoFields().MakeReadOnly(); - private static readonly string[] _testXmlNoFieldsFieldNames = new string[] { }; - private static readonly uint[] _testXmlNoFieldsFieldTags = new uint[] { }; - public static TestXmlNoFields DefaultInstance { - get { return defaultInstance; } - } - - public override TestXmlNoFields DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestXmlNoFields ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlNoFields__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlNoFields__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testXmlNoFieldsFieldNames; - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestXmlNoFields ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestXmlNoFields ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestXmlNoFields ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestXmlNoFields ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestXmlNoFields ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestXmlNoFields ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestXmlNoFields ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestXmlNoFields ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestXmlNoFields ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestXmlNoFields ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestXmlNoFields MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestXmlNoFields prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestXmlNoFields cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestXmlNoFields result; - - private TestXmlNoFields PrepareBuilder() { - if (resultIsReadOnly) { - TestXmlNoFields original = result; - result = new TestXmlNoFields(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestXmlNoFields MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlNoFields.Descriptor; } - } - - public override TestXmlNoFields DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlNoFields.DefaultInstance; } - } - - public override TestXmlNoFields BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestXmlNoFields) { - return MergeFrom((TestXmlNoFields) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestXmlNoFields other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlNoFields.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testXmlNoFieldsFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testXmlNoFieldsFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static TestXmlNoFields() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestXmlRescursive : pb::GeneratedMessage { - private TestXmlRescursive() { } - private static readonly TestXmlRescursive defaultInstance = new TestXmlRescursive().MakeReadOnly(); - private static readonly string[] _testXmlRescursiveFieldNames = new string[] { "child" }; - private static readonly uint[] _testXmlRescursiveFieldTags = new uint[] { 10 }; - public static TestXmlRescursive DefaultInstance { - get { return defaultInstance; } - } - - public override TestXmlRescursive DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestXmlRescursive ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlRescursive__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlRescursive__FieldAccessorTable; } - } - - public const int ChildFieldNumber = 1; - private bool hasChild; - private global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive child_; - public bool HasChild { - get { return hasChild; } - } - public global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive Child { - get { return child_ ?? global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.DefaultInstance; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testXmlRescursiveFieldNames; - if (hasChild) { - output.WriteMessage(1, field_names[0], Child); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasChild) { - size += pb::CodedOutputStream.ComputeMessageSize(1, Child); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestXmlRescursive ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestXmlRescursive ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestXmlRescursive ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestXmlRescursive ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestXmlRescursive ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestXmlRescursive ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestXmlRescursive ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestXmlRescursive ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestXmlRescursive ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestXmlRescursive ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestXmlRescursive MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestXmlRescursive prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestXmlRescursive cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestXmlRescursive result; - - private TestXmlRescursive PrepareBuilder() { - if (resultIsReadOnly) { - TestXmlRescursive original = result; - result = new TestXmlRescursive(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestXmlRescursive MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.Descriptor; } - } - - public override TestXmlRescursive DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.DefaultInstance; } - } - - public override TestXmlRescursive BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestXmlRescursive) { - return MergeFrom((TestXmlRescursive) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestXmlRescursive other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasChild) { - MergeChild(other.Child); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testXmlRescursiveFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testXmlRescursiveFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.CreateBuilder(); - if (result.hasChild) { - subBuilder.MergeFrom(Child); - } - input.ReadMessage(subBuilder, extensionRegistry); - Child = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasChild { - get { return result.hasChild; } - } - public global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive Child { - get { return result.Child; } - set { SetChild(value); } - } - public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasChild = true; - result.child_ = value; - return this; - } - public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasChild = true; - result.child_ = builderForValue.Build(); - return this; - } - public Builder MergeChild(global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasChild && - result.child_ != global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.DefaultInstance) { - result.child_ = global::Google.ProtocolBuffers.TestProtos.TestXmlRescursive.CreateBuilder(result.child_).MergeFrom(value).BuildPartial(); - } else { - result.child_ = value; - } - result.hasChild = true; - return this; - } - public Builder ClearChild() { - PrepareBuilder(); - result.hasChild = false; - result.child_ = null; - return this; - } - } - static TestXmlRescursive() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestXmlMessage : pb::ExtendableMessage { - private TestXmlMessage() { } - private static readonly TestXmlMessage defaultInstance = new TestXmlMessage().MakeReadOnly(); - private static readonly string[] _testXmlMessageFieldNames = new string[] { "child", "children", "number", "numbers", "text", "textlines", "valid" }; - private static readonly uint[] _testXmlMessageFieldTags = new uint[] { 10, 3211, 48, 16, 26, 5602, 40 }; - public static TestXmlMessage DefaultInstance { - get { return defaultInstance; } - } - - public override TestXmlMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestXmlMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlMessage__FieldAccessorTable; } - } - - #region Nested types - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class Types { - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Children : pb::GeneratedMessage { - private Children() { } - private static readonly Children defaultInstance = new Children().MakeReadOnly(); - private static readonly string[] _childrenFieldNames = new string[] { "binary", "options" }; - private static readonly uint[] _childrenFieldTags = new uint[] { 34, 24 }; - public static Children DefaultInstance { - get { return defaultInstance; } - } - - public override Children DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override Children ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlMessage_Children__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlMessage_Children__FieldAccessorTable; } - } - - public const int OptionsFieldNumber = 3; - private pbc::PopsicleList options_ = new pbc::PopsicleList(); - public scg::IList OptionsList { - get { return pbc::Lists.AsReadOnly(options_); } - } - public int OptionsCount { - get { return options_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.EnumOptions GetOptions(int index) { - return options_[index]; - } - - public const int BinaryFieldNumber = 4; - private bool hasBinary; - private pb::ByteString binary_ = pb::ByteString.Empty; - public bool HasBinary { - get { return hasBinary; } - } - public pb::ByteString Binary { - get { return binary_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _childrenFieldNames; - if (options_.Count > 0) { - output.WriteEnumArray(3, field_names[1], options_); - } - if (hasBinary) { - output.WriteBytes(4, field_names[0], Binary); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - if (options_.Count > 0) { - foreach (global::Google.ProtocolBuffers.TestProtos.EnumOptions element in options_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * options_.Count; - } - } - if (hasBinary) { - size += pb::CodedOutputStream.ComputeBytesSize(4, Binary); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static Children ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Children ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Children ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static Children ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static Children ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Children ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static Children ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static Children ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static Children ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static Children ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private Children MakeReadOnly() { - options_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(Children prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(Children cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private Children result; - - private Children PrepareBuilder() { - if (resultIsReadOnly) { - Children original = result; - result = new Children(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override Children MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.Descriptor; } - } - - public override Children DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.DefaultInstance; } - } - - public override Children BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is Children) { - return MergeFrom((Children) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(Children other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.DefaultInstance) return this; - PrepareBuilder(); - if (other.options_.Count != 0) { - result.options_.Add(other.options_); - } - if (other.HasBinary) { - Binary = other.Binary; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_childrenFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _childrenFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 26: - case 24: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.options_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(3, (ulong)(int)rawValue); - } - break; - } - case 34: { - result.hasBinary = input.ReadBytes(ref result.binary_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public pbc::IPopsicleList OptionsList { - get { return PrepareBuilder().options_; } - } - public int OptionsCount { - get { return result.OptionsCount; } - } - public global::Google.ProtocolBuffers.TestProtos.EnumOptions GetOptions(int index) { - return result.GetOptions(index); - } - public Builder SetOptions(int index, global::Google.ProtocolBuffers.TestProtos.EnumOptions value) { - PrepareBuilder(); - result.options_[index] = value; - return this; - } - public Builder AddOptions(global::Google.ProtocolBuffers.TestProtos.EnumOptions value) { - PrepareBuilder(); - result.options_.Add(value); - return this; - } - public Builder AddRangeOptions(scg::IEnumerable values) { - PrepareBuilder(); - result.options_.Add(values); - return this; - } - public Builder ClearOptions() { - PrepareBuilder(); - result.options_.Clear(); - return this; - } - - public bool HasBinary { - get { return result.hasBinary; } - } - public pb::ByteString Binary { - get { return result.Binary; } - set { SetBinary(value); } - } - public Builder SetBinary(pb::ByteString value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasBinary = true; - result.binary_ = value; - return this; - } - public Builder ClearBinary() { - PrepareBuilder(); - result.hasBinary = false; - result.binary_ = pb::ByteString.Empty; - return this; - } - } - static Children() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); - } - } - - } - #endregion - - public const int NumberFieldNumber = 6; - private bool hasNumber; - private long number_; - public bool HasNumber { - get { return hasNumber; } - } - public long Number { - get { return number_; } - } - - public const int NumbersFieldNumber = 2; - private pbc::PopsicleList numbers_ = new pbc::PopsicleList(); - public scg::IList NumbersList { - get { return pbc::Lists.AsReadOnly(numbers_); } - } - public int NumbersCount { - get { return numbers_.Count; } - } - public int GetNumbers(int index) { - return numbers_[index]; - } - - public const int TextFieldNumber = 3; - private bool hasText; - private string text_ = ""; - public bool HasText { - get { return hasText; } - } - public string Text { - get { return text_; } - } - - public const int TextlinesFieldNumber = 700; - private pbc::PopsicleList textlines_ = new pbc::PopsicleList(); - public scg::IList TextlinesList { - get { return pbc::Lists.AsReadOnly(textlines_); } - } - public int TextlinesCount { - get { return textlines_.Count; } - } - public string GetTextlines(int index) { - return textlines_[index]; - } - - public const int ValidFieldNumber = 5; - private bool hasValid; - private bool valid_; - public bool HasValid { - get { return hasValid; } - } - public bool Valid { - get { return valid_; } - } - - public const int ChildFieldNumber = 1; - private bool hasChild; - private global::Google.ProtocolBuffers.TestProtos.TestXmlChild child_; - public bool HasChild { - get { return hasChild; } - } - public global::Google.ProtocolBuffers.TestProtos.TestXmlChild Child { - get { return child_ ?? global::Google.ProtocolBuffers.TestProtos.TestXmlChild.DefaultInstance; } - } - - public const int ChildrenFieldNumber = 401; - private pbc::PopsicleList children_ = new pbc::PopsicleList(); - public scg::IList ChildrenList { - get { return children_; } - } - public int ChildrenCount { - get { return children_.Count; } - } - public global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children GetChildren(int index) { - return children_[index]; - } - - public override bool IsInitialized { - get { - if (!ExtensionsAreInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testXmlMessageFieldNames; - pb::ExtendableMessage.ExtensionWriter extensionWriter = CreateExtensionWriter(this); - if (hasChild) { - output.WriteMessage(1, field_names[0], Child); - } - if (numbers_.Count > 0) { - output.WriteInt32Array(2, field_names[3], numbers_); - } - if (hasText) { - output.WriteString(3, field_names[4], Text); - } - if (hasValid) { - output.WriteBool(5, field_names[6], Valid); - } - if (hasNumber) { - output.WriteInt64(6, field_names[2], Number); - } - extensionWriter.WriteUntil(200, output); - if (children_.Count > 0) { - output.WriteGroupArray(401, field_names[1], children_); - } - if (textlines_.Count > 0) { - output.WriteStringArray(700, field_names[5], textlines_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasNumber) { - size += pb::CodedOutputStream.ComputeInt64Size(6, Number); - } - { - int dataSize = 0; - foreach (int element in NumbersList) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 1 * numbers_.Count; - } - if (hasText) { - size += pb::CodedOutputStream.ComputeStringSize(3, Text); - } - { - int dataSize = 0; - foreach (string element in TextlinesList) { - dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element); - } - size += dataSize; - size += 2 * textlines_.Count; - } - if (hasValid) { - size += pb::CodedOutputStream.ComputeBoolSize(5, Valid); - } - if (hasChild) { - size += pb::CodedOutputStream.ComputeMessageSize(1, Child); - } - foreach (global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children element in ChildrenList) { - size += pb::CodedOutputStream.ComputeGroupSize(401, element); - } - size += ExtensionsSerializedSize; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestXmlMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestXmlMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestXmlMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestXmlMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestXmlMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestXmlMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestXmlMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestXmlMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestXmlMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestXmlMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestXmlMessage MakeReadOnly() { - numbers_.MakeReadOnly(); - textlines_.MakeReadOnly(); - children_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestXmlMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::ExtendableBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestXmlMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestXmlMessage result; - - private TestXmlMessage PrepareBuilder() { - if (resultIsReadOnly) { - TestXmlMessage original = result; - result = new TestXmlMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestXmlMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Descriptor; } - } - - public override TestXmlMessage DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.DefaultInstance; } - } - - public override TestXmlMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestXmlMessage) { - return MergeFrom((TestXmlMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestXmlMessage other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasNumber) { - Number = other.Number; - } - if (other.numbers_.Count != 0) { - result.numbers_.Add(other.numbers_); - } - if (other.HasText) { - Text = other.Text; - } - if (other.textlines_.Count != 0) { - result.textlines_.Add(other.textlines_); - } - if (other.HasValid) { - Valid = other.Valid; - } - if (other.HasChild) { - MergeChild(other.Child); - } - if (other.children_.Count != 0) { - result.children_.Add(other.children_); - } - this.MergeExtensionFields(other); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testXmlMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testXmlMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::Google.ProtocolBuffers.TestProtos.TestXmlChild.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestXmlChild.CreateBuilder(); - if (result.hasChild) { - subBuilder.MergeFrom(Child); - } - input.ReadMessage(subBuilder, extensionRegistry); - Child = subBuilder.BuildPartial(); - break; - } - case 18: - case 16: { - input.ReadInt32Array(tag, field_name, result.numbers_); - break; - } - case 26: { - result.hasText = input.ReadString(ref result.text_); - break; - } - case 40: { - result.hasValid = input.ReadBool(ref result.valid_); - break; - } - case 48: { - result.hasNumber = input.ReadInt64(ref result.number_); - break; - } - case 3211: { - input.ReadGroupArray(tag, field_name, result.children_, global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.DefaultInstance, extensionRegistry); - break; - } - case 5602: { - input.ReadStringArray(tag, field_name, result.textlines_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasNumber { - get { return result.hasNumber; } - } - public long Number { - get { return result.Number; } - set { SetNumber(value); } - } - public Builder SetNumber(long value) { - PrepareBuilder(); - result.hasNumber = true; - result.number_ = value; - return this; - } - public Builder ClearNumber() { - PrepareBuilder(); - result.hasNumber = false; - result.number_ = 0L; - return this; - } - - public pbc::IPopsicleList NumbersList { - get { return PrepareBuilder().numbers_; } - } - public int NumbersCount { - get { return result.NumbersCount; } - } - public int GetNumbers(int index) { - return result.GetNumbers(index); - } - public Builder SetNumbers(int index, int value) { - PrepareBuilder(); - result.numbers_[index] = value; - return this; - } - public Builder AddNumbers(int value) { - PrepareBuilder(); - result.numbers_.Add(value); - return this; - } - public Builder AddRangeNumbers(scg::IEnumerable values) { - PrepareBuilder(); - result.numbers_.Add(values); - return this; - } - public Builder ClearNumbers() { - PrepareBuilder(); - result.numbers_.Clear(); - return this; - } - - public bool HasText { - get { return result.hasText; } - } - public string Text { - get { return result.Text; } - set { SetText(value); } - } - public Builder SetText(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasText = true; - result.text_ = value; - return this; - } - public Builder ClearText() { - PrepareBuilder(); - result.hasText = false; - result.text_ = ""; - return this; - } - - public pbc::IPopsicleList TextlinesList { - get { return PrepareBuilder().textlines_; } - } - public int TextlinesCount { - get { return result.TextlinesCount; } - } - public string GetTextlines(int index) { - return result.GetTextlines(index); - } - public Builder SetTextlines(int index, string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.textlines_[index] = value; - return this; - } - public Builder AddTextlines(string value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.textlines_.Add(value); - return this; - } - public Builder AddRangeTextlines(scg::IEnumerable values) { - PrepareBuilder(); - result.textlines_.Add(values); - return this; - } - public Builder ClearTextlines() { - PrepareBuilder(); - result.textlines_.Clear(); - return this; - } - - public bool HasValid { - get { return result.hasValid; } - } - public bool Valid { - get { return result.Valid; } - set { SetValid(value); } - } - public Builder SetValid(bool value) { - PrepareBuilder(); - result.hasValid = true; - result.valid_ = value; - return this; - } - public Builder ClearValid() { - PrepareBuilder(); - result.hasValid = false; - result.valid_ = false; - return this; - } - - public bool HasChild { - get { return result.hasChild; } - } - public global::Google.ProtocolBuffers.TestProtos.TestXmlChild Child { - get { return result.Child; } - set { SetChild(value); } - } - public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.TestXmlChild value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasChild = true; - result.child_ = value; - return this; - } - public Builder SetChild(global::Google.ProtocolBuffers.TestProtos.TestXmlChild.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasChild = true; - result.child_ = builderForValue.Build(); - return this; - } - public Builder MergeChild(global::Google.ProtocolBuffers.TestProtos.TestXmlChild value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasChild && - result.child_ != global::Google.ProtocolBuffers.TestProtos.TestXmlChild.DefaultInstance) { - result.child_ = global::Google.ProtocolBuffers.TestProtos.TestXmlChild.CreateBuilder(result.child_).MergeFrom(value).BuildPartial(); - } else { - result.child_ = value; - } - result.hasChild = true; - return this; - } - public Builder ClearChild() { - PrepareBuilder(); - result.hasChild = false; - result.child_ = null; - return this; - } - - public pbc::IPopsicleList ChildrenList { - get { return PrepareBuilder().children_; } - } - public int ChildrenCount { - get { return result.ChildrenCount; } - } - public global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children GetChildren(int index) { - return result.GetChildren(index); - } - public Builder SetChildren(int index, global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.children_[index] = value; - return this; - } - public Builder SetChildren(int index, global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.children_[index] = builderForValue.Build(); - return this; - } - public Builder AddChildren(global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.children_.Add(value); - return this; - } - public Builder AddChildren(global::Google.ProtocolBuffers.TestProtos.TestXmlMessage.Types.Children.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.children_.Add(builderForValue.Build()); - return this; - } - public Builder AddRangeChildren(scg::IEnumerable values) { - PrepareBuilder(); - result.children_.Add(values); - return this; - } - public Builder ClearChildren() { - PrepareBuilder(); - result.children_.Clear(); - return this; - } - } - static TestXmlMessage() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class TestXmlExtension : pb::GeneratedMessage { - private TestXmlExtension() { } - private static readonly TestXmlExtension defaultInstance = new TestXmlExtension().MakeReadOnly(); - private static readonly string[] _testXmlExtensionFieldNames = new string[] { "number" }; - private static readonly uint[] _testXmlExtensionFieldTags = new uint[] { 8 }; - public static TestXmlExtension DefaultInstance { - get { return defaultInstance; } - } - - public override TestXmlExtension DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override TestXmlExtension ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlExtension__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.internal__static_protobuf_unittest_extra_TestXmlExtension__FieldAccessorTable; } - } - - public const int NumberFieldNumber = 1; - private bool hasNumber; - private int number_; - public bool HasNumber { - get { return hasNumber; } - } - public int Number { - get { return number_; } - } - - public override bool IsInitialized { - get { - if (!hasNumber) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _testXmlExtensionFieldNames; - if (hasNumber) { - output.WriteInt32(1, field_names[0], Number); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasNumber) { - size += pb::CodedOutputStream.ComputeInt32Size(1, Number); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static TestXmlExtension ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestXmlExtension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestXmlExtension ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static TestXmlExtension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static TestXmlExtension ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestXmlExtension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static TestXmlExtension ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static TestXmlExtension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static TestXmlExtension ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static TestXmlExtension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private TestXmlExtension MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(TestXmlExtension prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(TestXmlExtension cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private TestXmlExtension result; - - private TestXmlExtension PrepareBuilder() { - if (resultIsReadOnly) { - TestXmlExtension original = result; - result = new TestXmlExtension(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override TestXmlExtension MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlExtension.Descriptor; } - } - - public override TestXmlExtension DefaultInstanceForType { - get { return global::Google.ProtocolBuffers.TestProtos.TestXmlExtension.DefaultInstance; } - } - - public override TestXmlExtension BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is TestXmlExtension) { - return MergeFrom((TestXmlExtension) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(TestXmlExtension other) { - if (other == global::Google.ProtocolBuffers.TestProtos.TestXmlExtension.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasNumber) { - Number = other.Number; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_testXmlExtensionFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _testXmlExtensionFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasNumber = input.ReadInt32(ref result.number_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasNumber { - get { return result.hasNumber; } - } - public int Number { - get { return result.Number; } - set { SetNumber(value); } - } - public Builder SetNumber(int value) { - PrepareBuilder(); - result.hasNumber = true; - result.number_ = value; - return this; - } - public Builder ClearNumber() { - PrepareBuilder(); - result.hasNumber = false; - result.number_ = 0; - return this; - } - } - static TestXmlExtension() { - object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnittestExtrasXmltest.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestIssues.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestIssues.cs deleted file mode 100644 index e0bc151b..00000000 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestIssues.cs +++ /dev/null @@ -1,3437 +0,0 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: unittest_issues.proto -#pragma warning disable 1591, 0612, 3021 -#region Designer generated code - -using pb = global::Google.ProtocolBuffers; -using pbc = global::Google.ProtocolBuffers.Collections; -using pbd = global::Google.ProtocolBuffers.Descriptors; -using scg = global::System.Collections.Generic; -namespace UnitTest.Issues.TestProtos { - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public static partial class UnittestIssues { - - #region Extension registration - public static void RegisterAllExtensions(pb::ExtensionRegistry registry) { - } - #endregion - #region Static variables - internal static pbd::MessageDescriptor internal__static_unittest_issues_A__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_A__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_unittest_issues_B__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_B__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_unittest_issues_AB__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_AB__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_unittest_issues_NumberField__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_NumberField__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_unittest_issues_MyMessageAReferenceB__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_MyMessageAReferenceB__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_unittest_issues_MyMessageBReferenceA__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_MyMessageBReferenceA__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_unittest_issues_NegativeEnumMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_NegativeEnumMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_unittest_issues_DeprecatedChild__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_DeprecatedChild__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_unittest_issues_DeprecatedFieldsMessage__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_DeprecatedFieldsMessage__FieldAccessorTable; - internal static pbd::MessageDescriptor internal__static_unittest_issues_ItemField__Descriptor; - internal static pb::FieldAccess.FieldAccessorTable internal__static_unittest_issues_ItemField__FieldAccessorTable; - #endregion - #region Descriptor - public static pbd::FileDescriptor Descriptor { - get { return descriptor; } - } - private static pbd::FileDescriptor descriptor; - - static UnittestIssues() { - byte[] descriptorData = global::System.Convert.FromBase64String( - string.Concat( - "ChV1bml0dGVzdF9pc3N1ZXMucHJvdG8SD3VuaXR0ZXN0X2lzc3VlcyIPCgFB", - "EgoKAl9BGAEgASgFIg8KAUISCgoCQl8YASABKAUiEQoCQUISCwoDYV9iGAEg", - "ASgFIhoKC051bWJlckZpZWxkEgsKA18wMRgBIAEoBSJMChRNeU1lc3NhZ2VB", - "UmVmZXJlbmNlQhI0CgV2YWx1ZRgBIAIoCzIlLnVuaXR0ZXN0X2lzc3Vlcy5N", - "eU1lc3NhZ2VCUmVmZXJlbmNlQSJMChRNeU1lc3NhZ2VCUmVmZXJlbmNlQRI0", - "CgV2YWx1ZRgBIAIoCzIlLnVuaXR0ZXN0X2lzc3Vlcy5NeU1lc3NhZ2VBUmVm", - "ZXJlbmNlQiKsAQoTTmVnYXRpdmVFbnVtTWVzc2FnZRIsCgV2YWx1ZRgBIAEo", - "DjIdLnVuaXR0ZXN0X2lzc3Vlcy5OZWdhdGl2ZUVudW0SLQoGdmFsdWVzGAIg", - "AygOMh0udW5pdHRlc3RfaXNzdWVzLk5lZ2F0aXZlRW51bRI4Cg1wYWNrZWRf", - "dmFsdWVzGAMgAygOMh0udW5pdHRlc3RfaXNzdWVzLk5lZ2F0aXZlRW51bUIC", - "EAEiEQoPRGVwcmVjYXRlZENoaWxkIrkCChdEZXByZWNhdGVkRmllbGRzTWVz", - "c2FnZRIaCg5QcmltaXRpdmVWYWx1ZRgBIAEoBUICGAESGgoOUHJpbWl0aXZl", - "QXJyYXkYAiADKAVCAhgBEjoKDE1lc3NhZ2VWYWx1ZRgDIAEoCzIgLnVuaXR0", - "ZXN0X2lzc3Vlcy5EZXByZWNhdGVkQ2hpbGRCAhgBEjoKDE1lc3NhZ2VBcnJh", - "eRgEIAMoCzIgLnVuaXR0ZXN0X2lzc3Vlcy5EZXByZWNhdGVkQ2hpbGRCAhgB", - "EjYKCUVudW1WYWx1ZRgFIAEoDjIfLnVuaXR0ZXN0X2lzc3Vlcy5EZXByZWNh", - "dGVkRW51bUICGAESNgoJRW51bUFycmF5GAYgAygOMh8udW5pdHRlc3RfaXNz", - "dWVzLkRlcHJlY2F0ZWRFbnVtQgIYASIZCglJdGVtRmllbGQSDAoEaXRlbRgB", - "IAEoBSpHCgxOZWdhdGl2ZUVudW0SFgoJRml2ZUJlbG93EPv//////////wES", - "FQoITWludXNPbmUQ////////////ARIICgRaZXJvEAAqGQoORGVwcmVjYXRl", - "ZEVudW0SBwoDb25lEAFCH0gBqgIaVW5pdFRlc3QuSXNzdWVzLlRlc3RQcm90", - "b3M=")); - pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) { - descriptor = root; - internal__static_unittest_issues_A__Descriptor = Descriptor.MessageTypes[0]; - internal__static_unittest_issues_A__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_A__Descriptor, - new string[] { "A_", }); - internal__static_unittest_issues_B__Descriptor = Descriptor.MessageTypes[1]; - internal__static_unittest_issues_B__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_B__Descriptor, - new string[] { "B_", }); - internal__static_unittest_issues_AB__Descriptor = Descriptor.MessageTypes[2]; - internal__static_unittest_issues_AB__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_AB__Descriptor, - new string[] { "AB_", }); - internal__static_unittest_issues_NumberField__Descriptor = Descriptor.MessageTypes[3]; - internal__static_unittest_issues_NumberField__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_NumberField__Descriptor, - new string[] { "01", }); - internal__static_unittest_issues_MyMessageAReferenceB__Descriptor = Descriptor.MessageTypes[4]; - internal__static_unittest_issues_MyMessageAReferenceB__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_MyMessageAReferenceB__Descriptor, - new string[] { "Value", }); - internal__static_unittest_issues_MyMessageBReferenceA__Descriptor = Descriptor.MessageTypes[5]; - internal__static_unittest_issues_MyMessageBReferenceA__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_MyMessageBReferenceA__Descriptor, - new string[] { "Value", }); - internal__static_unittest_issues_NegativeEnumMessage__Descriptor = Descriptor.MessageTypes[6]; - internal__static_unittest_issues_NegativeEnumMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_NegativeEnumMessage__Descriptor, - new string[] { "Value", "Values", "PackedValues", }); - internal__static_unittest_issues_DeprecatedChild__Descriptor = Descriptor.MessageTypes[7]; - internal__static_unittest_issues_DeprecatedChild__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_DeprecatedChild__Descriptor, - new string[] { }); - internal__static_unittest_issues_DeprecatedFieldsMessage__Descriptor = Descriptor.MessageTypes[8]; - internal__static_unittest_issues_DeprecatedFieldsMessage__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_DeprecatedFieldsMessage__Descriptor, - new string[] { "PrimitiveValue", "PrimitiveArray", "MessageValue", "MessageArray", "EnumValue", "EnumArray", }); - internal__static_unittest_issues_ItemField__Descriptor = Descriptor.MessageTypes[9]; - internal__static_unittest_issues_ItemField__FieldAccessorTable = - new pb::FieldAccess.FieldAccessorTable(internal__static_unittest_issues_ItemField__Descriptor, - new string[] { "Item", }); - pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance(); - RegisterAllExtensions(registry); - return registry; - }; - pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData, - new pbd::FileDescriptor[] { - }, assigner); - } - #endregion - - } - #region Enums - public enum NegativeEnum { - FiveBelow = -5, - MinusOne = -1, - Zero = 0, - } - - public enum DeprecatedEnum { - one = 1, - } - - #endregion - - #region Messages - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class A : pb::GeneratedMessage { - private A() { } - private static readonly A defaultInstance = new A().MakeReadOnly(); - private static readonly string[] _aFieldNames = new string[] { "_A" }; - private static readonly uint[] _aFieldTags = new uint[] { 8 }; - public static A DefaultInstance { - get { return defaultInstance; } - } - - public override A DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override A ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_A__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_A__FieldAccessorTable; } - } - - public const int A_FieldNumber = 1; - private bool hasA_; - private int A_; - public bool HasA_ { - get { return hasA_; } - } - public int A_ { - get { return A_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _aFieldNames; - if (hasA_) { - output.WriteInt32(1, field_names[0], A_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasA_) { - size += pb::CodedOutputStream.ComputeInt32Size(1, A_); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static A ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static A ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static A ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static A ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static A ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static A ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static A ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static A ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static A ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static A ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private A MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(A prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(A cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private A result; - - private A PrepareBuilder() { - if (resultIsReadOnly) { - A original = result; - result = new A(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override A MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::UnitTest.Issues.TestProtos.A.Descriptor; } - } - - public override A DefaultInstanceForType { - get { return global::UnitTest.Issues.TestProtos.A.DefaultInstance; } - } - - public override A BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is A) { - return MergeFrom((A) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(A other) { - if (other == global::UnitTest.Issues.TestProtos.A.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasA_) { - A_ = other.A_; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_aFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _aFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasA_ = input.ReadInt32(ref result.A_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasA_ { - get { return result.hasA_; } - } - public int A_ { - get { return result.A_; } - set { SetA_(value); } - } - public Builder SetA_(int value) { - PrepareBuilder(); - result.hasA_ = true; - result.A_ = value; - return this; - } - public Builder ClearA_() { - PrepareBuilder(); - result.hasA_ = false; - result.A_ = 0; - return this; - } - } - static A() { - object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class B : pb::GeneratedMessage { - private B() { } - private static readonly B defaultInstance = new B().MakeReadOnly(); - private static readonly string[] _bFieldNames = new string[] { "B_" }; - private static readonly uint[] _bFieldTags = new uint[] { 8 }; - public static B DefaultInstance { - get { return defaultInstance; } - } - - public override B DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override B ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_B__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_B__FieldAccessorTable; } - } - - public const int B_FieldNumber = 1; - private bool hasB_; - private int b_; - public bool HasB_ { - get { return hasB_; } - } - public int B_ { - get { return b_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _bFieldNames; - if (hasB_) { - output.WriteInt32(1, field_names[0], B_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasB_) { - size += pb::CodedOutputStream.ComputeInt32Size(1, B_); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static B ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static B ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static B ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static B ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static B ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static B ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static B ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static B ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static B ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static B ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private B MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(B prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(B cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private B result; - - private B PrepareBuilder() { - if (resultIsReadOnly) { - B original = result; - result = new B(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override B MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::UnitTest.Issues.TestProtos.B.Descriptor; } - } - - public override B DefaultInstanceForType { - get { return global::UnitTest.Issues.TestProtos.B.DefaultInstance; } - } - - public override B BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is B) { - return MergeFrom((B) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(B other) { - if (other == global::UnitTest.Issues.TestProtos.B.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasB_) { - B_ = other.B_; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_bFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _bFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasB_ = input.ReadInt32(ref result.b_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasB_ { - get { return result.hasB_; } - } - public int B_ { - get { return result.B_; } - set { SetB_(value); } - } - public Builder SetB_(int value) { - PrepareBuilder(); - result.hasB_ = true; - result.b_ = value; - return this; - } - public Builder ClearB_() { - PrepareBuilder(); - result.hasB_ = false; - result.b_ = 0; - return this; - } - } - static B() { - object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class AB : pb::GeneratedMessage { - private AB() { } - private static readonly AB defaultInstance = new AB().MakeReadOnly(); - private static readonly string[] _aBFieldNames = new string[] { "a_b" }; - private static readonly uint[] _aBFieldTags = new uint[] { 8 }; - public static AB DefaultInstance { - get { return defaultInstance; } - } - - public override AB DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override AB ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_AB__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_AB__FieldAccessorTable; } - } - - public const int AB_FieldNumber = 1; - private bool hasAB_; - private int aB_; - public bool HasAB_ { - get { return hasAB_; } - } - public int AB_ { - get { return aB_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _aBFieldNames; - if (hasAB_) { - output.WriteInt32(1, field_names[0], AB_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasAB_) { - size += pb::CodedOutputStream.ComputeInt32Size(1, AB_); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static AB ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static AB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static AB ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static AB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static AB ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static AB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static AB ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static AB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static AB ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static AB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private AB MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(AB prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(AB cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private AB result; - - private AB PrepareBuilder() { - if (resultIsReadOnly) { - AB original = result; - result = new AB(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override AB MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::UnitTest.Issues.TestProtos.AB.Descriptor; } - } - - public override AB DefaultInstanceForType { - get { return global::UnitTest.Issues.TestProtos.AB.DefaultInstance; } - } - - public override AB BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is AB) { - return MergeFrom((AB) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(AB other) { - if (other == global::UnitTest.Issues.TestProtos.AB.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasAB_) { - AB_ = other.AB_; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_aBFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _aBFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasAB_ = input.ReadInt32(ref result.aB_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasAB_ { - get { return result.hasAB_; } - } - public int AB_ { - get { return result.AB_; } - set { SetAB_(value); } - } - public Builder SetAB_(int value) { - PrepareBuilder(); - result.hasAB_ = true; - result.aB_ = value; - return this; - } - public Builder ClearAB_() { - PrepareBuilder(); - result.hasAB_ = false; - result.aB_ = 0; - return this; - } - } - static AB() { - object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NumberField : pb::GeneratedMessage { - private NumberField() { } - private static readonly NumberField defaultInstance = new NumberField().MakeReadOnly(); - private static readonly string[] _numberFieldFieldNames = new string[] { "_01" }; - private static readonly uint[] _numberFieldFieldTags = new uint[] { 8 }; - public static NumberField DefaultInstance { - get { return defaultInstance; } - } - - public override NumberField DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override NumberField ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_NumberField__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_NumberField__FieldAccessorTable; } - } - - public const int 01FieldNumber = 1; - private bool has01; - private int 01_; - public bool Has01 { - get { return has01; } - } - public int 01 { - get { return 01_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _numberFieldFieldNames; - if (has01) { - output.WriteInt32(1, field_names[0], 01); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (has01) { - size += pb::CodedOutputStream.ComputeInt32Size(1, 01); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static NumberField ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NumberField ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NumberField ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NumberField ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NumberField ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NumberField ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NumberField ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NumberField ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NumberField ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NumberField ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NumberField MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NumberField prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NumberField cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NumberField result; - - private NumberField PrepareBuilder() { - if (resultIsReadOnly) { - NumberField original = result; - result = new NumberField(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NumberField MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::UnitTest.Issues.TestProtos.NumberField.Descriptor; } - } - - public override NumberField DefaultInstanceForType { - get { return global::UnitTest.Issues.TestProtos.NumberField.DefaultInstance; } - } - - public override NumberField BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is NumberField) { - return MergeFrom((NumberField) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(NumberField other) { - if (other == global::UnitTest.Issues.TestProtos.NumberField.DefaultInstance) return this; - PrepareBuilder(); - if (other.Has01) { - 01 = other.01; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_numberFieldFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _numberFieldFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.has01 = input.ReadInt32(ref result.01_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool Has01 { - get { return result.has01; } - } - public int 01 { - get { return result.01; } - set { Set01(value); } - } - public Builder Set01(int value) { - PrepareBuilder(); - result.has01 = true; - result.01_ = value; - return this; - } - public Builder Clear01() { - PrepareBuilder(); - result.has01 = false; - result.01_ = 0; - return this; - } - } - static NumberField() { - object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class MyMessageAReferenceB : pb::GeneratedMessage { - private MyMessageAReferenceB() { } - private static readonly MyMessageAReferenceB defaultInstance = new MyMessageAReferenceB().MakeReadOnly(); - private static readonly string[] _myMessageAReferenceBFieldNames = new string[] { "value" }; - private static readonly uint[] _myMessageAReferenceBFieldTags = new uint[] { 10 }; - public static MyMessageAReferenceB DefaultInstance { - get { return defaultInstance; } - } - - public override MyMessageAReferenceB DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override MyMessageAReferenceB ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_MyMessageAReferenceB__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_MyMessageAReferenceB__FieldAccessorTable; } - } - - public const int ValueFieldNumber = 1; - private bool hasValue; - private global::UnitTest.Issues.TestProtos.MyMessageBReferenceA value_; - public bool HasValue { - get { return hasValue; } - } - public global::UnitTest.Issues.TestProtos.MyMessageBReferenceA Value { - get { return value_ ?? global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.DefaultInstance; } - } - - public override bool IsInitialized { - get { - if (!hasValue) return false; - if (!Value.IsInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _myMessageAReferenceBFieldNames; - if (hasValue) { - output.WriteMessage(1, field_names[0], Value); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasValue) { - size += pb::CodedOutputStream.ComputeMessageSize(1, Value); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static MyMessageAReferenceB ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MyMessageAReferenceB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MyMessageAReferenceB ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MyMessageAReferenceB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MyMessageAReferenceB ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MyMessageAReferenceB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static MyMessageAReferenceB ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static MyMessageAReferenceB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static MyMessageAReferenceB ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MyMessageAReferenceB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private MyMessageAReferenceB MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(MyMessageAReferenceB prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(MyMessageAReferenceB cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private MyMessageAReferenceB result; - - private MyMessageAReferenceB PrepareBuilder() { - if (resultIsReadOnly) { - MyMessageAReferenceB original = result; - result = new MyMessageAReferenceB(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override MyMessageAReferenceB MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.Descriptor; } - } - - public override MyMessageAReferenceB DefaultInstanceForType { - get { return global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.DefaultInstance; } - } - - public override MyMessageAReferenceB BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is MyMessageAReferenceB) { - return MergeFrom((MyMessageAReferenceB) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(MyMessageAReferenceB other) { - if (other == global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasValue) { - MergeValue(other.Value); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_myMessageAReferenceBFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _myMessageAReferenceBFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.Builder subBuilder = global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.CreateBuilder(); - if (result.hasValue) { - subBuilder.MergeFrom(Value); - } - input.ReadMessage(subBuilder, extensionRegistry); - Value = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasValue { - get { return result.hasValue; } - } - public global::UnitTest.Issues.TestProtos.MyMessageBReferenceA Value { - get { return result.Value; } - set { SetValue(value); } - } - public Builder SetValue(global::UnitTest.Issues.TestProtos.MyMessageBReferenceA value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasValue = true; - result.value_ = value; - return this; - } - public Builder SetValue(global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasValue = true; - result.value_ = builderForValue.Build(); - return this; - } - public Builder MergeValue(global::UnitTest.Issues.TestProtos.MyMessageBReferenceA value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasValue && - result.value_ != global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.DefaultInstance) { - result.value_ = global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.CreateBuilder(result.value_).MergeFrom(value).BuildPartial(); - } else { - result.value_ = value; - } - result.hasValue = true; - return this; - } - public Builder ClearValue() { - PrepareBuilder(); - result.hasValue = false; - result.value_ = null; - return this; - } - } - static MyMessageAReferenceB() { - object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class MyMessageBReferenceA : pb::GeneratedMessage { - private MyMessageBReferenceA() { } - private static readonly MyMessageBReferenceA defaultInstance = new MyMessageBReferenceA().MakeReadOnly(); - private static readonly string[] _myMessageBReferenceAFieldNames = new string[] { "value" }; - private static readonly uint[] _myMessageBReferenceAFieldTags = new uint[] { 10 }; - public static MyMessageBReferenceA DefaultInstance { - get { return defaultInstance; } - } - - public override MyMessageBReferenceA DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override MyMessageBReferenceA ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_MyMessageBReferenceA__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_MyMessageBReferenceA__FieldAccessorTable; } - } - - public const int ValueFieldNumber = 1; - private bool hasValue; - private global::UnitTest.Issues.TestProtos.MyMessageAReferenceB value_; - public bool HasValue { - get { return hasValue; } - } - public global::UnitTest.Issues.TestProtos.MyMessageAReferenceB Value { - get { return value_ ?? global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.DefaultInstance; } - } - - public override bool IsInitialized { - get { - if (!hasValue) return false; - if (!Value.IsInitialized) return false; - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _myMessageBReferenceAFieldNames; - if (hasValue) { - output.WriteMessage(1, field_names[0], Value); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasValue) { - size += pb::CodedOutputStream.ComputeMessageSize(1, Value); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static MyMessageBReferenceA ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MyMessageBReferenceA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MyMessageBReferenceA ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static MyMessageBReferenceA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static MyMessageBReferenceA ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MyMessageBReferenceA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static MyMessageBReferenceA ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static MyMessageBReferenceA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static MyMessageBReferenceA ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static MyMessageBReferenceA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private MyMessageBReferenceA MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(MyMessageBReferenceA prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(MyMessageBReferenceA cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private MyMessageBReferenceA result; - - private MyMessageBReferenceA PrepareBuilder() { - if (resultIsReadOnly) { - MyMessageBReferenceA original = result; - result = new MyMessageBReferenceA(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override MyMessageBReferenceA MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.Descriptor; } - } - - public override MyMessageBReferenceA DefaultInstanceForType { - get { return global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.DefaultInstance; } - } - - public override MyMessageBReferenceA BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is MyMessageBReferenceA) { - return MergeFrom((MyMessageBReferenceA) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(MyMessageBReferenceA other) { - if (other == global::UnitTest.Issues.TestProtos.MyMessageBReferenceA.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasValue) { - MergeValue(other.Value); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_myMessageBReferenceAFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _myMessageBReferenceAFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 10: { - global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.Builder subBuilder = global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.CreateBuilder(); - if (result.hasValue) { - subBuilder.MergeFrom(Value); - } - input.ReadMessage(subBuilder, extensionRegistry); - Value = subBuilder.BuildPartial(); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasValue { - get { return result.hasValue; } - } - public global::UnitTest.Issues.TestProtos.MyMessageAReferenceB Value { - get { return result.Value; } - set { SetValue(value); } - } - public Builder SetValue(global::UnitTest.Issues.TestProtos.MyMessageAReferenceB value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasValue = true; - result.value_ = value; - return this; - } - public Builder SetValue(global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasValue = true; - result.value_ = builderForValue.Build(); - return this; - } - public Builder MergeValue(global::UnitTest.Issues.TestProtos.MyMessageAReferenceB value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasValue && - result.value_ != global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.DefaultInstance) { - result.value_ = global::UnitTest.Issues.TestProtos.MyMessageAReferenceB.CreateBuilder(result.value_).MergeFrom(value).BuildPartial(); - } else { - result.value_ = value; - } - result.hasValue = true; - return this; - } - public Builder ClearValue() { - PrepareBuilder(); - result.hasValue = false; - result.value_ = null; - return this; - } - } - static MyMessageBReferenceA() { - object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class NegativeEnumMessage : pb::GeneratedMessage { - private NegativeEnumMessage() { } - private static readonly NegativeEnumMessage defaultInstance = new NegativeEnumMessage().MakeReadOnly(); - private static readonly string[] _negativeEnumMessageFieldNames = new string[] { "packed_values", "value", "values" }; - private static readonly uint[] _negativeEnumMessageFieldTags = new uint[] { 26, 8, 16 }; - public static NegativeEnumMessage DefaultInstance { - get { return defaultInstance; } - } - - public override NegativeEnumMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override NegativeEnumMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_NegativeEnumMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_NegativeEnumMessage__FieldAccessorTable; } - } - - public const int ValueFieldNumber = 1; - private bool hasValue; - private global::UnitTest.Issues.TestProtos.NegativeEnum value_ = global::UnitTest.Issues.TestProtos.NegativeEnum.FiveBelow; - public bool HasValue { - get { return hasValue; } - } - public global::UnitTest.Issues.TestProtos.NegativeEnum Value { - get { return value_; } - } - - public const int ValuesFieldNumber = 2; - private pbc::PopsicleList values_ = new pbc::PopsicleList(); - public scg::IList ValuesList { - get { return pbc::Lists.AsReadOnly(values_); } - } - public int ValuesCount { - get { return values_.Count; } - } - public global::UnitTest.Issues.TestProtos.NegativeEnum GetValues(int index) { - return values_[index]; - } - - public const int PackedValuesFieldNumber = 3; - private int packedValuesMemoizedSerializedSize; - private pbc::PopsicleList packedValues_ = new pbc::PopsicleList(); - public scg::IList PackedValuesList { - get { return pbc::Lists.AsReadOnly(packedValues_); } - } - public int PackedValuesCount { - get { return packedValues_.Count; } - } - public global::UnitTest.Issues.TestProtos.NegativeEnum GetPackedValues(int index) { - return packedValues_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _negativeEnumMessageFieldNames; - if (hasValue) { - output.WriteEnum(1, field_names[1], (int) Value, Value); - } - if (values_.Count > 0) { - output.WriteEnumArray(2, field_names[2], values_); - } - if (packedValues_.Count > 0) { - output.WritePackedEnumArray(3, field_names[0], packedValuesMemoizedSerializedSize, packedValues_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasValue) { - size += pb::CodedOutputStream.ComputeEnumSize(1, (int) Value); - } - { - int dataSize = 0; - if (values_.Count > 0) { - foreach (global::UnitTest.Issues.TestProtos.NegativeEnum element in values_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * values_.Count; - } - } - { - int dataSize = 0; - if (packedValues_.Count > 0) { - foreach (global::UnitTest.Issues.TestProtos.NegativeEnum element in packedValues_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1; - size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize); - } - packedValuesMemoizedSerializedSize = dataSize; - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static NegativeEnumMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NegativeEnumMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NegativeEnumMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static NegativeEnumMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static NegativeEnumMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NegativeEnumMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static NegativeEnumMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static NegativeEnumMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static NegativeEnumMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static NegativeEnumMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private NegativeEnumMessage MakeReadOnly() { - values_.MakeReadOnly(); - packedValues_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(NegativeEnumMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(NegativeEnumMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private NegativeEnumMessage result; - - private NegativeEnumMessage PrepareBuilder() { - if (resultIsReadOnly) { - NegativeEnumMessage original = result; - result = new NegativeEnumMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override NegativeEnumMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::UnitTest.Issues.TestProtos.NegativeEnumMessage.Descriptor; } - } - - public override NegativeEnumMessage DefaultInstanceForType { - get { return global::UnitTest.Issues.TestProtos.NegativeEnumMessage.DefaultInstance; } - } - - public override NegativeEnumMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is NegativeEnumMessage) { - return MergeFrom((NegativeEnumMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(NegativeEnumMessage other) { - if (other == global::UnitTest.Issues.TestProtos.NegativeEnumMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasValue) { - Value = other.Value; - } - if (other.values_.Count != 0) { - result.values_.Add(other.values_); - } - if (other.packedValues_.Count != 0) { - result.packedValues_.Add(other.packedValues_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_negativeEnumMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _negativeEnumMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - object unknown; - if(input.ReadEnum(ref result.value_, out unknown)) { - result.hasValue = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(1, (ulong)(int)unknown); - } - break; - } - case 18: - case 16: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.values_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(2, (ulong)(int)rawValue); - } - break; - } - case 26: - case 24: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.packedValues_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(3, (ulong)(int)rawValue); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasValue { - get { return result.hasValue; } - } - public global::UnitTest.Issues.TestProtos.NegativeEnum Value { - get { return result.Value; } - set { SetValue(value); } - } - public Builder SetValue(global::UnitTest.Issues.TestProtos.NegativeEnum value) { - PrepareBuilder(); - result.hasValue = true; - result.value_ = value; - return this; - } - public Builder ClearValue() { - PrepareBuilder(); - result.hasValue = false; - result.value_ = global::UnitTest.Issues.TestProtos.NegativeEnum.FiveBelow; - return this; - } - - public pbc::IPopsicleList ValuesList { - get { return PrepareBuilder().values_; } - } - public int ValuesCount { - get { return result.ValuesCount; } - } - public global::UnitTest.Issues.TestProtos.NegativeEnum GetValues(int index) { - return result.GetValues(index); - } - public Builder SetValues(int index, global::UnitTest.Issues.TestProtos.NegativeEnum value) { - PrepareBuilder(); - result.values_[index] = value; - return this; - } - public Builder AddValues(global::UnitTest.Issues.TestProtos.NegativeEnum value) { - PrepareBuilder(); - result.values_.Add(value); - return this; - } - public Builder AddRangeValues(scg::IEnumerable values) { - PrepareBuilder(); - result.values_.Add(values); - return this; - } - public Builder ClearValues() { - PrepareBuilder(); - result.values_.Clear(); - return this; - } - - public pbc::IPopsicleList PackedValuesList { - get { return PrepareBuilder().packedValues_; } - } - public int PackedValuesCount { - get { return result.PackedValuesCount; } - } - public global::UnitTest.Issues.TestProtos.NegativeEnum GetPackedValues(int index) { - return result.GetPackedValues(index); - } - public Builder SetPackedValues(int index, global::UnitTest.Issues.TestProtos.NegativeEnum value) { - PrepareBuilder(); - result.packedValues_[index] = value; - return this; - } - public Builder AddPackedValues(global::UnitTest.Issues.TestProtos.NegativeEnum value) { - PrepareBuilder(); - result.packedValues_.Add(value); - return this; - } - public Builder AddRangePackedValues(scg::IEnumerable values) { - PrepareBuilder(); - result.packedValues_.Add(values); - return this; - } - public Builder ClearPackedValues() { - PrepareBuilder(); - result.packedValues_.Clear(); - return this; - } - } - static NegativeEnumMessage() { - object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class DeprecatedChild : pb::GeneratedMessage { - private DeprecatedChild() { } - private static readonly DeprecatedChild defaultInstance = new DeprecatedChild().MakeReadOnly(); - private static readonly string[] _deprecatedChildFieldNames = new string[] { }; - private static readonly uint[] _deprecatedChildFieldTags = new uint[] { }; - public static DeprecatedChild DefaultInstance { - get { return defaultInstance; } - } - - public override DeprecatedChild DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override DeprecatedChild ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_DeprecatedChild__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_DeprecatedChild__FieldAccessorTable; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _deprecatedChildFieldNames; - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static DeprecatedChild ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static DeprecatedChild ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static DeprecatedChild ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static DeprecatedChild ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static DeprecatedChild ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static DeprecatedChild ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static DeprecatedChild ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static DeprecatedChild ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static DeprecatedChild ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static DeprecatedChild ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private DeprecatedChild MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(DeprecatedChild prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(DeprecatedChild cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private DeprecatedChild result; - - private DeprecatedChild PrepareBuilder() { - if (resultIsReadOnly) { - DeprecatedChild original = result; - result = new DeprecatedChild(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override DeprecatedChild MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::UnitTest.Issues.TestProtos.DeprecatedChild.Descriptor; } - } - - public override DeprecatedChild DefaultInstanceForType { - get { return global::UnitTest.Issues.TestProtos.DeprecatedChild.DefaultInstance; } - } - - public override DeprecatedChild BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is DeprecatedChild) { - return MergeFrom((DeprecatedChild) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(DeprecatedChild other) { - if (other == global::UnitTest.Issues.TestProtos.DeprecatedChild.DefaultInstance) return this; - PrepareBuilder(); - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_deprecatedChildFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _deprecatedChildFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - } - static DeprecatedChild() { - object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class DeprecatedFieldsMessage : pb::GeneratedMessage { - private DeprecatedFieldsMessage() { } - private static readonly DeprecatedFieldsMessage defaultInstance = new DeprecatedFieldsMessage().MakeReadOnly(); - private static readonly string[] _deprecatedFieldsMessageFieldNames = new string[] { "EnumArray", "EnumValue", "MessageArray", "MessageValue", "PrimitiveArray", "PrimitiveValue" }; - private static readonly uint[] _deprecatedFieldsMessageFieldTags = new uint[] { 48, 40, 34, 26, 16, 8 }; - public static DeprecatedFieldsMessage DefaultInstance { - get { return defaultInstance; } - } - - public override DeprecatedFieldsMessage DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override DeprecatedFieldsMessage ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_DeprecatedFieldsMessage__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_DeprecatedFieldsMessage__FieldAccessorTable; } - } - - public const int PrimitiveValueFieldNumber = 1; - private bool hasPrimitiveValue; - private int primitiveValue_; - [global::System.ObsoleteAttribute()] - public bool HasPrimitiveValue { - get { return hasPrimitiveValue; } - } - [global::System.ObsoleteAttribute()] - public int PrimitiveValue { - get { return primitiveValue_; } - } - - public const int PrimitiveArrayFieldNumber = 2; - private pbc::PopsicleList primitiveArray_ = new pbc::PopsicleList(); - [global::System.ObsoleteAttribute()] - public scg::IList PrimitiveArrayList { - get { return pbc::Lists.AsReadOnly(primitiveArray_); } - } - [global::System.ObsoleteAttribute()] - public int PrimitiveArrayCount { - get { return primitiveArray_.Count; } - } - [global::System.ObsoleteAttribute()] - public int GetPrimitiveArray(int index) { - return primitiveArray_[index]; - } - - public const int MessageValueFieldNumber = 3; - private bool hasMessageValue; - private global::UnitTest.Issues.TestProtos.DeprecatedChild messageValue_; - [global::System.ObsoleteAttribute()] - public bool HasMessageValue { - get { return hasMessageValue; } - } - [global::System.ObsoleteAttribute()] - public global::UnitTest.Issues.TestProtos.DeprecatedChild MessageValue { - get { return messageValue_ ?? global::UnitTest.Issues.TestProtos.DeprecatedChild.DefaultInstance; } - } - - public const int MessageArrayFieldNumber = 4; - private pbc::PopsicleList messageArray_ = new pbc::PopsicleList(); - [global::System.ObsoleteAttribute()] - public scg::IList MessageArrayList { - get { return messageArray_; } - } - [global::System.ObsoleteAttribute()] - public int MessageArrayCount { - get { return messageArray_.Count; } - } - [global::System.ObsoleteAttribute()] - public global::UnitTest.Issues.TestProtos.DeprecatedChild GetMessageArray(int index) { - return messageArray_[index]; - } - - public const int EnumValueFieldNumber = 5; - private bool hasEnumValue; - private global::UnitTest.Issues.TestProtos.DeprecatedEnum enumValue_ = global::UnitTest.Issues.TestProtos.DeprecatedEnum.one; - [global::System.ObsoleteAttribute()] - public bool HasEnumValue { - get { return hasEnumValue; } - } - [global::System.ObsoleteAttribute()] - public global::UnitTest.Issues.TestProtos.DeprecatedEnum EnumValue { - get { return enumValue_; } - } - - public const int EnumArrayFieldNumber = 6; - private pbc::PopsicleList enumArray_ = new pbc::PopsicleList(); - [global::System.ObsoleteAttribute()] - public scg::IList EnumArrayList { - get { return pbc::Lists.AsReadOnly(enumArray_); } - } - [global::System.ObsoleteAttribute()] - public int EnumArrayCount { - get { return enumArray_.Count; } - } - [global::System.ObsoleteAttribute()] - public global::UnitTest.Issues.TestProtos.DeprecatedEnum GetEnumArray(int index) { - return enumArray_[index]; - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _deprecatedFieldsMessageFieldNames; - if (hasPrimitiveValue) { - output.WriteInt32(1, field_names[5], PrimitiveValue); - } - if (primitiveArray_.Count > 0) { - output.WriteInt32Array(2, field_names[4], primitiveArray_); - } - if (hasMessageValue) { - output.WriteMessage(3, field_names[3], MessageValue); - } - if (messageArray_.Count > 0) { - output.WriteMessageArray(4, field_names[2], messageArray_); - } - if (hasEnumValue) { - output.WriteEnum(5, field_names[1], (int) EnumValue, EnumValue); - } - if (enumArray_.Count > 0) { - output.WriteEnumArray(6, field_names[0], enumArray_); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasPrimitiveValue) { - size += pb::CodedOutputStream.ComputeInt32Size(1, PrimitiveValue); - } - { - int dataSize = 0; - foreach (int element in PrimitiveArrayList) { - dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element); - } - size += dataSize; - size += 1 * primitiveArray_.Count; - } - if (hasMessageValue) { - size += pb::CodedOutputStream.ComputeMessageSize(3, MessageValue); - } - foreach (global::UnitTest.Issues.TestProtos.DeprecatedChild element in MessageArrayList) { - size += pb::CodedOutputStream.ComputeMessageSize(4, element); - } - if (hasEnumValue) { - size += pb::CodedOutputStream.ComputeEnumSize(5, (int) EnumValue); - } - { - int dataSize = 0; - if (enumArray_.Count > 0) { - foreach (global::UnitTest.Issues.TestProtos.DeprecatedEnum element in enumArray_) { - dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element); - } - size += dataSize; - size += 1 * enumArray_.Count; - } - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static DeprecatedFieldsMessage ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static DeprecatedFieldsMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static DeprecatedFieldsMessage ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static DeprecatedFieldsMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static DeprecatedFieldsMessage ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static DeprecatedFieldsMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static DeprecatedFieldsMessage ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static DeprecatedFieldsMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static DeprecatedFieldsMessage ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static DeprecatedFieldsMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private DeprecatedFieldsMessage MakeReadOnly() { - primitiveArray_.MakeReadOnly(); - messageArray_.MakeReadOnly(); - enumArray_.MakeReadOnly(); - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(DeprecatedFieldsMessage prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(DeprecatedFieldsMessage cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private DeprecatedFieldsMessage result; - - private DeprecatedFieldsMessage PrepareBuilder() { - if (resultIsReadOnly) { - DeprecatedFieldsMessage original = result; - result = new DeprecatedFieldsMessage(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override DeprecatedFieldsMessage MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::UnitTest.Issues.TestProtos.DeprecatedFieldsMessage.Descriptor; } - } - - public override DeprecatedFieldsMessage DefaultInstanceForType { - get { return global::UnitTest.Issues.TestProtos.DeprecatedFieldsMessage.DefaultInstance; } - } - - public override DeprecatedFieldsMessage BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is DeprecatedFieldsMessage) { - return MergeFrom((DeprecatedFieldsMessage) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(DeprecatedFieldsMessage other) { - if (other == global::UnitTest.Issues.TestProtos.DeprecatedFieldsMessage.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasPrimitiveValue) { - PrimitiveValue = other.PrimitiveValue; - } - if (other.primitiveArray_.Count != 0) { - result.primitiveArray_.Add(other.primitiveArray_); - } - if (other.HasMessageValue) { - MergeMessageValue(other.MessageValue); - } - if (other.messageArray_.Count != 0) { - result.messageArray_.Add(other.messageArray_); - } - if (other.HasEnumValue) { - EnumValue = other.EnumValue; - } - if (other.enumArray_.Count != 0) { - result.enumArray_.Add(other.enumArray_); - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_deprecatedFieldsMessageFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _deprecatedFieldsMessageFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasPrimitiveValue = input.ReadInt32(ref result.primitiveValue_); - break; - } - case 18: - case 16: { - input.ReadInt32Array(tag, field_name, result.primitiveArray_); - break; - } - case 26: { - global::UnitTest.Issues.TestProtos.DeprecatedChild.Builder subBuilder = global::UnitTest.Issues.TestProtos.DeprecatedChild.CreateBuilder(); - if (result.hasMessageValue) { - subBuilder.MergeFrom(MessageValue); - } - input.ReadMessage(subBuilder, extensionRegistry); - MessageValue = subBuilder.BuildPartial(); - break; - } - case 34: { - input.ReadMessageArray(tag, field_name, result.messageArray_, global::UnitTest.Issues.TestProtos.DeprecatedChild.DefaultInstance, extensionRegistry); - break; - } - case 40: { - object unknown; - if(input.ReadEnum(ref result.enumValue_, out unknown)) { - result.hasEnumValue = true; - } else if(unknown is int) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - unknownFields.MergeVarintField(5, (ulong)(int)unknown); - } - break; - } - case 50: - case 48: { - scg::ICollection unknownItems; - input.ReadEnumArray(tag, field_name, result.enumArray_, out unknownItems); - if (unknownItems != null) { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - foreach (object rawValue in unknownItems) - if (rawValue is int) - unknownFields.MergeVarintField(6, (ulong)(int)rawValue); - } - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - [global::System.ObsoleteAttribute()] - public bool HasPrimitiveValue { - get { return result.hasPrimitiveValue; } - } - [global::System.ObsoleteAttribute()] - public int PrimitiveValue { - get { return result.PrimitiveValue; } - set { SetPrimitiveValue(value); } - } - [global::System.ObsoleteAttribute()] - public Builder SetPrimitiveValue(int value) { - PrepareBuilder(); - result.hasPrimitiveValue = true; - result.primitiveValue_ = value; - return this; - } - [global::System.ObsoleteAttribute()] - public Builder ClearPrimitiveValue() { - PrepareBuilder(); - result.hasPrimitiveValue = false; - result.primitiveValue_ = 0; - return this; - } - - [global::System.ObsoleteAttribute()] - public pbc::IPopsicleList PrimitiveArrayList { - get { return PrepareBuilder().primitiveArray_; } - } - [global::System.ObsoleteAttribute()] - public int PrimitiveArrayCount { - get { return result.PrimitiveArrayCount; } - } - [global::System.ObsoleteAttribute()] - public int GetPrimitiveArray(int index) { - return result.GetPrimitiveArray(index); - } - [global::System.ObsoleteAttribute()] - public Builder SetPrimitiveArray(int index, int value) { - PrepareBuilder(); - result.primitiveArray_[index] = value; - return this; - } - [global::System.ObsoleteAttribute()] - public Builder AddPrimitiveArray(int value) { - PrepareBuilder(); - result.primitiveArray_.Add(value); - return this; - } - [global::System.ObsoleteAttribute()] - public Builder AddRangePrimitiveArray(scg::IEnumerable values) { - PrepareBuilder(); - result.primitiveArray_.Add(values); - return this; - } - [global::System.ObsoleteAttribute()] - public Builder ClearPrimitiveArray() { - PrepareBuilder(); - result.primitiveArray_.Clear(); - return this; - } - - [global::System.ObsoleteAttribute()] - public bool HasMessageValue { - get { return result.hasMessageValue; } - } - [global::System.ObsoleteAttribute()] - public global::UnitTest.Issues.TestProtos.DeprecatedChild MessageValue { - get { return result.MessageValue; } - set { SetMessageValue(value); } - } - [global::System.ObsoleteAttribute()] - public Builder SetMessageValue(global::UnitTest.Issues.TestProtos.DeprecatedChild value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.hasMessageValue = true; - result.messageValue_ = value; - return this; - } - [global::System.ObsoleteAttribute()] - public Builder SetMessageValue(global::UnitTest.Issues.TestProtos.DeprecatedChild.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.hasMessageValue = true; - result.messageValue_ = builderForValue.Build(); - return this; - } - [global::System.ObsoleteAttribute()] - public Builder MergeMessageValue(global::UnitTest.Issues.TestProtos.DeprecatedChild value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - if (result.hasMessageValue && - result.messageValue_ != global::UnitTest.Issues.TestProtos.DeprecatedChild.DefaultInstance) { - result.messageValue_ = global::UnitTest.Issues.TestProtos.DeprecatedChild.CreateBuilder(result.messageValue_).MergeFrom(value).BuildPartial(); - } else { - result.messageValue_ = value; - } - result.hasMessageValue = true; - return this; - } - [global::System.ObsoleteAttribute()] - public Builder ClearMessageValue() { - PrepareBuilder(); - result.hasMessageValue = false; - result.messageValue_ = null; - return this; - } - - [global::System.ObsoleteAttribute()] - public pbc::IPopsicleList MessageArrayList { - get { return PrepareBuilder().messageArray_; } - } - [global::System.ObsoleteAttribute()] - public int MessageArrayCount { - get { return result.MessageArrayCount; } - } - [global::System.ObsoleteAttribute()] - public global::UnitTest.Issues.TestProtos.DeprecatedChild GetMessageArray(int index) { - return result.GetMessageArray(index); - } - [global::System.ObsoleteAttribute()] - public Builder SetMessageArray(int index, global::UnitTest.Issues.TestProtos.DeprecatedChild value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.messageArray_[index] = value; - return this; - } - [global::System.ObsoleteAttribute()] - public Builder SetMessageArray(int index, global::UnitTest.Issues.TestProtos.DeprecatedChild.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.messageArray_[index] = builderForValue.Build(); - return this; - } - [global::System.ObsoleteAttribute()] - public Builder AddMessageArray(global::UnitTest.Issues.TestProtos.DeprecatedChild value) { - pb::ThrowHelper.ThrowIfNull(value, "value"); - PrepareBuilder(); - result.messageArray_.Add(value); - return this; - } - [global::System.ObsoleteAttribute()] - public Builder AddMessageArray(global::UnitTest.Issues.TestProtos.DeprecatedChild.Builder builderForValue) { - pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue"); - PrepareBuilder(); - result.messageArray_.Add(builderForValue.Build()); - return this; - } - [global::System.ObsoleteAttribute()] - public Builder AddRangeMessageArray(scg::IEnumerable values) { - PrepareBuilder(); - result.messageArray_.Add(values); - return this; - } - [global::System.ObsoleteAttribute()] - public Builder ClearMessageArray() { - PrepareBuilder(); - result.messageArray_.Clear(); - return this; - } - - [global::System.ObsoleteAttribute()] - public bool HasEnumValue { - get { return result.hasEnumValue; } - } - [global::System.ObsoleteAttribute()] - public global::UnitTest.Issues.TestProtos.DeprecatedEnum EnumValue { - get { return result.EnumValue; } - set { SetEnumValue(value); } - } - [global::System.ObsoleteAttribute()] - public Builder SetEnumValue(global::UnitTest.Issues.TestProtos.DeprecatedEnum value) { - PrepareBuilder(); - result.hasEnumValue = true; - result.enumValue_ = value; - return this; - } - [global::System.ObsoleteAttribute()] - public Builder ClearEnumValue() { - PrepareBuilder(); - result.hasEnumValue = false; - result.enumValue_ = global::UnitTest.Issues.TestProtos.DeprecatedEnum.one; - return this; - } - - [global::System.ObsoleteAttribute()] - public pbc::IPopsicleList EnumArrayList { - get { return PrepareBuilder().enumArray_; } - } - [global::System.ObsoleteAttribute()] - public int EnumArrayCount { - get { return result.EnumArrayCount; } - } - [global::System.ObsoleteAttribute()] - public global::UnitTest.Issues.TestProtos.DeprecatedEnum GetEnumArray(int index) { - return result.GetEnumArray(index); - } - [global::System.ObsoleteAttribute()] - public Builder SetEnumArray(int index, global::UnitTest.Issues.TestProtos.DeprecatedEnum value) { - PrepareBuilder(); - result.enumArray_[index] = value; - return this; - } - [global::System.ObsoleteAttribute()] - public Builder AddEnumArray(global::UnitTest.Issues.TestProtos.DeprecatedEnum value) { - PrepareBuilder(); - result.enumArray_.Add(value); - return this; - } - [global::System.ObsoleteAttribute()] - public Builder AddRangeEnumArray(scg::IEnumerable values) { - PrepareBuilder(); - result.enumArray_.Add(values); - return this; - } - [global::System.ObsoleteAttribute()] - public Builder ClearEnumArray() { - PrepareBuilder(); - result.enumArray_.Clear(); - return this; - } - } - static DeprecatedFieldsMessage() { - object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class ItemField : pb::GeneratedMessage { - private ItemField() { } - private static readonly ItemField defaultInstance = new ItemField().MakeReadOnly(); - private static readonly string[] _itemFieldFieldNames = new string[] { "item" }; - private static readonly uint[] _itemFieldFieldTags = new uint[] { 8 }; - public static ItemField DefaultInstance { - get { return defaultInstance; } - } - - public override ItemField DefaultInstanceForType { - get { return DefaultInstance; } - } - - protected override ItemField ThisMessage { - get { return this; } - } - - public static pbd::MessageDescriptor Descriptor { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_ItemField__Descriptor; } - } - - protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return global::UnitTest.Issues.TestProtos.UnittestIssues.internal__static_unittest_issues_ItemField__FieldAccessorTable; } - } - - public const int ItemFieldNumber = 1; - private bool hasItem; - private int item_; - public bool HasItem { - get { return hasItem; } - } - public int Item { - get { return item_; } - } - - public override bool IsInitialized { - get { - return true; - } - } - - public override void WriteTo(pb::ICodedOutputStream output) { - CalcSerializedSize(); - string[] field_names = _itemFieldFieldNames; - if (hasItem) { - output.WriteInt32(1, field_names[0], Item); - } - UnknownFields.WriteTo(output); - } - - private int memoizedSerializedSize = -1; - public override int SerializedSize { - get { - int size = memoizedSerializedSize; - if (size != -1) return size; - return CalcSerializedSize(); - } - } - - private int CalcSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (hasItem) { - size += pb::CodedOutputStream.ComputeInt32Size(1, Item); - } - size += UnknownFields.SerializedSize; - memoizedSerializedSize = size; - return size; - } - public static ItemField ParseFrom(pb::ByteString data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ItemField ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ItemField ParseFrom(byte[] data) { - return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); - } - public static ItemField ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed(); - } - public static ItemField ParseFrom(global::System.IO.Stream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ItemField ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - public static ItemField ParseDelimitedFrom(global::System.IO.Stream input) { - return CreateBuilder().MergeDelimitedFrom(input).BuildParsed(); - } - public static ItemField ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { - return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed(); - } - public static ItemField ParseFrom(pb::ICodedInputStream input) { - return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); - } - public static ItemField ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed(); - } - private ItemField MakeReadOnly() { - return this; - } - - public static Builder CreateBuilder() { return new Builder(); } - public override Builder ToBuilder() { return CreateBuilder(this); } - public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(ItemField prototype) { - return new Builder(prototype); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - public sealed partial class Builder : pb::GeneratedBuilder { - protected override Builder ThisBuilder { - get { return this; } - } - public Builder() { - result = DefaultInstance; - resultIsReadOnly = true; - } - internal Builder(ItemField cloneFrom) { - result = cloneFrom; - resultIsReadOnly = true; - } - - private bool resultIsReadOnly; - private ItemField result; - - private ItemField PrepareBuilder() { - if (resultIsReadOnly) { - ItemField original = result; - result = new ItemField(); - resultIsReadOnly = false; - MergeFrom(original); - } - return result; - } - - public override bool IsInitialized { - get { return result.IsInitialized; } - } - - protected override ItemField MessageBeingBuilt { - get { return PrepareBuilder(); } - } - - public override Builder Clear() { - result = DefaultInstance; - resultIsReadOnly = true; - return this; - } - - public override Builder Clone() { - if (resultIsReadOnly) { - return new Builder(result); - } else { - return new Builder().MergeFrom(result); - } - } - - public override pbd::MessageDescriptor DescriptorForType { - get { return global::UnitTest.Issues.TestProtos.ItemField.Descriptor; } - } - - public override ItemField DefaultInstanceForType { - get { return global::UnitTest.Issues.TestProtos.ItemField.DefaultInstance; } - } - - public override ItemField BuildPartial() { - if (resultIsReadOnly) { - return result; - } - resultIsReadOnly = true; - return result.MakeReadOnly(); - } - - public override Builder MergeFrom(pb::IMessage other) { - if (other is ItemField) { - return MergeFrom((ItemField) other); - } else { - base.MergeFrom(other); - return this; - } - } - - public override Builder MergeFrom(ItemField other) { - if (other == global::UnitTest.Issues.TestProtos.ItemField.DefaultInstance) return this; - PrepareBuilder(); - if (other.HasItem) { - Item = other.Item; - } - this.MergeUnknownFields(other.UnknownFields); - return this; - } - - public override Builder MergeFrom(pb::ICodedInputStream input) { - return MergeFrom(input, pb::ExtensionRegistry.Empty); - } - - public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) { - PrepareBuilder(); - pb::UnknownFieldSet.Builder unknownFields = null; - uint tag; - string field_name; - while (input.ReadTag(out tag, out field_name)) { - if(tag == 0 && field_name != null) { - int field_ordinal = global::System.Array.BinarySearch(_itemFieldFieldNames, field_name, global::System.StringComparer.Ordinal); - if(field_ordinal >= 0) - tag = _itemFieldFieldTags[field_ordinal]; - else { - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - continue; - } - } - switch (tag) { - case 0: { - throw pb::InvalidProtocolBufferException.InvalidTag(); - } - default: { - if (pb::WireFormat.IsEndGroupTag(tag)) { - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - if (unknownFields == null) { - unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields); - } - ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name); - break; - } - case 8: { - result.hasItem = input.ReadInt32(ref result.item_); - break; - } - } - } - - if (unknownFields != null) { - this.UnknownFields = unknownFields.Build(); - } - return this; - } - - - public bool HasItem { - get { return result.hasItem; } - } - public int Item { - get { return result.Item; } - set { SetItem(value); } - } - public Builder SetItem(int value) { - PrepareBuilder(); - result.hasItem = true; - result.item_ = value; - return this; - } - public Builder ClearItem() { - PrepareBuilder(); - result.hasItem = false; - result.item_ = 0; - return this; - } - } - static ItemField() { - object.ReferenceEquals(global::UnitTest.Issues.TestProtos.UnittestIssues.Descriptor, null); - } - } - - #endregion - -} - -#endregion Designer generated code -- cgit v1.2.3 From 3aa58085577aa9f2ef7308f5afb26966707e7f71 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 12 May 2015 21:56:40 -0700 Subject: Regenerated UnittestExtrasLite.cs --- .../TestProtos/UnittestExtrasLite.cs | 99 +++++++++++----------- 1 file changed, 48 insertions(+), 51 deletions(-) (limited to 'csharp/src/ProtocolBuffersLite.Test/TestProtos') diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasLite.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasLite.cs index 2cb0459b..441a7c60 100644 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasLite.cs +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestExtrasLite.cs @@ -39,20 +39,16 @@ namespace Google.ProtocolBuffers.TestProtos { public const int UnpackedInt64ExtensionLiteFieldNumber = 91; public static pb::GeneratedRepeatExtensionLite UnpackedInt64ExtensionLite; public const int UnpackedUint32ExtensionLiteFieldNumber = 92; - [global::System.CLSCompliant(false)] public static pb::GeneratedRepeatExtensionLite UnpackedUint32ExtensionLite; public const int UnpackedUint64ExtensionLiteFieldNumber = 93; - [global::System.CLSCompliant(false)] public static pb::GeneratedRepeatExtensionLite UnpackedUint64ExtensionLite; public const int UnpackedSint32ExtensionLiteFieldNumber = 94; public static pb::GeneratedRepeatExtensionLite UnpackedSint32ExtensionLite; public const int UnpackedSint64ExtensionLiteFieldNumber = 95; public static pb::GeneratedRepeatExtensionLite UnpackedSint64ExtensionLite; public const int UnpackedFixed32ExtensionLiteFieldNumber = 96; - [global::System.CLSCompliant(false)] public static pb::GeneratedRepeatExtensionLite UnpackedFixed32ExtensionLite; public const int UnpackedFixed64ExtensionLiteFieldNumber = 97; - [global::System.CLSCompliant(false)] public static pb::GeneratedRepeatExtensionLite UnpackedFixed64ExtensionLite; public const int UnpackedSfixed32ExtensionLiteFieldNumber = 98; public static pb::GeneratedRepeatExtensionLite UnpackedSfixed32ExtensionLite; @@ -313,8 +309,12 @@ namespace Google.ProtocolBuffers.TestProtos { #region Lite runtime methods public override int GetHashCode() { int hash = GetType().GetHashCode(); - if (hasD) hash ^= d_.GetHashCode(); - if (hasEn) hash ^= en_.GetHashCode(); + if (hasD) { + hash ^= d_.GetHashCode(); + } + if (hasEn) { + hash ^= en_.GetHashCode(); + } return hash; } @@ -657,8 +657,12 @@ namespace Google.ProtocolBuffers.TestProtos { #region Lite runtime methods public override int GetHashCode() { int hash = GetType().GetHashCode(); - if (hasNumber) hash ^= number_.GetHashCode(); - if (hasType) hash ^= type_.GetHashCode(); + if (hasNumber) { + hash ^= number_.GetHashCode(); + } + if (hasType) { + hash ^= type_.GetHashCode(); + } return hash; } @@ -957,7 +961,6 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasZip { get { return hasZip; } } - [global::System.CLSCompliant(false)] public uint Zip { get { return zip_; } } @@ -1027,11 +1030,21 @@ namespace Google.ProtocolBuffers.TestProtos { #region Lite runtime methods public override int GetHashCode() { int hash = GetType().GetHashCode(); - if (hasAddress) hash ^= address_.GetHashCode(); - if (hasAddress2) hash ^= address2_.GetHashCode(); - if (hasCity) hash ^= city_.GetHashCode(); - if (hasState) hash ^= state_.GetHashCode(); - if (hasZip) hash ^= zip_.GetHashCode(); + if (hasAddress) { + hash ^= address_.GetHashCode(); + } + if (hasAddress2) { + hash ^= address2_.GetHashCode(); + } + if (hasCity) { + hash ^= city_.GetHashCode(); + } + if (hasState) { + hash ^= state_.GetHashCode(); + } + if (hasZip) { + hash ^= zip_.GetHashCode(); + } return hash; } @@ -1330,12 +1343,10 @@ namespace Google.ProtocolBuffers.TestProtos { public bool HasZip { get { return result.hasZip; } } - [global::System.CLSCompliant(false)] public uint Zip { get { return result.Zip; } set { SetZip(value); } } - [global::System.CLSCompliant(false)] public Builder SetZip(uint value) { PrepareBuilder(); result.hasZip = true; @@ -1508,9 +1519,15 @@ namespace Google.ProtocolBuffers.TestProtos { #region Lite runtime methods public override int GetHashCode() { int hash = GetType().GetHashCode(); - if (hasName) hash ^= name_.GetHashCode(); - if (hasId) hash ^= id_.GetHashCode(); - if (hasEmail) hash ^= email_.GetHashCode(); + if (hasName) { + hash ^= name_.GetHashCode(); + } + if (hasId) { + hash ^= id_.GetHashCode(); + } + if (hasEmail) { + hash ^= email_.GetHashCode(); + } foreach(int i in codes_) hash ^= i.GetHashCode(); foreach(global::Google.ProtocolBuffers.TestProtos.TestInteropPersonLite.Types.PhoneNumber i in phone_) @@ -2002,7 +2019,9 @@ namespace Google.ProtocolBuffers.TestProtos { #region Lite runtime methods public override int GetHashCode() { int hash = GetType().GetHashCode(); - if (hasNumber) hash ^= number_.GetHashCode(); + if (hasNumber) { + hash ^= number_.GetHashCode(); + } return hash; } @@ -2476,28 +2495,24 @@ namespace Google.ProtocolBuffers.TestProtos { public const int UnpackedUint32FieldNumber = 92; private pbc::PopsicleList unpackedUint32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] public scg::IList UnpackedUint32List { get { return pbc::Lists.AsReadOnly(unpackedUint32_); } } public int UnpackedUint32Count { get { return unpackedUint32_.Count; } } - [global::System.CLSCompliant(false)] public uint GetUnpackedUint32(int index) { return unpackedUint32_[index]; } public const int UnpackedUint64FieldNumber = 93; private pbc::PopsicleList unpackedUint64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] public scg::IList UnpackedUint64List { get { return pbc::Lists.AsReadOnly(unpackedUint64_); } } public int UnpackedUint64Count { get { return unpackedUint64_.Count; } } - [global::System.CLSCompliant(false)] public ulong GetUnpackedUint64(int index) { return unpackedUint64_[index]; } @@ -2528,28 +2543,24 @@ namespace Google.ProtocolBuffers.TestProtos { public const int UnpackedFixed32FieldNumber = 96; private pbc::PopsicleList unpackedFixed32_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] public scg::IList UnpackedFixed32List { get { return pbc::Lists.AsReadOnly(unpackedFixed32_); } } public int UnpackedFixed32Count { get { return unpackedFixed32_.Count; } } - [global::System.CLSCompliant(false)] public uint GetUnpackedFixed32(int index) { return unpackedFixed32_[index]; } public const int UnpackedFixed64FieldNumber = 97; private pbc::PopsicleList unpackedFixed64_ = new pbc::PopsicleList(); - [global::System.CLSCompliant(false)] public scg::IList UnpackedFixed64List { get { return pbc::Lists.AsReadOnly(unpackedFixed64_); } } public int UnpackedFixed64Count { get { return unpackedFixed64_.Count; } } - [global::System.CLSCompliant(false)] public ulong GetUnpackedFixed64(int index) { return unpackedFixed64_[index]; } @@ -3236,30 +3247,25 @@ namespace Google.ProtocolBuffers.TestProtos { return this; } - [global::System.CLSCompliant(false)] public pbc::IPopsicleList UnpackedUint32List { get { return PrepareBuilder().unpackedUint32_; } } public int UnpackedUint32Count { get { return result.UnpackedUint32Count; } } - [global::System.CLSCompliant(false)] public uint GetUnpackedUint32(int index) { return result.GetUnpackedUint32(index); } - [global::System.CLSCompliant(false)] public Builder SetUnpackedUint32(int index, uint value) { PrepareBuilder(); result.unpackedUint32_[index] = value; return this; } - [global::System.CLSCompliant(false)] public Builder AddUnpackedUint32(uint value) { PrepareBuilder(); result.unpackedUint32_.Add(value); return this; } - [global::System.CLSCompliant(false)] public Builder AddRangeUnpackedUint32(scg::IEnumerable values) { PrepareBuilder(); result.unpackedUint32_.Add(values); @@ -3271,30 +3277,25 @@ namespace Google.ProtocolBuffers.TestProtos { return this; } - [global::System.CLSCompliant(false)] public pbc::IPopsicleList UnpackedUint64List { get { return PrepareBuilder().unpackedUint64_; } } public int UnpackedUint64Count { get { return result.UnpackedUint64Count; } } - [global::System.CLSCompliant(false)] public ulong GetUnpackedUint64(int index) { return result.GetUnpackedUint64(index); } - [global::System.CLSCompliant(false)] public Builder SetUnpackedUint64(int index, ulong value) { PrepareBuilder(); result.unpackedUint64_[index] = value; return this; } - [global::System.CLSCompliant(false)] public Builder AddUnpackedUint64(ulong value) { PrepareBuilder(); result.unpackedUint64_.Add(value); return this; } - [global::System.CLSCompliant(false)] public Builder AddRangeUnpackedUint64(scg::IEnumerable values) { PrepareBuilder(); result.unpackedUint64_.Add(values); @@ -3366,30 +3367,25 @@ namespace Google.ProtocolBuffers.TestProtos { return this; } - [global::System.CLSCompliant(false)] public pbc::IPopsicleList UnpackedFixed32List { get { return PrepareBuilder().unpackedFixed32_; } } public int UnpackedFixed32Count { get { return result.UnpackedFixed32Count; } } - [global::System.CLSCompliant(false)] public uint GetUnpackedFixed32(int index) { return result.GetUnpackedFixed32(index); } - [global::System.CLSCompliant(false)] public Builder SetUnpackedFixed32(int index, uint value) { PrepareBuilder(); result.unpackedFixed32_[index] = value; return this; } - [global::System.CLSCompliant(false)] public Builder AddUnpackedFixed32(uint value) { PrepareBuilder(); result.unpackedFixed32_.Add(value); return this; } - [global::System.CLSCompliant(false)] public Builder AddRangeUnpackedFixed32(scg::IEnumerable values) { PrepareBuilder(); result.unpackedFixed32_.Add(values); @@ -3401,30 +3397,25 @@ namespace Google.ProtocolBuffers.TestProtos { return this; } - [global::System.CLSCompliant(false)] public pbc::IPopsicleList UnpackedFixed64List { get { return PrepareBuilder().unpackedFixed64_; } } public int UnpackedFixed64Count { get { return result.UnpackedFixed64Count; } } - [global::System.CLSCompliant(false)] public ulong GetUnpackedFixed64(int index) { return result.GetUnpackedFixed64(index); } - [global::System.CLSCompliant(false)] public Builder SetUnpackedFixed64(int index, ulong value) { PrepareBuilder(); result.unpackedFixed64_[index] = value; return this; } - [global::System.CLSCompliant(false)] public Builder AddUnpackedFixed64(ulong value) { PrepareBuilder(); result.unpackedFixed64_.Add(value); return this; } - [global::System.CLSCompliant(false)] public Builder AddRangeUnpackedFixed64(scg::IEnumerable values) { PrepareBuilder(); result.unpackedFixed64_.Add(values); @@ -3686,7 +3677,9 @@ namespace Google.ProtocolBuffers.TestProtos { #region Lite runtime methods public override int GetHashCode() { int hash = GetType().GetHashCode(); - if (hasValue) hash ^= value_.GetHashCode(); + if (hasValue) { + hash ^= value_.GetHashCode(); + } return hash; } @@ -3969,8 +3962,12 @@ namespace Google.ProtocolBuffers.TestProtos { #region Lite runtime methods public override int GetHashCode() { int hash = GetType().GetHashCode(); - if (hasValue) hash ^= value_.GetHashCode(); - if (hasValue2) hash ^= value2_.GetHashCode(); + if (hasValue) { + hash ^= value_.GetHashCode(); + } + if (hasValue2) { + hash ^= value2_.GetHashCode(); + } return hash; } -- cgit v1.2.3 From 4083104aa4862e22aa5addbfaaa3a49ebbd2c4a0 Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 12 May 2015 21:58:59 -0700 Subject: regenerated UnittestImportPublicLite --- .../ProtocolBuffersLite.Test/TestProtos/UnittestImportPublicLite.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'csharp/src/ProtocolBuffersLite.Test/TestProtos') diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublicLite.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublicLite.cs index de250899..6dabfcdb 100644 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublicLite.cs +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportPublicLite.cs @@ -92,7 +92,9 @@ namespace Google.ProtocolBuffers.TestProtos { #region Lite runtime methods public override int GetHashCode() { int hash = GetType().GetHashCode(); - if (hasE) hash ^= e_.GetHashCode(); + if (hasE) { + hash ^= e_.GetHashCode(); + } return hash; } -- cgit v1.2.3 From 881995352dfedc23ed62f45d4acc18f948f1785a Mon Sep 17 00:00:00 2001 From: Jan Tattermusch Date: Tue, 12 May 2015 22:00:38 -0700 Subject: regenerated UnittestImportLite.cs --- csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportLite.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'csharp/src/ProtocolBuffersLite.Test/TestProtos') diff --git a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportLite.cs b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportLite.cs index b0ad3155..1fee16e0 100644 --- a/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportLite.cs +++ b/csharp/src/ProtocolBuffersLite.Test/TestProtos/UnittestImportLite.cs @@ -101,7 +101,9 @@ namespace Google.ProtocolBuffers.TestProtos { #region Lite runtime methods public override int GetHashCode() { int hash = GetType().GetHashCode(); - if (hasD) hash ^= d_.GetHashCode(); + if (hasD) { + hash ^= d_.GetHashCode(); + } return hash; } -- cgit v1.2.3