Commit aa7ea3b6 authored by Jon Skeet's avatar Jon Skeet

Merge pull request #834 from jskeet/docfixes

Add (some) XML documentation to generated code
parents 5ebac49f 6bbbdfa2
...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection; ...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection;
using scg = global::System.Collections.Generic; using scg = global::System.Collections.Generic;
namespace Google.Protobuf.Examples.AddressBook { namespace Google.Protobuf.Examples.AddressBook {
/// <summary>Holder for reflection information generated from addressbook.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Addressbook { public static partial class Addressbook {
#region Descriptor #region Descriptor
/// <summary>File descriptor for addressbook.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
...@@ -212,6 +214,7 @@ namespace Google.Protobuf.Examples.AddressBook { ...@@ -212,6 +214,7 @@ namespace Google.Protobuf.Examples.AddressBook {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the Person message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
public enum PhoneType { public enum PhoneType {
......
...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection; ...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection;
using scg = global::System.Collections.Generic; using scg = global::System.Collections.Generic;
namespace Conformance { namespace Conformance {
/// <summary>Holder for reflection information generated from conformance.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Conformance { public static partial class Conformance {
#region Descriptor #region Descriptor
/// <summary>File descriptor for conformance.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
...@@ -225,6 +227,7 @@ namespace Conformance { ...@@ -225,6 +227,7 @@ namespace Conformance {
} }
private object payload_; private object payload_;
/// <summary>Enum of possible cases for the "payload" oneof.</summary>
public enum PayloadOneofCase { public enum PayloadOneofCase {
None = 0, None = 0,
ProtobufPayload = 1, ProtobufPayload = 1,
...@@ -431,6 +434,7 @@ namespace Conformance { ...@@ -431,6 +434,7 @@ namespace Conformance {
} }
private object result_; private object result_;
/// <summary>Enum of possible cases for the "result" oneof.</summary>
public enum ResultOneofCase { public enum ResultOneofCase {
None = 0, None = 0,
ParseError = 1, ParseError = 1,
...@@ -1240,6 +1244,7 @@ namespace Conformance { ...@@ -1240,6 +1244,7 @@ namespace Conformance {
} }
private object oneofField_; private object oneofField_;
/// <summary>Enum of possible cases for the "oneof_field" oneof.</summary>
public enum OneofFieldOneofCase { public enum OneofFieldOneofCase {
None = 0, None = 0,
OneofUint32 = 111, OneofUint32 = 111,
...@@ -2123,6 +2128,7 @@ namespace Conformance { ...@@ -2123,6 +2128,7 @@ namespace Conformance {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the TestAllTypes message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
public enum NestedEnum { public enum NestedEnum {
......
...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection; ...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection;
using scg = global::System.Collections.Generic; using scg = global::System.Collections.Generic;
namespace Google.Protobuf.TestProtos { namespace Google.Protobuf.TestProtos {
/// <summary>Holder for reflection information generated from google/protobuf/map_unittest_proto3.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class MapUnittestProto3 { public static partial class MapUnittestProto3 {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/map_unittest_proto3.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
...@@ -1305,6 +1307,7 @@ namespace Google.Protobuf.TestProtos { ...@@ -1305,6 +1307,7 @@ namespace Google.Protobuf.TestProtos {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the MessageContainingEnumCalledType message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
public enum Type { public enum Type {
......
...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection; ...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection;
using scg = global::System.Collections.Generic; using scg = global::System.Collections.Generic;
namespace Google.Protobuf.TestProtos { namespace Google.Protobuf.TestProtos {
/// <summary>Holder for reflection information generated from google/protobuf/unittest_import_proto3.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class UnittestImportProto3 { public static partial class UnittestImportProto3 {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/unittest_import_proto3.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
......
...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection; ...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection;
using scg = global::System.Collections.Generic; using scg = global::System.Collections.Generic;
namespace Google.Protobuf.TestProtos { namespace Google.Protobuf.TestProtos {
/// <summary>Holder for reflection information generated from google/protobuf/unittest_import_public_proto3.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class UnittestImportPublicProto3 { public static partial class UnittestImportPublicProto3 {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/unittest_import_public_proto3.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
......
...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection; ...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection;
using scg = global::System.Collections.Generic; using scg = global::System.Collections.Generic;
namespace UnitTest.Issues.TestProtos { namespace UnitTest.Issues.TestProtos {
/// <summary>Holder for reflection information generated from unittest_issues.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class UnittestIssues { public static partial class UnittestIssues {
#region Descriptor #region Descriptor
/// <summary>File descriptor for unittest_issues.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
...@@ -149,6 +151,7 @@ namespace UnitTest.Issues.TestProtos { ...@@ -149,6 +151,7 @@ namespace UnitTest.Issues.TestProtos {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the Issue307 message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
...@@ -226,6 +229,7 @@ namespace UnitTest.Issues.TestProtos { ...@@ -226,6 +229,7 @@ namespace UnitTest.Issues.TestProtos {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the NestedOnce message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
...@@ -981,6 +985,7 @@ namespace UnitTest.Issues.TestProtos { ...@@ -981,6 +985,7 @@ namespace UnitTest.Issues.TestProtos {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the ReservedNames message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
...@@ -1165,6 +1170,7 @@ namespace UnitTest.Issues.TestProtos { ...@@ -1165,6 +1170,7 @@ namespace UnitTest.Issues.TestProtos {
} }
private object o1_; private object o1_;
/// <summary>Enum of possible cases for the "o1" oneof.</summary>
public enum O1OneofCase { public enum O1OneofCase {
None = 0, None = 0,
O1String = 2, O1String = 2,
...@@ -1181,6 +1187,7 @@ namespace UnitTest.Issues.TestProtos { ...@@ -1181,6 +1187,7 @@ namespace UnitTest.Issues.TestProtos {
} }
private object o2_; private object o2_;
/// <summary>Enum of possible cases for the "o2" oneof.</summary>
public enum O2OneofCase { public enum O2OneofCase {
None = 0, None = 0,
O2Int32 = 6, O2Int32 = 6,
......
...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection; ...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection;
using scg = global::System.Collections.Generic; using scg = global::System.Collections.Generic;
namespace Google.Protobuf.TestProtos { namespace Google.Protobuf.TestProtos {
/// <summary>Holder for reflection information generated from google/protobuf/unittest_proto3.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class UnittestProto3 { public static partial class UnittestProto3 {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/unittest_proto3.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
...@@ -715,6 +717,7 @@ namespace Google.Protobuf.TestProtos { ...@@ -715,6 +717,7 @@ namespace Google.Protobuf.TestProtos {
} }
private object oneofField_; private object oneofField_;
/// <summary>Enum of possible cases for the "oneof_field" oneof.</summary>
public enum OneofFieldOneofCase { public enum OneofFieldOneofCase {
None = 0, None = 0,
OneofUint32 = 111, OneofUint32 = 111,
...@@ -1443,6 +1446,7 @@ namespace Google.Protobuf.TestProtos { ...@@ -1443,6 +1446,7 @@ namespace Google.Protobuf.TestProtos {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the TestAllTypes message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
public enum NestedEnum { public enum NestedEnum {
...@@ -3056,6 +3060,7 @@ namespace Google.Protobuf.TestProtos { ...@@ -3056,6 +3060,7 @@ namespace Google.Protobuf.TestProtos {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the TestFieldOrderings message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
...@@ -4269,6 +4274,7 @@ namespace Google.Protobuf.TestProtos { ...@@ -4269,6 +4274,7 @@ namespace Google.Protobuf.TestProtos {
} }
private object foo_; private object foo_;
/// <summary>Enum of possible cases for the "foo" oneof.</summary>
public enum FooOneofCase { public enum FooOneofCase {
None = 0, None = 0,
FooInt = 1, FooInt = 1,
......
...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection; ...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection;
using scg = global::System.Collections.Generic; using scg = global::System.Collections.Generic;
namespace Google.Protobuf.TestProtos { namespace Google.Protobuf.TestProtos {
/// <summary>Holder for reflection information generated from google/protobuf/unittest_well_known_types.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class UnittestWellKnownTypes { public static partial class UnittestWellKnownTypes {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/unittest_well_known_types.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
...@@ -1468,6 +1470,7 @@ namespace Google.Protobuf.TestProtos { ...@@ -1468,6 +1470,7 @@ namespace Google.Protobuf.TestProtos {
} }
private object oneofField_; private object oneofField_;
/// <summary>Enum of possible cases for the "oneof_field" oneof.</summary>
public enum OneofFieldOneofCase { public enum OneofFieldOneofCase {
None = 0, None = 0,
AnyField = 1, AnyField = 1,
......
...@@ -38,7 +38,7 @@ using System.IO; ...@@ -38,7 +38,7 @@ using System.IO;
namespace Google.Protobuf namespace Google.Protobuf
{ {
/// <summary> /// <summary>
/// Readings and decodes protocol message fields. /// Reads and decodes protocol message fields.
/// </summary> /// </summary>
/// <remarks> /// <remarks>
/// <para> /// <para>
......
...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection; ...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection;
using scg = global::System.Collections.Generic; using scg = global::System.Collections.Generic;
namespace Google.Protobuf.Reflection { namespace Google.Protobuf.Reflection {
/// <summary>Holder for reflection information generated from google/protobuf/descriptor.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
internal static partial class DescriptorProtoFile { internal static partial class DescriptorProtoFile {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/descriptor.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
...@@ -877,6 +879,7 @@ namespace Google.Protobuf.Reflection { ...@@ -877,6 +879,7 @@ namespace Google.Protobuf.Reflection {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the DescriptorProto message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
...@@ -1455,6 +1458,7 @@ namespace Google.Protobuf.Reflection { ...@@ -1455,6 +1458,7 @@ namespace Google.Protobuf.Reflection {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the FieldDescriptorProto message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
internal enum Type { internal enum Type {
...@@ -2776,6 +2780,7 @@ namespace Google.Protobuf.Reflection { ...@@ -2776,6 +2780,7 @@ namespace Google.Protobuf.Reflection {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the FileOptions message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
internal enum OptimizeMode { internal enum OptimizeMode {
...@@ -3236,6 +3241,7 @@ namespace Google.Protobuf.Reflection { ...@@ -3236,6 +3241,7 @@ namespace Google.Protobuf.Reflection {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the FieldOptions message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
internal enum CType { internal enum CType {
...@@ -4010,6 +4016,7 @@ namespace Google.Protobuf.Reflection { ...@@ -4010,6 +4016,7 @@ namespace Google.Protobuf.Reflection {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the UninterpretedOption message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
...@@ -4238,6 +4245,7 @@ namespace Google.Protobuf.Reflection { ...@@ -4238,6 +4245,7 @@ namespace Google.Protobuf.Reflection {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the SourceCodeInfo message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
......
...@@ -252,7 +252,7 @@ namespace Google.Protobuf.Reflection ...@@ -252,7 +252,7 @@ namespace Google.Protobuf.Reflection
{ {
if (fieldType != FieldType.Message) if (fieldType != FieldType.Message)
{ {
throw new InvalidOperationException("MessageType is only valid for enum fields."); throw new InvalidOperationException("MessageType is only valid for message fields.");
} }
return messageType; return messageType;
} }
......
...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes {
namespace Proto { namespace Proto {
/// <summary>Holder for reflection information generated from google/protobuf/any.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Any { public static partial class Any {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/any.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
......
...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes {
namespace Proto { namespace Proto {
/// <summary>Holder for reflection information generated from google/protobuf/api.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Api { public static partial class Api {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/api.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
......
...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes {
namespace Proto { namespace Proto {
/// <summary>Holder for reflection information generated from google/protobuf/duration.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Duration { public static partial class Duration {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/duration.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
......
...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes {
namespace Proto { namespace Proto {
/// <summary>Holder for reflection information generated from google/protobuf/empty.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Empty { public static partial class Empty {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/empty.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
......
...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes {
namespace Proto { namespace Proto {
/// <summary>Holder for reflection information generated from google/protobuf/field_mask.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class FieldMask { public static partial class FieldMask {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/field_mask.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
......
...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes {
namespace Proto { namespace Proto {
/// <summary>Holder for reflection information generated from google/protobuf/source_context.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class SourceContext { public static partial class SourceContext {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/source_context.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
......
...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes {
namespace Proto { namespace Proto {
/// <summary>Holder for reflection information generated from google/protobuf/struct.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Struct { public static partial class Struct {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/struct.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
...@@ -253,6 +255,7 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -253,6 +255,7 @@ namespace Google.Protobuf.WellKnownTypes {
} }
private object kind_; private object kind_;
/// <summary>Enum of possible cases for the "kind" oneof.</summary>
public enum KindOneofCase { public enum KindOneofCase {
None = 0, None = 0,
NullValue = 1, NullValue = 1,
......
...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes {
namespace Proto { namespace Proto {
/// <summary>Holder for reflection information generated from google/protobuf/timestamp.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Timestamp { public static partial class Timestamp {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/timestamp.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
......
...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -11,10 +11,12 @@ namespace Google.Protobuf.WellKnownTypes {
namespace Proto { namespace Proto {
/// <summary>Holder for reflection information generated from google/protobuf/type.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Type { public static partial class Type {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/type.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
...@@ -595,6 +597,7 @@ namespace Google.Protobuf.WellKnownTypes { ...@@ -595,6 +597,7 @@ namespace Google.Protobuf.WellKnownTypes {
} }
#region Nested types #region Nested types
/// <summary>Container for nested types declared in the Field message type.</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Types { public static partial class Types {
public enum Kind { public enum Kind {
......
...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection; ...@@ -9,10 +9,12 @@ using pbr = global::Google.Protobuf.Reflection;
using scg = global::System.Collections.Generic; using scg = global::System.Collections.Generic;
namespace Google.Protobuf.WellKnownTypes { namespace Google.Protobuf.WellKnownTypes {
/// <summary>Holder for reflection information generated from google/protobuf/wrappers.proto</summary>
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
public static partial class Wrappers { public static partial class Wrappers {
#region Descriptor #region Descriptor
/// <summary>File descriptor for google/protobuf/wrappers.proto</summary>
public static pbr::FileDescriptor Descriptor { public static pbr::FileDescriptor Descriptor {
get { return descriptor; } get { return descriptor; }
} }
......
...@@ -169,6 +169,7 @@ void MessageGenerator::Generate(io::Printer* printer) { ...@@ -169,6 +169,7 @@ void MessageGenerator::Generate(io::Printer* printer) {
printer->Print( printer->Print(
vars, vars,
"private object $name$_;\n" "private object $name$_;\n"
"/// <summary>Enum of possible cases for the \"$original_name$\" oneof.</summary>\n"
"public enum $property_name$OneofCase {\n"); "public enum $property_name$OneofCase {\n");
printer->Indent(); printer->Indent();
printer->Print("None = 0,\n"); printer->Print("None = 0,\n");
...@@ -199,7 +200,10 @@ void MessageGenerator::Generate(io::Printer* printer) { ...@@ -199,7 +200,10 @@ void MessageGenerator::Generate(io::Printer* printer) {
// Nested messages and enums // Nested messages and enums
if (HasNestedGeneratedTypes()) { if (HasNestedGeneratedTypes()) {
printer->Print("#region Nested types\n" printer->Print(
vars,
"#region Nested types\n"
"/// <summary>Container for nested types declared in the $class_name$ message type.</summary>\n"
"[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n"); "[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n");
WriteGeneratedCodeAttributes(printer); WriteGeneratedCodeAttributes(printer);
printer->Print("public static partial class Types {\n"); printer->Print("public static partial class Types {\n");
......
...@@ -135,7 +135,9 @@ void UmbrellaClassGenerator::WriteIntroduction(io::Printer* printer) { ...@@ -135,7 +135,9 @@ void UmbrellaClassGenerator::WriteIntroduction(io::Printer* printer) {
} }
printer->Print( printer->Print(
"[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n"); "/// <summary>Holder for reflection information generated from $file_name$</summary>\n"
"[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n",
"file_name", file_->name());
WriteGeneratedCodeAttributes(printer); WriteGeneratedCodeAttributes(printer);
printer->Print( printer->Print(
"$access_level$ static partial class $umbrella_class_name$ {\n" "$access_level$ static partial class $umbrella_class_name$ {\n"
...@@ -148,12 +150,14 @@ void UmbrellaClassGenerator::WriteIntroduction(io::Printer* printer) { ...@@ -148,12 +150,14 @@ void UmbrellaClassGenerator::WriteIntroduction(io::Printer* printer) {
void UmbrellaClassGenerator::WriteDescriptor(io::Printer* printer) { void UmbrellaClassGenerator::WriteDescriptor(io::Printer* printer) {
printer->Print( printer->Print(
"#region Descriptor\n" "#region Descriptor\n"
"/// <summary>File descriptor for $file_name$</summary>\n"
"public static pbr::FileDescriptor Descriptor {\n" "public static pbr::FileDescriptor Descriptor {\n"
" get { return descriptor; }\n" " get { return descriptor; }\n"
"}\n" "}\n"
"private static pbr::FileDescriptor descriptor;\n" "private static pbr::FileDescriptor descriptor;\n"
"\n" "\n"
"static $umbrella_class_name$() {\n", "static $umbrella_class_name$() {\n",
"file_name", file_->name(),
"umbrella_class_name", umbrellaClassname_); "umbrella_class_name", umbrellaClassname_);
printer->Indent(); printer->Indent();
printer->Print( printer->Print(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment