diff options
author | Jon Skeet <jonskeet@google.com> | 2016-07-01 13:19:19 +0100 |
---|---|---|
committer | Jon Skeet <jonskeet@google.com> | 2016-07-04 08:22:18 +0100 |
commit | c53484539c691a717ad531081e6fbed7fd4ea192 (patch) | |
tree | 075bbd85e82dd8a9a3ca9667751cd0120de178f2 /csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs | |
parent | ada0a81a74afdc472f019ba142cfc101ca7b3543 (diff) | |
download | protobuf-c53484539c691a717ad531081e6fbed7fd4ea192.tar.gz protobuf-c53484539c691a717ad531081e6fbed7fd4ea192.tar.bz2 protobuf-c53484539c691a717ad531081e6fbed7fd4ea192.zip |
Changes to generated code from previous commit
Diffstat (limited to 'csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs')
-rw-r--r-- | csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs | 56 |
1 files changed, 52 insertions, 4 deletions
diff --git a/csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs b/csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs index edc8940d..b3d62fbf 100644 --- a/csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs +++ b/csharp/src/Google.Protobuf/WellKnownTypes/Struct.cs @@ -10,7 +10,6 @@ using scg = global::System.Collections.Generic; namespace Google.Protobuf.WellKnownTypes { /// <summary>Holder for reflection information generated from google/protobuf/struct.proto</summary> - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] public static partial class StructReflection { #region Descriptor @@ -76,29 +75,34 @@ namespace Google.Protobuf.WellKnownTypes { /// /// The JSON representation for `Struct` is JSON object. /// </summary> - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] public sealed partial class Struct : pb::IMessage<Struct> { private static readonly pb::MessageParser<Struct> _parser = new pb::MessageParser<Struct>(() => new Struct()); + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<Struct> Parser { get { return _parser; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pbr::MessageDescriptor Descriptor { get { return global::Google.Protobuf.WellKnownTypes.StructReflection.Descriptor.MessageTypes[0]; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] pbr::MessageDescriptor pb::IMessage.Descriptor { get { return Descriptor; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Struct() { OnConstruction(); } partial void OnConstruction(); + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Struct(Struct other) : this() { fields_ = other.fields_.Clone(); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Struct Clone() { return new Struct(this); } @@ -111,14 +115,17 @@ namespace Google.Protobuf.WellKnownTypes { /// <summary> /// Unordered map of dynamically typed values. /// </summary> + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public pbc::MapField<string, global::Google.Protobuf.WellKnownTypes.Value> Fields { get { return fields_; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override bool Equals(object other) { return Equals(other as Struct); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public bool Equals(Struct other) { if (ReferenceEquals(other, null)) { return false; @@ -130,26 +137,31 @@ namespace Google.Protobuf.WellKnownTypes { return true; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; hash ^= Fields.GetHashCode(); return hash; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override string ToString() { return pb::JsonFormatter.ToDiagnosticString(this); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { fields_.WriteTo(output, _map_fields_codec); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; size += fields_.CalculateSize(_map_fields_codec); return size; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void MergeFrom(Struct other) { if (other == null) { return; @@ -157,6 +169,7 @@ namespace Google.Protobuf.WellKnownTypes { fields_.Add(other.fields_); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void MergeFrom(pb::CodedInputStream input) { uint tag; while ((tag = input.ReadTag()) != 0) { @@ -182,25 +195,29 @@ namespace Google.Protobuf.WellKnownTypes { /// /// The JSON representation for `Value` is JSON value. /// </summary> - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] public sealed partial class Value : pb::IMessage<Value> { private static readonly pb::MessageParser<Value> _parser = new pb::MessageParser<Value>(() => new Value()); + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<Value> Parser { get { return _parser; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pbr::MessageDescriptor Descriptor { get { return global::Google.Protobuf.WellKnownTypes.StructReflection.Descriptor.MessageTypes[1]; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] pbr::MessageDescriptor pb::IMessage.Descriptor { get { return Descriptor; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Value() { OnConstruction(); } partial void OnConstruction(); + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Value(Value other) : this() { switch (other.KindCase) { case KindOneofCase.NullValue: @@ -225,6 +242,7 @@ namespace Google.Protobuf.WellKnownTypes { } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Value Clone() { return new Value(this); } @@ -234,6 +252,7 @@ namespace Google.Protobuf.WellKnownTypes { /// <summary> /// Represents a null value. /// </summary> + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public global::Google.Protobuf.WellKnownTypes.NullValue NullValue { get { return kindCase_ == KindOneofCase.NullValue ? (global::Google.Protobuf.WellKnownTypes.NullValue) kind_ : 0; } set { @@ -247,6 +266,7 @@ namespace Google.Protobuf.WellKnownTypes { /// <summary> /// Represents a double value. /// </summary> + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public double NumberValue { get { return kindCase_ == KindOneofCase.NumberValue ? (double) kind_ : 0D; } set { @@ -260,6 +280,7 @@ namespace Google.Protobuf.WellKnownTypes { /// <summary> /// Represents a string value. /// </summary> + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public string StringValue { get { return kindCase_ == KindOneofCase.StringValue ? (string) kind_ : ""; } set { @@ -273,6 +294,7 @@ namespace Google.Protobuf.WellKnownTypes { /// <summary> /// Represents a boolean value. /// </summary> + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public bool BoolValue { get { return kindCase_ == KindOneofCase.BoolValue ? (bool) kind_ : false; } set { @@ -286,6 +308,7 @@ namespace Google.Protobuf.WellKnownTypes { /// <summary> /// Represents a structured value. /// </summary> + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public global::Google.Protobuf.WellKnownTypes.Struct StructValue { get { return kindCase_ == KindOneofCase.StructValue ? (global::Google.Protobuf.WellKnownTypes.Struct) kind_ : null; } set { @@ -299,6 +322,7 @@ namespace Google.Protobuf.WellKnownTypes { /// <summary> /// Represents a repeated `Value`. /// </summary> + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public global::Google.Protobuf.WellKnownTypes.ListValue ListValue { get { return kindCase_ == KindOneofCase.ListValue ? (global::Google.Protobuf.WellKnownTypes.ListValue) kind_ : null; } set { @@ -319,19 +343,23 @@ namespace Google.Protobuf.WellKnownTypes { ListValue = 6, } private KindOneofCase kindCase_ = KindOneofCase.None; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public KindOneofCase KindCase { get { return kindCase_; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void ClearKind() { kindCase_ = KindOneofCase.None; kind_ = null; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override bool Equals(object other) { return Equals(other as Value); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public bool Equals(Value other) { if (ReferenceEquals(other, null)) { return false; @@ -349,6 +377,7 @@ namespace Google.Protobuf.WellKnownTypes { return true; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (kindCase_ == KindOneofCase.NullValue) hash ^= NullValue.GetHashCode(); @@ -361,10 +390,12 @@ namespace Google.Protobuf.WellKnownTypes { return hash; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override string ToString() { return pb::JsonFormatter.ToDiagnosticString(this); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { if (kindCase_ == KindOneofCase.NullValue) { output.WriteRawTag(8); @@ -392,6 +423,7 @@ namespace Google.Protobuf.WellKnownTypes { } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; if (kindCase_ == KindOneofCase.NullValue) { @@ -415,6 +447,7 @@ namespace Google.Protobuf.WellKnownTypes { return size; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void MergeFrom(Value other) { if (other == null) { return; @@ -442,6 +475,7 @@ namespace Google.Protobuf.WellKnownTypes { } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void MergeFrom(pb::CodedInputStream input) { uint tag; while ((tag = input.ReadTag()) != 0) { @@ -495,29 +529,34 @@ namespace Google.Protobuf.WellKnownTypes { /// /// The JSON representation for `ListValue` is JSON array. /// </summary> - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] public sealed partial class ListValue : pb::IMessage<ListValue> { private static readonly pb::MessageParser<ListValue> _parser = new pb::MessageParser<ListValue>(() => new ListValue()); + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<ListValue> Parser { get { return _parser; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pbr::MessageDescriptor Descriptor { get { return global::Google.Protobuf.WellKnownTypes.StructReflection.Descriptor.MessageTypes[2]; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] pbr::MessageDescriptor pb::IMessage.Descriptor { get { return Descriptor; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public ListValue() { OnConstruction(); } partial void OnConstruction(); + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public ListValue(ListValue other) : this() { values_ = other.values_.Clone(); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public ListValue Clone() { return new ListValue(this); } @@ -530,14 +569,17 @@ namespace Google.Protobuf.WellKnownTypes { /// <summary> /// Repeated field of dynamically typed values. /// </summary> + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public pbc::RepeatedField<global::Google.Protobuf.WellKnownTypes.Value> Values { get { return values_; } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override bool Equals(object other) { return Equals(other as ListValue); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public bool Equals(ListValue other) { if (ReferenceEquals(other, null)) { return false; @@ -549,26 +591,31 @@ namespace Google.Protobuf.WellKnownTypes { return true; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; hash ^= values_.GetHashCode(); return hash; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override string ToString() { return pb::JsonFormatter.ToDiagnosticString(this); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { values_.WriteTo(output, _repeated_values_codec); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; size += values_.CalculateSize(_repeated_values_codec); return size; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void MergeFrom(ListValue other) { if (other == null) { return; @@ -576,6 +623,7 @@ namespace Google.Protobuf.WellKnownTypes { values_.Add(other.values_); } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void MergeFrom(pb::CodedInputStream input) { uint tag; while ((tag = input.ReadTag()) != 0) { |