diff options
author | Jon Skeet <skeet@pobox.com> | 2008-08-14 20:35:35 +0100 |
---|---|---|
committer | Jon Skeet <skeet@pobox.com> | 2008-08-14 20:35:35 +0100 |
commit | eb4ef52c66a8e9f9a0477936adf4444ae37dd045 (patch) | |
tree | 8f9fd99e786dd5361a127affcc92285c980b27b0 /csharp/ProtocolBuffers.Test/TestProtos/UnitTestImportProtoFile.cs | |
parent | 5407a4329d578d8858cbcb3097b29a438fb03e43 (diff) | |
download | protobuf-eb4ef52c66a8e9f9a0477936adf4444ae37dd045.tar.gz protobuf-eb4ef52c66a8e9f9a0477936adf4444ae37dd045.tar.bz2 protobuf-eb4ef52c66a8e9f9a0477936adf4444ae37dd045.zip |
Abandon the 'self' namespace alias - we need to be able to import types in other namespaces too.
Diffstat (limited to 'csharp/ProtocolBuffers.Test/TestProtos/UnitTestImportProtoFile.cs')
-rw-r--r-- | csharp/ProtocolBuffers.Test/TestProtos/UnitTestImportProtoFile.cs | 56 |
1 files changed, 27 insertions, 29 deletions
diff --git a/csharp/ProtocolBuffers.Test/TestProtos/UnitTestImportProtoFile.cs b/csharp/ProtocolBuffers.Test/TestProtos/UnitTestImportProtoFile.cs index 5d5a546b..ff784d47 100644 --- a/csharp/ProtocolBuffers.Test/TestProtos/UnitTestImportProtoFile.cs +++ b/csharp/ProtocolBuffers.Test/TestProtos/UnitTestImportProtoFile.cs @@ -4,8 +4,6 @@ using pb = global::Google.ProtocolBuffers; using pbc = global::Google.ProtocolBuffers.Collections; using pbd = global::Google.ProtocolBuffers.Descriptors; using scg = global::System.Collections.Generic; -using self = global::Google.ProtocolBuffers.TestProtos; - namespace Google.ProtocolBuffers.TestProtos { public static partial class UnitTestImportProtoFile { @@ -42,8 +40,8 @@ namespace Google.ProtocolBuffers.TestProtos { internal static pb::FieldAccess.FieldAccessorTable internal__static_protobuf_unittest_import_ImportMessage__FieldAccessorTable = new pb::FieldAccess.FieldAccessorTable(internal__static_protobuf_unittest_import_ImportMessage__Descriptor, new string[] { "D", }, - typeof (self::ImportMessage), - typeof (self::ImportMessage.Builder)); + typeof (global::Google.ProtocolBuffers.TestProtos.ImportMessage), + typeof (global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder)); #endregion } @@ -69,11 +67,11 @@ namespace Google.ProtocolBuffers.TestProtos { } public static pbd::MessageDescriptor Descriptor { - get { return self::UnitTestImportProtoFile.internal__static_protobuf_unittest_import_ImportMessage__Descriptor; } + get { return global::Google.ProtocolBuffers.TestProtos.UnitTestImportProtoFile.internal__static_protobuf_unittest_import_ImportMessage__Descriptor; } } protected override pb::FieldAccess.FieldAccessorTable InternalFieldAccessors { - get { return self::UnitTestImportProtoFile.internal__static_protobuf_unittest_import_ImportMessage__FieldAccessorTable; } + get { return global::Google.ProtocolBuffers.TestProtos.UnitTestImportProtoFile.internal__static_protobuf_unittest_import_ImportMessage__FieldAccessorTable; } } // optional int32 d = 1; @@ -115,35 +113,35 @@ namespace Google.ProtocolBuffers.TestProtos { } } - public static self::ImportMessage ParseFrom(pb::ByteString data) { + public static global::Google.ProtocolBuffers.TestProtos.ImportMessage ParseFrom(pb::ByteString data) { return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static self::ImportMessage ParseFrom(pb::ByteString data, + public static global::Google.ProtocolBuffers.TestProtos.ImportMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) { return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)) .BuildParsed(); } - public static self::ImportMessage ParseFrom(byte[] data) { + public static global::Google.ProtocolBuffers.TestProtos.ImportMessage ParseFrom(byte[] data) { return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed(); } - public static self::ImportMessage ParseFrom(byte[] data, + public static global::Google.ProtocolBuffers.TestProtos.ImportMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) { return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)) .BuildParsed(); } - public static self::ImportMessage ParseFrom(global::System.IO.Stream input) { + public static global::Google.ProtocolBuffers.TestProtos.ImportMessage ParseFrom(global::System.IO.Stream input) { return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static self::ImportMessage ParseFrom( + public static global::Google.ProtocolBuffers.TestProtos.ImportMessage ParseFrom( global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) { return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)) .BuildParsed(); } - public static self::ImportMessage ParseFrom(pb::CodedInputStream input) { + public static global::Google.ProtocolBuffers.TestProtos.ImportMessage ParseFrom(pb::CodedInputStream input) { return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed(); } - public static self::ImportMessage ParseFrom(pb::CodedInputStream input, + public static global::Google.ProtocolBuffers.TestProtos.ImportMessage ParseFrom(pb::CodedInputStream input, pb::ExtensionRegistry extensionRegistry) { return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)) .BuildParsed(); @@ -151,26 +149,26 @@ namespace Google.ProtocolBuffers.TestProtos { public static Builder CreateBuilder() { return new Builder(); } public override Builder CreateBuilderForType() { return new Builder(); } - public static Builder CreateBuilder(self::ImportMessage prototype) { + public static Builder CreateBuilder(global::Google.ProtocolBuffers.TestProtos.ImportMessage prototype) { return (Builder) new Builder().MergeFrom(prototype); } - public sealed partial class Builder : pb::GeneratedBuilder<self::ImportMessage, Builder> { + public sealed partial class Builder : pb::GeneratedBuilder<global::Google.ProtocolBuffers.TestProtos.ImportMessage, Builder> { protected override Builder ThisBuilder { get { return this; } } - // Construct using self::ImportMessage.CreateBuilder() + // Construct using global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder() internal Builder() {} - self::ImportMessage result = new self::ImportMessage(); + global::Google.ProtocolBuffers.TestProtos.ImportMessage result = new global::Google.ProtocolBuffers.TestProtos.ImportMessage(); - protected override self::ImportMessage MessageBeingBuilt { + protected override global::Google.ProtocolBuffers.TestProtos.ImportMessage MessageBeingBuilt { get { return result; } } public override Builder Clear() { - result = new self::ImportMessage(); + result = new global::Google.ProtocolBuffers.TestProtos.ImportMessage(); return this; } @@ -179,30 +177,30 @@ namespace Google.ProtocolBuffers.TestProtos { } public override pbd::MessageDescriptor DescriptorForType { - get { return self::ImportMessage.Descriptor; } + get { return global::Google.ProtocolBuffers.TestProtos.ImportMessage.Descriptor; } } - public override self::ImportMessage DefaultInstanceForType { - get { return self::ImportMessage.DefaultInstance; } + public override global::Google.ProtocolBuffers.TestProtos.ImportMessage DefaultInstanceForType { + get { return global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance; } } - public override self::ImportMessage BuildPartial() { - self::ImportMessage returnMe = result; + public override global::Google.ProtocolBuffers.TestProtos.ImportMessage BuildPartial() { + global::Google.ProtocolBuffers.TestProtos.ImportMessage returnMe = result; result = null; return returnMe; } public override Builder MergeFrom(pb::IMessage other) { - if (other is self::ImportMessage) { - return MergeFrom((self::ImportMessage) other); + if (other is global::Google.ProtocolBuffers.TestProtos.ImportMessage) { + return MergeFrom((global::Google.ProtocolBuffers.TestProtos.ImportMessage) other); } else { base.MergeFrom(other); return this; } } - public override Builder MergeFrom(self::ImportMessage other) { - if (other == self::ImportMessage.DefaultInstance) return this; + public override Builder MergeFrom(global::Google.ProtocolBuffers.TestProtos.ImportMessage other) { + if (other == global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance) return this; if (other.HasD) { D = other.D; } |