xref: /aosp_15_r20/external/protobuf/csharp/src/Google.Protobuf.Test.TestProtos/UnittestImportPublic.cs (revision 1b3f573f81763fcece89efc2b6a5209149e44ab8)
1 // <auto-generated>
2 //     Generated by the protocol buffer compiler.  DO NOT EDIT!
3 //     source: unittest_import_public.proto
4 // </auto-generated>
5 #pragma warning disable 1591, 0612, 3021, 8981
6 #region Designer generated code
7 
8 using pb = global::Google.Protobuf;
9 using pbc = global::Google.Protobuf.Collections;
10 using pbr = global::Google.Protobuf.Reflection;
11 using scg = global::System.Collections.Generic;
12 namespace Google.Protobuf.TestProtos.Proto2 {
13 
14   /// <summary>Holder for reflection information generated from unittest_import_public.proto</summary>
15   public static partial class UnittestImportPublicReflection {
16 
17     #region Descriptor
18     /// <summary>File descriptor for unittest_import_public.proto</summary>
19     public static pbr::FileDescriptor Descriptor {
20       get { return descriptor; }
21     }
22     private static pbr::FileDescriptor descriptor;
23 
UnittestImportPublicReflection()24     static UnittestImportPublicReflection() {
25       byte[] descriptorData = global::System.Convert.FromBase64String(
26           string.Concat(
27             "Chx1bml0dGVzdF9pbXBvcnRfcHVibGljLnByb3RvEh9wcm90b2J1Zl91bml0",
28             "dGVzdF9pbXBvcnRfcHJvdG8yIiAKE1B1YmxpY0ltcG9ydE1lc3NhZ2USCQoB",
29             "ZRgBIAEoBUIkqgIhR29vZ2xlLlByb3RvYnVmLlRlc3RQcm90b3MuUHJvdG8y"));
30       descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
31           new pbr::FileDescriptor[] { },
32           new pbr::GeneratedClrTypeInfo(null, null, new pbr::GeneratedClrTypeInfo[] {
33             new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.TestProtos.Proto2.PublicImportMessage), global::Google.Protobuf.TestProtos.Proto2.PublicImportMessage.Parser, new[]{ "E" }, null, null, null, null)
34           }));
35     }
36     #endregion
37 
38   }
39   #region Messages
40   public sealed partial class PublicImportMessage : pb::IMessage<PublicImportMessage>
41   #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
42       , pb::IBufferMessage
43   #endif
44   {
45     private static readonly pb::MessageParser<PublicImportMessage> _parser = new pb::MessageParser<PublicImportMessage>(() => new PublicImportMessage());
46     private pb::UnknownFieldSet _unknownFields;
47     private int _hasBits0;
48     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
49     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
50     public static pb::MessageParser<PublicImportMessage> Parser { get { return _parser; } }
51 
52     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
53     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
54     public static pbr::MessageDescriptor Descriptor {
55       get { return global::Google.Protobuf.TestProtos.Proto2.UnittestImportPublicReflection.Descriptor.MessageTypes[0]; }
56     }
57 
58     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
59     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
60     pbr::MessageDescriptor pb::IMessage.Descriptor {
61       get { return Descriptor; }
62     }
63 
64     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
65     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
PublicImportMessage()66     public PublicImportMessage() {
67       OnConstruction();
68     }
69 
OnConstruction()70     partial void OnConstruction();
71 
72     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
73     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
PublicImportMessage(PublicImportMessage other)74     public PublicImportMessage(PublicImportMessage other) : this() {
75       _hasBits0 = other._hasBits0;
76       e_ = other.e_;
77       _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields);
78     }
79 
80     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
81     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
Clone()82     public PublicImportMessage Clone() {
83       return new PublicImportMessage(this);
84     }
85 
86     /// <summary>Field number for the "e" field.</summary>
87     public const int EFieldNumber = 1;
88     private readonly static int EDefaultValue = 0;
89 
90     private int e_;
91     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
92     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
93     public int E {
94       get { if ((_hasBits0 & 1) != 0) { return e_; } else { return EDefaultValue; } }
95       set {
96         _hasBits0 |= 1;
97         e_ = value;
98       }
99     }
100     /// <summary>Gets whether the "e" field is set</summary>
101     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
102     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
103     public bool HasE {
104       get { return (_hasBits0 & 1) != 0; }
105     }
106     /// <summary>Clears the value of the "e" field</summary>
107     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
108     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
ClearE()109     public void ClearE() {
110       _hasBits0 &= ~1;
111     }
112 
113     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
114     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
Equals(object other)115     public override bool Equals(object other) {
116       return Equals(other as PublicImportMessage);
117     }
118 
119     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
120     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
Equals(PublicImportMessage other)121     public bool Equals(PublicImportMessage other) {
122       if (ReferenceEquals(other, null)) {
123         return false;
124       }
125       if (ReferenceEquals(other, this)) {
126         return true;
127       }
128       if (E != other.E) return false;
129       return Equals(_unknownFields, other._unknownFields);
130     }
131 
132     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
133     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
GetHashCode()134     public override int GetHashCode() {
135       int hash = 1;
136       if (HasE) hash ^= E.GetHashCode();
137       if (_unknownFields != null) {
138         hash ^= _unknownFields.GetHashCode();
139       }
140       return hash;
141     }
142 
143     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
144     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
ToString()145     public override string ToString() {
146       return pb::JsonFormatter.ToDiagnosticString(this);
147     }
148 
149     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
150     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
WriteTo(pb::CodedOutputStream output)151     public void WriteTo(pb::CodedOutputStream output) {
152     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
153       output.WriteRawMessage(this);
154     #else
155       if (HasE) {
156         output.WriteRawTag(8);
157         output.WriteInt32(E);
158       }
159       if (_unknownFields != null) {
160         _unknownFields.WriteTo(output);
161       }
162     #endif
163     }
164 
165     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
166     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
167     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
IBufferMessage.InternalWriteTo(ref pb::WriteContext output)168     void pb::IBufferMessage.InternalWriteTo(ref pb::WriteContext output) {
169       if (HasE) {
170         output.WriteRawTag(8);
171         output.WriteInt32(E);
172       }
173       if (_unknownFields != null) {
174         _unknownFields.WriteTo(ref output);
175       }
176     }
177     #endif
178 
179     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
180     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
CalculateSize()181     public int CalculateSize() {
182       int size = 0;
183       if (HasE) {
184         size += 1 + pb::CodedOutputStream.ComputeInt32Size(E);
185       }
186       if (_unknownFields != null) {
187         size += _unknownFields.CalculateSize();
188       }
189       return size;
190     }
191 
192     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
193     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
MergeFrom(PublicImportMessage other)194     public void MergeFrom(PublicImportMessage other) {
195       if (other == null) {
196         return;
197       }
198       if (other.HasE) {
199         E = other.E;
200       }
201       _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
202     }
203 
204     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
205     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
MergeFrom(pb::CodedInputStream input)206     public void MergeFrom(pb::CodedInputStream input) {
207     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
208       input.ReadRawMessage(this);
209     #else
210       uint tag;
211       while ((tag = input.ReadTag()) != 0) {
212         switch(tag) {
213           default:
214             _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input);
215             break;
216           case 8: {
217             E = input.ReadInt32();
218             break;
219           }
220         }
221       }
222     #endif
223     }
224 
225     #if !GOOGLE_PROTOBUF_REFSTRUCT_COMPATIBILITY_MODE
226     [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
227     [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)]
IBufferMessage.InternalMergeFrom(ref pb::ParseContext input)228     void pb::IBufferMessage.InternalMergeFrom(ref pb::ParseContext input) {
229       uint tag;
230       while ((tag = input.ReadTag()) != 0) {
231         switch(tag) {
232           default:
233             _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, ref input);
234             break;
235           case 8: {
236             E = input.ReadInt32();
237             break;
238           }
239         }
240       }
241     }
242     #endif
243 
244   }
245 
246   #endregion
247 
248 }
249 
250 #endregion Designer generated code
251