blob: a3294ca1c87edd37dd1aa1a51ee3c1e08c169661 [file] [log] [blame]
csharptest35b68522011-05-20 12:22:21 -05001// Generated by ProtoGen, Version=2.3.0.277, Culture=neutral, PublicKeyToken=17b3b1f090c3ea48. DO NOT EDIT!
Jon Skeet82bb0f12011-04-03 20:17:12 +01002
3using pb = global::Google.ProtocolBuffers;
4using pbc = global::Google.ProtocolBuffers.Collections;
5using pbd = global::Google.ProtocolBuffers.Descriptors;
6using scg = global::System.Collections.Generic;
7namespace Google.ProtocolBuffers.TestProtos {
8
csharptest445bdce2011-05-20 15:50:54 -05009 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
10 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
11 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010012 public static partial class UnitTestProtoFile {
13
14 #region Extension registration
15 public static void RegisterAllExtensions(pb::ExtensionRegistry registry) {
16 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalInt32Extension);
17 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalInt64Extension);
18 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalUint32Extension);
19 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalUint64Extension);
20 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSint32Extension);
21 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSint64Extension);
22 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFixed32Extension);
23 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFixed64Extension);
24 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSfixed32Extension);
25 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSfixed64Extension);
26 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFloatExtension);
27 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalDoubleExtension);
28 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalBoolExtension);
29 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalStringExtension);
30 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalBytesExtension);
31 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalGroupExtension);
32 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalNestedMessageExtension);
33 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalForeignMessageExtension);
34 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalImportMessageExtension);
35 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalNestedEnumExtension);
36 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalForeignEnumExtension);
37 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalImportEnumExtension);
38 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalStringPieceExtension);
39 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalCordExtension);
40 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedInt32Extension);
41 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedInt64Extension);
42 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedUint32Extension);
43 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedUint64Extension);
44 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSint32Extension);
45 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSint64Extension);
46 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFixed32Extension);
47 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFixed64Extension);
48 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSfixed32Extension);
49 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSfixed64Extension);
50 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFloatExtension);
51 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedDoubleExtension);
52 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedBoolExtension);
53 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedStringExtension);
54 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedBytesExtension);
55 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedGroupExtension);
56 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedNestedMessageExtension);
57 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedForeignMessageExtension);
58 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedImportMessageExtension);
59 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedNestedEnumExtension);
60 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedForeignEnumExtension);
61 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedImportEnumExtension);
62 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedStringPieceExtension);
63 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedCordExtension);
64 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultInt32Extension);
65 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultInt64Extension);
66 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultUint32Extension);
67 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultUint64Extension);
68 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSint32Extension);
69 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSint64Extension);
70 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFixed32Extension);
71 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFixed64Extension);
72 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSfixed32Extension);
73 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSfixed64Extension);
74 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFloatExtension);
75 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultDoubleExtension);
76 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultBoolExtension);
77 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultStringExtension);
78 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultBytesExtension);
79 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultNestedEnumExtension);
80 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultForeignEnumExtension);
81 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultImportEnumExtension);
82 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultStringPieceExtension);
83 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultCordExtension);
84 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.MyExtensionString);
85 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.MyExtensionInt);
86 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedInt32Extension);
87 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedInt64Extension);
88 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedUint32Extension);
89 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedUint64Extension);
90 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSint32Extension);
91 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSint64Extension);
92 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFixed32Extension);
93 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFixed64Extension);
94 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSfixed32Extension);
95 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSfixed64Extension);
96 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFloatExtension);
97 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedDoubleExtension);
98 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedBoolExtension);
99 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedEnumExtension);
csharptest6da31702011-06-04 12:52:57 -0500100 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedInt32Extension);
101 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedInt64Extension);
102 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedUint32Extension);
103 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedUint64Extension);
104 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedSint32Extension);
105 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedSint64Extension);
106 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedFixed32Extension);
107 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedFixed64Extension);
108 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedSfixed32Extension);
109 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedSfixed64Extension);
110 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedFloatExtension);
111 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedDoubleExtension);
112 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedBoolExtension);
113 registry.Add(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedEnumExtension);
Jon Skeet82bb0f12011-04-03 20:17:12 +0100114 registry.Add(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Test);
115 registry.Add(global::Google.ProtocolBuffers.TestProtos.TestRequired.Single);
116 registry.Add(global::Google.ProtocolBuffers.TestProtos.TestRequired.Multi);
117 }
118 #endregion
119 #region Extensions
120 public const int OptionalInt32ExtensionFieldNumber = 1;
121 public static pb::GeneratedExtensionBase<int> OptionalInt32Extension;
122 public const int OptionalInt64ExtensionFieldNumber = 2;
123 public static pb::GeneratedExtensionBase<long> OptionalInt64Extension;
124 public const int OptionalUint32ExtensionFieldNumber = 3;
125 [global::System.CLSCompliant(false)]
126 public static pb::GeneratedExtensionBase<uint> OptionalUint32Extension;
127 public const int OptionalUint64ExtensionFieldNumber = 4;
128 [global::System.CLSCompliant(false)]
129 public static pb::GeneratedExtensionBase<ulong> OptionalUint64Extension;
130 public const int OptionalSint32ExtensionFieldNumber = 5;
131 public static pb::GeneratedExtensionBase<int> OptionalSint32Extension;
132 public const int OptionalSint64ExtensionFieldNumber = 6;
133 public static pb::GeneratedExtensionBase<long> OptionalSint64Extension;
134 public const int OptionalFixed32ExtensionFieldNumber = 7;
135 [global::System.CLSCompliant(false)]
136 public static pb::GeneratedExtensionBase<uint> OptionalFixed32Extension;
137 public const int OptionalFixed64ExtensionFieldNumber = 8;
138 [global::System.CLSCompliant(false)]
139 public static pb::GeneratedExtensionBase<ulong> OptionalFixed64Extension;
140 public const int OptionalSfixed32ExtensionFieldNumber = 9;
141 public static pb::GeneratedExtensionBase<int> OptionalSfixed32Extension;
142 public const int OptionalSfixed64ExtensionFieldNumber = 10;
143 public static pb::GeneratedExtensionBase<long> OptionalSfixed64Extension;
144 public const int OptionalFloatExtensionFieldNumber = 11;
145 public static pb::GeneratedExtensionBase<float> OptionalFloatExtension;
146 public const int OptionalDoubleExtensionFieldNumber = 12;
147 public static pb::GeneratedExtensionBase<double> OptionalDoubleExtension;
148 public const int OptionalBoolExtensionFieldNumber = 13;
149 public static pb::GeneratedExtensionBase<bool> OptionalBoolExtension;
150 public const int OptionalStringExtensionFieldNumber = 14;
151 public static pb::GeneratedExtensionBase<string> OptionalStringExtension;
152 public const int OptionalBytesExtensionFieldNumber = 15;
153 public static pb::GeneratedExtensionBase<pb::ByteString> OptionalBytesExtension;
154 public const int OptionalGroupExtensionFieldNumber = 16;
155 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension> OptionalGroupExtension;
156 public const int OptionalNestedMessageExtensionFieldNumber = 18;
157 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage> OptionalNestedMessageExtension;
158 public const int OptionalForeignMessageExtensionFieldNumber = 19;
159 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> OptionalForeignMessageExtension;
160 public const int OptionalImportMessageExtensionFieldNumber = 20;
161 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.ImportMessage> OptionalImportMessageExtension;
162 public const int OptionalNestedEnumExtensionFieldNumber = 21;
163 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum> OptionalNestedEnumExtension;
164 public const int OptionalForeignEnumExtensionFieldNumber = 22;
165 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> OptionalForeignEnumExtension;
166 public const int OptionalImportEnumExtensionFieldNumber = 23;
167 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.ImportEnum> OptionalImportEnumExtension;
168 public const int OptionalStringPieceExtensionFieldNumber = 24;
169 public static pb::GeneratedExtensionBase<string> OptionalStringPieceExtension;
170 public const int OptionalCordExtensionFieldNumber = 25;
171 public static pb::GeneratedExtensionBase<string> OptionalCordExtension;
172 public const int RepeatedInt32ExtensionFieldNumber = 31;
173 public static pb::GeneratedExtensionBase<scg::IList<int>> RepeatedInt32Extension;
174 public const int RepeatedInt64ExtensionFieldNumber = 32;
175 public static pb::GeneratedExtensionBase<scg::IList<long>> RepeatedInt64Extension;
176 public const int RepeatedUint32ExtensionFieldNumber = 33;
177 [global::System.CLSCompliant(false)]
178 public static pb::GeneratedExtensionBase<scg::IList<uint>> RepeatedUint32Extension;
179 public const int RepeatedUint64ExtensionFieldNumber = 34;
180 [global::System.CLSCompliant(false)]
181 public static pb::GeneratedExtensionBase<scg::IList<ulong>> RepeatedUint64Extension;
182 public const int RepeatedSint32ExtensionFieldNumber = 35;
183 public static pb::GeneratedExtensionBase<scg::IList<int>> RepeatedSint32Extension;
184 public const int RepeatedSint64ExtensionFieldNumber = 36;
185 public static pb::GeneratedExtensionBase<scg::IList<long>> RepeatedSint64Extension;
186 public const int RepeatedFixed32ExtensionFieldNumber = 37;
187 [global::System.CLSCompliant(false)]
188 public static pb::GeneratedExtensionBase<scg::IList<uint>> RepeatedFixed32Extension;
189 public const int RepeatedFixed64ExtensionFieldNumber = 38;
190 [global::System.CLSCompliant(false)]
191 public static pb::GeneratedExtensionBase<scg::IList<ulong>> RepeatedFixed64Extension;
192 public const int RepeatedSfixed32ExtensionFieldNumber = 39;
193 public static pb::GeneratedExtensionBase<scg::IList<int>> RepeatedSfixed32Extension;
194 public const int RepeatedSfixed64ExtensionFieldNumber = 40;
195 public static pb::GeneratedExtensionBase<scg::IList<long>> RepeatedSfixed64Extension;
196 public const int RepeatedFloatExtensionFieldNumber = 41;
197 public static pb::GeneratedExtensionBase<scg::IList<float>> RepeatedFloatExtension;
198 public const int RepeatedDoubleExtensionFieldNumber = 42;
199 public static pb::GeneratedExtensionBase<scg::IList<double>> RepeatedDoubleExtension;
200 public const int RepeatedBoolExtensionFieldNumber = 43;
201 public static pb::GeneratedExtensionBase<scg::IList<bool>> RepeatedBoolExtension;
202 public const int RepeatedStringExtensionFieldNumber = 44;
203 public static pb::GeneratedExtensionBase<scg::IList<string>> RepeatedStringExtension;
204 public const int RepeatedBytesExtensionFieldNumber = 45;
205 public static pb::GeneratedExtensionBase<scg::IList<pb::ByteString>> RepeatedBytesExtension;
206 public const int RepeatedGroupExtensionFieldNumber = 46;
207 public static pb::GeneratedExtensionBase<scg::IList<global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension>> RepeatedGroupExtension;
208 public const int RepeatedNestedMessageExtensionFieldNumber = 48;
209 public static pb::GeneratedExtensionBase<scg::IList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage>> RepeatedNestedMessageExtension;
210 public const int RepeatedForeignMessageExtensionFieldNumber = 49;
211 public static pb::GeneratedExtensionBase<scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage>> RepeatedForeignMessageExtension;
212 public const int RepeatedImportMessageExtensionFieldNumber = 50;
213 public static pb::GeneratedExtensionBase<scg::IList<global::Google.ProtocolBuffers.TestProtos.ImportMessage>> RepeatedImportMessageExtension;
214 public const int RepeatedNestedEnumExtensionFieldNumber = 51;
215 public static pb::GeneratedExtensionBase<scg::IList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum>> RepeatedNestedEnumExtension;
216 public const int RepeatedForeignEnumExtensionFieldNumber = 52;
217 public static pb::GeneratedExtensionBase<scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>> RepeatedForeignEnumExtension;
218 public const int RepeatedImportEnumExtensionFieldNumber = 53;
219 public static pb::GeneratedExtensionBase<scg::IList<global::Google.ProtocolBuffers.TestProtos.ImportEnum>> RepeatedImportEnumExtension;
220 public const int RepeatedStringPieceExtensionFieldNumber = 54;
221 public static pb::GeneratedExtensionBase<scg::IList<string>> RepeatedStringPieceExtension;
222 public const int RepeatedCordExtensionFieldNumber = 55;
223 public static pb::GeneratedExtensionBase<scg::IList<string>> RepeatedCordExtension;
224 public const int DefaultInt32ExtensionFieldNumber = 61;
225 public static pb::GeneratedExtensionBase<int> DefaultInt32Extension;
226 public const int DefaultInt64ExtensionFieldNumber = 62;
227 public static pb::GeneratedExtensionBase<long> DefaultInt64Extension;
228 public const int DefaultUint32ExtensionFieldNumber = 63;
229 [global::System.CLSCompliant(false)]
230 public static pb::GeneratedExtensionBase<uint> DefaultUint32Extension;
231 public const int DefaultUint64ExtensionFieldNumber = 64;
232 [global::System.CLSCompliant(false)]
233 public static pb::GeneratedExtensionBase<ulong> DefaultUint64Extension;
234 public const int DefaultSint32ExtensionFieldNumber = 65;
235 public static pb::GeneratedExtensionBase<int> DefaultSint32Extension;
236 public const int DefaultSint64ExtensionFieldNumber = 66;
237 public static pb::GeneratedExtensionBase<long> DefaultSint64Extension;
238 public const int DefaultFixed32ExtensionFieldNumber = 67;
239 [global::System.CLSCompliant(false)]
240 public static pb::GeneratedExtensionBase<uint> DefaultFixed32Extension;
241 public const int DefaultFixed64ExtensionFieldNumber = 68;
242 [global::System.CLSCompliant(false)]
243 public static pb::GeneratedExtensionBase<ulong> DefaultFixed64Extension;
244 public const int DefaultSfixed32ExtensionFieldNumber = 69;
245 public static pb::GeneratedExtensionBase<int> DefaultSfixed32Extension;
246 public const int DefaultSfixed64ExtensionFieldNumber = 70;
247 public static pb::GeneratedExtensionBase<long> DefaultSfixed64Extension;
248 public const int DefaultFloatExtensionFieldNumber = 71;
249 public static pb::GeneratedExtensionBase<float> DefaultFloatExtension;
250 public const int DefaultDoubleExtensionFieldNumber = 72;
251 public static pb::GeneratedExtensionBase<double> DefaultDoubleExtension;
252 public const int DefaultBoolExtensionFieldNumber = 73;
253 public static pb::GeneratedExtensionBase<bool> DefaultBoolExtension;
254 public const int DefaultStringExtensionFieldNumber = 74;
255 public static pb::GeneratedExtensionBase<string> DefaultStringExtension;
256 public const int DefaultBytesExtensionFieldNumber = 75;
257 public static pb::GeneratedExtensionBase<pb::ByteString> DefaultBytesExtension;
258 public const int DefaultNestedEnumExtensionFieldNumber = 81;
259 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum> DefaultNestedEnumExtension;
260 public const int DefaultForeignEnumExtensionFieldNumber = 82;
261 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> DefaultForeignEnumExtension;
262 public const int DefaultImportEnumExtensionFieldNumber = 83;
263 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.ImportEnum> DefaultImportEnumExtension;
264 public const int DefaultStringPieceExtensionFieldNumber = 84;
265 public static pb::GeneratedExtensionBase<string> DefaultStringPieceExtension;
266 public const int DefaultCordExtensionFieldNumber = 85;
267 public static pb::GeneratedExtensionBase<string> DefaultCordExtension;
268 public const int MyExtensionStringFieldNumber = 50;
269 public static pb::GeneratedExtensionBase<string> MyExtensionString;
270 public const int MyExtensionIntFieldNumber = 5;
271 public static pb::GeneratedExtensionBase<int> MyExtensionInt;
272 public const int PackedInt32ExtensionFieldNumber = 90;
273 public static pb::GeneratedExtensionBase<scg::IList<int>> PackedInt32Extension;
274 public const int PackedInt64ExtensionFieldNumber = 91;
275 public static pb::GeneratedExtensionBase<scg::IList<long>> PackedInt64Extension;
276 public const int PackedUint32ExtensionFieldNumber = 92;
277 [global::System.CLSCompliant(false)]
278 public static pb::GeneratedExtensionBase<scg::IList<uint>> PackedUint32Extension;
279 public const int PackedUint64ExtensionFieldNumber = 93;
280 [global::System.CLSCompliant(false)]
281 public static pb::GeneratedExtensionBase<scg::IList<ulong>> PackedUint64Extension;
282 public const int PackedSint32ExtensionFieldNumber = 94;
283 public static pb::GeneratedExtensionBase<scg::IList<int>> PackedSint32Extension;
284 public const int PackedSint64ExtensionFieldNumber = 95;
285 public static pb::GeneratedExtensionBase<scg::IList<long>> PackedSint64Extension;
286 public const int PackedFixed32ExtensionFieldNumber = 96;
287 [global::System.CLSCompliant(false)]
288 public static pb::GeneratedExtensionBase<scg::IList<uint>> PackedFixed32Extension;
289 public const int PackedFixed64ExtensionFieldNumber = 97;
290 [global::System.CLSCompliant(false)]
291 public static pb::GeneratedExtensionBase<scg::IList<ulong>> PackedFixed64Extension;
292 public const int PackedSfixed32ExtensionFieldNumber = 98;
293 public static pb::GeneratedExtensionBase<scg::IList<int>> PackedSfixed32Extension;
294 public const int PackedSfixed64ExtensionFieldNumber = 99;
295 public static pb::GeneratedExtensionBase<scg::IList<long>> PackedSfixed64Extension;
296 public const int PackedFloatExtensionFieldNumber = 100;
297 public static pb::GeneratedExtensionBase<scg::IList<float>> PackedFloatExtension;
298 public const int PackedDoubleExtensionFieldNumber = 101;
299 public static pb::GeneratedExtensionBase<scg::IList<double>> PackedDoubleExtension;
300 public const int PackedBoolExtensionFieldNumber = 102;
301 public static pb::GeneratedExtensionBase<scg::IList<bool>> PackedBoolExtension;
302 public const int PackedEnumExtensionFieldNumber = 103;
303 public static pb::GeneratedExtensionBase<scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>> PackedEnumExtension;
csharptest6da31702011-06-04 12:52:57 -0500304 public const int UnpackedInt32ExtensionFieldNumber = 90;
305 public static pb::GeneratedExtensionBase<scg::IList<int>> UnpackedInt32Extension;
306 public const int UnpackedInt64ExtensionFieldNumber = 91;
307 public static pb::GeneratedExtensionBase<scg::IList<long>> UnpackedInt64Extension;
308 public const int UnpackedUint32ExtensionFieldNumber = 92;
309 [global::System.CLSCompliant(false)]
310 public static pb::GeneratedExtensionBase<scg::IList<uint>> UnpackedUint32Extension;
311 public const int UnpackedUint64ExtensionFieldNumber = 93;
312 [global::System.CLSCompliant(false)]
313 public static pb::GeneratedExtensionBase<scg::IList<ulong>> UnpackedUint64Extension;
314 public const int UnpackedSint32ExtensionFieldNumber = 94;
315 public static pb::GeneratedExtensionBase<scg::IList<int>> UnpackedSint32Extension;
316 public const int UnpackedSint64ExtensionFieldNumber = 95;
317 public static pb::GeneratedExtensionBase<scg::IList<long>> UnpackedSint64Extension;
318 public const int UnpackedFixed32ExtensionFieldNumber = 96;
319 [global::System.CLSCompliant(false)]
320 public static pb::GeneratedExtensionBase<scg::IList<uint>> UnpackedFixed32Extension;
321 public const int UnpackedFixed64ExtensionFieldNumber = 97;
322 [global::System.CLSCompliant(false)]
323 public static pb::GeneratedExtensionBase<scg::IList<ulong>> UnpackedFixed64Extension;
324 public const int UnpackedSfixed32ExtensionFieldNumber = 98;
325 public static pb::GeneratedExtensionBase<scg::IList<int>> UnpackedSfixed32Extension;
326 public const int UnpackedSfixed64ExtensionFieldNumber = 99;
327 public static pb::GeneratedExtensionBase<scg::IList<long>> UnpackedSfixed64Extension;
328 public const int UnpackedFloatExtensionFieldNumber = 100;
329 public static pb::GeneratedExtensionBase<scg::IList<float>> UnpackedFloatExtension;
330 public const int UnpackedDoubleExtensionFieldNumber = 101;
331 public static pb::GeneratedExtensionBase<scg::IList<double>> UnpackedDoubleExtension;
332 public const int UnpackedBoolExtensionFieldNumber = 102;
333 public static pb::GeneratedExtensionBase<scg::IList<bool>> UnpackedBoolExtension;
334 public const int UnpackedEnumExtensionFieldNumber = 103;
335 public static pb::GeneratedExtensionBase<scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>> UnpackedEnumExtension;
Jon Skeet82bb0f12011-04-03 20:17:12 +0100336 #endregion
337
338 #region Static variables
339 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes__Descriptor;
340 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder> internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable;
341 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor;
342 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder> internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable;
343 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor;
344 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder> internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable;
345 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor;
346 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder> internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable;
347 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor;
348 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields, global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.Builder> internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable;
349 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_ForeignMessage__Descriptor;
350 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.ForeignMessage, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder> internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable;
351 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestAllExtensions__Descriptor;
352 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestAllExtensions, global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.Builder> internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable;
353 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor;
354 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension, global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.Builder> internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable;
355 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor;
356 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension, global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.Builder> internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable;
357 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedExtension__Descriptor;
358 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestNestedExtension, global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Builder> internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable;
359 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequired__Descriptor;
360 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestRequired, global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder> internal__static_protobuf_unittest_TestRequired__FieldAccessorTable;
361 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRequiredForeign__Descriptor;
362 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign, global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.Builder> internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable;
363 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestForeignNested__Descriptor;
364 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestForeignNested, global::Google.ProtocolBuffers.TestProtos.TestForeignNested.Builder> internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable;
365 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEmptyMessage__Descriptor;
366 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage, global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.Builder> internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable;
367 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor;
368 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions, global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.Builder> internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable;
369 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor;
370 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges, global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.Builder> internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable;
371 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor;
372 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber, global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.Builder> internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable;
373 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor;
374 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage, global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder> internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable;
375 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor;
376 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA, global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder> internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable;
377 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor;
378 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB, global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder> internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable;
379 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor;
380 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber, global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Builder> internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable;
381 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor;
382 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo, global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder> internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable;
383 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor;
384 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar, global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder> internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable;
385 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor;
386 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits, global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Builder> internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable;
387 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor;
388 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage, global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder> internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable;
389 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor;
390 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames, global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.Builder> internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable;
391 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestFieldOrderings__Descriptor;
392 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings, global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Builder> internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable;
393 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor;
394 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues, global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Builder> internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable;
395 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OneString__Descriptor;
396 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.OneString, global::Google.ProtocolBuffers.TestProtos.OneString.Builder> internal__static_protobuf_unittest_OneString__FieldAccessorTable;
397 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_OneBytes__Descriptor;
398 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.OneBytes, global::Google.ProtocolBuffers.TestProtos.OneBytes.Builder> internal__static_protobuf_unittest_OneBytes__FieldAccessorTable;
399 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestPackedTypes__Descriptor;
400 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestPackedTypes, global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.Builder> internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable;
401 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor;
402 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes, global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.Builder> internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable;
403 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestPackedExtensions__Descriptor;
404 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions, global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.Builder> internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable;
csharptest6da31702011-06-04 12:52:57 -0500405 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor;
406 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions, global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.Builder> internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable;
Jon Skeet82bb0f12011-04-03 20:17:12 +0100407 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor;
408 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions, global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Builder> internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable;
409 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor;
410 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType, global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder> internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable;
411 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor;
412 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes, global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.Builder> internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable;
413 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooRequest__Descriptor;
414 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.FooRequest, global::Google.ProtocolBuffers.TestProtos.FooRequest.Builder> internal__static_protobuf_unittest_FooRequest__FieldAccessorTable;
415 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_FooResponse__Descriptor;
416 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.FooResponse, global::Google.ProtocolBuffers.TestProtos.FooResponse.Builder> internal__static_protobuf_unittest_FooResponse__FieldAccessorTable;
417 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BarRequest__Descriptor;
418 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.BarRequest, global::Google.ProtocolBuffers.TestProtos.BarRequest.Builder> internal__static_protobuf_unittest_BarRequest__FieldAccessorTable;
419 internal static pbd::MessageDescriptor internal__static_protobuf_unittest_BarResponse__Descriptor;
420 internal static pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.BarResponse, global::Google.ProtocolBuffers.TestProtos.BarResponse.Builder> internal__static_protobuf_unittest_BarResponse__FieldAccessorTable;
421 #endregion
422 #region Descriptor
423 public static pbd::FileDescriptor Descriptor {
424 get { return descriptor; }
425 }
426 private static pbd::FileDescriptor descriptor;
427
428 static UnitTestProtoFile() {
429 byte[] descriptorData = global::System.Convert.FromBase64String(
430 "Ch5nb29nbGUvcHJvdG9idWYvdW5pdHRlc3QucHJvdG8SEXByb3RvYnVmX3Vu" +
431 "aXR0ZXN0GiRnb29nbGUvcHJvdG9idWYvY3NoYXJwX29wdGlvbnMucHJvdG8a" +
432 "JWdvb2dsZS9wcm90b2J1Zi91bml0dGVzdF9pbXBvcnQucHJvdG8iuxUKDFRl" +
433 "c3RBbGxUeXBlcxIWCg5vcHRpb25hbF9pbnQzMhgBIAEoBRIWCg5vcHRpb25h" +
434 "bF9pbnQ2NBgCIAEoAxIXCg9vcHRpb25hbF91aW50MzIYAyABKA0SFwoPb3B0" +
435 "aW9uYWxfdWludDY0GAQgASgEEhcKD29wdGlvbmFsX3NpbnQzMhgFIAEoERIX" +
436 "Cg9vcHRpb25hbF9zaW50NjQYBiABKBISGAoQb3B0aW9uYWxfZml4ZWQzMhgH" +
437 "IAEoBxIYChBvcHRpb25hbF9maXhlZDY0GAggASgGEhkKEW9wdGlvbmFsX3Nm" +
438 "aXhlZDMyGAkgASgPEhkKEW9wdGlvbmFsX3NmaXhlZDY0GAogASgQEhYKDm9w" +
439 "dGlvbmFsX2Zsb2F0GAsgASgCEhcKD29wdGlvbmFsX2RvdWJsZRgMIAEoARIV" +
440 "Cg1vcHRpb25hbF9ib29sGA0gASgIEhcKD29wdGlvbmFsX3N0cmluZxgOIAEo" +
441 "CRIWCg5vcHRpb25hbF9ieXRlcxgPIAEoDBJECg1vcHRpb25hbGdyb3VwGBAg" +
442 "ASgKMi0ucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzLk9wdGlvbmFs" +
443 "R3JvdXASTgoXb3B0aW9uYWxfbmVzdGVkX21lc3NhZ2UYEiABKAsyLS5wcm90" +
444 "b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkTWVzc2FnZRJDChhv" +
445 "cHRpb25hbF9mb3JlaWduX21lc3NhZ2UYEyABKAsyIS5wcm90b2J1Zl91bml0" +
446 "dGVzdC5Gb3JlaWduTWVzc2FnZRJIChdvcHRpb25hbF9pbXBvcnRfbWVzc2Fn" +
447 "ZRgUIAEoCzInLnByb3RvYnVmX3VuaXR0ZXN0X2ltcG9ydC5JbXBvcnRNZXNz" +
448 "YWdlEkgKFG9wdGlvbmFsX25lc3RlZF9lbnVtGBUgASgOMioucHJvdG9idWZf" +
449 "dW5pdHRlc3QuVGVzdEFsbFR5cGVzLk5lc3RlZEVudW0SPQoVb3B0aW9uYWxf" +
450 "Zm9yZWlnbl9lbnVtGBYgASgOMh4ucHJvdG9idWZfdW5pdHRlc3QuRm9yZWln" +
451 "bkVudW0SQgoUb3B0aW9uYWxfaW1wb3J0X2VudW0YFyABKA4yJC5wcm90b2J1" +
452 "Zl91bml0dGVzdF9pbXBvcnQuSW1wb3J0RW51bRIhChVvcHRpb25hbF9zdHJp" +
453 "bmdfcGllY2UYGCABKAlCAggCEhkKDW9wdGlvbmFsX2NvcmQYGSABKAlCAggB" +
454 "EhYKDnJlcGVhdGVkX2ludDMyGB8gAygFEhYKDnJlcGVhdGVkX2ludDY0GCAg" +
455 "AygDEhcKD3JlcGVhdGVkX3VpbnQzMhghIAMoDRIXCg9yZXBlYXRlZF91aW50" +
456 "NjQYIiADKAQSFwoPcmVwZWF0ZWRfc2ludDMyGCMgAygREhcKD3JlcGVhdGVk" +
457 "X3NpbnQ2NBgkIAMoEhIYChByZXBlYXRlZF9maXhlZDMyGCUgAygHEhgKEHJl" +
458 "cGVhdGVkX2ZpeGVkNjQYJiADKAYSGQoRcmVwZWF0ZWRfc2ZpeGVkMzIYJyAD" +
459 "KA8SGQoRcmVwZWF0ZWRfc2ZpeGVkNjQYKCADKBASFgoOcmVwZWF0ZWRfZmxv" +
460 "YXQYKSADKAISFwoPcmVwZWF0ZWRfZG91YmxlGCogAygBEhUKDXJlcGVhdGVk" +
461 "X2Jvb2wYKyADKAgSFwoPcmVwZWF0ZWRfc3RyaW5nGCwgAygJEhYKDnJlcGVh" +
462 "dGVkX2J5dGVzGC0gAygMEkQKDXJlcGVhdGVkZ3JvdXAYLiADKAoyLS5wcm90" +
463 "b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlwZXMuUmVwZWF0ZWRHcm91cBJOChdy" +
464 "ZXBlYXRlZF9uZXN0ZWRfbWVzc2FnZRgwIAMoCzItLnByb3RvYnVmX3VuaXR0" +
465 "ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdlEkMKGHJlcGVhdGVkX2Zv" +
466 "cmVpZ25fbWVzc2FnZRgxIAMoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVp" +
467 "Z25NZXNzYWdlEkgKF3JlcGVhdGVkX2ltcG9ydF9tZXNzYWdlGDIgAygLMicu" +
468 "cHJvdG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydE1lc3NhZ2USSAoUcmVw" +
469 "ZWF0ZWRfbmVzdGVkX2VudW0YMyADKA4yKi5wcm90b2J1Zl91bml0dGVzdC5U" +
470 "ZXN0QWxsVHlwZXMuTmVzdGVkRW51bRI9ChVyZXBlYXRlZF9mb3JlaWduX2Vu" +
471 "dW0YNCADKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bRJCChRy" +
472 "ZXBlYXRlZF9pbXBvcnRfZW51bRg1IAMoDjIkLnByb3RvYnVmX3VuaXR0ZXN0" +
473 "X2ltcG9ydC5JbXBvcnRFbnVtEiEKFXJlcGVhdGVkX3N0cmluZ19waWVjZRg2" +
474 "IAMoCUICCAISGQoNcmVwZWF0ZWRfY29yZBg3IAMoCUICCAESGQoNZGVmYXVs" +
475 "dF9pbnQzMhg9IAEoBToCNDESGQoNZGVmYXVsdF9pbnQ2NBg+IAEoAzoCNDIS" +
476 "GgoOZGVmYXVsdF91aW50MzIYPyABKA06AjQzEhoKDmRlZmF1bHRfdWludDY0" +
477 "GEAgASgEOgI0NBIbCg5kZWZhdWx0X3NpbnQzMhhBIAEoEToDLTQ1EhoKDmRl" +
478 "ZmF1bHRfc2ludDY0GEIgASgSOgI0NhIbCg9kZWZhdWx0X2ZpeGVkMzIYQyAB" +
479 "KAc6AjQ3EhsKD2RlZmF1bHRfZml4ZWQ2NBhEIAEoBjoCNDgSHAoQZGVmYXVs" +
480 "dF9zZml4ZWQzMhhFIAEoDzoCNDkSHQoQZGVmYXVsdF9zZml4ZWQ2NBhGIAEo" +
481 "EDoDLTUwEhsKDWRlZmF1bHRfZmxvYXQYRyABKAI6BDUxLjUSHQoOZGVmYXVs" +
482 "dF9kb3VibGUYSCABKAE6BTUyMDAwEhoKDGRlZmF1bHRfYm9vbBhJIAEoCDoE" +
483 "dHJ1ZRIdCg5kZWZhdWx0X3N0cmluZxhKIAEoCToFaGVsbG8SHAoNZGVmYXVs" +
484 "dF9ieXRlcxhLIAEoDDoFd29ybGQSTAoTZGVmYXVsdF9uZXN0ZWRfZW51bRhR" +
485 "IAEoDjIqLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRF" +
486 "bnVtOgNCQVISSQoUZGVmYXVsdF9mb3JlaWduX2VudW0YUiABKA4yHi5wcm90" +
487 "b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bToLRk9SRUlHTl9CQVISTQoTZGVm" +
488 "YXVsdF9pbXBvcnRfZW51bRhTIAEoDjIkLnByb3RvYnVmX3VuaXR0ZXN0X2lt" +
489 "cG9ydC5JbXBvcnRFbnVtOgpJTVBPUlRfQkFSEiUKFGRlZmF1bHRfc3RyaW5n" +
490 "X3BpZWNlGFQgASgJOgNhYmNCAggCEh0KDGRlZmF1bHRfY29yZBhVIAEoCToD" +
491 "MTIzQgIIARobCg1OZXN0ZWRNZXNzYWdlEgoKAmJiGAEgASgFGhoKDU9wdGlv" +
492 "bmFsR3JvdXASCQoBYRgRIAEoBRoaCg1SZXBlYXRlZEdyb3VwEgkKAWEYLyAB" +
493 "KAUiJwoKTmVzdGVkRW51bRIHCgNGT08QARIHCgNCQVIQAhIHCgNCQVoQAyI0" +
494 "ChRUZXN0RGVwcmVjYXRlZEZpZWxkcxIcChBkZXByZWNhdGVkX2ludDMyGAEg" +
495 "ASgFQgIYASIbCg5Gb3JlaWduTWVzc2FnZRIJCgFjGAEgASgFIh0KEVRlc3RB" +
496 "bGxFeHRlbnNpb25zKggIARCAgICAAiIkChdPcHRpb25hbEdyb3VwX2V4dGVu" +
497 "c2lvbhIJCgFhGBEgASgFIiQKF1JlcGVhdGVkR3JvdXBfZXh0ZW5zaW9uEgkK" +
498 "AWEYLyABKAUiUAoTVGVzdE5lc3RlZEV4dGVuc2lvbjI5CgR0ZXN0EiQucHJv" +
499 "dG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY6gcgASgJOgR0ZXN0" +
500 "ItUFCgxUZXN0UmVxdWlyZWQSCQoBYRgBIAIoBRIOCgZkdW1teTIYAiABKAUS" +
501 "CQoBYhgDIAIoBRIOCgZkdW1teTQYBCABKAUSDgoGZHVtbXk1GAUgASgFEg4K" +
502 "BmR1bW15NhgGIAEoBRIOCgZkdW1teTcYByABKAUSDgoGZHVtbXk4GAggASgF" +
503 "Eg4KBmR1bW15ORgJIAEoBRIPCgdkdW1teTEwGAogASgFEg8KB2R1bW15MTEY" +
504 "CyABKAUSDwoHZHVtbXkxMhgMIAEoBRIPCgdkdW1teTEzGA0gASgFEg8KB2R1" +
505 "bW15MTQYDiABKAUSDwoHZHVtbXkxNRgPIAEoBRIPCgdkdW1teTE2GBAgASgF" +
506 "Eg8KB2R1bW15MTcYESABKAUSDwoHZHVtbXkxOBgSIAEoBRIPCgdkdW1teTE5" +
507 "GBMgASgFEg8KB2R1bW15MjAYFCABKAUSDwoHZHVtbXkyMRgVIAEoBRIPCgdk" +
508 "dW1teTIyGBYgASgFEg8KB2R1bW15MjMYFyABKAUSDwoHZHVtbXkyNBgYIAEo" +
509 "BRIPCgdkdW1teTI1GBkgASgFEg8KB2R1bW15MjYYGiABKAUSDwoHZHVtbXky" +
510 "NxgbIAEoBRIPCgdkdW1teTI4GBwgASgFEg8KB2R1bW15MjkYHSABKAUSDwoH" +
511 "ZHVtbXkzMBgeIAEoBRIPCgdkdW1teTMxGB8gASgFEg8KB2R1bW15MzIYICAB" +
512 "KAUSCQoBYxghIAIoBTJWCgZzaW5nbGUSJC5wcm90b2J1Zl91bml0dGVzdC5U" +
513 "ZXN0QWxsRXh0ZW5zaW9ucxjoByABKAsyHy5wcm90b2J1Zl91bml0dGVzdC5U" +
514 "ZXN0UmVxdWlyZWQyVQoFbXVsdGkSJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0" +
515 "QWxsRXh0ZW5zaW9ucxjpByADKAsyHy5wcm90b2J1Zl91bml0dGVzdC5UZXN0" +
516 "UmVxdWlyZWQimgEKE1Rlc3RSZXF1aXJlZEZvcmVpZ24SOQoQb3B0aW9uYWxf" +
517 "bWVzc2FnZRgBIAEoCzIfLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RSZXF1aXJl" +
518 "ZBI5ChByZXBlYXRlZF9tZXNzYWdlGAIgAygLMh8ucHJvdG9idWZfdW5pdHRl" +
519 "c3QuVGVzdFJlcXVpcmVkEg0KBWR1bW15GAMgASgFIloKEVRlc3RGb3JlaWdu" +
520 "TmVzdGVkEkUKDmZvcmVpZ25fbmVzdGVkGAEgASgLMi0ucHJvdG9idWZfdW5p" +
521 "dHRlc3QuVGVzdEFsbFR5cGVzLk5lc3RlZE1lc3NhZ2UiEgoQVGVzdEVtcHR5" +
522 "TWVzc2FnZSIqCh5UZXN0RW1wdHlNZXNzYWdlV2l0aEV4dGVuc2lvbnMqCAgB" +
523 "EICAgIACIjcKG1Rlc3RNdWx0aXBsZUV4dGVuc2lvblJhbmdlcyoECCoQKyoG" +
524 "CK8gEJQhKgoIgIAEEICAgIACIjQKGFRlc3RSZWFsbHlMYXJnZVRhZ051bWJl" +
525 "chIJCgFhGAEgASgFEg0KAmJiGP///38gASgFIlUKFFRlc3RSZWN1cnNpdmVN" +
526 "ZXNzYWdlEjIKAWEYASABKAsyJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0UmVj" +
527 "dXJzaXZlTWVzc2FnZRIJCgFpGAIgASgFIksKFFRlc3RNdXR1YWxSZWN1cnNp" +
528 "b25BEjMKAmJiGAEgASgLMicucHJvdG9idWZfdW5pdHRlc3QuVGVzdE11dHVh" +
529 "bFJlY3Vyc2lvbkIiYgoUVGVzdE11dHVhbFJlY3Vyc2lvbkISMgoBYRgBIAEo" +
530 "CzInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RNdXR1YWxSZWN1cnNpb25BEhYK" +
531 "Dm9wdGlvbmFsX2ludDMyGAIgASgFIrMBChJUZXN0RHVwRmllbGROdW1iZXIS" +
532 "CQoBYRgBIAEoBRI2CgNmb28YAiABKAoyKS5wcm90b2J1Zl91bml0dGVzdC5U" +
533 "ZXN0RHVwRmllbGROdW1iZXIuRm9vEjYKA2JhchgDIAEoCjIpLnByb3RvYnVm" +
534 "X3VuaXR0ZXN0LlRlc3REdXBGaWVsZE51bWJlci5CYXIaEAoDRm9vEgkKAWEY" +
535 "ASABKAUaEAoDQmFyEgkKAWEYASABKAUigAIKGFRlc3ROZXN0ZWRNZXNzYWdl" +
536 "SGFzQml0cxJaChdvcHRpb25hbF9uZXN0ZWRfbWVzc2FnZRgBIAEoCzI5LnBy" +
537 "b3RvYnVmX3VuaXR0ZXN0LlRlc3ROZXN0ZWRNZXNzYWdlSGFzQml0cy5OZXN0" +
538 "ZWRNZXNzYWdlGocBCg1OZXN0ZWRNZXNzYWdlEiQKHG5lc3RlZG1lc3NhZ2Vf" +
539 "cmVwZWF0ZWRfaW50MzIYASADKAUSUAolbmVzdGVkbWVzc2FnZV9yZXBlYXRl" +
540 "ZF9mb3JlaWdubWVzc2FnZRgCIAMoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZv" +
541 "cmVpZ25NZXNzYWdlIuUDChdUZXN0Q2FtZWxDYXNlRmllbGROYW1lcxIWCg5Q" +
542 "cmltaXRpdmVGaWVsZBgBIAEoBRITCgtTdHJpbmdGaWVsZBgCIAEoCRIxCglF" +
543 "bnVtRmllbGQYAyABKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51" +
544 "bRI3CgxNZXNzYWdlRmllbGQYBCABKAsyIS5wcm90b2J1Zl91bml0dGVzdC5G" +
545 "b3JlaWduTWVzc2FnZRIcChBTdHJpbmdQaWVjZUZpZWxkGAUgASgJQgIIAhIV" +
546 "CglDb3JkRmllbGQYBiABKAlCAggBEh4KFlJlcGVhdGVkUHJpbWl0aXZlRmll" +
547 "bGQYByADKAUSGwoTUmVwZWF0ZWRTdHJpbmdGaWVsZBgIIAMoCRI5ChFSZXBl" +
548 "YXRlZEVudW1GaWVsZBgJIAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVp" +
549 "Z25FbnVtEj8KFFJlcGVhdGVkTWVzc2FnZUZpZWxkGAogAygLMiEucHJvdG9i" +
550 "dWZfdW5pdHRlc3QuRm9yZWlnbk1lc3NhZ2USJAoYUmVwZWF0ZWRTdHJpbmdQ" +
551 "aWVjZUZpZWxkGAsgAygJQgIIAhIdChFSZXBlYXRlZENvcmRGaWVsZBgMIAMo" +
552 "CUICCAEiVQoSVGVzdEZpZWxkT3JkZXJpbmdzEhEKCW15X3N0cmluZxgLIAEo" +
553 "CRIOCgZteV9pbnQYASABKAMSEAoIbXlfZmxvYXQYZSABKAIqBAgCEAsqBAgM" +
554 "EGUi9gQKGFRlc3RFeHRyZW1lRGVmYXVsdFZhbHVlcxI/Cg1lc2NhcGVkX2J5" +
555 "dGVzGAEgASgMOihcMDAwXDAwMVwwMDdcMDEwXDAxNFxuXHJcdFwwMTNcXFwn" +
556 "XCJcMzc2EiAKDGxhcmdlX3VpbnQzMhgCIAEoDToKNDI5NDk2NzI5NRIqCgxs" +
557 "YXJnZV91aW50NjQYAyABKAQ6FDE4NDQ2NzQ0MDczNzA5NTUxNjE1EiAKC3Nt" +
558 "YWxsX2ludDMyGAQgASgFOgstMjE0NzQ4MzY0NxIpCgtzbWFsbF9pbnQ2NBgF" +
559 "IAEoAzoULTkyMjMzNzIwMzY4NTQ3NzU4MDcSGAoLdXRmOF9zdHJpbmcYBiAB" +
560 "KAk6A+GItBIVCgp6ZXJvX2Zsb2F0GAcgASgCOgEwEhQKCW9uZV9mbG9hdBgI" +
561 "IAEoAjoBMRIYCgtzbWFsbF9mbG9hdBgJIAEoAjoDMS41Eh4KEm5lZ2F0aXZl" +
562 "X29uZV9mbG9hdBgKIAEoAjoCLTESHAoObmVnYXRpdmVfZmxvYXQYCyABKAI6" +
563 "BC0xLjUSGwoLbGFyZ2VfZmxvYXQYDCABKAI6BjJlKzAwOBIlChRzbWFsbF9u" +
564 "ZWdhdGl2ZV9mbG9hdBgNIAEoAjoHLThlLTAyOBIXCgppbmZfZG91YmxlGA4g" +
565 "ASgBOgNpbmYSHAoObmVnX2luZl9kb3VibGUYDyABKAE6BC1pbmYSFwoKbmFu" +
566 "X2RvdWJsZRgQIAEoAToDbmFuEhYKCWluZl9mbG9hdBgRIAEoAjoDaW5mEhsK" +
567 "DW5lZ19pbmZfZmxvYXQYEiABKAI6BC1pbmYSFgoJbmFuX2Zsb2F0GBMgASgC" +
568 "OgNuYW4iGQoJT25lU3RyaW5nEgwKBGRhdGEYASABKAkiGAoIT25lQnl0ZXMS" +
569 "DAoEZGF0YRgBIAEoDCKqAwoPVGVzdFBhY2tlZFR5cGVzEhgKDHBhY2tlZF9p" +
570 "bnQzMhhaIAMoBUICEAESGAoMcGFja2VkX2ludDY0GFsgAygDQgIQARIZCg1w" +
571 "YWNrZWRfdWludDMyGFwgAygNQgIQARIZCg1wYWNrZWRfdWludDY0GF0gAygE" +
572 "QgIQARIZCg1wYWNrZWRfc2ludDMyGF4gAygRQgIQARIZCg1wYWNrZWRfc2lu" +
573 "dDY0GF8gAygSQgIQARIaCg5wYWNrZWRfZml4ZWQzMhhgIAMoB0ICEAESGgoO" +
574 "cGFja2VkX2ZpeGVkNjQYYSADKAZCAhABEhsKD3BhY2tlZF9zZml4ZWQzMhhi" +
575 "IAMoD0ICEAESGwoPcGFja2VkX3NmaXhlZDY0GGMgAygQQgIQARIYCgxwYWNr" +
576 "ZWRfZmxvYXQYZCADKAJCAhABEhkKDXBhY2tlZF9kb3VibGUYZSADKAFCAhAB" +
577 "EhcKC3BhY2tlZF9ib29sGGYgAygIQgIQARI3CgtwYWNrZWRfZW51bRhnIAMo" +
578 "DjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtQgIQASLIAwoRVGVz" +
579 "dFVucGFja2VkVHlwZXMSGgoOdW5wYWNrZWRfaW50MzIYWiADKAVCAhAAEhoK" +
580 "DnVucGFja2VkX2ludDY0GFsgAygDQgIQABIbCg91bnBhY2tlZF91aW50MzIY" +
581 "XCADKA1CAhAAEhsKD3VucGFja2VkX3VpbnQ2NBhdIAMoBEICEAASGwoPdW5w" +
582 "YWNrZWRfc2ludDMyGF4gAygRQgIQABIbCg91bnBhY2tlZF9zaW50NjQYXyAD" +
583 "KBJCAhAAEhwKEHVucGFja2VkX2ZpeGVkMzIYYCADKAdCAhAAEhwKEHVucGFj" +
584 "a2VkX2ZpeGVkNjQYYSADKAZCAhAAEh0KEXVucGFja2VkX3NmaXhlZDMyGGIg" +
585 "AygPQgIQABIdChF1bnBhY2tlZF9zZml4ZWQ2NBhjIAMoEEICEAASGgoOdW5w" +
586 "YWNrZWRfZmxvYXQYZCADKAJCAhAAEhsKD3VucGFja2VkX2RvdWJsZRhlIAMo" +
587 "AUICEAASGQoNdW5wYWNrZWRfYm9vbBhmIAMoCEICEAASOQoNdW5wYWNrZWRf" +
588 "ZW51bRhnIAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25FbnVtQgIQ" +
csharptest6da31702011-06-04 12:52:57 -0500589 "ACIgChRUZXN0UGFja2VkRXh0ZW5zaW9ucyoICAEQgICAgAIiIgoWVGVzdFVu" +
590 "cGFja2VkRXh0ZW5zaW9ucyoICAEQgICAgAIimQQKFVRlc3REeW5hbWljRXh0" +
591 "ZW5zaW9ucxIZChBzY2FsYXJfZXh0ZW5zaW9uGNAPIAEoBxI3Cg5lbnVtX2V4" +
592 "dGVuc2lvbhjRDyABKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51" +
593 "bRJZChZkeW5hbWljX2VudW1fZXh0ZW5zaW9uGNIPIAEoDjI4LnByb3RvYnVm" +
594 "X3VuaXR0ZXN0LlRlc3REeW5hbWljRXh0ZW5zaW9ucy5EeW5hbWljRW51bVR5" +
595 "cGUSPQoRbWVzc2FnZV9leHRlbnNpb24Y0w8gASgLMiEucHJvdG9idWZfdW5p" +
596 "dHRlc3QuRm9yZWlnbk1lc3NhZ2USXwoZZHluYW1pY19tZXNzYWdlX2V4dGVu" +
597 "c2lvbhjUDyABKAsyOy5wcm90b2J1Zl91bml0dGVzdC5UZXN0RHluYW1pY0V4" +
598 "dGVuc2lvbnMuRHluYW1pY01lc3NhZ2VUeXBlEhsKEnJlcGVhdGVkX2V4dGVu" +
599 "c2lvbhjVDyADKAkSHQoQcGFja2VkX2V4dGVuc2lvbhjWDyADKBFCAhABGiwK" +
600 "EkR5bmFtaWNNZXNzYWdlVHlwZRIWCg1keW5hbWljX2ZpZWxkGLQQIAEoBSJH" +
601 "Cg9EeW5hbWljRW51bVR5cGUSEAoLRFlOQU1JQ19GT08QmBESEAoLRFlOQU1J" +
602 "Q19CQVIQmRESEAoLRFlOQU1JQ19CQVoQmhEiwAEKI1Rlc3RSZXBlYXRlZFNj" +
603 "YWxhckRpZmZlcmVudFRhZ1NpemVzEhgKEHJlcGVhdGVkX2ZpeGVkMzIYDCAD" +
604 "KAcSFgoOcmVwZWF0ZWRfaW50MzIYDSADKAUSGQoQcmVwZWF0ZWRfZml4ZWQ2" +
605 "NBj+DyADKAYSFwoOcmVwZWF0ZWRfaW50NjQY/w8gAygDEhgKDnJlcGVhdGVk" +
606 "X2Zsb2F0GP7/DyADKAISGQoPcmVwZWF0ZWRfdWludDY0GP//DyADKAQiDAoK" +
607 "Rm9vUmVxdWVzdCINCgtGb29SZXNwb25zZSIMCgpCYXJSZXF1ZXN0Ig0KC0Jh" +
608 "clJlc3BvbnNlKkAKC0ZvcmVpZ25FbnVtEg8KC0ZPUkVJR05fRk9PEAQSDwoL" +
609 "Rk9SRUlHTl9CQVIQBRIPCgtGT1JFSUdOX0JBWhAGKkcKFFRlc3RFbnVtV2l0" +
610 "aER1cFZhbHVlEggKBEZPTzEQARIICgRCQVIxEAISBwoDQkFaEAMSCAoERk9P" +
611 "MhABEggKBEJBUjIQAiqJAQoOVGVzdFNwYXJzZUVudW0SDAoIU1BBUlNFX0EQ" +
612 "exIOCghTUEFSU0VfQhCm5wMSDwoIU1BBUlNFX0MQsrGABhIVCghTUEFSU0Vf" +
613 "RBDx//////////8BEhUKCFNQQVJTRV9FELTe/P///////wESDAoIU1BBUlNF" +
614 "X0YQABIMCghTUEFSU0VfRxACMpkBCgtUZXN0U2VydmljZRJECgNGb28SHS5w" +
615 "cm90b2J1Zl91bml0dGVzdC5Gb29SZXF1ZXN0Gh4ucHJvdG9idWZfdW5pdHRl" +
616 "c3QuRm9vUmVzcG9uc2USRAoDQmFyEh0ucHJvdG9idWZfdW5pdHRlc3QuQmFy" +
617 "UmVxdWVzdBoeLnByb3RvYnVmX3VuaXR0ZXN0LkJhclJlc3BvbnNlOkYKGG9w" +
618 "dGlvbmFsX2ludDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRl" +
619 "c3RBbGxFeHRlbnNpb25zGAEgASgFOkYKGG9wdGlvbmFsX2ludDY0X2V4dGVu" +
620 "c2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGAIg" +
621 "ASgDOkcKGW9wdGlvbmFsX3VpbnQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91" +
622 "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgDIAEoDTpHChlvcHRpb25hbF91" +
Jon Skeet82bb0f12011-04-03 20:17:12 +0100623 "aW50NjRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4" +
csharptest6da31702011-06-04 12:52:57 -0500624 "dGVuc2lvbnMYBCABKAQ6RwoZb3B0aW9uYWxfc2ludDMyX2V4dGVuc2lvbhIk" +
625 "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGAUgASgROkcK" +
626 "GW9wdGlvbmFsX3NpbnQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz" +
627 "dC5UZXN0QWxsRXh0ZW5zaW9ucxgGIAEoEjpIChpvcHRpb25hbF9maXhlZDMy" +
628 "X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNp" +
629 "b25zGAcgASgHOkgKGm9wdGlvbmFsX2ZpeGVkNjRfZXh0ZW5zaW9uEiQucHJv" +
630 "dG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYCCABKAY6SQobb3B0" +
631 "aW9uYWxfc2ZpeGVkMzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3Qu" +
632 "VGVzdEFsbEV4dGVuc2lvbnMYCSABKA86SQobb3B0aW9uYWxfc2ZpeGVkNjRf" +
633 "ZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lv" +
634 "bnMYCiABKBA6RgoYb3B0aW9uYWxfZmxvYXRfZXh0ZW5zaW9uEiQucHJvdG9i" +
635 "dWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYCyABKAI6RwoZb3B0aW9u" +
636 "YWxfZG91YmxlX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB" +
637 "bGxFeHRlbnNpb25zGAwgASgBOkUKF29wdGlvbmFsX2Jvb2xfZXh0ZW5zaW9u" +
638 "EiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYDSABKAg6" +
639 "RwoZb3B0aW9uYWxfc3RyaW5nX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0" +
640 "ZXN0LlRlc3RBbGxFeHRlbnNpb25zGA4gASgJOkYKGG9wdGlvbmFsX2J5dGVz" +
641 "X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNp" +
642 "b25zGA8gASgMOnEKF29wdGlvbmFsZ3JvdXBfZXh0ZW5zaW9uEiQucHJvdG9i" +
643 "dWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYECABKAoyKi5wcm90b2J1" +
644 "Zl91bml0dGVzdC5PcHRpb25hbEdyb3VwX2V4dGVuc2lvbjp+CiFvcHRpb25h" +
645 "bF9uZXN0ZWRfbWVzc2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVz" +
646 "dC5UZXN0QWxsRXh0ZW5zaW9ucxgSIAEoCzItLnByb3RvYnVmX3VuaXR0ZXN0" +
647 "LlRlc3RBbGxUeXBlcy5OZXN0ZWRNZXNzYWdlOnMKIm9wdGlvbmFsX2ZvcmVp" +
648 "Z25fbWVzc2FnZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0" +
649 "QWxsRXh0ZW5zaW9ucxgTIAEoCzIhLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVp" +
650 "Z25NZXNzYWdlOngKIW9wdGlvbmFsX2ltcG9ydF9tZXNzYWdlX2V4dGVuc2lv" +
651 "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGBQgASgL" +
652 "MicucHJvdG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydE1lc3NhZ2U6eAoe" +
653 "b3B0aW9uYWxfbmVzdGVkX2VudW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5p" +
654 "dHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYFSABKA4yKi5wcm90b2J1Zl91bml0" +
655 "dGVzdC5UZXN0QWxsVHlwZXMuTmVzdGVkRW51bTptCh9vcHRpb25hbF9mb3Jl" +
656 "aWduX2VudW1fZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFs" +
657 "bEV4dGVuc2lvbnMYFiABKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWdu" +
658 "RW51bTpyCh5vcHRpb25hbF9pbXBvcnRfZW51bV9leHRlbnNpb24SJC5wcm90" +
659 "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgXIAEoDjIkLnByb3Rv" +
660 "YnVmX3VuaXR0ZXN0X2ltcG9ydC5JbXBvcnRFbnVtOlEKH29wdGlvbmFsX3N0" +
661 "cmluZ19waWVjZV9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0" +
662 "QWxsRXh0ZW5zaW9ucxgYIAEoCUICCAI6SQoXb3B0aW9uYWxfY29yZF9leHRl" +
663 "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgZ" +
664 "IAEoCUICCAE6RgoYcmVwZWF0ZWRfaW50MzJfZXh0ZW5zaW9uEiQucHJvdG9i" +
665 "dWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYHyADKAU6RgoYcmVwZWF0" +
666 "ZWRfaW50NjRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFs" +
667 "bEV4dGVuc2lvbnMYICADKAM6RwoZcmVwZWF0ZWRfdWludDMyX2V4dGVuc2lv" +
668 "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCEgAygN" +
669 "OkcKGXJlcGVhdGVkX3VpbnQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0" +
670 "dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgiIAMoBDpHChlyZXBlYXRlZF9zaW50" +
671 "MzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVu" +
672 "c2lvbnMYIyADKBE6RwoZcmVwZWF0ZWRfc2ludDY0X2V4dGVuc2lvbhIkLnBy" +
673 "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGCQgAygSOkgKGnJl" +
674 "cGVhdGVkX2ZpeGVkMzJfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3Qu" +
675 "VGVzdEFsbEV4dGVuc2lvbnMYJSADKAc6SAoacmVwZWF0ZWRfZml4ZWQ2NF9l" +
676 "eHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9u" +
677 "cxgmIAMoBjpJChtyZXBlYXRlZF9zZml4ZWQzMl9leHRlbnNpb24SJC5wcm90" +
678 "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgnIAMoDzpJChtyZXBl" +
679 "YXRlZF9zZml4ZWQ2NF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5U" +
680 "ZXN0QWxsRXh0ZW5zaW9ucxgoIAMoEDpGChhyZXBlYXRlZF9mbG9hdF9leHRl" +
681 "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgp" +
682 "IAMoAjpHChlyZXBlYXRlZF9kb3VibGVfZXh0ZW5zaW9uEiQucHJvdG9idWZf" +
683 "dW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYKiADKAE6RQoXcmVwZWF0ZWRf" +
684 "Ym9vbF9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0" +
685 "ZW5zaW9ucxgrIAMoCDpHChlyZXBlYXRlZF9zdHJpbmdfZXh0ZW5zaW9uEiQu" +
686 "cHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMYLCADKAk6RgoY" +
687 "cmVwZWF0ZWRfYnl0ZXNfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3Qu" +
688 "VGVzdEFsbEV4dGVuc2lvbnMYLSADKAw6cQoXcmVwZWF0ZWRncm91cF9leHRl" +
689 "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgu" +
690 "IAMoCjIqLnByb3RvYnVmX3VuaXR0ZXN0LlJlcGVhdGVkR3JvdXBfZXh0ZW5z" +
691 "aW9uOn4KIXJlcGVhdGVkX25lc3RlZF9tZXNzYWdlX2V4dGVuc2lvbhIkLnBy" +
692 "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGDAgAygLMi0ucHJv" +
693 "dG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzLk5lc3RlZE1lc3NhZ2U6cwoi" +
694 "cmVwZWF0ZWRfZm9yZWlnbl9tZXNzYWdlX2V4dGVuc2lvbhIkLnByb3RvYnVm" +
695 "X3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGDEgAygLMiEucHJvdG9idWZf" +
696 "dW5pdHRlc3QuRm9yZWlnbk1lc3NhZ2U6eAohcmVwZWF0ZWRfaW1wb3J0X21l" +
697 "c3NhZ2VfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4" +
698 "dGVuc2lvbnMYMiADKAsyJy5wcm90b2J1Zl91bml0dGVzdF9pbXBvcnQuSW1w" +
699 "b3J0TWVzc2FnZTp4Ch5yZXBlYXRlZF9uZXN0ZWRfZW51bV9leHRlbnNpb24S" +
700 "JC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxgzIAMoDjIq" +
701 "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxUeXBlcy5OZXN0ZWRFbnVtOm0K" +
702 "H3JlcGVhdGVkX2ZvcmVpZ25fZW51bV9leHRlbnNpb24SJC5wcm90b2J1Zl91" +
703 "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxg0IAMoDjIeLnByb3RvYnVmX3Vu" +
704 "aXR0ZXN0LkZvcmVpZ25FbnVtOnIKHnJlcGVhdGVkX2ltcG9ydF9lbnVtX2V4" +
Jon Skeet82bb0f12011-04-03 20:17:12 +0100705 "dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25z" +
csharptest6da31702011-06-04 12:52:57 -0500706 "GDUgAygOMiQucHJvdG9idWZfdW5pdHRlc3RfaW1wb3J0LkltcG9ydEVudW06" +
707 "UQofcmVwZWF0ZWRfc3RyaW5nX3BpZWNlX2V4dGVuc2lvbhIkLnByb3RvYnVm" +
708 "X3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGDYgAygJQgIIAjpJChdyZXBl" +
709 "YXRlZF9jb3JkX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB" +
710 "bGxFeHRlbnNpb25zGDcgAygJQgIIATpJChdkZWZhdWx0X2ludDMyX2V4dGVu" +
711 "c2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGD0g" +
712 "ASgFOgI0MTpJChdkZWZhdWx0X2ludDY0X2V4dGVuc2lvbhIkLnByb3RvYnVm" +
713 "X3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGD4gASgDOgI0MjpKChhkZWZh" +
714 "dWx0X3VpbnQzMl9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0" +
715 "QWxsRXh0ZW5zaW9ucxg/IAEoDToCNDM6SgoYZGVmYXVsdF91aW50NjRfZXh0" +
716 "ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVuc2lvbnMY" +
717 "QCABKAQ6AjQ0OksKGGRlZmF1bHRfc2ludDMyX2V4dGVuc2lvbhIkLnByb3Rv" +
718 "YnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEEgASgROgMtNDU6SgoY" +
719 "ZGVmYXVsdF9zaW50NjRfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3Qu" +
720 "VGVzdEFsbEV4dGVuc2lvbnMYQiABKBI6AjQ2OksKGWRlZmF1bHRfZml4ZWQz" +
721 "Ml9leHRlbnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5z" +
722 "aW9ucxhDIAEoBzoCNDc6SwoZZGVmYXVsdF9maXhlZDY0X2V4dGVuc2lvbhIk" +
723 "LnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEQgASgGOgI0" +
724 "ODpMChpkZWZhdWx0X3NmaXhlZDMyX2V4dGVuc2lvbhIkLnByb3RvYnVmX3Vu" +
725 "aXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEUgASgPOgI0OTpNChpkZWZhdWx0" +
726 "X3NmaXhlZDY0X2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB" +
727 "bGxFeHRlbnNpb25zGEYgASgQOgMtNTA6SwoXZGVmYXVsdF9mbG9hdF9leHRl" +
728 "bnNpb24SJC5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhH" +
729 "IAEoAjoENTEuNTpNChhkZWZhdWx0X2RvdWJsZV9leHRlbnNpb24SJC5wcm90" +
730 "b2J1Zl91bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhIIAEoAToFNTIwMDA6" +
731 "SgoWZGVmYXVsdF9ib29sX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0" +
732 "LlRlc3RBbGxFeHRlbnNpb25zGEkgASgIOgR0cnVlOk0KGGRlZmF1bHRfc3Ry" +
733 "aW5nX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRl" +
734 "bnNpb25zGEogASgJOgVoZWxsbzpMChdkZWZhdWx0X2J5dGVzX2V4dGVuc2lv" +
735 "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGEsgASgM" +
736 "OgV3b3JsZDp8Ch1kZWZhdWx0X25lc3RlZF9lbnVtX2V4dGVuc2lvbhIkLnBy" +
737 "b3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGFEgASgOMioucHJv" +
738 "dG9idWZfdW5pdHRlc3QuVGVzdEFsbFR5cGVzLk5lc3RlZEVudW06A0JBUjp5" +
739 "Ch5kZWZhdWx0X2ZvcmVpZ25fZW51bV9leHRlbnNpb24SJC5wcm90b2J1Zl91" +
740 "bml0dGVzdC5UZXN0QWxsRXh0ZW5zaW9ucxhSIAEoDjIeLnByb3RvYnVmX3Vu" +
741 "aXR0ZXN0LkZvcmVpZ25FbnVtOgtGT1JFSUdOX0JBUjp9Ch1kZWZhdWx0X2lt" +
742 "cG9ydF9lbnVtX2V4dGVuc2lvbhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RB" +
743 "bGxFeHRlbnNpb25zGFMgASgOMiQucHJvdG9idWZfdW5pdHRlc3RfaW1wb3J0" +
744 "LkltcG9ydEVudW06CklNUE9SVF9CQVI6VQoeZGVmYXVsdF9zdHJpbmdfcGll" +
745 "Y2VfZXh0ZW5zaW9uEiQucHJvdG9idWZfdW5pdHRlc3QuVGVzdEFsbEV4dGVu" +
746 "c2lvbnMYVCABKAk6A2FiY0ICCAI6TQoWZGVmYXVsdF9jb3JkX2V4dGVuc2lv" +
747 "bhIkLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RBbGxFeHRlbnNpb25zGFUgASgJ" +
748 "OgMxMjNCAggBOkIKE215X2V4dGVuc2lvbl9zdHJpbmcSJS5wcm90b2J1Zl91" +
749 "bml0dGVzdC5UZXN0RmllbGRPcmRlcmluZ3MYMiABKAk6PwoQbXlfZXh0ZW5z" +
750 "aW9uX2ludBIlLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RGaWVsZE9yZGVyaW5n" +
751 "cxgFIAEoBTpLChZwYWNrZWRfaW50MzJfZXh0ZW5zaW9uEicucHJvdG9idWZf" +
752 "dW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMYWiADKAVCAhABOksKFnBh" +
753 "Y2tlZF9pbnQ2NF9leHRlbnNpb24SJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0" +
754 "UGFja2VkRXh0ZW5zaW9ucxhbIAMoA0ICEAE6TAoXcGFja2VkX3VpbnQzMl9l" +
755 "eHRlbnNpb24SJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5z" +
756 "aW9ucxhcIAMoDUICEAE6TAoXcGFja2VkX3VpbnQ2NF9leHRlbnNpb24SJy5w" +
757 "cm90b2J1Zl91bml0dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhdIAMoBEIC" +
758 "EAE6TAoXcGFja2VkX3NpbnQzMl9leHRlbnNpb24SJy5wcm90b2J1Zl91bml0" +
759 "dGVzdC5UZXN0UGFja2VkRXh0ZW5zaW9ucxheIAMoEUICEAE6TAoXcGFja2Vk" +
760 "X3NpbnQ2NF9leHRlbnNpb24SJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0UGFj" +
761 "a2VkRXh0ZW5zaW9ucxhfIAMoEkICEAE6TQoYcGFja2VkX2ZpeGVkMzJfZXh0" +
762 "ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lv" +
763 "bnMYYCADKAdCAhABOk0KGHBhY2tlZF9maXhlZDY0X2V4dGVuc2lvbhInLnBy" +
764 "b3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNpb25zGGEgAygGQgIQ" +
765 "ATpOChlwYWNrZWRfc2ZpeGVkMzJfZXh0ZW5zaW9uEicucHJvdG9idWZfdW5p" +
766 "dHRlc3QuVGVzdFBhY2tlZEV4dGVuc2lvbnMYYiADKA9CAhABOk4KGXBhY2tl" +
767 "ZF9zZml4ZWQ2NF9leHRlbnNpb24SJy5wcm90b2J1Zl91bml0dGVzdC5UZXN0" +
768 "UGFja2VkRXh0ZW5zaW9ucxhjIAMoEEICEAE6SwoWcGFja2VkX2Zsb2F0X2V4" +
769 "dGVuc2lvbhInLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNp" +
770 "b25zGGQgAygCQgIQATpMChdwYWNrZWRfZG91YmxlX2V4dGVuc2lvbhInLnBy" +
771 "b3RvYnVmX3VuaXR0ZXN0LlRlc3RQYWNrZWRFeHRlbnNpb25zGGUgAygBQgIQ" +
772 "ATpKChVwYWNrZWRfYm9vbF9leHRlbnNpb24SJy5wcm90b2J1Zl91bml0dGVz" +
773 "dC5UZXN0UGFja2VkRXh0ZW5zaW9ucxhmIAMoCEICEAE6agoVcGFja2VkX2Vu" +
774 "dW1fZXh0ZW5zaW9uEicucHJvdG9idWZfdW5pdHRlc3QuVGVzdFBhY2tlZEV4" +
775 "dGVuc2lvbnMYZyADKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51" +
776 "bUICEAE6SwoYdW5wYWNrZWRfaW50MzJfZXh0ZW5zaW9uEikucHJvdG9idWZf" +
777 "dW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5zaW9ucxhaIAMoBTpLChh1bnBh" +
778 "Y2tlZF9pbnQ2NF9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVzdC5UZXN0" +
779 "VW5wYWNrZWRFeHRlbnNpb25zGFsgAygDOkwKGXVucGFja2VkX3VpbnQzMl9l" +
780 "eHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVzdC5UZXN0VW5wYWNrZWRFeHRl" +
781 "bnNpb25zGFwgAygNOkwKGXVucGFja2VkX3VpbnQ2NF9leHRlbnNpb24SKS5w" +
782 "cm90b2J1Zl91bml0dGVzdC5UZXN0VW5wYWNrZWRFeHRlbnNpb25zGF0gAygE" +
783 "OkwKGXVucGFja2VkX3NpbnQzMl9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0" +
784 "dGVzdC5UZXN0VW5wYWNrZWRFeHRlbnNpb25zGF4gAygROkwKGXVucGFja2Vk" +
785 "X3NpbnQ2NF9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVzdC5UZXN0VW5w" +
786 "YWNrZWRFeHRlbnNpb25zGF8gAygSOk0KGnVucGFja2VkX2ZpeGVkMzJfZXh0" +
787 "ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2VkRXh0ZW5z" +
788 "aW9ucxhgIAMoBzpNChp1bnBhY2tlZF9maXhlZDY0X2V4dGVuc2lvbhIpLnBy" +
789 "b3RvYnVmX3VuaXR0ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYYSADKAY6" +
790 "TgobdW5wYWNrZWRfc2ZpeGVkMzJfZXh0ZW5zaW9uEikucHJvdG9idWZfdW5p" +
791 "dHRlc3QuVGVzdFVucGFja2VkRXh0ZW5zaW9ucxhiIAMoDzpOCht1bnBhY2tl" +
792 "ZF9zZml4ZWQ2NF9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVzdC5UZXN0" +
793 "VW5wYWNrZWRFeHRlbnNpb25zGGMgAygQOksKGHVucGFja2VkX2Zsb2F0X2V4" +
794 "dGVuc2lvbhIpLnByb3RvYnVmX3VuaXR0ZXN0LlRlc3RVbnBhY2tlZEV4dGVu" +
795 "c2lvbnMYZCADKAI6TAoZdW5wYWNrZWRfZG91YmxlX2V4dGVuc2lvbhIpLnBy" +
796 "b3RvYnVmX3VuaXR0ZXN0LlRlc3RVbnBhY2tlZEV4dGVuc2lvbnMYZSADKAE6" +
797 "SgoXdW5wYWNrZWRfYm9vbF9leHRlbnNpb24SKS5wcm90b2J1Zl91bml0dGVz" +
798 "dC5UZXN0VW5wYWNrZWRFeHRlbnNpb25zGGYgAygIOmoKF3VucGFja2VkX2Vu" +
799 "dW1fZXh0ZW5zaW9uEikucHJvdG9idWZfdW5pdHRlc3QuVGVzdFVucGFja2Vk" +
800 "RXh0ZW5zaW9ucxhnIAMoDjIeLnByb3RvYnVmX3VuaXR0ZXN0LkZvcmVpZ25F" +
801 "bnVtQkpCDVVuaXR0ZXN0UHJvdG9IAcI+NgohR29vZ2xlLlByb3RvY29sQnVm" +
802 "ZmVycy5UZXN0UHJvdG9zEhFVbml0VGVzdFByb3RvRmlsZQ==");
Jon Skeet82bb0f12011-04-03 20:17:12 +0100803 pbd::FileDescriptor.InternalDescriptorAssigner assigner = delegate(pbd::FileDescriptor root) {
804 descriptor = root;
805 internal__static_protobuf_unittest_TestAllTypes__Descriptor = Descriptor.MessageTypes[0];
806 internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable =
807 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Builder>(internal__static_protobuf_unittest_TestAllTypes__Descriptor,
808 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", });
809 internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[0];
810 internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable =
811 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder>(internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor,
812 new string[] { "Bb", });
813 internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[1];
814 internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable =
815 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder>(internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor,
816 new string[] { "A", });
817 internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor = internal__static_protobuf_unittest_TestAllTypes__Descriptor.NestedTypes[2];
818 internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable =
819 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder>(internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor,
820 new string[] { "A", });
821 internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor = Descriptor.MessageTypes[1];
822 internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable =
823 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields, global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.Builder>(internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor,
824 new string[] { "DeprecatedInt32", });
825 internal__static_protobuf_unittest_ForeignMessage__Descriptor = Descriptor.MessageTypes[2];
826 internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable =
827 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.ForeignMessage, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder>(internal__static_protobuf_unittest_ForeignMessage__Descriptor,
828 new string[] { "C", });
829 internal__static_protobuf_unittest_TestAllExtensions__Descriptor = Descriptor.MessageTypes[3];
830 internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable =
831 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestAllExtensions, global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.Builder>(internal__static_protobuf_unittest_TestAllExtensions__Descriptor,
832 new string[] { });
833 internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor = Descriptor.MessageTypes[4];
834 internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable =
835 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension, global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.Builder>(internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor,
836 new string[] { "A", });
837 internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor = Descriptor.MessageTypes[5];
838 internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable =
839 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension, global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.Builder>(internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor,
840 new string[] { "A", });
841 internal__static_protobuf_unittest_TestNestedExtension__Descriptor = Descriptor.MessageTypes[6];
842 internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable =
843 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestNestedExtension, global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Builder>(internal__static_protobuf_unittest_TestNestedExtension__Descriptor,
844 new string[] { });
845 global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Test = pb::GeneratedSingleExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor.Extensions[0]);
846 internal__static_protobuf_unittest_TestRequired__Descriptor = Descriptor.MessageTypes[7];
847 internal__static_protobuf_unittest_TestRequired__FieldAccessorTable =
848 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestRequired, global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder>(internal__static_protobuf_unittest_TestRequired__Descriptor,
849 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", });
850 global::Google.ProtocolBuffers.TestProtos.TestRequired.Single = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.TestRequired>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor.Extensions[0]);
851 global::Google.ProtocolBuffers.TestProtos.TestRequired.Multi = pb::GeneratedRepeatExtension<global::Google.ProtocolBuffers.TestProtos.TestRequired>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor.Extensions[1]);
852 internal__static_protobuf_unittest_TestRequiredForeign__Descriptor = Descriptor.MessageTypes[8];
853 internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable =
854 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign, global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.Builder>(internal__static_protobuf_unittest_TestRequiredForeign__Descriptor,
855 new string[] { "OptionalMessage", "RepeatedMessage", "Dummy", });
856 internal__static_protobuf_unittest_TestForeignNested__Descriptor = Descriptor.MessageTypes[9];
857 internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable =
858 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestForeignNested, global::Google.ProtocolBuffers.TestProtos.TestForeignNested.Builder>(internal__static_protobuf_unittest_TestForeignNested__Descriptor,
859 new string[] { "ForeignNested", });
860 internal__static_protobuf_unittest_TestEmptyMessage__Descriptor = Descriptor.MessageTypes[10];
861 internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable =
862 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage, global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.Builder>(internal__static_protobuf_unittest_TestEmptyMessage__Descriptor,
863 new string[] { });
864 internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor = Descriptor.MessageTypes[11];
865 internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable =
866 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions, global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.Builder>(internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor,
867 new string[] { });
868 internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor = Descriptor.MessageTypes[12];
869 internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable =
870 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges, global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.Builder>(internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor,
871 new string[] { });
872 internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor = Descriptor.MessageTypes[13];
873 internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable =
874 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber, global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.Builder>(internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor,
875 new string[] { "A", "Bb", });
876 internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor = Descriptor.MessageTypes[14];
877 internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable =
878 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage, global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder>(internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor,
879 new string[] { "A", "I", });
880 internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor = Descriptor.MessageTypes[15];
881 internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable =
882 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA, global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder>(internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor,
883 new string[] { "Bb", });
884 internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor = Descriptor.MessageTypes[16];
885 internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable =
886 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB, global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder>(internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor,
887 new string[] { "A", "OptionalInt32", });
888 internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor = Descriptor.MessageTypes[17];
889 internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable =
890 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber, global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Builder>(internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor,
891 new string[] { "A", "Foo", "Bar", });
892 internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor = internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor.NestedTypes[0];
893 internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable =
894 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo, global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder>(internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor,
895 new string[] { "A", });
896 internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor = internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor.NestedTypes[1];
897 internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable =
898 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar, global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder>(internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor,
899 new string[] { "A", });
900 internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor = Descriptor.MessageTypes[18];
901 internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable =
902 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits, global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Builder>(internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor,
903 new string[] { "OptionalNestedMessage", });
904 internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor = internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor.NestedTypes[0];
905 internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable =
906 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage, global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder>(internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor,
907 new string[] { "NestedmessageRepeatedInt32", "NestedmessageRepeatedForeignmessage", });
908 internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor = Descriptor.MessageTypes[19];
909 internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable =
910 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames, global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.Builder>(internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor,
911 new string[] { "PrimitiveField", "StringField", "EnumField", "MessageField", "StringPieceField", "CordField", "RepeatedPrimitiveField", "RepeatedStringField", "RepeatedEnumField", "RepeatedMessageField", "RepeatedStringPieceField", "RepeatedCordField", });
912 internal__static_protobuf_unittest_TestFieldOrderings__Descriptor = Descriptor.MessageTypes[20];
913 internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable =
914 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings, global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Builder>(internal__static_protobuf_unittest_TestFieldOrderings__Descriptor,
915 new string[] { "MyString", "MyInt", "MyFloat", });
916 internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor = Descriptor.MessageTypes[21];
917 internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable =
918 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues, global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Builder>(internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor,
919 new string[] { "EscapedBytes", "LargeUint32", "LargeUint64", "SmallInt32", "SmallInt64", "Utf8String", "ZeroFloat", "OneFloat", "SmallFloat", "NegativeOneFloat", "NegativeFloat", "LargeFloat", "SmallNegativeFloat", "InfDouble", "NegInfDouble", "NanDouble", "InfFloat", "NegInfFloat", "NanFloat", });
920 internal__static_protobuf_unittest_OneString__Descriptor = Descriptor.MessageTypes[22];
921 internal__static_protobuf_unittest_OneString__FieldAccessorTable =
922 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.OneString, global::Google.ProtocolBuffers.TestProtos.OneString.Builder>(internal__static_protobuf_unittest_OneString__Descriptor,
923 new string[] { "Data", });
924 internal__static_protobuf_unittest_OneBytes__Descriptor = Descriptor.MessageTypes[23];
925 internal__static_protobuf_unittest_OneBytes__FieldAccessorTable =
926 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.OneBytes, global::Google.ProtocolBuffers.TestProtos.OneBytes.Builder>(internal__static_protobuf_unittest_OneBytes__Descriptor,
927 new string[] { "Data", });
928 internal__static_protobuf_unittest_TestPackedTypes__Descriptor = Descriptor.MessageTypes[24];
929 internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable =
930 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestPackedTypes, global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.Builder>(internal__static_protobuf_unittest_TestPackedTypes__Descriptor,
931 new string[] { "PackedInt32", "PackedInt64", "PackedUint32", "PackedUint64", "PackedSint32", "PackedSint64", "PackedFixed32", "PackedFixed64", "PackedSfixed32", "PackedSfixed64", "PackedFloat", "PackedDouble", "PackedBool", "PackedEnum", });
932 internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor = Descriptor.MessageTypes[25];
933 internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable =
934 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes, global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.Builder>(internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor,
935 new string[] { "UnpackedInt32", "UnpackedInt64", "UnpackedUint32", "UnpackedUint64", "UnpackedSint32", "UnpackedSint64", "UnpackedFixed32", "UnpackedFixed64", "UnpackedSfixed32", "UnpackedSfixed64", "UnpackedFloat", "UnpackedDouble", "UnpackedBool", "UnpackedEnum", });
936 internal__static_protobuf_unittest_TestPackedExtensions__Descriptor = Descriptor.MessageTypes[26];
937 internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable =
938 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions, global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.Builder>(internal__static_protobuf_unittest_TestPackedExtensions__Descriptor,
939 new string[] { });
csharptest6da31702011-06-04 12:52:57 -0500940 internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor = Descriptor.MessageTypes[27];
941 internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable =
942 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions, global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.Builder>(internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor,
943 new string[] { });
944 internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor = Descriptor.MessageTypes[28];
Jon Skeet82bb0f12011-04-03 20:17:12 +0100945 internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable =
946 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions, global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Builder>(internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor,
947 new string[] { "ScalarExtension", "EnumExtension", "DynamicEnumExtension", "MessageExtension", "DynamicMessageExtension", "RepeatedExtension", "PackedExtension", });
948 internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor = internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor.NestedTypes[0];
949 internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable =
950 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType, global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder>(internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor,
951 new string[] { "DynamicField", });
csharptest6da31702011-06-04 12:52:57 -0500952 internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor = Descriptor.MessageTypes[29];
Jon Skeet82bb0f12011-04-03 20:17:12 +0100953 internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable =
954 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes, global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.Builder>(internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor,
955 new string[] { "RepeatedFixed32", "RepeatedInt32", "RepeatedFixed64", "RepeatedInt64", "RepeatedFloat", "RepeatedUint64", });
csharptest6da31702011-06-04 12:52:57 -0500956 internal__static_protobuf_unittest_FooRequest__Descriptor = Descriptor.MessageTypes[30];
Jon Skeet82bb0f12011-04-03 20:17:12 +0100957 internal__static_protobuf_unittest_FooRequest__FieldAccessorTable =
958 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.FooRequest, global::Google.ProtocolBuffers.TestProtos.FooRequest.Builder>(internal__static_protobuf_unittest_FooRequest__Descriptor,
959 new string[] { });
csharptest6da31702011-06-04 12:52:57 -0500960 internal__static_protobuf_unittest_FooResponse__Descriptor = Descriptor.MessageTypes[31];
Jon Skeet82bb0f12011-04-03 20:17:12 +0100961 internal__static_protobuf_unittest_FooResponse__FieldAccessorTable =
962 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.FooResponse, global::Google.ProtocolBuffers.TestProtos.FooResponse.Builder>(internal__static_protobuf_unittest_FooResponse__Descriptor,
963 new string[] { });
csharptest6da31702011-06-04 12:52:57 -0500964 internal__static_protobuf_unittest_BarRequest__Descriptor = Descriptor.MessageTypes[32];
Jon Skeet82bb0f12011-04-03 20:17:12 +0100965 internal__static_protobuf_unittest_BarRequest__FieldAccessorTable =
966 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.BarRequest, global::Google.ProtocolBuffers.TestProtos.BarRequest.Builder>(internal__static_protobuf_unittest_BarRequest__Descriptor,
967 new string[] { });
csharptest6da31702011-06-04 12:52:57 -0500968 internal__static_protobuf_unittest_BarResponse__Descriptor = Descriptor.MessageTypes[33];
Jon Skeet82bb0f12011-04-03 20:17:12 +0100969 internal__static_protobuf_unittest_BarResponse__FieldAccessorTable =
970 new pb::FieldAccess.FieldAccessorTable<global::Google.ProtocolBuffers.TestProtos.BarResponse, global::Google.ProtocolBuffers.TestProtos.BarResponse.Builder>(internal__static_protobuf_unittest_BarResponse__Descriptor,
971 new string[] { });
972 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalInt32Extension = pb::GeneratedSingleExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[0]);
973 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalInt64Extension = pb::GeneratedSingleExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[1]);
974 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalUint32Extension = pb::GeneratedSingleExtension<uint>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[2]);
975 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalUint64Extension = pb::GeneratedSingleExtension<ulong>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[3]);
976 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSint32Extension = pb::GeneratedSingleExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[4]);
977 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSint64Extension = pb::GeneratedSingleExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[5]);
978 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFixed32Extension = pb::GeneratedSingleExtension<uint>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[6]);
979 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFixed64Extension = pb::GeneratedSingleExtension<ulong>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[7]);
980 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSfixed32Extension = pb::GeneratedSingleExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[8]);
981 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalSfixed64Extension = pb::GeneratedSingleExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[9]);
982 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalFloatExtension = pb::GeneratedSingleExtension<float>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[10]);
983 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalDoubleExtension = pb::GeneratedSingleExtension<double>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[11]);
984 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalBoolExtension = pb::GeneratedSingleExtension<bool>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[12]);
985 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalStringExtension = pb::GeneratedSingleExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[13]);
986 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalBytesExtension = pb::GeneratedSingleExtension<pb::ByteString>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[14]);
987 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalGroupExtension = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[15]);
988 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalNestedMessageExtension = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[16]);
989 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalForeignMessageExtension = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.ForeignMessage>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[17]);
990 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalImportMessageExtension = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.ImportMessage>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[18]);
991 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalNestedEnumExtension = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[19]);
992 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalForeignEnumExtension = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[20]);
993 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalImportEnumExtension = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.ImportEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[21]);
994 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalStringPieceExtension = pb::GeneratedSingleExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[22]);
995 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.OptionalCordExtension = pb::GeneratedSingleExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[23]);
996 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedInt32Extension = pb::GeneratedRepeatExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[24]);
997 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedInt64Extension = pb::GeneratedRepeatExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[25]);
998 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedUint32Extension = pb::GeneratedRepeatExtension<uint>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[26]);
999 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedUint64Extension = pb::GeneratedRepeatExtension<ulong>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[27]);
1000 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSint32Extension = pb::GeneratedRepeatExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[28]);
1001 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSint64Extension = pb::GeneratedRepeatExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[29]);
1002 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFixed32Extension = pb::GeneratedRepeatExtension<uint>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[30]);
1003 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFixed64Extension = pb::GeneratedRepeatExtension<ulong>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[31]);
1004 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSfixed32Extension = pb::GeneratedRepeatExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[32]);
1005 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedSfixed64Extension = pb::GeneratedRepeatExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[33]);
1006 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedFloatExtension = pb::GeneratedRepeatExtension<float>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[34]);
1007 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedDoubleExtension = pb::GeneratedRepeatExtension<double>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[35]);
1008 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedBoolExtension = pb::GeneratedRepeatExtension<bool>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[36]);
1009 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedStringExtension = pb::GeneratedRepeatExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[37]);
1010 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedBytesExtension = pb::GeneratedRepeatExtension<pb::ByteString>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[38]);
1011 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedGroupExtension = pb::GeneratedRepeatExtension<global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[39]);
1012 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedNestedMessageExtension = pb::GeneratedRepeatExtension<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[40]);
1013 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedForeignMessageExtension = pb::GeneratedRepeatExtension<global::Google.ProtocolBuffers.TestProtos.ForeignMessage>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[41]);
1014 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedImportMessageExtension = pb::GeneratedRepeatExtension<global::Google.ProtocolBuffers.TestProtos.ImportMessage>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[42]);
1015 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedNestedEnumExtension = pb::GeneratedRepeatExtension<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[43]);
1016 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedForeignEnumExtension = pb::GeneratedRepeatExtension<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[44]);
1017 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedImportEnumExtension = pb::GeneratedRepeatExtension<global::Google.ProtocolBuffers.TestProtos.ImportEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[45]);
1018 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedStringPieceExtension = pb::GeneratedRepeatExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[46]);
1019 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.RepeatedCordExtension = pb::GeneratedRepeatExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[47]);
1020 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultInt32Extension = pb::GeneratedSingleExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[48]);
1021 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultInt64Extension = pb::GeneratedSingleExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[49]);
1022 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultUint32Extension = pb::GeneratedSingleExtension<uint>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[50]);
1023 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultUint64Extension = pb::GeneratedSingleExtension<ulong>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[51]);
1024 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSint32Extension = pb::GeneratedSingleExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[52]);
1025 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSint64Extension = pb::GeneratedSingleExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[53]);
1026 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFixed32Extension = pb::GeneratedSingleExtension<uint>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[54]);
1027 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFixed64Extension = pb::GeneratedSingleExtension<ulong>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[55]);
1028 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSfixed32Extension = pb::GeneratedSingleExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[56]);
1029 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultSfixed64Extension = pb::GeneratedSingleExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[57]);
1030 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultFloatExtension = pb::GeneratedSingleExtension<float>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[58]);
1031 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultDoubleExtension = pb::GeneratedSingleExtension<double>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[59]);
1032 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultBoolExtension = pb::GeneratedSingleExtension<bool>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[60]);
1033 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultStringExtension = pb::GeneratedSingleExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[61]);
1034 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultBytesExtension = pb::GeneratedSingleExtension<pb::ByteString>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[62]);
1035 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultNestedEnumExtension = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[63]);
1036 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultForeignEnumExtension = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[64]);
1037 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultImportEnumExtension = pb::GeneratedSingleExtension<global::Google.ProtocolBuffers.TestProtos.ImportEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[65]);
1038 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultStringPieceExtension = pb::GeneratedSingleExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[66]);
1039 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.DefaultCordExtension = pb::GeneratedSingleExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[67]);
1040 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.MyExtensionString = pb::GeneratedSingleExtension<string>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[68]);
1041 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.MyExtensionInt = pb::GeneratedSingleExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[69]);
1042 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedInt32Extension = pb::GeneratedRepeatExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[70]);
1043 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedInt64Extension = pb::GeneratedRepeatExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[71]);
1044 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedUint32Extension = pb::GeneratedRepeatExtension<uint>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[72]);
1045 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedUint64Extension = pb::GeneratedRepeatExtension<ulong>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[73]);
1046 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSint32Extension = pb::GeneratedRepeatExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[74]);
1047 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSint64Extension = pb::GeneratedRepeatExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[75]);
1048 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFixed32Extension = pb::GeneratedRepeatExtension<uint>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[76]);
1049 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFixed64Extension = pb::GeneratedRepeatExtension<ulong>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[77]);
1050 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSfixed32Extension = pb::GeneratedRepeatExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[78]);
1051 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedSfixed64Extension = pb::GeneratedRepeatExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[79]);
1052 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedFloatExtension = pb::GeneratedRepeatExtension<float>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[80]);
1053 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedDoubleExtension = pb::GeneratedRepeatExtension<double>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[81]);
1054 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedBoolExtension = pb::GeneratedRepeatExtension<bool>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[82]);
1055 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.PackedEnumExtension = pb::GeneratedRepeatExtension<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[83]);
csharptest6da31702011-06-04 12:52:57 -05001056 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedInt32Extension = pb::GeneratedRepeatExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[84]);
1057 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedInt64Extension = pb::GeneratedRepeatExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[85]);
1058 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedUint32Extension = pb::GeneratedRepeatExtension<uint>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[86]);
1059 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedUint64Extension = pb::GeneratedRepeatExtension<ulong>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[87]);
1060 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedSint32Extension = pb::GeneratedRepeatExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[88]);
1061 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedSint64Extension = pb::GeneratedRepeatExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[89]);
1062 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedFixed32Extension = pb::GeneratedRepeatExtension<uint>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[90]);
1063 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedFixed64Extension = pb::GeneratedRepeatExtension<ulong>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[91]);
1064 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedSfixed32Extension = pb::GeneratedRepeatExtension<int>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[92]);
1065 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedSfixed64Extension = pb::GeneratedRepeatExtension<long>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[93]);
1066 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedFloatExtension = pb::GeneratedRepeatExtension<float>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[94]);
1067 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedDoubleExtension = pb::GeneratedRepeatExtension<double>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[95]);
1068 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedBoolExtension = pb::GeneratedRepeatExtension<bool>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[96]);
1069 global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.UnpackedEnumExtension = pb::GeneratedRepeatExtension<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>.CreateInstance(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor.Extensions[97]);
Jon Skeet82bb0f12011-04-03 20:17:12 +01001070 pb::ExtensionRegistry registry = pb::ExtensionRegistry.CreateInstance();
1071 RegisterAllExtensions(registry);
1072 global::Google.ProtocolBuffers.DescriptorProtos.CSharpOptions.RegisterAllExtensions(registry);
1073 global::Google.ProtocolBuffers.TestProtos.UnitTestImportProtoFile.RegisterAllExtensions(registry);
1074 return registry;
1075 };
1076 pbd::FileDescriptor.InternalBuildGeneratedFileFrom(descriptorData,
1077 new pbd::FileDescriptor[] {
1078 global::Google.ProtocolBuffers.DescriptorProtos.CSharpOptions.Descriptor,
1079 global::Google.ProtocolBuffers.TestProtos.UnitTestImportProtoFile.Descriptor,
1080 }, assigner);
1081 }
1082 #endregion
1083
1084 }
1085 #region Enums
csharptest445bdce2011-05-20 15:50:54 -05001086 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1087 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001088 public enum ForeignEnum {
1089 FOREIGN_FOO = 4,
1090 FOREIGN_BAR = 5,
1091 FOREIGN_BAZ = 6,
1092 }
1093
csharptest445bdce2011-05-20 15:50:54 -05001094 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1095 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001096 public enum TestEnumWithDupValue {
1097 FOO1 = 1,
1098 BAR1 = 2,
1099 BAZ = 3,
1100 FOO2 = 1,
1101 BAR2 = 2,
1102 }
1103
csharptest445bdce2011-05-20 15:50:54 -05001104 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1105 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001106 public enum TestSparseEnum {
1107 SPARSE_A = 123,
1108 SPARSE_B = 62374,
1109 SPARSE_C = 12589234,
1110 SPARSE_D = -15,
1111 SPARSE_E = -53452,
1112 SPARSE_F = 0,
1113 SPARSE_G = 2,
1114 }
1115
1116 #endregion
1117
1118 #region Messages
csharptest445bdce2011-05-20 15:50:54 -05001119 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1120 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1121 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001122 public sealed partial class TestAllTypes : pb::GeneratedMessage<TestAllTypes, TestAllTypes.Builder> {
1123 private static readonly TestAllTypes defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05001124 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" };
1125 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 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01001126 public static TestAllTypes DefaultInstance {
1127 get { return defaultInstance; }
1128 }
1129
1130 public override TestAllTypes DefaultInstanceForType {
1131 get { return defaultInstance; }
1132 }
1133
1134 protected override TestAllTypes ThisMessage {
1135 get { return this; }
1136 }
1137
1138 public static pbd::MessageDescriptor Descriptor {
1139 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes__Descriptor; }
1140 }
1141
1142 protected override pb::FieldAccess.FieldAccessorTable<TestAllTypes, TestAllTypes.Builder> InternalFieldAccessors {
1143 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes__FieldAccessorTable; }
1144 }
1145
1146 #region Nested types
csharptest445bdce2011-05-20 15:50:54 -05001147 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1148 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1149 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001150 public static class Types {
csharptest445bdce2011-05-20 15:50:54 -05001151 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1152 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001153 public enum NestedEnum {
1154 FOO = 1,
1155 BAR = 2,
1156 BAZ = 3,
1157 }
1158
csharptest445bdce2011-05-20 15:50:54 -05001159 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1160 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1161 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001162 public sealed partial class NestedMessage : pb::GeneratedMessage<NestedMessage, NestedMessage.Builder> {
1163 private static readonly NestedMessage defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05001164 private static readonly string[] _nestedMessageFieldNames = new string[] { "bb" };
1165 private static readonly uint[] _nestedMessageFieldTags = new uint[] { 8 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01001166 public static NestedMessage DefaultInstance {
1167 get { return defaultInstance; }
1168 }
1169
1170 public override NestedMessage DefaultInstanceForType {
1171 get { return defaultInstance; }
1172 }
1173
1174 protected override NestedMessage ThisMessage {
1175 get { return this; }
1176 }
1177
1178 public static pbd::MessageDescriptor Descriptor {
1179 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_NestedMessage__Descriptor; }
1180 }
1181
1182 protected override pb::FieldAccess.FieldAccessorTable<NestedMessage, NestedMessage.Builder> InternalFieldAccessors {
1183 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_NestedMessage__FieldAccessorTable; }
1184 }
1185
1186 public const int BbFieldNumber = 1;
1187 private bool hasBb;
csharptestced18e12011-06-09 19:47:56 -05001188 private int bb_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001189 public bool HasBb {
1190 get { return hasBb; }
1191 }
1192 public int Bb {
1193 get { return bb_; }
1194 }
1195
1196 public override bool IsInitialized {
1197 get {
1198 return true;
1199 }
1200 }
1201
csharptestffafdaa2011-06-03 12:58:14 -05001202 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001203 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05001204 string[] field_names = _nestedMessageFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05001205 if (hasBb) {
csharptest920b09a2011-06-08 20:13:29 -05001206 output.WriteInt32(1, field_names[0], Bb);
Jon Skeet82bb0f12011-04-03 20:17:12 +01001207 }
1208 UnknownFields.WriteTo(output);
1209 }
1210
1211 private int memoizedSerializedSize = -1;
1212 public override int SerializedSize {
1213 get {
1214 int size = memoizedSerializedSize;
1215 if (size != -1) return size;
1216
1217 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05001218 if (hasBb) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001219 size += pb::CodedOutputStream.ComputeInt32Size(1, Bb);
1220 }
1221 size += UnknownFields.SerializedSize;
1222 memoizedSerializedSize = size;
1223 return size;
1224 }
1225 }
1226
1227 public static NestedMessage ParseFrom(pb::ByteString data) {
1228 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
1229 }
1230 public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
1231 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
1232 }
1233 public static NestedMessage ParseFrom(byte[] data) {
1234 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
1235 }
1236 public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
1237 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
1238 }
1239 public static NestedMessage ParseFrom(global::System.IO.Stream input) {
1240 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
1241 }
1242 public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
1243 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
1244 }
1245 public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) {
1246 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
1247 }
1248 public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
1249 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
1250 }
csharptest17699c22011-06-03 21:57:15 -05001251 public static NestedMessage ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001252 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
1253 }
csharptest17699c22011-06-03 21:57:15 -05001254 public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001255 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
1256 }
1257 public static Builder CreateBuilder() { return new Builder(); }
1258 public override Builder ToBuilder() { return CreateBuilder(this); }
1259 public override Builder CreateBuilderForType() { return new Builder(); }
1260 public static Builder CreateBuilder(NestedMessage prototype) {
1261 return (Builder) new Builder().MergeFrom(prototype);
1262 }
1263
csharptest445bdce2011-05-20 15:50:54 -05001264 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1265 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1266 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001267 public sealed partial class Builder : pb::GeneratedBuilder<NestedMessage, Builder> {
1268 protected override Builder ThisBuilder {
1269 get { return this; }
1270 }
1271 public Builder() {}
1272
1273 NestedMessage result = new NestedMessage();
1274
1275 protected override NestedMessage MessageBeingBuilt {
1276 get { return result; }
1277 }
1278
1279 public override Builder Clear() {
1280 result = new NestedMessage();
1281 return this;
1282 }
1283
1284 public override Builder Clone() {
1285 return new Builder().MergeFrom(result);
1286 }
1287
1288 public override pbd::MessageDescriptor DescriptorForType {
1289 get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Descriptor; }
1290 }
1291
1292 public override NestedMessage DefaultInstanceForType {
1293 get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance; }
1294 }
1295
1296 public override NestedMessage BuildPartial() {
1297 if (result == null) {
1298 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
1299 }
1300 NestedMessage returnMe = result;
1301 result = null;
1302 return returnMe;
1303 }
1304
1305 public override Builder MergeFrom(pb::IMessage other) {
1306 if (other is NestedMessage) {
1307 return MergeFrom((NestedMessage) other);
1308 } else {
1309 base.MergeFrom(other);
1310 return this;
1311 }
1312 }
1313
1314 public override Builder MergeFrom(NestedMessage other) {
1315 if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) return this;
1316 if (other.HasBb) {
1317 Bb = other.Bb;
1318 }
1319 this.MergeUnknownFields(other.UnknownFields);
1320 return this;
1321 }
1322
csharptest17699c22011-06-03 21:57:15 -05001323 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001324 return MergeFrom(input, pb::ExtensionRegistry.Empty);
1325 }
1326
csharptest17699c22011-06-03 21:57:15 -05001327 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001328 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05001329 uint tag;
1330 string field_name;
1331 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05001332 if(tag == 0 && field_name != null) {
1333 int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal);
1334 if(field_ordinal >= 0)
1335 tag = _nestedMessageFieldTags[field_ordinal];
1336 else {
1337 if (unknownFields == null) {
1338 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
1339 }
1340 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
1341 continue;
1342 }
1343 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01001344 switch (tag) {
1345 case 0: {
csharptest99284412011-06-03 14:51:06 -05001346 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01001347 }
1348 default: {
1349 if (pb::WireFormat.IsEndGroupTag(tag)) {
1350 if (unknownFields != null) {
1351 this.UnknownFields = unknownFields.Build();
1352 }
1353 return this;
1354 }
1355 if (unknownFields == null) {
1356 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
1357 }
csharptestd2af9e92011-06-03 21:35:02 -05001358 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01001359 break;
1360 }
1361 case 8: {
csharptest920b09a2011-06-08 20:13:29 -05001362 result.hasBb = input.ReadInt32(ref result.bb_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01001363 break;
1364 }
1365 }
1366 }
csharptest123e5342011-06-03 14:15:21 -05001367
1368 if (unknownFields != null) {
1369 this.UnknownFields = unknownFields.Build();
1370 }
1371 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001372 }
1373
1374
1375 public bool HasBb {
csharptestc671a4b2011-06-08 11:51:24 -05001376 get { return result.hasBb; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01001377 }
1378 public int Bb {
1379 get { return result.Bb; }
1380 set { SetBb(value); }
1381 }
1382 public Builder SetBb(int value) {
1383 result.hasBb = true;
1384 result.bb_ = value;
1385 return this;
1386 }
1387 public Builder ClearBb() {
1388 result.hasBb = false;
1389 result.bb_ = 0;
1390 return this;
1391 }
1392 }
1393 static NestedMessage() {
1394 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
1395 }
1396 }
1397
csharptest445bdce2011-05-20 15:50:54 -05001398 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1399 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1400 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001401 public sealed partial class OptionalGroup : pb::GeneratedMessage<OptionalGroup, OptionalGroup.Builder> {
1402 private static readonly OptionalGroup defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05001403 private static readonly string[] _optionalGroupFieldNames = new string[] { "a" };
1404 private static readonly uint[] _optionalGroupFieldTags = new uint[] { 136 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01001405 public static OptionalGroup DefaultInstance {
1406 get { return defaultInstance; }
1407 }
1408
1409 public override OptionalGroup DefaultInstanceForType {
1410 get { return defaultInstance; }
1411 }
1412
1413 protected override OptionalGroup ThisMessage {
1414 get { return this; }
1415 }
1416
1417 public static pbd::MessageDescriptor Descriptor {
1418 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__Descriptor; }
1419 }
1420
1421 protected override pb::FieldAccess.FieldAccessorTable<OptionalGroup, OptionalGroup.Builder> InternalFieldAccessors {
1422 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_OptionalGroup__FieldAccessorTable; }
1423 }
1424
1425 public const int AFieldNumber = 17;
1426 private bool hasA;
csharptestced18e12011-06-09 19:47:56 -05001427 private int a_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001428 public bool HasA {
1429 get { return hasA; }
1430 }
1431 public int A {
1432 get { return a_; }
1433 }
1434
1435 public override bool IsInitialized {
1436 get {
1437 return true;
1438 }
1439 }
1440
csharptestffafdaa2011-06-03 12:58:14 -05001441 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001442 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05001443 string[] field_names = _optionalGroupFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05001444 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -05001445 output.WriteInt32(17, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +01001446 }
1447 UnknownFields.WriteTo(output);
1448 }
1449
1450 private int memoizedSerializedSize = -1;
1451 public override int SerializedSize {
1452 get {
1453 int size = memoizedSerializedSize;
1454 if (size != -1) return size;
1455
1456 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05001457 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001458 size += pb::CodedOutputStream.ComputeInt32Size(17, A);
1459 }
1460 size += UnknownFields.SerializedSize;
1461 memoizedSerializedSize = size;
1462 return size;
1463 }
1464 }
1465
1466 public static OptionalGroup ParseFrom(pb::ByteString data) {
1467 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
1468 }
1469 public static OptionalGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
1470 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
1471 }
1472 public static OptionalGroup ParseFrom(byte[] data) {
1473 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
1474 }
1475 public static OptionalGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
1476 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
1477 }
1478 public static OptionalGroup ParseFrom(global::System.IO.Stream input) {
1479 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
1480 }
1481 public static OptionalGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
1482 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
1483 }
1484 public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input) {
1485 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
1486 }
1487 public static OptionalGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
1488 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
1489 }
csharptest17699c22011-06-03 21:57:15 -05001490 public static OptionalGroup ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001491 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
1492 }
csharptest17699c22011-06-03 21:57:15 -05001493 public static OptionalGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001494 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
1495 }
1496 public static Builder CreateBuilder() { return new Builder(); }
1497 public override Builder ToBuilder() { return CreateBuilder(this); }
1498 public override Builder CreateBuilderForType() { return new Builder(); }
1499 public static Builder CreateBuilder(OptionalGroup prototype) {
1500 return (Builder) new Builder().MergeFrom(prototype);
1501 }
1502
csharptest445bdce2011-05-20 15:50:54 -05001503 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1504 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1505 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001506 public sealed partial class Builder : pb::GeneratedBuilder<OptionalGroup, Builder> {
1507 protected override Builder ThisBuilder {
1508 get { return this; }
1509 }
1510 public Builder() {}
1511
1512 OptionalGroup result = new OptionalGroup();
1513
1514 protected override OptionalGroup MessageBeingBuilt {
1515 get { return result; }
1516 }
1517
1518 public override Builder Clear() {
1519 result = new OptionalGroup();
1520 return this;
1521 }
1522
1523 public override Builder Clone() {
1524 return new Builder().MergeFrom(result);
1525 }
1526
1527 public override pbd::MessageDescriptor DescriptorForType {
1528 get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Descriptor; }
1529 }
1530
1531 public override OptionalGroup DefaultInstanceForType {
1532 get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance; }
1533 }
1534
1535 public override OptionalGroup BuildPartial() {
1536 if (result == null) {
1537 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
1538 }
1539 OptionalGroup returnMe = result;
1540 result = null;
1541 return returnMe;
1542 }
1543
1544 public override Builder MergeFrom(pb::IMessage other) {
1545 if (other is OptionalGroup) {
1546 return MergeFrom((OptionalGroup) other);
1547 } else {
1548 base.MergeFrom(other);
1549 return this;
1550 }
1551 }
1552
1553 public override Builder MergeFrom(OptionalGroup other) {
1554 if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance) return this;
1555 if (other.HasA) {
1556 A = other.A;
1557 }
1558 this.MergeUnknownFields(other.UnknownFields);
1559 return this;
1560 }
1561
csharptest17699c22011-06-03 21:57:15 -05001562 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001563 return MergeFrom(input, pb::ExtensionRegistry.Empty);
1564 }
1565
csharptest17699c22011-06-03 21:57:15 -05001566 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001567 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05001568 uint tag;
1569 string field_name;
1570 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05001571 if(tag == 0 && field_name != null) {
1572 int field_ordinal = global::System.Array.BinarySearch(_optionalGroupFieldNames, field_name, global::System.StringComparer.Ordinal);
1573 if(field_ordinal >= 0)
1574 tag = _optionalGroupFieldTags[field_ordinal];
1575 else {
1576 if (unknownFields == null) {
1577 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
1578 }
1579 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
1580 continue;
1581 }
1582 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01001583 switch (tag) {
1584 case 0: {
csharptest99284412011-06-03 14:51:06 -05001585 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01001586 }
1587 default: {
1588 if (pb::WireFormat.IsEndGroupTag(tag)) {
1589 if (unknownFields != null) {
1590 this.UnknownFields = unknownFields.Build();
1591 }
1592 return this;
1593 }
1594 if (unknownFields == null) {
1595 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
1596 }
csharptestd2af9e92011-06-03 21:35:02 -05001597 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01001598 break;
1599 }
1600 case 136: {
csharptest920b09a2011-06-08 20:13:29 -05001601 result.hasA = input.ReadInt32(ref result.a_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01001602 break;
1603 }
1604 }
1605 }
csharptest123e5342011-06-03 14:15:21 -05001606
1607 if (unknownFields != null) {
1608 this.UnknownFields = unknownFields.Build();
1609 }
1610 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001611 }
1612
1613
1614 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -05001615 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01001616 }
1617 public int A {
1618 get { return result.A; }
1619 set { SetA(value); }
1620 }
1621 public Builder SetA(int value) {
1622 result.hasA = true;
1623 result.a_ = value;
1624 return this;
1625 }
1626 public Builder ClearA() {
1627 result.hasA = false;
1628 result.a_ = 0;
1629 return this;
1630 }
1631 }
1632 static OptionalGroup() {
1633 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
1634 }
1635 }
1636
csharptest445bdce2011-05-20 15:50:54 -05001637 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1638 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1639 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001640 public sealed partial class RepeatedGroup : pb::GeneratedMessage<RepeatedGroup, RepeatedGroup.Builder> {
1641 private static readonly RepeatedGroup defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05001642 private static readonly string[] _repeatedGroupFieldNames = new string[] { "a" };
1643 private static readonly uint[] _repeatedGroupFieldTags = new uint[] { 376 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01001644 public static RepeatedGroup DefaultInstance {
1645 get { return defaultInstance; }
1646 }
1647
1648 public override RepeatedGroup DefaultInstanceForType {
1649 get { return defaultInstance; }
1650 }
1651
1652 protected override RepeatedGroup ThisMessage {
1653 get { return this; }
1654 }
1655
1656 public static pbd::MessageDescriptor Descriptor {
1657 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__Descriptor; }
1658 }
1659
1660 protected override pb::FieldAccess.FieldAccessorTable<RepeatedGroup, RepeatedGroup.Builder> InternalFieldAccessors {
1661 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllTypes_RepeatedGroup__FieldAccessorTable; }
1662 }
1663
1664 public const int AFieldNumber = 47;
1665 private bool hasA;
csharptestced18e12011-06-09 19:47:56 -05001666 private int a_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001667 public bool HasA {
1668 get { return hasA; }
1669 }
1670 public int A {
1671 get { return a_; }
1672 }
1673
1674 public override bool IsInitialized {
1675 get {
1676 return true;
1677 }
1678 }
1679
csharptestffafdaa2011-06-03 12:58:14 -05001680 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001681 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05001682 string[] field_names = _repeatedGroupFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05001683 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -05001684 output.WriteInt32(47, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +01001685 }
1686 UnknownFields.WriteTo(output);
1687 }
1688
1689 private int memoizedSerializedSize = -1;
1690 public override int SerializedSize {
1691 get {
1692 int size = memoizedSerializedSize;
1693 if (size != -1) return size;
1694
1695 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05001696 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001697 size += pb::CodedOutputStream.ComputeInt32Size(47, A);
1698 }
1699 size += UnknownFields.SerializedSize;
1700 memoizedSerializedSize = size;
1701 return size;
1702 }
1703 }
1704
1705 public static RepeatedGroup ParseFrom(pb::ByteString data) {
1706 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
1707 }
1708 public static RepeatedGroup ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
1709 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
1710 }
1711 public static RepeatedGroup ParseFrom(byte[] data) {
1712 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
1713 }
1714 public static RepeatedGroup ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
1715 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
1716 }
1717 public static RepeatedGroup ParseFrom(global::System.IO.Stream input) {
1718 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
1719 }
1720 public static RepeatedGroup ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
1721 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
1722 }
1723 public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input) {
1724 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
1725 }
1726 public static RepeatedGroup ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
1727 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
1728 }
csharptest17699c22011-06-03 21:57:15 -05001729 public static RepeatedGroup ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001730 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
1731 }
csharptest17699c22011-06-03 21:57:15 -05001732 public static RepeatedGroup ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001733 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
1734 }
1735 public static Builder CreateBuilder() { return new Builder(); }
1736 public override Builder ToBuilder() { return CreateBuilder(this); }
1737 public override Builder CreateBuilderForType() { return new Builder(); }
1738 public static Builder CreateBuilder(RepeatedGroup prototype) {
1739 return (Builder) new Builder().MergeFrom(prototype);
1740 }
1741
csharptest445bdce2011-05-20 15:50:54 -05001742 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1743 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
1744 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01001745 public sealed partial class Builder : pb::GeneratedBuilder<RepeatedGroup, Builder> {
1746 protected override Builder ThisBuilder {
1747 get { return this; }
1748 }
1749 public Builder() {}
1750
1751 RepeatedGroup result = new RepeatedGroup();
1752
1753 protected override RepeatedGroup MessageBeingBuilt {
1754 get { return result; }
1755 }
1756
1757 public override Builder Clear() {
1758 result = new RepeatedGroup();
1759 return this;
1760 }
1761
1762 public override Builder Clone() {
1763 return new Builder().MergeFrom(result);
1764 }
1765
1766 public override pbd::MessageDescriptor DescriptorForType {
1767 get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Descriptor; }
1768 }
1769
1770 public override RepeatedGroup DefaultInstanceForType {
1771 get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance; }
1772 }
1773
1774 public override RepeatedGroup BuildPartial() {
1775 if (result == null) {
1776 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
1777 }
1778 RepeatedGroup returnMe = result;
1779 result = null;
1780 return returnMe;
1781 }
1782
1783 public override Builder MergeFrom(pb::IMessage other) {
1784 if (other is RepeatedGroup) {
1785 return MergeFrom((RepeatedGroup) other);
1786 } else {
1787 base.MergeFrom(other);
1788 return this;
1789 }
1790 }
1791
1792 public override Builder MergeFrom(RepeatedGroup other) {
1793 if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance) return this;
1794 if (other.HasA) {
1795 A = other.A;
1796 }
1797 this.MergeUnknownFields(other.UnknownFields);
1798 return this;
1799 }
1800
csharptest17699c22011-06-03 21:57:15 -05001801 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001802 return MergeFrom(input, pb::ExtensionRegistry.Empty);
1803 }
1804
csharptest17699c22011-06-03 21:57:15 -05001805 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01001806 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05001807 uint tag;
1808 string field_name;
1809 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05001810 if(tag == 0 && field_name != null) {
1811 int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupFieldNames, field_name, global::System.StringComparer.Ordinal);
1812 if(field_ordinal >= 0)
1813 tag = _repeatedGroupFieldTags[field_ordinal];
1814 else {
1815 if (unknownFields == null) {
1816 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
1817 }
1818 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
1819 continue;
1820 }
1821 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01001822 switch (tag) {
1823 case 0: {
csharptest99284412011-06-03 14:51:06 -05001824 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01001825 }
1826 default: {
1827 if (pb::WireFormat.IsEndGroupTag(tag)) {
1828 if (unknownFields != null) {
1829 this.UnknownFields = unknownFields.Build();
1830 }
1831 return this;
1832 }
1833 if (unknownFields == null) {
1834 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
1835 }
csharptestd2af9e92011-06-03 21:35:02 -05001836 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01001837 break;
1838 }
1839 case 376: {
csharptest920b09a2011-06-08 20:13:29 -05001840 result.hasA = input.ReadInt32(ref result.a_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01001841 break;
1842 }
1843 }
1844 }
csharptest123e5342011-06-03 14:15:21 -05001845
1846 if (unknownFields != null) {
1847 this.UnknownFields = unknownFields.Build();
1848 }
1849 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001850 }
1851
1852
1853 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -05001854 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01001855 }
1856 public int A {
1857 get { return result.A; }
1858 set { SetA(value); }
1859 }
1860 public Builder SetA(int value) {
1861 result.hasA = true;
1862 result.a_ = value;
1863 return this;
1864 }
1865 public Builder ClearA() {
1866 result.hasA = false;
1867 result.a_ = 0;
1868 return this;
1869 }
1870 }
1871 static RepeatedGroup() {
1872 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
1873 }
1874 }
1875
1876 }
1877 #endregion
1878
1879 public const int OptionalInt32FieldNumber = 1;
1880 private bool hasOptionalInt32;
csharptestced18e12011-06-09 19:47:56 -05001881 private int optionalInt32_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001882 public bool HasOptionalInt32 {
1883 get { return hasOptionalInt32; }
1884 }
1885 public int OptionalInt32 {
1886 get { return optionalInt32_; }
1887 }
1888
1889 public const int OptionalInt64FieldNumber = 2;
1890 private bool hasOptionalInt64;
csharptestced18e12011-06-09 19:47:56 -05001891 private long optionalInt64_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001892 public bool HasOptionalInt64 {
1893 get { return hasOptionalInt64; }
1894 }
1895 public long OptionalInt64 {
1896 get { return optionalInt64_; }
1897 }
1898
1899 public const int OptionalUint32FieldNumber = 3;
1900 private bool hasOptionalUint32;
csharptestced18e12011-06-09 19:47:56 -05001901 private uint optionalUint32_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001902 public bool HasOptionalUint32 {
1903 get { return hasOptionalUint32; }
1904 }
1905 [global::System.CLSCompliant(false)]
1906 public uint OptionalUint32 {
1907 get { return optionalUint32_; }
1908 }
1909
1910 public const int OptionalUint64FieldNumber = 4;
1911 private bool hasOptionalUint64;
csharptestced18e12011-06-09 19:47:56 -05001912 private ulong optionalUint64_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001913 public bool HasOptionalUint64 {
1914 get { return hasOptionalUint64; }
1915 }
1916 [global::System.CLSCompliant(false)]
1917 public ulong OptionalUint64 {
1918 get { return optionalUint64_; }
1919 }
1920
1921 public const int OptionalSint32FieldNumber = 5;
1922 private bool hasOptionalSint32;
csharptestced18e12011-06-09 19:47:56 -05001923 private int optionalSint32_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001924 public bool HasOptionalSint32 {
1925 get { return hasOptionalSint32; }
1926 }
1927 public int OptionalSint32 {
1928 get { return optionalSint32_; }
1929 }
1930
1931 public const int OptionalSint64FieldNumber = 6;
1932 private bool hasOptionalSint64;
csharptestced18e12011-06-09 19:47:56 -05001933 private long optionalSint64_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001934 public bool HasOptionalSint64 {
1935 get { return hasOptionalSint64; }
1936 }
1937 public long OptionalSint64 {
1938 get { return optionalSint64_; }
1939 }
1940
1941 public const int OptionalFixed32FieldNumber = 7;
1942 private bool hasOptionalFixed32;
csharptestced18e12011-06-09 19:47:56 -05001943 private uint optionalFixed32_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001944 public bool HasOptionalFixed32 {
1945 get { return hasOptionalFixed32; }
1946 }
1947 [global::System.CLSCompliant(false)]
1948 public uint OptionalFixed32 {
1949 get { return optionalFixed32_; }
1950 }
1951
1952 public const int OptionalFixed64FieldNumber = 8;
1953 private bool hasOptionalFixed64;
csharptestced18e12011-06-09 19:47:56 -05001954 private ulong optionalFixed64_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001955 public bool HasOptionalFixed64 {
1956 get { return hasOptionalFixed64; }
1957 }
1958 [global::System.CLSCompliant(false)]
1959 public ulong OptionalFixed64 {
1960 get { return optionalFixed64_; }
1961 }
1962
1963 public const int OptionalSfixed32FieldNumber = 9;
1964 private bool hasOptionalSfixed32;
csharptestced18e12011-06-09 19:47:56 -05001965 private int optionalSfixed32_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001966 public bool HasOptionalSfixed32 {
1967 get { return hasOptionalSfixed32; }
1968 }
1969 public int OptionalSfixed32 {
1970 get { return optionalSfixed32_; }
1971 }
1972
1973 public const int OptionalSfixed64FieldNumber = 10;
1974 private bool hasOptionalSfixed64;
csharptestced18e12011-06-09 19:47:56 -05001975 private long optionalSfixed64_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001976 public bool HasOptionalSfixed64 {
1977 get { return hasOptionalSfixed64; }
1978 }
1979 public long OptionalSfixed64 {
1980 get { return optionalSfixed64_; }
1981 }
1982
1983 public const int OptionalFloatFieldNumber = 11;
1984 private bool hasOptionalFloat;
csharptestced18e12011-06-09 19:47:56 -05001985 private float optionalFloat_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001986 public bool HasOptionalFloat {
1987 get { return hasOptionalFloat; }
1988 }
1989 public float OptionalFloat {
1990 get { return optionalFloat_; }
1991 }
1992
1993 public const int OptionalDoubleFieldNumber = 12;
1994 private bool hasOptionalDouble;
csharptestced18e12011-06-09 19:47:56 -05001995 private double optionalDouble_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01001996 public bool HasOptionalDouble {
1997 get { return hasOptionalDouble; }
1998 }
1999 public double OptionalDouble {
2000 get { return optionalDouble_; }
2001 }
2002
2003 public const int OptionalBoolFieldNumber = 13;
2004 private bool hasOptionalBool;
csharptestced18e12011-06-09 19:47:56 -05002005 private bool optionalBool_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01002006 public bool HasOptionalBool {
2007 get { return hasOptionalBool; }
2008 }
2009 public bool OptionalBool {
2010 get { return optionalBool_; }
2011 }
2012
2013 public const int OptionalStringFieldNumber = 14;
2014 private bool hasOptionalString;
2015 private string optionalString_ = "";
2016 public bool HasOptionalString {
2017 get { return hasOptionalString; }
2018 }
2019 public string OptionalString {
2020 get { return optionalString_; }
2021 }
2022
2023 public const int OptionalBytesFieldNumber = 15;
2024 private bool hasOptionalBytes;
2025 private pb::ByteString optionalBytes_ = pb::ByteString.Empty;
2026 public bool HasOptionalBytes {
2027 get { return hasOptionalBytes; }
2028 }
2029 public pb::ByteString OptionalBytes {
2030 get { return optionalBytes_; }
2031 }
2032
2033 public const int OptionalGroupFieldNumber = 16;
2034 private bool hasOptionalGroup;
2035 private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance;
2036 public bool HasOptionalGroup {
2037 get { return hasOptionalGroup; }
2038 }
2039 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup OptionalGroup {
2040 get { return optionalGroup_; }
2041 }
2042
2043 public const int OptionalNestedMessageFieldNumber = 18;
2044 private bool hasOptionalNestedMessage;
2045 private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance;
2046 public bool HasOptionalNestedMessage {
2047 get { return hasOptionalNestedMessage; }
2048 }
2049 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage {
2050 get { return optionalNestedMessage_; }
2051 }
2052
2053 public const int OptionalForeignMessageFieldNumber = 19;
2054 private bool hasOptionalForeignMessage;
2055 private global::Google.ProtocolBuffers.TestProtos.ForeignMessage optionalForeignMessage_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance;
2056 public bool HasOptionalForeignMessage {
2057 get { return hasOptionalForeignMessage; }
2058 }
2059 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage {
2060 get { return optionalForeignMessage_; }
2061 }
2062
2063 public const int OptionalImportMessageFieldNumber = 20;
2064 private bool hasOptionalImportMessage;
2065 private global::Google.ProtocolBuffers.TestProtos.ImportMessage optionalImportMessage_ = global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance;
2066 public bool HasOptionalImportMessage {
2067 get { return hasOptionalImportMessage; }
2068 }
2069 public global::Google.ProtocolBuffers.TestProtos.ImportMessage OptionalImportMessage {
2070 get { return optionalImportMessage_; }
2071 }
2072
2073 public const int OptionalNestedEnumFieldNumber = 21;
2074 private bool hasOptionalNestedEnum;
2075 private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO;
2076 public bool HasOptionalNestedEnum {
2077 get { return hasOptionalNestedEnum; }
2078 }
2079 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum {
2080 get { return optionalNestedEnum_; }
2081 }
2082
2083 public const int OptionalForeignEnumFieldNumber = 22;
2084 private bool hasOptionalForeignEnum;
2085 private global::Google.ProtocolBuffers.TestProtos.ForeignEnum optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO;
2086 public bool HasOptionalForeignEnum {
2087 get { return hasOptionalForeignEnum; }
2088 }
2089 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum {
2090 get { return optionalForeignEnum_; }
2091 }
2092
2093 public const int OptionalImportEnumFieldNumber = 23;
2094 private bool hasOptionalImportEnum;
2095 private global::Google.ProtocolBuffers.TestProtos.ImportEnum optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_FOO;
2096 public bool HasOptionalImportEnum {
2097 get { return hasOptionalImportEnum; }
2098 }
2099 public global::Google.ProtocolBuffers.TestProtos.ImportEnum OptionalImportEnum {
2100 get { return optionalImportEnum_; }
2101 }
2102
2103 public const int OptionalStringPieceFieldNumber = 24;
2104 private bool hasOptionalStringPiece;
2105 private string optionalStringPiece_ = "";
2106 public bool HasOptionalStringPiece {
2107 get { return hasOptionalStringPiece; }
2108 }
2109 public string OptionalStringPiece {
2110 get { return optionalStringPiece_; }
2111 }
2112
2113 public const int OptionalCordFieldNumber = 25;
2114 private bool hasOptionalCord;
2115 private string optionalCord_ = "";
2116 public bool HasOptionalCord {
2117 get { return hasOptionalCord; }
2118 }
2119 public string OptionalCord {
2120 get { return optionalCord_; }
2121 }
2122
2123 public const int RepeatedInt32FieldNumber = 31;
2124 private pbc::PopsicleList<int> repeatedInt32_ = new pbc::PopsicleList<int>();
2125 public scg::IList<int> RepeatedInt32List {
2126 get { return pbc::Lists.AsReadOnly(repeatedInt32_); }
2127 }
2128 public int RepeatedInt32Count {
2129 get { return repeatedInt32_.Count; }
2130 }
2131 public int GetRepeatedInt32(int index) {
2132 return repeatedInt32_[index];
2133 }
2134
2135 public const int RepeatedInt64FieldNumber = 32;
2136 private pbc::PopsicleList<long> repeatedInt64_ = new pbc::PopsicleList<long>();
2137 public scg::IList<long> RepeatedInt64List {
2138 get { return pbc::Lists.AsReadOnly(repeatedInt64_); }
2139 }
2140 public int RepeatedInt64Count {
2141 get { return repeatedInt64_.Count; }
2142 }
2143 public long GetRepeatedInt64(int index) {
2144 return repeatedInt64_[index];
2145 }
2146
2147 public const int RepeatedUint32FieldNumber = 33;
2148 private pbc::PopsicleList<uint> repeatedUint32_ = new pbc::PopsicleList<uint>();
2149 [global::System.CLSCompliant(false)]
2150 public scg::IList<uint> RepeatedUint32List {
2151 get { return pbc::Lists.AsReadOnly(repeatedUint32_); }
2152 }
2153 public int RepeatedUint32Count {
2154 get { return repeatedUint32_.Count; }
2155 }
2156 [global::System.CLSCompliant(false)]
2157 public uint GetRepeatedUint32(int index) {
2158 return repeatedUint32_[index];
2159 }
2160
2161 public const int RepeatedUint64FieldNumber = 34;
2162 private pbc::PopsicleList<ulong> repeatedUint64_ = new pbc::PopsicleList<ulong>();
2163 [global::System.CLSCompliant(false)]
2164 public scg::IList<ulong> RepeatedUint64List {
2165 get { return pbc::Lists.AsReadOnly(repeatedUint64_); }
2166 }
2167 public int RepeatedUint64Count {
2168 get { return repeatedUint64_.Count; }
2169 }
2170 [global::System.CLSCompliant(false)]
2171 public ulong GetRepeatedUint64(int index) {
2172 return repeatedUint64_[index];
2173 }
2174
2175 public const int RepeatedSint32FieldNumber = 35;
2176 private pbc::PopsicleList<int> repeatedSint32_ = new pbc::PopsicleList<int>();
2177 public scg::IList<int> RepeatedSint32List {
2178 get { return pbc::Lists.AsReadOnly(repeatedSint32_); }
2179 }
2180 public int RepeatedSint32Count {
2181 get { return repeatedSint32_.Count; }
2182 }
2183 public int GetRepeatedSint32(int index) {
2184 return repeatedSint32_[index];
2185 }
2186
2187 public const int RepeatedSint64FieldNumber = 36;
2188 private pbc::PopsicleList<long> repeatedSint64_ = new pbc::PopsicleList<long>();
2189 public scg::IList<long> RepeatedSint64List {
2190 get { return pbc::Lists.AsReadOnly(repeatedSint64_); }
2191 }
2192 public int RepeatedSint64Count {
2193 get { return repeatedSint64_.Count; }
2194 }
2195 public long GetRepeatedSint64(int index) {
2196 return repeatedSint64_[index];
2197 }
2198
2199 public const int RepeatedFixed32FieldNumber = 37;
2200 private pbc::PopsicleList<uint> repeatedFixed32_ = new pbc::PopsicleList<uint>();
2201 [global::System.CLSCompliant(false)]
2202 public scg::IList<uint> RepeatedFixed32List {
2203 get { return pbc::Lists.AsReadOnly(repeatedFixed32_); }
2204 }
2205 public int RepeatedFixed32Count {
2206 get { return repeatedFixed32_.Count; }
2207 }
2208 [global::System.CLSCompliant(false)]
2209 public uint GetRepeatedFixed32(int index) {
2210 return repeatedFixed32_[index];
2211 }
2212
2213 public const int RepeatedFixed64FieldNumber = 38;
2214 private pbc::PopsicleList<ulong> repeatedFixed64_ = new pbc::PopsicleList<ulong>();
2215 [global::System.CLSCompliant(false)]
2216 public scg::IList<ulong> RepeatedFixed64List {
2217 get { return pbc::Lists.AsReadOnly(repeatedFixed64_); }
2218 }
2219 public int RepeatedFixed64Count {
2220 get { return repeatedFixed64_.Count; }
2221 }
2222 [global::System.CLSCompliant(false)]
2223 public ulong GetRepeatedFixed64(int index) {
2224 return repeatedFixed64_[index];
2225 }
2226
2227 public const int RepeatedSfixed32FieldNumber = 39;
2228 private pbc::PopsicleList<int> repeatedSfixed32_ = new pbc::PopsicleList<int>();
2229 public scg::IList<int> RepeatedSfixed32List {
2230 get { return pbc::Lists.AsReadOnly(repeatedSfixed32_); }
2231 }
2232 public int RepeatedSfixed32Count {
2233 get { return repeatedSfixed32_.Count; }
2234 }
2235 public int GetRepeatedSfixed32(int index) {
2236 return repeatedSfixed32_[index];
2237 }
2238
2239 public const int RepeatedSfixed64FieldNumber = 40;
2240 private pbc::PopsicleList<long> repeatedSfixed64_ = new pbc::PopsicleList<long>();
2241 public scg::IList<long> RepeatedSfixed64List {
2242 get { return pbc::Lists.AsReadOnly(repeatedSfixed64_); }
2243 }
2244 public int RepeatedSfixed64Count {
2245 get { return repeatedSfixed64_.Count; }
2246 }
2247 public long GetRepeatedSfixed64(int index) {
2248 return repeatedSfixed64_[index];
2249 }
2250
2251 public const int RepeatedFloatFieldNumber = 41;
2252 private pbc::PopsicleList<float> repeatedFloat_ = new pbc::PopsicleList<float>();
2253 public scg::IList<float> RepeatedFloatList {
2254 get { return pbc::Lists.AsReadOnly(repeatedFloat_); }
2255 }
2256 public int RepeatedFloatCount {
2257 get { return repeatedFloat_.Count; }
2258 }
2259 public float GetRepeatedFloat(int index) {
2260 return repeatedFloat_[index];
2261 }
2262
2263 public const int RepeatedDoubleFieldNumber = 42;
2264 private pbc::PopsicleList<double> repeatedDouble_ = new pbc::PopsicleList<double>();
2265 public scg::IList<double> RepeatedDoubleList {
2266 get { return pbc::Lists.AsReadOnly(repeatedDouble_); }
2267 }
2268 public int RepeatedDoubleCount {
2269 get { return repeatedDouble_.Count; }
2270 }
2271 public double GetRepeatedDouble(int index) {
2272 return repeatedDouble_[index];
2273 }
2274
2275 public const int RepeatedBoolFieldNumber = 43;
2276 private pbc::PopsicleList<bool> repeatedBool_ = new pbc::PopsicleList<bool>();
2277 public scg::IList<bool> RepeatedBoolList {
2278 get { return pbc::Lists.AsReadOnly(repeatedBool_); }
2279 }
2280 public int RepeatedBoolCount {
2281 get { return repeatedBool_.Count; }
2282 }
2283 public bool GetRepeatedBool(int index) {
2284 return repeatedBool_[index];
2285 }
2286
2287 public const int RepeatedStringFieldNumber = 44;
2288 private pbc::PopsicleList<string> repeatedString_ = new pbc::PopsicleList<string>();
2289 public scg::IList<string> RepeatedStringList {
2290 get { return pbc::Lists.AsReadOnly(repeatedString_); }
2291 }
2292 public int RepeatedStringCount {
2293 get { return repeatedString_.Count; }
2294 }
2295 public string GetRepeatedString(int index) {
2296 return repeatedString_[index];
2297 }
2298
2299 public const int RepeatedBytesFieldNumber = 45;
2300 private pbc::PopsicleList<pb::ByteString> repeatedBytes_ = new pbc::PopsicleList<pb::ByteString>();
2301 public scg::IList<pb::ByteString> RepeatedBytesList {
2302 get { return pbc::Lists.AsReadOnly(repeatedBytes_); }
2303 }
2304 public int RepeatedBytesCount {
2305 get { return repeatedBytes_.Count; }
2306 }
2307 public pb::ByteString GetRepeatedBytes(int index) {
2308 return repeatedBytes_[index];
2309 }
2310
2311 public const int RepeatedGroupFieldNumber = 46;
2312 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup> repeatedGroup_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup>();
2313 public scg::IList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup> RepeatedGroupList {
2314 get { return repeatedGroup_; }
2315 }
2316 public int RepeatedGroupCount {
2317 get { return repeatedGroup_.Count; }
2318 }
2319 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup GetRepeatedGroup(int index) {
2320 return repeatedGroup_[index];
2321 }
2322
2323 public const int RepeatedNestedMessageFieldNumber = 48;
2324 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage> repeatedNestedMessage_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage>();
2325 public scg::IList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage> RepeatedNestedMessageList {
2326 get { return repeatedNestedMessage_; }
2327 }
2328 public int RepeatedNestedMessageCount {
2329 get { return repeatedNestedMessage_.Count; }
2330 }
2331 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) {
2332 return repeatedNestedMessage_[index];
2333 }
2334
2335 public const int RepeatedForeignMessageFieldNumber = 49;
2336 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> repeatedForeignMessage_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage>();
2337 public scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> RepeatedForeignMessageList {
2338 get { return repeatedForeignMessage_; }
2339 }
2340 public int RepeatedForeignMessageCount {
2341 get { return repeatedForeignMessage_.Count; }
2342 }
2343 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) {
2344 return repeatedForeignMessage_[index];
2345 }
2346
2347 public const int RepeatedImportMessageFieldNumber = 50;
2348 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ImportMessage> repeatedImportMessage_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ImportMessage>();
2349 public scg::IList<global::Google.ProtocolBuffers.TestProtos.ImportMessage> RepeatedImportMessageList {
2350 get { return repeatedImportMessage_; }
2351 }
2352 public int RepeatedImportMessageCount {
2353 get { return repeatedImportMessage_.Count; }
2354 }
2355 public global::Google.ProtocolBuffers.TestProtos.ImportMessage GetRepeatedImportMessage(int index) {
2356 return repeatedImportMessage_[index];
2357 }
2358
2359 public const int RepeatedNestedEnumFieldNumber = 51;
2360 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum> repeatedNestedEnum_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum>();
2361 public scg::IList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum> RepeatedNestedEnumList {
2362 get { return pbc::Lists.AsReadOnly(repeatedNestedEnum_); }
2363 }
2364 public int RepeatedNestedEnumCount {
2365 get { return repeatedNestedEnum_.Count; }
2366 }
2367 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) {
2368 return repeatedNestedEnum_[index];
2369 }
2370
2371 public const int RepeatedForeignEnumFieldNumber = 52;
2372 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> repeatedForeignEnum_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>();
2373 public scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> RepeatedForeignEnumList {
2374 get { return pbc::Lists.AsReadOnly(repeatedForeignEnum_); }
2375 }
2376 public int RepeatedForeignEnumCount {
2377 get { return repeatedForeignEnum_.Count; }
2378 }
2379 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) {
2380 return repeatedForeignEnum_[index];
2381 }
2382
2383 public const int RepeatedImportEnumFieldNumber = 53;
2384 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ImportEnum> repeatedImportEnum_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ImportEnum>();
2385 public scg::IList<global::Google.ProtocolBuffers.TestProtos.ImportEnum> RepeatedImportEnumList {
2386 get { return pbc::Lists.AsReadOnly(repeatedImportEnum_); }
2387 }
2388 public int RepeatedImportEnumCount {
2389 get { return repeatedImportEnum_.Count; }
2390 }
2391 public global::Google.ProtocolBuffers.TestProtos.ImportEnum GetRepeatedImportEnum(int index) {
2392 return repeatedImportEnum_[index];
2393 }
2394
2395 public const int RepeatedStringPieceFieldNumber = 54;
2396 private pbc::PopsicleList<string> repeatedStringPiece_ = new pbc::PopsicleList<string>();
2397 public scg::IList<string> RepeatedStringPieceList {
2398 get { return pbc::Lists.AsReadOnly(repeatedStringPiece_); }
2399 }
2400 public int RepeatedStringPieceCount {
2401 get { return repeatedStringPiece_.Count; }
2402 }
2403 public string GetRepeatedStringPiece(int index) {
2404 return repeatedStringPiece_[index];
2405 }
2406
2407 public const int RepeatedCordFieldNumber = 55;
2408 private pbc::PopsicleList<string> repeatedCord_ = new pbc::PopsicleList<string>();
2409 public scg::IList<string> RepeatedCordList {
2410 get { return pbc::Lists.AsReadOnly(repeatedCord_); }
2411 }
2412 public int RepeatedCordCount {
2413 get { return repeatedCord_.Count; }
2414 }
2415 public string GetRepeatedCord(int index) {
2416 return repeatedCord_[index];
2417 }
2418
2419 public const int DefaultInt32FieldNumber = 61;
2420 private bool hasDefaultInt32;
2421 private int defaultInt32_ = 41;
2422 public bool HasDefaultInt32 {
2423 get { return hasDefaultInt32; }
2424 }
2425 public int DefaultInt32 {
2426 get { return defaultInt32_; }
2427 }
2428
2429 public const int DefaultInt64FieldNumber = 62;
2430 private bool hasDefaultInt64;
2431 private long defaultInt64_ = 42L;
2432 public bool HasDefaultInt64 {
2433 get { return hasDefaultInt64; }
2434 }
2435 public long DefaultInt64 {
2436 get { return defaultInt64_; }
2437 }
2438
2439 public const int DefaultUint32FieldNumber = 63;
2440 private bool hasDefaultUint32;
2441 private uint defaultUint32_ = 43;
2442 public bool HasDefaultUint32 {
2443 get { return hasDefaultUint32; }
2444 }
2445 [global::System.CLSCompliant(false)]
2446 public uint DefaultUint32 {
2447 get { return defaultUint32_; }
2448 }
2449
2450 public const int DefaultUint64FieldNumber = 64;
2451 private bool hasDefaultUint64;
2452 private ulong defaultUint64_ = 44UL;
2453 public bool HasDefaultUint64 {
2454 get { return hasDefaultUint64; }
2455 }
2456 [global::System.CLSCompliant(false)]
2457 public ulong DefaultUint64 {
2458 get { return defaultUint64_; }
2459 }
2460
2461 public const int DefaultSint32FieldNumber = 65;
2462 private bool hasDefaultSint32;
2463 private int defaultSint32_ = -45;
2464 public bool HasDefaultSint32 {
2465 get { return hasDefaultSint32; }
2466 }
2467 public int DefaultSint32 {
2468 get { return defaultSint32_; }
2469 }
2470
2471 public const int DefaultSint64FieldNumber = 66;
2472 private bool hasDefaultSint64;
2473 private long defaultSint64_ = 46;
2474 public bool HasDefaultSint64 {
2475 get { return hasDefaultSint64; }
2476 }
2477 public long DefaultSint64 {
2478 get { return defaultSint64_; }
2479 }
2480
2481 public const int DefaultFixed32FieldNumber = 67;
2482 private bool hasDefaultFixed32;
2483 private uint defaultFixed32_ = 47;
2484 public bool HasDefaultFixed32 {
2485 get { return hasDefaultFixed32; }
2486 }
2487 [global::System.CLSCompliant(false)]
2488 public uint DefaultFixed32 {
2489 get { return defaultFixed32_; }
2490 }
2491
2492 public const int DefaultFixed64FieldNumber = 68;
2493 private bool hasDefaultFixed64;
2494 private ulong defaultFixed64_ = 48;
2495 public bool HasDefaultFixed64 {
2496 get { return hasDefaultFixed64; }
2497 }
2498 [global::System.CLSCompliant(false)]
2499 public ulong DefaultFixed64 {
2500 get { return defaultFixed64_; }
2501 }
2502
2503 public const int DefaultSfixed32FieldNumber = 69;
2504 private bool hasDefaultSfixed32;
2505 private int defaultSfixed32_ = 49;
2506 public bool HasDefaultSfixed32 {
2507 get { return hasDefaultSfixed32; }
2508 }
2509 public int DefaultSfixed32 {
2510 get { return defaultSfixed32_; }
2511 }
2512
2513 public const int DefaultSfixed64FieldNumber = 70;
2514 private bool hasDefaultSfixed64;
2515 private long defaultSfixed64_ = -50;
2516 public bool HasDefaultSfixed64 {
2517 get { return hasDefaultSfixed64; }
2518 }
2519 public long DefaultSfixed64 {
2520 get { return defaultSfixed64_; }
2521 }
2522
2523 public const int DefaultFloatFieldNumber = 71;
2524 private bool hasDefaultFloat;
2525 private float defaultFloat_ = 51.5F;
2526 public bool HasDefaultFloat {
2527 get { return hasDefaultFloat; }
2528 }
2529 public float DefaultFloat {
2530 get { return defaultFloat_; }
2531 }
2532
2533 public const int DefaultDoubleFieldNumber = 72;
2534 private bool hasDefaultDouble;
2535 private double defaultDouble_ = 52000D;
2536 public bool HasDefaultDouble {
2537 get { return hasDefaultDouble; }
2538 }
2539 public double DefaultDouble {
2540 get { return defaultDouble_; }
2541 }
2542
2543 public const int DefaultBoolFieldNumber = 73;
2544 private bool hasDefaultBool;
2545 private bool defaultBool_ = true;
2546 public bool HasDefaultBool {
2547 get { return hasDefaultBool; }
2548 }
2549 public bool DefaultBool {
2550 get { return defaultBool_; }
2551 }
2552
2553 public const int DefaultStringFieldNumber = 74;
2554 private bool hasDefaultString;
2555 private string defaultString_ = "hello";
2556 public bool HasDefaultString {
2557 get { return hasDefaultString; }
2558 }
2559 public string DefaultString {
2560 get { return defaultString_; }
2561 }
2562
2563 public const int DefaultBytesFieldNumber = 75;
2564 private bool hasDefaultBytes;
2565 private pb::ByteString defaultBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor.Fields[62].DefaultValue;
2566 public bool HasDefaultBytes {
2567 get { return hasDefaultBytes; }
2568 }
2569 public pb::ByteString DefaultBytes {
2570 get { return defaultBytes_; }
2571 }
2572
2573 public const int DefaultNestedEnumFieldNumber = 81;
2574 private bool hasDefaultNestedEnum;
2575 private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.BAR;
2576 public bool HasDefaultNestedEnum {
2577 get { return hasDefaultNestedEnum; }
2578 }
2579 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum DefaultNestedEnum {
2580 get { return defaultNestedEnum_; }
2581 }
2582
2583 public const int DefaultForeignEnumFieldNumber = 82;
2584 private bool hasDefaultForeignEnum;
2585 private global::Google.ProtocolBuffers.TestProtos.ForeignEnum defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_BAR;
2586 public bool HasDefaultForeignEnum {
2587 get { return hasDefaultForeignEnum; }
2588 }
2589 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum DefaultForeignEnum {
2590 get { return defaultForeignEnum_; }
2591 }
2592
2593 public const int DefaultImportEnumFieldNumber = 83;
2594 private bool hasDefaultImportEnum;
2595 private global::Google.ProtocolBuffers.TestProtos.ImportEnum defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_BAR;
2596 public bool HasDefaultImportEnum {
2597 get { return hasDefaultImportEnum; }
2598 }
2599 public global::Google.ProtocolBuffers.TestProtos.ImportEnum DefaultImportEnum {
2600 get { return defaultImportEnum_; }
2601 }
2602
2603 public const int DefaultStringPieceFieldNumber = 84;
2604 private bool hasDefaultStringPiece;
2605 private string defaultStringPiece_ = "abc";
2606 public bool HasDefaultStringPiece {
2607 get { return hasDefaultStringPiece; }
2608 }
2609 public string DefaultStringPiece {
2610 get { return defaultStringPiece_; }
2611 }
2612
2613 public const int DefaultCordFieldNumber = 85;
2614 private bool hasDefaultCord;
2615 private string defaultCord_ = "123";
2616 public bool HasDefaultCord {
2617 get { return hasDefaultCord; }
2618 }
2619 public string DefaultCord {
2620 get { return defaultCord_; }
2621 }
2622
2623 public override bool IsInitialized {
2624 get {
2625 return true;
2626 }
2627 }
2628
csharptestffafdaa2011-06-03 12:58:14 -05002629 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002630 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05002631 string[] field_names = _testAllTypesFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05002632 if (hasOptionalInt32) {
csharptest920b09a2011-06-08 20:13:29 -05002633 output.WriteInt32(1, field_names[31], OptionalInt32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002634 }
csharptestc671a4b2011-06-08 11:51:24 -05002635 if (hasOptionalInt64) {
csharptest920b09a2011-06-08 20:13:29 -05002636 output.WriteInt64(2, field_names[32], OptionalInt64);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002637 }
csharptestc671a4b2011-06-08 11:51:24 -05002638 if (hasOptionalUint32) {
csharptest920b09a2011-06-08 20:13:29 -05002639 output.WriteUInt32(3, field_names[41], OptionalUint32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002640 }
csharptestc671a4b2011-06-08 11:51:24 -05002641 if (hasOptionalUint64) {
csharptest920b09a2011-06-08 20:13:29 -05002642 output.WriteUInt64(4, field_names[42], OptionalUint64);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002643 }
csharptestc671a4b2011-06-08 11:51:24 -05002644 if (hasOptionalSint32) {
csharptest920b09a2011-06-08 20:13:29 -05002645 output.WriteSInt32(5, field_names[37], OptionalSint32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002646 }
csharptestc671a4b2011-06-08 11:51:24 -05002647 if (hasOptionalSint64) {
csharptest920b09a2011-06-08 20:13:29 -05002648 output.WriteSInt64(6, field_names[38], OptionalSint64);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002649 }
csharptestc671a4b2011-06-08 11:51:24 -05002650 if (hasOptionalFixed32) {
csharptest920b09a2011-06-08 20:13:29 -05002651 output.WriteFixed32(7, field_names[24], OptionalFixed32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002652 }
csharptestc671a4b2011-06-08 11:51:24 -05002653 if (hasOptionalFixed64) {
csharptest920b09a2011-06-08 20:13:29 -05002654 output.WriteFixed64(8, field_names[25], OptionalFixed64);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002655 }
csharptestc671a4b2011-06-08 11:51:24 -05002656 if (hasOptionalSfixed32) {
csharptest920b09a2011-06-08 20:13:29 -05002657 output.WriteSFixed32(9, field_names[35], OptionalSfixed32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002658 }
csharptestc671a4b2011-06-08 11:51:24 -05002659 if (hasOptionalSfixed64) {
csharptest920b09a2011-06-08 20:13:29 -05002660 output.WriteSFixed64(10, field_names[36], OptionalSfixed64);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002661 }
csharptestc671a4b2011-06-08 11:51:24 -05002662 if (hasOptionalFloat) {
csharptest920b09a2011-06-08 20:13:29 -05002663 output.WriteFloat(11, field_names[26], OptionalFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002664 }
csharptestc671a4b2011-06-08 11:51:24 -05002665 if (hasOptionalDouble) {
csharptest920b09a2011-06-08 20:13:29 -05002666 output.WriteDouble(12, field_names[23], OptionalDouble);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002667 }
csharptestc671a4b2011-06-08 11:51:24 -05002668 if (hasOptionalBool) {
csharptest920b09a2011-06-08 20:13:29 -05002669 output.WriteBool(13, field_names[20], OptionalBool);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002670 }
csharptestc671a4b2011-06-08 11:51:24 -05002671 if (hasOptionalString) {
csharptest920b09a2011-06-08 20:13:29 -05002672 output.WriteString(14, field_names[39], OptionalString);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002673 }
csharptestc671a4b2011-06-08 11:51:24 -05002674 if (hasOptionalBytes) {
csharptest920b09a2011-06-08 20:13:29 -05002675 output.WriteBytes(15, field_names[21], OptionalBytes);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002676 }
csharptestc671a4b2011-06-08 11:51:24 -05002677 if (hasOptionalGroup) {
csharptest920b09a2011-06-08 20:13:29 -05002678 output.WriteGroup(16, field_names[43], OptionalGroup);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002679 }
csharptestc671a4b2011-06-08 11:51:24 -05002680 if (hasOptionalNestedMessage) {
csharptest920b09a2011-06-08 20:13:29 -05002681 output.WriteMessage(18, field_names[34], OptionalNestedMessage);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002682 }
csharptestc671a4b2011-06-08 11:51:24 -05002683 if (hasOptionalForeignMessage) {
csharptest920b09a2011-06-08 20:13:29 -05002684 output.WriteMessage(19, field_names[28], OptionalForeignMessage);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002685 }
csharptestc671a4b2011-06-08 11:51:24 -05002686 if (hasOptionalImportMessage) {
csharptest920b09a2011-06-08 20:13:29 -05002687 output.WriteMessage(20, field_names[30], OptionalImportMessage);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002688 }
csharptestc671a4b2011-06-08 11:51:24 -05002689 if (hasOptionalNestedEnum) {
csharptestced18e12011-06-09 19:47:56 -05002690 output.WriteEnum(21, field_names[33], (int) OptionalNestedEnum, OptionalNestedEnum);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002691 }
csharptestc671a4b2011-06-08 11:51:24 -05002692 if (hasOptionalForeignEnum) {
csharptestced18e12011-06-09 19:47:56 -05002693 output.WriteEnum(22, field_names[27], (int) OptionalForeignEnum, OptionalForeignEnum);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002694 }
csharptestc671a4b2011-06-08 11:51:24 -05002695 if (hasOptionalImportEnum) {
csharptestced18e12011-06-09 19:47:56 -05002696 output.WriteEnum(23, field_names[29], (int) OptionalImportEnum, OptionalImportEnum);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002697 }
csharptestc671a4b2011-06-08 11:51:24 -05002698 if (hasOptionalStringPiece) {
csharptest920b09a2011-06-08 20:13:29 -05002699 output.WriteString(24, field_names[40], OptionalStringPiece);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002700 }
csharptestc671a4b2011-06-08 11:51:24 -05002701 if (hasOptionalCord) {
csharptest920b09a2011-06-08 20:13:29 -05002702 output.WriteString(25, field_names[22], OptionalCord);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002703 }
2704 if (repeatedInt32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002705 output.WriteArray(pbd::FieldType.Int32, 31, field_names[55], repeatedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002706 }
2707 if (repeatedInt64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002708 output.WriteArray(pbd::FieldType.Int64, 32, field_names[56], repeatedInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002709 }
2710 if (repeatedUint32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002711 output.WriteArray(pbd::FieldType.UInt32, 33, field_names[65], repeatedUint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002712 }
2713 if (repeatedUint64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002714 output.WriteArray(pbd::FieldType.UInt64, 34, field_names[66], repeatedUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002715 }
2716 if (repeatedSint32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002717 output.WriteArray(pbd::FieldType.SInt32, 35, field_names[61], repeatedSint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002718 }
2719 if (repeatedSint64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002720 output.WriteArray(pbd::FieldType.SInt64, 36, field_names[62], repeatedSint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002721 }
2722 if (repeatedFixed32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002723 output.WriteArray(pbd::FieldType.Fixed32, 37, field_names[48], repeatedFixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002724 }
2725 if (repeatedFixed64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002726 output.WriteArray(pbd::FieldType.Fixed64, 38, field_names[49], repeatedFixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002727 }
2728 if (repeatedSfixed32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002729 output.WriteArray(pbd::FieldType.SFixed32, 39, field_names[59], repeatedSfixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002730 }
2731 if (repeatedSfixed64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002732 output.WriteArray(pbd::FieldType.SFixed64, 40, field_names[60], repeatedSfixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002733 }
2734 if (repeatedFloat_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002735 output.WriteArray(pbd::FieldType.Float, 41, field_names[50], repeatedFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002736 }
2737 if (repeatedDouble_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002738 output.WriteArray(pbd::FieldType.Double, 42, field_names[47], repeatedDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002739 }
2740 if (repeatedBool_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002741 output.WriteArray(pbd::FieldType.Bool, 43, field_names[44], repeatedBool_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002742 }
2743 if (repeatedString_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002744 output.WriteArray(pbd::FieldType.String, 44, field_names[63], repeatedString_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002745 }
2746 if (repeatedBytes_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002747 output.WriteArray(pbd::FieldType.Bytes, 45, field_names[45], repeatedBytes_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002748 }
csharptest90922db2011-06-03 11:57:47 -05002749 if (repeatedGroup_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002750 output.WriteArray(pbd::FieldType.Group, 46, field_names[67], repeatedGroup_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002751 }
csharptest90922db2011-06-03 11:57:47 -05002752 if (repeatedNestedMessage_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002753 output.WriteArray(pbd::FieldType.Message, 48, field_names[58], repeatedNestedMessage_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002754 }
csharptest90922db2011-06-03 11:57:47 -05002755 if (repeatedForeignMessage_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002756 output.WriteArray(pbd::FieldType.Message, 49, field_names[52], repeatedForeignMessage_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002757 }
csharptest90922db2011-06-03 11:57:47 -05002758 if (repeatedImportMessage_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002759 output.WriteArray(pbd::FieldType.Message, 50, field_names[54], repeatedImportMessage_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002760 }
2761 if (repeatedNestedEnum_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002762 output.WriteArray(pbd::FieldType.Enum, 51, field_names[57], repeatedNestedEnum_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002763 }
2764 if (repeatedForeignEnum_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002765 output.WriteArray(pbd::FieldType.Enum, 52, field_names[51], repeatedForeignEnum_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002766 }
2767 if (repeatedImportEnum_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002768 output.WriteArray(pbd::FieldType.Enum, 53, field_names[53], repeatedImportEnum_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002769 }
2770 if (repeatedStringPiece_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002771 output.WriteArray(pbd::FieldType.String, 54, field_names[64], repeatedStringPiece_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002772 }
2773 if (repeatedCord_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05002774 output.WriteArray(pbd::FieldType.String, 55, field_names[46], repeatedCord_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002775 }
csharptestc671a4b2011-06-08 11:51:24 -05002776 if (hasDefaultInt32) {
csharptest920b09a2011-06-08 20:13:29 -05002777 output.WriteInt32(61, field_names[9], DefaultInt32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002778 }
csharptestc671a4b2011-06-08 11:51:24 -05002779 if (hasDefaultInt64) {
csharptest920b09a2011-06-08 20:13:29 -05002780 output.WriteInt64(62, field_names[10], DefaultInt64);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002781 }
csharptestc671a4b2011-06-08 11:51:24 -05002782 if (hasDefaultUint32) {
csharptest920b09a2011-06-08 20:13:29 -05002783 output.WriteUInt32(63, field_names[18], DefaultUint32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002784 }
csharptestc671a4b2011-06-08 11:51:24 -05002785 if (hasDefaultUint64) {
csharptest920b09a2011-06-08 20:13:29 -05002786 output.WriteUInt64(64, field_names[19], DefaultUint64);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002787 }
csharptestc671a4b2011-06-08 11:51:24 -05002788 if (hasDefaultSint32) {
csharptest920b09a2011-06-08 20:13:29 -05002789 output.WriteSInt32(65, field_names[14], DefaultSint32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002790 }
csharptestc671a4b2011-06-08 11:51:24 -05002791 if (hasDefaultSint64) {
csharptest920b09a2011-06-08 20:13:29 -05002792 output.WriteSInt64(66, field_names[15], DefaultSint64);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002793 }
csharptestc671a4b2011-06-08 11:51:24 -05002794 if (hasDefaultFixed32) {
csharptest920b09a2011-06-08 20:13:29 -05002795 output.WriteFixed32(67, field_names[4], DefaultFixed32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002796 }
csharptestc671a4b2011-06-08 11:51:24 -05002797 if (hasDefaultFixed64) {
csharptest920b09a2011-06-08 20:13:29 -05002798 output.WriteFixed64(68, field_names[5], DefaultFixed64);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002799 }
csharptestc671a4b2011-06-08 11:51:24 -05002800 if (hasDefaultSfixed32) {
csharptest920b09a2011-06-08 20:13:29 -05002801 output.WriteSFixed32(69, field_names[12], DefaultSfixed32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002802 }
csharptestc671a4b2011-06-08 11:51:24 -05002803 if (hasDefaultSfixed64) {
csharptest920b09a2011-06-08 20:13:29 -05002804 output.WriteSFixed64(70, field_names[13], DefaultSfixed64);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002805 }
csharptestc671a4b2011-06-08 11:51:24 -05002806 if (hasDefaultFloat) {
csharptest920b09a2011-06-08 20:13:29 -05002807 output.WriteFloat(71, field_names[6], DefaultFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002808 }
csharptestc671a4b2011-06-08 11:51:24 -05002809 if (hasDefaultDouble) {
csharptest920b09a2011-06-08 20:13:29 -05002810 output.WriteDouble(72, field_names[3], DefaultDouble);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002811 }
csharptestc671a4b2011-06-08 11:51:24 -05002812 if (hasDefaultBool) {
csharptest920b09a2011-06-08 20:13:29 -05002813 output.WriteBool(73, field_names[0], DefaultBool);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002814 }
csharptestc671a4b2011-06-08 11:51:24 -05002815 if (hasDefaultString) {
csharptest920b09a2011-06-08 20:13:29 -05002816 output.WriteString(74, field_names[16], DefaultString);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002817 }
csharptestc671a4b2011-06-08 11:51:24 -05002818 if (hasDefaultBytes) {
csharptest920b09a2011-06-08 20:13:29 -05002819 output.WriteBytes(75, field_names[1], DefaultBytes);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002820 }
csharptestc671a4b2011-06-08 11:51:24 -05002821 if (hasDefaultNestedEnum) {
csharptestced18e12011-06-09 19:47:56 -05002822 output.WriteEnum(81, field_names[11], (int) DefaultNestedEnum, DefaultNestedEnum);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002823 }
csharptestc671a4b2011-06-08 11:51:24 -05002824 if (hasDefaultForeignEnum) {
csharptestced18e12011-06-09 19:47:56 -05002825 output.WriteEnum(82, field_names[7], (int) DefaultForeignEnum, DefaultForeignEnum);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002826 }
csharptestc671a4b2011-06-08 11:51:24 -05002827 if (hasDefaultImportEnum) {
csharptestced18e12011-06-09 19:47:56 -05002828 output.WriteEnum(83, field_names[8], (int) DefaultImportEnum, DefaultImportEnum);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002829 }
csharptestc671a4b2011-06-08 11:51:24 -05002830 if (hasDefaultStringPiece) {
csharptest920b09a2011-06-08 20:13:29 -05002831 output.WriteString(84, field_names[17], DefaultStringPiece);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002832 }
csharptestc671a4b2011-06-08 11:51:24 -05002833 if (hasDefaultCord) {
csharptest920b09a2011-06-08 20:13:29 -05002834 output.WriteString(85, field_names[2], DefaultCord);
Jon Skeet82bb0f12011-04-03 20:17:12 +01002835 }
2836 UnknownFields.WriteTo(output);
2837 }
2838
2839 private int memoizedSerializedSize = -1;
2840 public override int SerializedSize {
2841 get {
2842 int size = memoizedSerializedSize;
2843 if (size != -1) return size;
2844
2845 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05002846 if (hasOptionalInt32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002847 size += pb::CodedOutputStream.ComputeInt32Size(1, OptionalInt32);
2848 }
csharptestc671a4b2011-06-08 11:51:24 -05002849 if (hasOptionalInt64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002850 size += pb::CodedOutputStream.ComputeInt64Size(2, OptionalInt64);
2851 }
csharptestc671a4b2011-06-08 11:51:24 -05002852 if (hasOptionalUint32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002853 size += pb::CodedOutputStream.ComputeUInt32Size(3, OptionalUint32);
2854 }
csharptestc671a4b2011-06-08 11:51:24 -05002855 if (hasOptionalUint64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002856 size += pb::CodedOutputStream.ComputeUInt64Size(4, OptionalUint64);
2857 }
csharptestc671a4b2011-06-08 11:51:24 -05002858 if (hasOptionalSint32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002859 size += pb::CodedOutputStream.ComputeSInt32Size(5, OptionalSint32);
2860 }
csharptestc671a4b2011-06-08 11:51:24 -05002861 if (hasOptionalSint64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002862 size += pb::CodedOutputStream.ComputeSInt64Size(6, OptionalSint64);
2863 }
csharptestc671a4b2011-06-08 11:51:24 -05002864 if (hasOptionalFixed32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002865 size += pb::CodedOutputStream.ComputeFixed32Size(7, OptionalFixed32);
2866 }
csharptestc671a4b2011-06-08 11:51:24 -05002867 if (hasOptionalFixed64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002868 size += pb::CodedOutputStream.ComputeFixed64Size(8, OptionalFixed64);
2869 }
csharptestc671a4b2011-06-08 11:51:24 -05002870 if (hasOptionalSfixed32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002871 size += pb::CodedOutputStream.ComputeSFixed32Size(9, OptionalSfixed32);
2872 }
csharptestc671a4b2011-06-08 11:51:24 -05002873 if (hasOptionalSfixed64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002874 size += pb::CodedOutputStream.ComputeSFixed64Size(10, OptionalSfixed64);
2875 }
csharptestc671a4b2011-06-08 11:51:24 -05002876 if (hasOptionalFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002877 size += pb::CodedOutputStream.ComputeFloatSize(11, OptionalFloat);
2878 }
csharptestc671a4b2011-06-08 11:51:24 -05002879 if (hasOptionalDouble) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002880 size += pb::CodedOutputStream.ComputeDoubleSize(12, OptionalDouble);
2881 }
csharptestc671a4b2011-06-08 11:51:24 -05002882 if (hasOptionalBool) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002883 size += pb::CodedOutputStream.ComputeBoolSize(13, OptionalBool);
2884 }
csharptestc671a4b2011-06-08 11:51:24 -05002885 if (hasOptionalString) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002886 size += pb::CodedOutputStream.ComputeStringSize(14, OptionalString);
2887 }
csharptestc671a4b2011-06-08 11:51:24 -05002888 if (hasOptionalBytes) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002889 size += pb::CodedOutputStream.ComputeBytesSize(15, OptionalBytes);
2890 }
csharptestc671a4b2011-06-08 11:51:24 -05002891 if (hasOptionalGroup) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002892 size += pb::CodedOutputStream.ComputeGroupSize(16, OptionalGroup);
2893 }
csharptestc671a4b2011-06-08 11:51:24 -05002894 if (hasOptionalNestedMessage) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002895 size += pb::CodedOutputStream.ComputeMessageSize(18, OptionalNestedMessage);
2896 }
csharptestc671a4b2011-06-08 11:51:24 -05002897 if (hasOptionalForeignMessage) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002898 size += pb::CodedOutputStream.ComputeMessageSize(19, OptionalForeignMessage);
2899 }
csharptestc671a4b2011-06-08 11:51:24 -05002900 if (hasOptionalImportMessage) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002901 size += pb::CodedOutputStream.ComputeMessageSize(20, OptionalImportMessage);
2902 }
csharptestc671a4b2011-06-08 11:51:24 -05002903 if (hasOptionalNestedEnum) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002904 size += pb::CodedOutputStream.ComputeEnumSize(21, (int) OptionalNestedEnum);
2905 }
csharptestc671a4b2011-06-08 11:51:24 -05002906 if (hasOptionalForeignEnum) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002907 size += pb::CodedOutputStream.ComputeEnumSize(22, (int) OptionalForeignEnum);
2908 }
csharptestc671a4b2011-06-08 11:51:24 -05002909 if (hasOptionalImportEnum) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002910 size += pb::CodedOutputStream.ComputeEnumSize(23, (int) OptionalImportEnum);
2911 }
csharptestc671a4b2011-06-08 11:51:24 -05002912 if (hasOptionalStringPiece) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002913 size += pb::CodedOutputStream.ComputeStringSize(24, OptionalStringPiece);
2914 }
csharptestc671a4b2011-06-08 11:51:24 -05002915 if (hasOptionalCord) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01002916 size += pb::CodedOutputStream.ComputeStringSize(25, OptionalCord);
2917 }
2918 {
2919 int dataSize = 0;
2920 foreach (int element in RepeatedInt32List) {
2921 dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element);
2922 }
2923 size += dataSize;
2924 size += 2 * repeatedInt32_.Count;
2925 }
2926 {
2927 int dataSize = 0;
2928 foreach (long element in RepeatedInt64List) {
2929 dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element);
2930 }
2931 size += dataSize;
2932 size += 2 * repeatedInt64_.Count;
2933 }
2934 {
2935 int dataSize = 0;
2936 foreach (uint element in RepeatedUint32List) {
2937 dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element);
2938 }
2939 size += dataSize;
2940 size += 2 * repeatedUint32_.Count;
2941 }
2942 {
2943 int dataSize = 0;
2944 foreach (ulong element in RepeatedUint64List) {
2945 dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element);
2946 }
2947 size += dataSize;
2948 size += 2 * repeatedUint64_.Count;
2949 }
2950 {
2951 int dataSize = 0;
2952 foreach (int element in RepeatedSint32List) {
2953 dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element);
2954 }
2955 size += dataSize;
2956 size += 2 * repeatedSint32_.Count;
2957 }
2958 {
2959 int dataSize = 0;
2960 foreach (long element in RepeatedSint64List) {
2961 dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element);
2962 }
2963 size += dataSize;
2964 size += 2 * repeatedSint64_.Count;
2965 }
2966 {
2967 int dataSize = 0;
2968 dataSize = 4 * repeatedFixed32_.Count;
2969 size += dataSize;
2970 size += 2 * repeatedFixed32_.Count;
2971 }
2972 {
2973 int dataSize = 0;
2974 dataSize = 8 * repeatedFixed64_.Count;
2975 size += dataSize;
2976 size += 2 * repeatedFixed64_.Count;
2977 }
2978 {
2979 int dataSize = 0;
2980 dataSize = 4 * repeatedSfixed32_.Count;
2981 size += dataSize;
2982 size += 2 * repeatedSfixed32_.Count;
2983 }
2984 {
2985 int dataSize = 0;
2986 dataSize = 8 * repeatedSfixed64_.Count;
2987 size += dataSize;
2988 size += 2 * repeatedSfixed64_.Count;
2989 }
2990 {
2991 int dataSize = 0;
2992 dataSize = 4 * repeatedFloat_.Count;
2993 size += dataSize;
2994 size += 2 * repeatedFloat_.Count;
2995 }
2996 {
2997 int dataSize = 0;
2998 dataSize = 8 * repeatedDouble_.Count;
2999 size += dataSize;
3000 size += 2 * repeatedDouble_.Count;
3001 }
3002 {
3003 int dataSize = 0;
3004 dataSize = 1 * repeatedBool_.Count;
3005 size += dataSize;
3006 size += 2 * repeatedBool_.Count;
3007 }
3008 {
3009 int dataSize = 0;
3010 foreach (string element in RepeatedStringList) {
3011 dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element);
3012 }
3013 size += dataSize;
3014 size += 2 * repeatedString_.Count;
3015 }
3016 {
3017 int dataSize = 0;
3018 foreach (pb::ByteString element in RepeatedBytesList) {
3019 dataSize += pb::CodedOutputStream.ComputeBytesSizeNoTag(element);
3020 }
3021 size += dataSize;
3022 size += 2 * repeatedBytes_.Count;
3023 }
3024 foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup element in RepeatedGroupList) {
3025 size += pb::CodedOutputStream.ComputeGroupSize(46, element);
3026 }
3027 foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage element in RepeatedNestedMessageList) {
3028 size += pb::CodedOutputStream.ComputeMessageSize(48, element);
3029 }
3030 foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedForeignMessageList) {
3031 size += pb::CodedOutputStream.ComputeMessageSize(49, element);
3032 }
3033 foreach (global::Google.ProtocolBuffers.TestProtos.ImportMessage element in RepeatedImportMessageList) {
3034 size += pb::CodedOutputStream.ComputeMessageSize(50, element);
3035 }
3036 {
3037 int dataSize = 0;
3038 if (repeatedNestedEnum_.Count > 0) {
3039 foreach (global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum element in repeatedNestedEnum_) {
3040 dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element);
3041 }
3042 size += dataSize;
3043 size += 2 * repeatedNestedEnum_.Count;
3044 }
3045 }
3046 {
3047 int dataSize = 0;
3048 if (repeatedForeignEnum_.Count > 0) {
3049 foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedForeignEnum_) {
3050 dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element);
3051 }
3052 size += dataSize;
3053 size += 2 * repeatedForeignEnum_.Count;
3054 }
3055 }
3056 {
3057 int dataSize = 0;
3058 if (repeatedImportEnum_.Count > 0) {
3059 foreach (global::Google.ProtocolBuffers.TestProtos.ImportEnum element in repeatedImportEnum_) {
3060 dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element);
3061 }
3062 size += dataSize;
3063 size += 2 * repeatedImportEnum_.Count;
3064 }
3065 }
3066 {
3067 int dataSize = 0;
3068 foreach (string element in RepeatedStringPieceList) {
3069 dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element);
3070 }
3071 size += dataSize;
3072 size += 2 * repeatedStringPiece_.Count;
3073 }
3074 {
3075 int dataSize = 0;
3076 foreach (string element in RepeatedCordList) {
3077 dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element);
3078 }
3079 size += dataSize;
3080 size += 2 * repeatedCord_.Count;
3081 }
csharptestc671a4b2011-06-08 11:51:24 -05003082 if (hasDefaultInt32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003083 size += pb::CodedOutputStream.ComputeInt32Size(61, DefaultInt32);
3084 }
csharptestc671a4b2011-06-08 11:51:24 -05003085 if (hasDefaultInt64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003086 size += pb::CodedOutputStream.ComputeInt64Size(62, DefaultInt64);
3087 }
csharptestc671a4b2011-06-08 11:51:24 -05003088 if (hasDefaultUint32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003089 size += pb::CodedOutputStream.ComputeUInt32Size(63, DefaultUint32);
3090 }
csharptestc671a4b2011-06-08 11:51:24 -05003091 if (hasDefaultUint64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003092 size += pb::CodedOutputStream.ComputeUInt64Size(64, DefaultUint64);
3093 }
csharptestc671a4b2011-06-08 11:51:24 -05003094 if (hasDefaultSint32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003095 size += pb::CodedOutputStream.ComputeSInt32Size(65, DefaultSint32);
3096 }
csharptestc671a4b2011-06-08 11:51:24 -05003097 if (hasDefaultSint64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003098 size += pb::CodedOutputStream.ComputeSInt64Size(66, DefaultSint64);
3099 }
csharptestc671a4b2011-06-08 11:51:24 -05003100 if (hasDefaultFixed32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003101 size += pb::CodedOutputStream.ComputeFixed32Size(67, DefaultFixed32);
3102 }
csharptestc671a4b2011-06-08 11:51:24 -05003103 if (hasDefaultFixed64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003104 size += pb::CodedOutputStream.ComputeFixed64Size(68, DefaultFixed64);
3105 }
csharptestc671a4b2011-06-08 11:51:24 -05003106 if (hasDefaultSfixed32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003107 size += pb::CodedOutputStream.ComputeSFixed32Size(69, DefaultSfixed32);
3108 }
csharptestc671a4b2011-06-08 11:51:24 -05003109 if (hasDefaultSfixed64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003110 size += pb::CodedOutputStream.ComputeSFixed64Size(70, DefaultSfixed64);
3111 }
csharptestc671a4b2011-06-08 11:51:24 -05003112 if (hasDefaultFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003113 size += pb::CodedOutputStream.ComputeFloatSize(71, DefaultFloat);
3114 }
csharptestc671a4b2011-06-08 11:51:24 -05003115 if (hasDefaultDouble) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003116 size += pb::CodedOutputStream.ComputeDoubleSize(72, DefaultDouble);
3117 }
csharptestc671a4b2011-06-08 11:51:24 -05003118 if (hasDefaultBool) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003119 size += pb::CodedOutputStream.ComputeBoolSize(73, DefaultBool);
3120 }
csharptestc671a4b2011-06-08 11:51:24 -05003121 if (hasDefaultString) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003122 size += pb::CodedOutputStream.ComputeStringSize(74, DefaultString);
3123 }
csharptestc671a4b2011-06-08 11:51:24 -05003124 if (hasDefaultBytes) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003125 size += pb::CodedOutputStream.ComputeBytesSize(75, DefaultBytes);
3126 }
csharptestc671a4b2011-06-08 11:51:24 -05003127 if (hasDefaultNestedEnum) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003128 size += pb::CodedOutputStream.ComputeEnumSize(81, (int) DefaultNestedEnum);
3129 }
csharptestc671a4b2011-06-08 11:51:24 -05003130 if (hasDefaultForeignEnum) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003131 size += pb::CodedOutputStream.ComputeEnumSize(82, (int) DefaultForeignEnum);
3132 }
csharptestc671a4b2011-06-08 11:51:24 -05003133 if (hasDefaultImportEnum) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003134 size += pb::CodedOutputStream.ComputeEnumSize(83, (int) DefaultImportEnum);
3135 }
csharptestc671a4b2011-06-08 11:51:24 -05003136 if (hasDefaultStringPiece) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003137 size += pb::CodedOutputStream.ComputeStringSize(84, DefaultStringPiece);
3138 }
csharptestc671a4b2011-06-08 11:51:24 -05003139 if (hasDefaultCord) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003140 size += pb::CodedOutputStream.ComputeStringSize(85, DefaultCord);
3141 }
3142 size += UnknownFields.SerializedSize;
3143 memoizedSerializedSize = size;
3144 return size;
3145 }
3146 }
3147
3148 public static TestAllTypes ParseFrom(pb::ByteString data) {
3149 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
3150 }
3151 public static TestAllTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
3152 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
3153 }
3154 public static TestAllTypes ParseFrom(byte[] data) {
3155 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
3156 }
3157 public static TestAllTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
3158 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
3159 }
3160 public static TestAllTypes ParseFrom(global::System.IO.Stream input) {
3161 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
3162 }
3163 public static TestAllTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
3164 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
3165 }
3166 public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input) {
3167 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
3168 }
3169 public static TestAllTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
3170 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
3171 }
csharptest17699c22011-06-03 21:57:15 -05003172 public static TestAllTypes ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003173 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
3174 }
csharptest17699c22011-06-03 21:57:15 -05003175 public static TestAllTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003176 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
3177 }
3178 public static Builder CreateBuilder() { return new Builder(); }
3179 public override Builder ToBuilder() { return CreateBuilder(this); }
3180 public override Builder CreateBuilderForType() { return new Builder(); }
3181 public static Builder CreateBuilder(TestAllTypes prototype) {
3182 return (Builder) new Builder().MergeFrom(prototype);
3183 }
3184
csharptest445bdce2011-05-20 15:50:54 -05003185 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
3186 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
3187 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01003188 public sealed partial class Builder : pb::GeneratedBuilder<TestAllTypes, Builder> {
3189 protected override Builder ThisBuilder {
3190 get { return this; }
3191 }
3192 public Builder() {}
3193
3194 TestAllTypes result = new TestAllTypes();
3195
3196 protected override TestAllTypes MessageBeingBuilt {
3197 get { return result; }
3198 }
3199
3200 public override Builder Clear() {
3201 result = new TestAllTypes();
3202 return this;
3203 }
3204
3205 public override Builder Clone() {
3206 return new Builder().MergeFrom(result);
3207 }
3208
3209 public override pbd::MessageDescriptor DescriptorForType {
3210 get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor; }
3211 }
3212
3213 public override TestAllTypes DefaultInstanceForType {
3214 get { return global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance; }
3215 }
3216
3217 public override TestAllTypes BuildPartial() {
3218 if (result == null) {
3219 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
3220 }
3221 result.repeatedInt32_.MakeReadOnly();
3222 result.repeatedInt64_.MakeReadOnly();
3223 result.repeatedUint32_.MakeReadOnly();
3224 result.repeatedUint64_.MakeReadOnly();
3225 result.repeatedSint32_.MakeReadOnly();
3226 result.repeatedSint64_.MakeReadOnly();
3227 result.repeatedFixed32_.MakeReadOnly();
3228 result.repeatedFixed64_.MakeReadOnly();
3229 result.repeatedSfixed32_.MakeReadOnly();
3230 result.repeatedSfixed64_.MakeReadOnly();
3231 result.repeatedFloat_.MakeReadOnly();
3232 result.repeatedDouble_.MakeReadOnly();
3233 result.repeatedBool_.MakeReadOnly();
3234 result.repeatedString_.MakeReadOnly();
3235 result.repeatedBytes_.MakeReadOnly();
3236 result.repeatedGroup_.MakeReadOnly();
3237 result.repeatedNestedMessage_.MakeReadOnly();
3238 result.repeatedForeignMessage_.MakeReadOnly();
3239 result.repeatedImportMessage_.MakeReadOnly();
3240 result.repeatedNestedEnum_.MakeReadOnly();
3241 result.repeatedForeignEnum_.MakeReadOnly();
3242 result.repeatedImportEnum_.MakeReadOnly();
3243 result.repeatedStringPiece_.MakeReadOnly();
3244 result.repeatedCord_.MakeReadOnly();
3245 TestAllTypes returnMe = result;
3246 result = null;
3247 return returnMe;
3248 }
3249
3250 public override Builder MergeFrom(pb::IMessage other) {
3251 if (other is TestAllTypes) {
3252 return MergeFrom((TestAllTypes) other);
3253 } else {
3254 base.MergeFrom(other);
3255 return this;
3256 }
3257 }
3258
3259 public override Builder MergeFrom(TestAllTypes other) {
3260 if (other == global::Google.ProtocolBuffers.TestProtos.TestAllTypes.DefaultInstance) return this;
3261 if (other.HasOptionalInt32) {
3262 OptionalInt32 = other.OptionalInt32;
3263 }
3264 if (other.HasOptionalInt64) {
3265 OptionalInt64 = other.OptionalInt64;
3266 }
3267 if (other.HasOptionalUint32) {
3268 OptionalUint32 = other.OptionalUint32;
3269 }
3270 if (other.HasOptionalUint64) {
3271 OptionalUint64 = other.OptionalUint64;
3272 }
3273 if (other.HasOptionalSint32) {
3274 OptionalSint32 = other.OptionalSint32;
3275 }
3276 if (other.HasOptionalSint64) {
3277 OptionalSint64 = other.OptionalSint64;
3278 }
3279 if (other.HasOptionalFixed32) {
3280 OptionalFixed32 = other.OptionalFixed32;
3281 }
3282 if (other.HasOptionalFixed64) {
3283 OptionalFixed64 = other.OptionalFixed64;
3284 }
3285 if (other.HasOptionalSfixed32) {
3286 OptionalSfixed32 = other.OptionalSfixed32;
3287 }
3288 if (other.HasOptionalSfixed64) {
3289 OptionalSfixed64 = other.OptionalSfixed64;
3290 }
3291 if (other.HasOptionalFloat) {
3292 OptionalFloat = other.OptionalFloat;
3293 }
3294 if (other.HasOptionalDouble) {
3295 OptionalDouble = other.OptionalDouble;
3296 }
3297 if (other.HasOptionalBool) {
3298 OptionalBool = other.OptionalBool;
3299 }
3300 if (other.HasOptionalString) {
3301 OptionalString = other.OptionalString;
3302 }
3303 if (other.HasOptionalBytes) {
3304 OptionalBytes = other.OptionalBytes;
3305 }
3306 if (other.HasOptionalGroup) {
3307 MergeOptionalGroup(other.OptionalGroup);
3308 }
3309 if (other.HasOptionalNestedMessage) {
3310 MergeOptionalNestedMessage(other.OptionalNestedMessage);
3311 }
3312 if (other.HasOptionalForeignMessage) {
3313 MergeOptionalForeignMessage(other.OptionalForeignMessage);
3314 }
3315 if (other.HasOptionalImportMessage) {
3316 MergeOptionalImportMessage(other.OptionalImportMessage);
3317 }
3318 if (other.HasOptionalNestedEnum) {
3319 OptionalNestedEnum = other.OptionalNestedEnum;
3320 }
3321 if (other.HasOptionalForeignEnum) {
3322 OptionalForeignEnum = other.OptionalForeignEnum;
3323 }
3324 if (other.HasOptionalImportEnum) {
3325 OptionalImportEnum = other.OptionalImportEnum;
3326 }
3327 if (other.HasOptionalStringPiece) {
3328 OptionalStringPiece = other.OptionalStringPiece;
3329 }
3330 if (other.HasOptionalCord) {
3331 OptionalCord = other.OptionalCord;
3332 }
3333 if (other.repeatedInt32_.Count != 0) {
3334 base.AddRange(other.repeatedInt32_, result.repeatedInt32_);
3335 }
3336 if (other.repeatedInt64_.Count != 0) {
3337 base.AddRange(other.repeatedInt64_, result.repeatedInt64_);
3338 }
3339 if (other.repeatedUint32_.Count != 0) {
3340 base.AddRange(other.repeatedUint32_, result.repeatedUint32_);
3341 }
3342 if (other.repeatedUint64_.Count != 0) {
3343 base.AddRange(other.repeatedUint64_, result.repeatedUint64_);
3344 }
3345 if (other.repeatedSint32_.Count != 0) {
3346 base.AddRange(other.repeatedSint32_, result.repeatedSint32_);
3347 }
3348 if (other.repeatedSint64_.Count != 0) {
3349 base.AddRange(other.repeatedSint64_, result.repeatedSint64_);
3350 }
3351 if (other.repeatedFixed32_.Count != 0) {
3352 base.AddRange(other.repeatedFixed32_, result.repeatedFixed32_);
3353 }
3354 if (other.repeatedFixed64_.Count != 0) {
3355 base.AddRange(other.repeatedFixed64_, result.repeatedFixed64_);
3356 }
3357 if (other.repeatedSfixed32_.Count != 0) {
3358 base.AddRange(other.repeatedSfixed32_, result.repeatedSfixed32_);
3359 }
3360 if (other.repeatedSfixed64_.Count != 0) {
3361 base.AddRange(other.repeatedSfixed64_, result.repeatedSfixed64_);
3362 }
3363 if (other.repeatedFloat_.Count != 0) {
3364 base.AddRange(other.repeatedFloat_, result.repeatedFloat_);
3365 }
3366 if (other.repeatedDouble_.Count != 0) {
3367 base.AddRange(other.repeatedDouble_, result.repeatedDouble_);
3368 }
3369 if (other.repeatedBool_.Count != 0) {
3370 base.AddRange(other.repeatedBool_, result.repeatedBool_);
3371 }
3372 if (other.repeatedString_.Count != 0) {
3373 base.AddRange(other.repeatedString_, result.repeatedString_);
3374 }
3375 if (other.repeatedBytes_.Count != 0) {
3376 base.AddRange(other.repeatedBytes_, result.repeatedBytes_);
3377 }
3378 if (other.repeatedGroup_.Count != 0) {
3379 base.AddRange(other.repeatedGroup_, result.repeatedGroup_);
3380 }
3381 if (other.repeatedNestedMessage_.Count != 0) {
3382 base.AddRange(other.repeatedNestedMessage_, result.repeatedNestedMessage_);
3383 }
3384 if (other.repeatedForeignMessage_.Count != 0) {
3385 base.AddRange(other.repeatedForeignMessage_, result.repeatedForeignMessage_);
3386 }
3387 if (other.repeatedImportMessage_.Count != 0) {
3388 base.AddRange(other.repeatedImportMessage_, result.repeatedImportMessage_);
3389 }
3390 if (other.repeatedNestedEnum_.Count != 0) {
3391 base.AddRange(other.repeatedNestedEnum_, result.repeatedNestedEnum_);
3392 }
3393 if (other.repeatedForeignEnum_.Count != 0) {
3394 base.AddRange(other.repeatedForeignEnum_, result.repeatedForeignEnum_);
3395 }
3396 if (other.repeatedImportEnum_.Count != 0) {
3397 base.AddRange(other.repeatedImportEnum_, result.repeatedImportEnum_);
3398 }
3399 if (other.repeatedStringPiece_.Count != 0) {
3400 base.AddRange(other.repeatedStringPiece_, result.repeatedStringPiece_);
3401 }
3402 if (other.repeatedCord_.Count != 0) {
3403 base.AddRange(other.repeatedCord_, result.repeatedCord_);
3404 }
3405 if (other.HasDefaultInt32) {
3406 DefaultInt32 = other.DefaultInt32;
3407 }
3408 if (other.HasDefaultInt64) {
3409 DefaultInt64 = other.DefaultInt64;
3410 }
3411 if (other.HasDefaultUint32) {
3412 DefaultUint32 = other.DefaultUint32;
3413 }
3414 if (other.HasDefaultUint64) {
3415 DefaultUint64 = other.DefaultUint64;
3416 }
3417 if (other.HasDefaultSint32) {
3418 DefaultSint32 = other.DefaultSint32;
3419 }
3420 if (other.HasDefaultSint64) {
3421 DefaultSint64 = other.DefaultSint64;
3422 }
3423 if (other.HasDefaultFixed32) {
3424 DefaultFixed32 = other.DefaultFixed32;
3425 }
3426 if (other.HasDefaultFixed64) {
3427 DefaultFixed64 = other.DefaultFixed64;
3428 }
3429 if (other.HasDefaultSfixed32) {
3430 DefaultSfixed32 = other.DefaultSfixed32;
3431 }
3432 if (other.HasDefaultSfixed64) {
3433 DefaultSfixed64 = other.DefaultSfixed64;
3434 }
3435 if (other.HasDefaultFloat) {
3436 DefaultFloat = other.DefaultFloat;
3437 }
3438 if (other.HasDefaultDouble) {
3439 DefaultDouble = other.DefaultDouble;
3440 }
3441 if (other.HasDefaultBool) {
3442 DefaultBool = other.DefaultBool;
3443 }
3444 if (other.HasDefaultString) {
3445 DefaultString = other.DefaultString;
3446 }
3447 if (other.HasDefaultBytes) {
3448 DefaultBytes = other.DefaultBytes;
3449 }
3450 if (other.HasDefaultNestedEnum) {
3451 DefaultNestedEnum = other.DefaultNestedEnum;
3452 }
3453 if (other.HasDefaultForeignEnum) {
3454 DefaultForeignEnum = other.DefaultForeignEnum;
3455 }
3456 if (other.HasDefaultImportEnum) {
3457 DefaultImportEnum = other.DefaultImportEnum;
3458 }
3459 if (other.HasDefaultStringPiece) {
3460 DefaultStringPiece = other.DefaultStringPiece;
3461 }
3462 if (other.HasDefaultCord) {
3463 DefaultCord = other.DefaultCord;
3464 }
3465 this.MergeUnknownFields(other.UnknownFields);
3466 return this;
3467 }
3468
csharptest17699c22011-06-03 21:57:15 -05003469 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003470 return MergeFrom(input, pb::ExtensionRegistry.Empty);
3471 }
3472
csharptest17699c22011-06-03 21:57:15 -05003473 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003474 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05003475 uint tag;
3476 string field_name;
3477 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05003478 if(tag == 0 && field_name != null) {
3479 int field_ordinal = global::System.Array.BinarySearch(_testAllTypesFieldNames, field_name, global::System.StringComparer.Ordinal);
3480 if(field_ordinal >= 0)
3481 tag = _testAllTypesFieldTags[field_ordinal];
3482 else {
3483 if (unknownFields == null) {
3484 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3485 }
3486 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
3487 continue;
3488 }
3489 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01003490 switch (tag) {
3491 case 0: {
csharptest99284412011-06-03 14:51:06 -05003492 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01003493 }
3494 default: {
3495 if (pb::WireFormat.IsEndGroupTag(tag)) {
3496 if (unknownFields != null) {
3497 this.UnknownFields = unknownFields.Build();
3498 }
3499 return this;
3500 }
3501 if (unknownFields == null) {
3502 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3503 }
csharptestd2af9e92011-06-03 21:35:02 -05003504 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003505 break;
3506 }
3507 case 8: {
csharptest920b09a2011-06-08 20:13:29 -05003508 result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003509 break;
3510 }
3511 case 16: {
csharptest920b09a2011-06-08 20:13:29 -05003512 result.hasOptionalInt64 = input.ReadInt64(ref result.optionalInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003513 break;
3514 }
3515 case 24: {
csharptest920b09a2011-06-08 20:13:29 -05003516 result.hasOptionalUint32 = input.ReadUInt32(ref result.optionalUint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003517 break;
3518 }
3519 case 32: {
csharptest920b09a2011-06-08 20:13:29 -05003520 result.hasOptionalUint64 = input.ReadUInt64(ref result.optionalUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003521 break;
3522 }
3523 case 40: {
csharptest920b09a2011-06-08 20:13:29 -05003524 result.hasOptionalSint32 = input.ReadSInt32(ref result.optionalSint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003525 break;
3526 }
3527 case 48: {
csharptest920b09a2011-06-08 20:13:29 -05003528 result.hasOptionalSint64 = input.ReadSInt64(ref result.optionalSint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003529 break;
3530 }
3531 case 61: {
csharptest920b09a2011-06-08 20:13:29 -05003532 result.hasOptionalFixed32 = input.ReadFixed32(ref result.optionalFixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003533 break;
3534 }
3535 case 65: {
csharptest920b09a2011-06-08 20:13:29 -05003536 result.hasOptionalFixed64 = input.ReadFixed64(ref result.optionalFixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003537 break;
3538 }
3539 case 77: {
csharptest920b09a2011-06-08 20:13:29 -05003540 result.hasOptionalSfixed32 = input.ReadSFixed32(ref result.optionalSfixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003541 break;
3542 }
3543 case 81: {
csharptest920b09a2011-06-08 20:13:29 -05003544 result.hasOptionalSfixed64 = input.ReadSFixed64(ref result.optionalSfixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003545 break;
3546 }
3547 case 93: {
csharptest920b09a2011-06-08 20:13:29 -05003548 result.hasOptionalFloat = input.ReadFloat(ref result.optionalFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003549 break;
3550 }
3551 case 97: {
csharptest920b09a2011-06-08 20:13:29 -05003552 result.hasOptionalDouble = input.ReadDouble(ref result.optionalDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003553 break;
3554 }
3555 case 104: {
csharptest920b09a2011-06-08 20:13:29 -05003556 result.hasOptionalBool = input.ReadBool(ref result.optionalBool_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003557 break;
3558 }
3559 case 114: {
csharptest920b09a2011-06-08 20:13:29 -05003560 result.hasOptionalString = input.ReadString(ref result.optionalString_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003561 break;
3562 }
3563 case 122: {
csharptest920b09a2011-06-08 20:13:29 -05003564 result.hasOptionalBytes = input.ReadBytes(ref result.optionalBytes_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003565 break;
3566 }
3567 case 131: {
3568 global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -05003569 if (result.hasOptionalGroup) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003570 subBuilder.MergeFrom(OptionalGroup);
3571 }
3572 input.ReadGroup(16, subBuilder, extensionRegistry);
3573 OptionalGroup = subBuilder.BuildPartial();
3574 break;
3575 }
3576 case 146: {
3577 global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -05003578 if (result.hasOptionalNestedMessage) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003579 subBuilder.MergeFrom(OptionalNestedMessage);
3580 }
3581 input.ReadMessage(subBuilder, extensionRegistry);
3582 OptionalNestedMessage = subBuilder.BuildPartial();
3583 break;
3584 }
3585 case 154: {
3586 global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -05003587 if (result.hasOptionalForeignMessage) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003588 subBuilder.MergeFrom(OptionalForeignMessage);
3589 }
3590 input.ReadMessage(subBuilder, extensionRegistry);
3591 OptionalForeignMessage = subBuilder.BuildPartial();
3592 break;
3593 }
3594 case 162: {
3595 global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -05003596 if (result.hasOptionalImportMessage) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003597 subBuilder.MergeFrom(OptionalImportMessage);
3598 }
3599 input.ReadMessage(subBuilder, extensionRegistry);
3600 OptionalImportMessage = subBuilder.BuildPartial();
3601 break;
3602 }
3603 case 168: {
csharptestd2af9e92011-06-03 21:35:02 -05003604 object unknown;
3605 if(input.ReadEnum(ref result.optionalNestedEnum_, out unknown)) {
3606 result.hasOptionalNestedEnum = true;
3607 } else if(unknown is int) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003608 if (unknownFields == null) {
3609 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3610 }
csharptestd2af9e92011-06-03 21:35:02 -05003611 unknownFields.MergeVarintField(21, (ulong)(int)unknown);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003612 }
3613 break;
3614 }
3615 case 176: {
csharptestd2af9e92011-06-03 21:35:02 -05003616 object unknown;
3617 if(input.ReadEnum(ref result.optionalForeignEnum_, out unknown)) {
3618 result.hasOptionalForeignEnum = true;
3619 } else if(unknown is int) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003620 if (unknownFields == null) {
3621 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3622 }
csharptestd2af9e92011-06-03 21:35:02 -05003623 unknownFields.MergeVarintField(22, (ulong)(int)unknown);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003624 }
3625 break;
3626 }
3627 case 184: {
csharptestd2af9e92011-06-03 21:35:02 -05003628 object unknown;
3629 if(input.ReadEnum(ref result.optionalImportEnum_, out unknown)) {
3630 result.hasOptionalImportEnum = true;
3631 } else if(unknown is int) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003632 if (unknownFields == null) {
3633 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3634 }
csharptestd2af9e92011-06-03 21:35:02 -05003635 unknownFields.MergeVarintField(23, (ulong)(int)unknown);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003636 }
3637 break;
3638 }
3639 case 194: {
csharptest920b09a2011-06-08 20:13:29 -05003640 result.hasOptionalStringPiece = input.ReadString(ref result.optionalStringPiece_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003641 break;
3642 }
3643 case 202: {
csharptest920b09a2011-06-08 20:13:29 -05003644 result.hasOptionalCord = input.ReadString(ref result.optionalCord_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003645 break;
3646 }
csharptest6da31702011-06-04 12:52:57 -05003647 case 250:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003648 case 248: {
csharptestd2af9e92011-06-03 21:35:02 -05003649 input.ReadPrimitiveArray(pbd::FieldType.Int32, tag, field_name, result.repeatedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003650 break;
3651 }
csharptest6da31702011-06-04 12:52:57 -05003652 case 258:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003653 case 256: {
csharptestd2af9e92011-06-03 21:35:02 -05003654 input.ReadPrimitiveArray(pbd::FieldType.Int64, tag, field_name, result.repeatedInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003655 break;
3656 }
csharptest6da31702011-06-04 12:52:57 -05003657 case 266:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003658 case 264: {
csharptestd2af9e92011-06-03 21:35:02 -05003659 input.ReadPrimitiveArray(pbd::FieldType.UInt32, tag, field_name, result.repeatedUint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003660 break;
3661 }
csharptest6da31702011-06-04 12:52:57 -05003662 case 274:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003663 case 272: {
csharptestd2af9e92011-06-03 21:35:02 -05003664 input.ReadPrimitiveArray(pbd::FieldType.UInt64, tag, field_name, result.repeatedUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003665 break;
3666 }
csharptest6da31702011-06-04 12:52:57 -05003667 case 282:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003668 case 280: {
csharptestd2af9e92011-06-03 21:35:02 -05003669 input.ReadPrimitiveArray(pbd::FieldType.SInt32, tag, field_name, result.repeatedSint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003670 break;
3671 }
csharptest6da31702011-06-04 12:52:57 -05003672 case 290:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003673 case 288: {
csharptestd2af9e92011-06-03 21:35:02 -05003674 input.ReadPrimitiveArray(pbd::FieldType.SInt64, tag, field_name, result.repeatedSint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003675 break;
3676 }
csharptest6da31702011-06-04 12:52:57 -05003677 case 298:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003678 case 301: {
csharptestd2af9e92011-06-03 21:35:02 -05003679 input.ReadPrimitiveArray(pbd::FieldType.Fixed32, tag, field_name, result.repeatedFixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003680 break;
3681 }
csharptest6da31702011-06-04 12:52:57 -05003682 case 306:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003683 case 305: {
csharptestd2af9e92011-06-03 21:35:02 -05003684 input.ReadPrimitiveArray(pbd::FieldType.Fixed64, tag, field_name, result.repeatedFixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003685 break;
3686 }
csharptest6da31702011-06-04 12:52:57 -05003687 case 314:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003688 case 317: {
csharptestd2af9e92011-06-03 21:35:02 -05003689 input.ReadPrimitiveArray(pbd::FieldType.SFixed32, tag, field_name, result.repeatedSfixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003690 break;
3691 }
csharptest6da31702011-06-04 12:52:57 -05003692 case 322:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003693 case 321: {
csharptestd2af9e92011-06-03 21:35:02 -05003694 input.ReadPrimitiveArray(pbd::FieldType.SFixed64, tag, field_name, result.repeatedSfixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003695 break;
3696 }
csharptest6da31702011-06-04 12:52:57 -05003697 case 330:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003698 case 333: {
csharptestd2af9e92011-06-03 21:35:02 -05003699 input.ReadPrimitiveArray(pbd::FieldType.Float, tag, field_name, result.repeatedFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003700 break;
3701 }
csharptest6da31702011-06-04 12:52:57 -05003702 case 338:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003703 case 337: {
csharptestd2af9e92011-06-03 21:35:02 -05003704 input.ReadPrimitiveArray(pbd::FieldType.Double, tag, field_name, result.repeatedDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003705 break;
3706 }
csharptest6da31702011-06-04 12:52:57 -05003707 case 346:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003708 case 344: {
csharptestd2af9e92011-06-03 21:35:02 -05003709 input.ReadPrimitiveArray(pbd::FieldType.Bool, tag, field_name, result.repeatedBool_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003710 break;
3711 }
3712 case 354: {
csharptestd2af9e92011-06-03 21:35:02 -05003713 input.ReadPrimitiveArray(pbd::FieldType.String, tag, field_name, result.repeatedString_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003714 break;
3715 }
3716 case 362: {
csharptestd2af9e92011-06-03 21:35:02 -05003717 input.ReadPrimitiveArray(pbd::FieldType.Bytes, tag, field_name, result.repeatedBytes_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003718 break;
3719 }
3720 case 371: {
csharptestd2af9e92011-06-03 21:35:02 -05003721 input.ReadGroupArray(tag, field_name, result.repeatedGroup_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.DefaultInstance, extensionRegistry);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003722 break;
3723 }
3724 case 386: {
csharptestd2af9e92011-06-03 21:35:02 -05003725 input.ReadMessageArray(tag, field_name, result.repeatedNestedMessage_, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance, extensionRegistry);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003726 break;
3727 }
3728 case 394: {
csharptestd2af9e92011-06-03 21:35:02 -05003729 input.ReadMessageArray(tag, field_name, result.repeatedForeignMessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003730 break;
3731 }
3732 case 402: {
csharptestd2af9e92011-06-03 21:35:02 -05003733 input.ReadMessageArray(tag, field_name, result.repeatedImportMessage_, global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance, extensionRegistry);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003734 break;
3735 }
csharptest6da31702011-06-04 12:52:57 -05003736 case 410:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003737 case 408: {
csharptestd2af9e92011-06-03 21:35:02 -05003738 scg::ICollection<object> unknownItems;
3739 input.ReadEnumArray<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum>(tag, field_name, result.repeatedNestedEnum_, out unknownItems);
3740 if (unknownItems != null) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003741 if (unknownFields == null) {
3742 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3743 }
csharptestd2af9e92011-06-03 21:35:02 -05003744 foreach (object rawValue in unknownItems)
3745 if (rawValue is int)
3746 unknownFields.MergeVarintField(51, (ulong)(int)rawValue);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003747 }
3748 break;
3749 }
csharptest6da31702011-06-04 12:52:57 -05003750 case 418:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003751 case 416: {
csharptestd2af9e92011-06-03 21:35:02 -05003752 scg::ICollection<object> unknownItems;
3753 input.ReadEnumArray<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>(tag, field_name, result.repeatedForeignEnum_, out unknownItems);
3754 if (unknownItems != null) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003755 if (unknownFields == null) {
3756 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3757 }
csharptestd2af9e92011-06-03 21:35:02 -05003758 foreach (object rawValue in unknownItems)
3759 if (rawValue is int)
3760 unknownFields.MergeVarintField(52, (ulong)(int)rawValue);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003761 }
3762 break;
3763 }
csharptest6da31702011-06-04 12:52:57 -05003764 case 426:
Jon Skeet82bb0f12011-04-03 20:17:12 +01003765 case 424: {
csharptestd2af9e92011-06-03 21:35:02 -05003766 scg::ICollection<object> unknownItems;
3767 input.ReadEnumArray<global::Google.ProtocolBuffers.TestProtos.ImportEnum>(tag, field_name, result.repeatedImportEnum_, out unknownItems);
3768 if (unknownItems != null) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003769 if (unknownFields == null) {
3770 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3771 }
csharptestd2af9e92011-06-03 21:35:02 -05003772 foreach (object rawValue in unknownItems)
3773 if (rawValue is int)
3774 unknownFields.MergeVarintField(53, (ulong)(int)rawValue);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003775 }
3776 break;
3777 }
3778 case 434: {
csharptestd2af9e92011-06-03 21:35:02 -05003779 input.ReadPrimitiveArray(pbd::FieldType.String, tag, field_name, result.repeatedStringPiece_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003780 break;
3781 }
3782 case 442: {
csharptestd2af9e92011-06-03 21:35:02 -05003783 input.ReadPrimitiveArray(pbd::FieldType.String, tag, field_name, result.repeatedCord_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003784 break;
3785 }
3786 case 488: {
csharptest920b09a2011-06-08 20:13:29 -05003787 result.hasDefaultInt32 = input.ReadInt32(ref result.defaultInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003788 break;
3789 }
3790 case 496: {
csharptest920b09a2011-06-08 20:13:29 -05003791 result.hasDefaultInt64 = input.ReadInt64(ref result.defaultInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003792 break;
3793 }
3794 case 504: {
csharptest920b09a2011-06-08 20:13:29 -05003795 result.hasDefaultUint32 = input.ReadUInt32(ref result.defaultUint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003796 break;
3797 }
3798 case 512: {
csharptest920b09a2011-06-08 20:13:29 -05003799 result.hasDefaultUint64 = input.ReadUInt64(ref result.defaultUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003800 break;
3801 }
3802 case 520: {
csharptest920b09a2011-06-08 20:13:29 -05003803 result.hasDefaultSint32 = input.ReadSInt32(ref result.defaultSint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003804 break;
3805 }
3806 case 528: {
csharptest920b09a2011-06-08 20:13:29 -05003807 result.hasDefaultSint64 = input.ReadSInt64(ref result.defaultSint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003808 break;
3809 }
3810 case 541: {
csharptest920b09a2011-06-08 20:13:29 -05003811 result.hasDefaultFixed32 = input.ReadFixed32(ref result.defaultFixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003812 break;
3813 }
3814 case 545: {
csharptest920b09a2011-06-08 20:13:29 -05003815 result.hasDefaultFixed64 = input.ReadFixed64(ref result.defaultFixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003816 break;
3817 }
3818 case 557: {
csharptest920b09a2011-06-08 20:13:29 -05003819 result.hasDefaultSfixed32 = input.ReadSFixed32(ref result.defaultSfixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003820 break;
3821 }
3822 case 561: {
csharptest920b09a2011-06-08 20:13:29 -05003823 result.hasDefaultSfixed64 = input.ReadSFixed64(ref result.defaultSfixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003824 break;
3825 }
3826 case 573: {
csharptest920b09a2011-06-08 20:13:29 -05003827 result.hasDefaultFloat = input.ReadFloat(ref result.defaultFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003828 break;
3829 }
3830 case 577: {
csharptest920b09a2011-06-08 20:13:29 -05003831 result.hasDefaultDouble = input.ReadDouble(ref result.defaultDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003832 break;
3833 }
3834 case 584: {
csharptest920b09a2011-06-08 20:13:29 -05003835 result.hasDefaultBool = input.ReadBool(ref result.defaultBool_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003836 break;
3837 }
3838 case 594: {
csharptest920b09a2011-06-08 20:13:29 -05003839 result.hasDefaultString = input.ReadString(ref result.defaultString_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003840 break;
3841 }
3842 case 602: {
csharptest920b09a2011-06-08 20:13:29 -05003843 result.hasDefaultBytes = input.ReadBytes(ref result.defaultBytes_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003844 break;
3845 }
3846 case 648: {
csharptestd2af9e92011-06-03 21:35:02 -05003847 object unknown;
3848 if(input.ReadEnum(ref result.defaultNestedEnum_, out unknown)) {
3849 result.hasDefaultNestedEnum = true;
3850 } else if(unknown is int) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003851 if (unknownFields == null) {
3852 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3853 }
csharptestd2af9e92011-06-03 21:35:02 -05003854 unknownFields.MergeVarintField(81, (ulong)(int)unknown);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003855 }
3856 break;
3857 }
3858 case 656: {
csharptestd2af9e92011-06-03 21:35:02 -05003859 object unknown;
3860 if(input.ReadEnum(ref result.defaultForeignEnum_, out unknown)) {
3861 result.hasDefaultForeignEnum = true;
3862 } else if(unknown is int) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003863 if (unknownFields == null) {
3864 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3865 }
csharptestd2af9e92011-06-03 21:35:02 -05003866 unknownFields.MergeVarintField(82, (ulong)(int)unknown);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003867 }
3868 break;
3869 }
3870 case 664: {
csharptestd2af9e92011-06-03 21:35:02 -05003871 object unknown;
3872 if(input.ReadEnum(ref result.defaultImportEnum_, out unknown)) {
3873 result.hasDefaultImportEnum = true;
3874 } else if(unknown is int) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01003875 if (unknownFields == null) {
3876 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
3877 }
csharptestd2af9e92011-06-03 21:35:02 -05003878 unknownFields.MergeVarintField(83, (ulong)(int)unknown);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003879 }
3880 break;
3881 }
3882 case 674: {
csharptest920b09a2011-06-08 20:13:29 -05003883 result.hasDefaultStringPiece = input.ReadString(ref result.defaultStringPiece_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003884 break;
3885 }
3886 case 682: {
csharptest920b09a2011-06-08 20:13:29 -05003887 result.hasDefaultCord = input.ReadString(ref result.defaultCord_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01003888 break;
3889 }
3890 }
3891 }
csharptest123e5342011-06-03 14:15:21 -05003892
3893 if (unknownFields != null) {
3894 this.UnknownFields = unknownFields.Build();
3895 }
3896 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01003897 }
3898
3899
3900 public bool HasOptionalInt32 {
csharptestc671a4b2011-06-08 11:51:24 -05003901 get { return result.hasOptionalInt32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01003902 }
3903 public int OptionalInt32 {
3904 get { return result.OptionalInt32; }
3905 set { SetOptionalInt32(value); }
3906 }
3907 public Builder SetOptionalInt32(int value) {
3908 result.hasOptionalInt32 = true;
3909 result.optionalInt32_ = value;
3910 return this;
3911 }
3912 public Builder ClearOptionalInt32() {
3913 result.hasOptionalInt32 = false;
3914 result.optionalInt32_ = 0;
3915 return this;
3916 }
3917
3918 public bool HasOptionalInt64 {
csharptestc671a4b2011-06-08 11:51:24 -05003919 get { return result.hasOptionalInt64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01003920 }
3921 public long OptionalInt64 {
3922 get { return result.OptionalInt64; }
3923 set { SetOptionalInt64(value); }
3924 }
3925 public Builder SetOptionalInt64(long value) {
3926 result.hasOptionalInt64 = true;
3927 result.optionalInt64_ = value;
3928 return this;
3929 }
3930 public Builder ClearOptionalInt64() {
3931 result.hasOptionalInt64 = false;
3932 result.optionalInt64_ = 0L;
3933 return this;
3934 }
3935
3936 public bool HasOptionalUint32 {
csharptestc671a4b2011-06-08 11:51:24 -05003937 get { return result.hasOptionalUint32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01003938 }
3939 [global::System.CLSCompliant(false)]
3940 public uint OptionalUint32 {
3941 get { return result.OptionalUint32; }
3942 set { SetOptionalUint32(value); }
3943 }
3944 [global::System.CLSCompliant(false)]
3945 public Builder SetOptionalUint32(uint value) {
3946 result.hasOptionalUint32 = true;
3947 result.optionalUint32_ = value;
3948 return this;
3949 }
3950 public Builder ClearOptionalUint32() {
3951 result.hasOptionalUint32 = false;
3952 result.optionalUint32_ = 0;
3953 return this;
3954 }
3955
3956 public bool HasOptionalUint64 {
csharptestc671a4b2011-06-08 11:51:24 -05003957 get { return result.hasOptionalUint64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01003958 }
3959 [global::System.CLSCompliant(false)]
3960 public ulong OptionalUint64 {
3961 get { return result.OptionalUint64; }
3962 set { SetOptionalUint64(value); }
3963 }
3964 [global::System.CLSCompliant(false)]
3965 public Builder SetOptionalUint64(ulong value) {
3966 result.hasOptionalUint64 = true;
3967 result.optionalUint64_ = value;
3968 return this;
3969 }
3970 public Builder ClearOptionalUint64() {
3971 result.hasOptionalUint64 = false;
3972 result.optionalUint64_ = 0UL;
3973 return this;
3974 }
3975
3976 public bool HasOptionalSint32 {
csharptestc671a4b2011-06-08 11:51:24 -05003977 get { return result.hasOptionalSint32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01003978 }
3979 public int OptionalSint32 {
3980 get { return result.OptionalSint32; }
3981 set { SetOptionalSint32(value); }
3982 }
3983 public Builder SetOptionalSint32(int value) {
3984 result.hasOptionalSint32 = true;
3985 result.optionalSint32_ = value;
3986 return this;
3987 }
3988 public Builder ClearOptionalSint32() {
3989 result.hasOptionalSint32 = false;
3990 result.optionalSint32_ = 0;
3991 return this;
3992 }
3993
3994 public bool HasOptionalSint64 {
csharptestc671a4b2011-06-08 11:51:24 -05003995 get { return result.hasOptionalSint64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01003996 }
3997 public long OptionalSint64 {
3998 get { return result.OptionalSint64; }
3999 set { SetOptionalSint64(value); }
4000 }
4001 public Builder SetOptionalSint64(long value) {
4002 result.hasOptionalSint64 = true;
4003 result.optionalSint64_ = value;
4004 return this;
4005 }
4006 public Builder ClearOptionalSint64() {
4007 result.hasOptionalSint64 = false;
4008 result.optionalSint64_ = 0;
4009 return this;
4010 }
4011
4012 public bool HasOptionalFixed32 {
csharptestc671a4b2011-06-08 11:51:24 -05004013 get { return result.hasOptionalFixed32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004014 }
4015 [global::System.CLSCompliant(false)]
4016 public uint OptionalFixed32 {
4017 get { return result.OptionalFixed32; }
4018 set { SetOptionalFixed32(value); }
4019 }
4020 [global::System.CLSCompliant(false)]
4021 public Builder SetOptionalFixed32(uint value) {
4022 result.hasOptionalFixed32 = true;
4023 result.optionalFixed32_ = value;
4024 return this;
4025 }
4026 public Builder ClearOptionalFixed32() {
4027 result.hasOptionalFixed32 = false;
4028 result.optionalFixed32_ = 0;
4029 return this;
4030 }
4031
4032 public bool HasOptionalFixed64 {
csharptestc671a4b2011-06-08 11:51:24 -05004033 get { return result.hasOptionalFixed64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004034 }
4035 [global::System.CLSCompliant(false)]
4036 public ulong OptionalFixed64 {
4037 get { return result.OptionalFixed64; }
4038 set { SetOptionalFixed64(value); }
4039 }
4040 [global::System.CLSCompliant(false)]
4041 public Builder SetOptionalFixed64(ulong value) {
4042 result.hasOptionalFixed64 = true;
4043 result.optionalFixed64_ = value;
4044 return this;
4045 }
4046 public Builder ClearOptionalFixed64() {
4047 result.hasOptionalFixed64 = false;
4048 result.optionalFixed64_ = 0;
4049 return this;
4050 }
4051
4052 public bool HasOptionalSfixed32 {
csharptestc671a4b2011-06-08 11:51:24 -05004053 get { return result.hasOptionalSfixed32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004054 }
4055 public int OptionalSfixed32 {
4056 get { return result.OptionalSfixed32; }
4057 set { SetOptionalSfixed32(value); }
4058 }
4059 public Builder SetOptionalSfixed32(int value) {
4060 result.hasOptionalSfixed32 = true;
4061 result.optionalSfixed32_ = value;
4062 return this;
4063 }
4064 public Builder ClearOptionalSfixed32() {
4065 result.hasOptionalSfixed32 = false;
4066 result.optionalSfixed32_ = 0;
4067 return this;
4068 }
4069
4070 public bool HasOptionalSfixed64 {
csharptestc671a4b2011-06-08 11:51:24 -05004071 get { return result.hasOptionalSfixed64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004072 }
4073 public long OptionalSfixed64 {
4074 get { return result.OptionalSfixed64; }
4075 set { SetOptionalSfixed64(value); }
4076 }
4077 public Builder SetOptionalSfixed64(long value) {
4078 result.hasOptionalSfixed64 = true;
4079 result.optionalSfixed64_ = value;
4080 return this;
4081 }
4082 public Builder ClearOptionalSfixed64() {
4083 result.hasOptionalSfixed64 = false;
4084 result.optionalSfixed64_ = 0;
4085 return this;
4086 }
4087
4088 public bool HasOptionalFloat {
csharptestc671a4b2011-06-08 11:51:24 -05004089 get { return result.hasOptionalFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004090 }
4091 public float OptionalFloat {
4092 get { return result.OptionalFloat; }
4093 set { SetOptionalFloat(value); }
4094 }
4095 public Builder SetOptionalFloat(float value) {
4096 result.hasOptionalFloat = true;
4097 result.optionalFloat_ = value;
4098 return this;
4099 }
4100 public Builder ClearOptionalFloat() {
4101 result.hasOptionalFloat = false;
4102 result.optionalFloat_ = 0F;
4103 return this;
4104 }
4105
4106 public bool HasOptionalDouble {
csharptestc671a4b2011-06-08 11:51:24 -05004107 get { return result.hasOptionalDouble; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004108 }
4109 public double OptionalDouble {
4110 get { return result.OptionalDouble; }
4111 set { SetOptionalDouble(value); }
4112 }
4113 public Builder SetOptionalDouble(double value) {
4114 result.hasOptionalDouble = true;
4115 result.optionalDouble_ = value;
4116 return this;
4117 }
4118 public Builder ClearOptionalDouble() {
4119 result.hasOptionalDouble = false;
4120 result.optionalDouble_ = 0D;
4121 return this;
4122 }
4123
4124 public bool HasOptionalBool {
csharptestc671a4b2011-06-08 11:51:24 -05004125 get { return result.hasOptionalBool; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004126 }
4127 public bool OptionalBool {
4128 get { return result.OptionalBool; }
4129 set { SetOptionalBool(value); }
4130 }
4131 public Builder SetOptionalBool(bool value) {
4132 result.hasOptionalBool = true;
4133 result.optionalBool_ = value;
4134 return this;
4135 }
4136 public Builder ClearOptionalBool() {
4137 result.hasOptionalBool = false;
4138 result.optionalBool_ = false;
4139 return this;
4140 }
4141
4142 public bool HasOptionalString {
csharptestc671a4b2011-06-08 11:51:24 -05004143 get { return result.hasOptionalString; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004144 }
4145 public string OptionalString {
4146 get { return result.OptionalString; }
4147 set { SetOptionalString(value); }
4148 }
4149 public Builder SetOptionalString(string value) {
4150 pb::ThrowHelper.ThrowIfNull(value, "value");
4151 result.hasOptionalString = true;
4152 result.optionalString_ = value;
4153 return this;
4154 }
4155 public Builder ClearOptionalString() {
4156 result.hasOptionalString = false;
4157 result.optionalString_ = "";
4158 return this;
4159 }
4160
4161 public bool HasOptionalBytes {
csharptestc671a4b2011-06-08 11:51:24 -05004162 get { return result.hasOptionalBytes; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004163 }
4164 public pb::ByteString OptionalBytes {
4165 get { return result.OptionalBytes; }
4166 set { SetOptionalBytes(value); }
4167 }
4168 public Builder SetOptionalBytes(pb::ByteString value) {
4169 pb::ThrowHelper.ThrowIfNull(value, "value");
4170 result.hasOptionalBytes = true;
4171 result.optionalBytes_ = value;
4172 return this;
4173 }
4174 public Builder ClearOptionalBytes() {
4175 result.hasOptionalBytes = false;
4176 result.optionalBytes_ = pb::ByteString.Empty;
4177 return this;
4178 }
4179
4180 public bool HasOptionalGroup {
csharptestc671a4b2011-06-08 11:51:24 -05004181 get { return result.hasOptionalGroup; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004182 }
4183 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup OptionalGroup {
4184 get { return result.OptionalGroup; }
4185 set { SetOptionalGroup(value); }
4186 }
4187 public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup value) {
4188 pb::ThrowHelper.ThrowIfNull(value, "value");
4189 result.hasOptionalGroup = true;
4190 result.optionalGroup_ = value;
4191 return this;
4192 }
4193 public Builder SetOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.Builder builderForValue) {
4194 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4195 result.hasOptionalGroup = true;
4196 result.optionalGroup_ = builderForValue.Build();
4197 return this;
4198 }
4199 public Builder MergeOptionalGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup value) {
4200 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -05004201 if (result.hasOptionalGroup &&
Jon Skeet82bb0f12011-04-03 20:17:12 +01004202 result.optionalGroup_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance) {
4203 result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.CreateBuilder(result.optionalGroup_).MergeFrom(value).BuildPartial();
4204 } else {
4205 result.optionalGroup_ = value;
4206 }
4207 result.hasOptionalGroup = true;
4208 return this;
4209 }
4210 public Builder ClearOptionalGroup() {
4211 result.hasOptionalGroup = false;
4212 result.optionalGroup_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.OptionalGroup.DefaultInstance;
4213 return this;
4214 }
4215
4216 public bool HasOptionalNestedMessage {
csharptestc671a4b2011-06-08 11:51:24 -05004217 get { return result.hasOptionalNestedMessage; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004218 }
4219 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage OptionalNestedMessage {
4220 get { return result.OptionalNestedMessage; }
4221 set { SetOptionalNestedMessage(value); }
4222 }
4223 public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) {
4224 pb::ThrowHelper.ThrowIfNull(value, "value");
4225 result.hasOptionalNestedMessage = true;
4226 result.optionalNestedMessage_ = value;
4227 return this;
4228 }
4229 public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) {
4230 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4231 result.hasOptionalNestedMessage = true;
4232 result.optionalNestedMessage_ = builderForValue.Build();
4233 return this;
4234 }
4235 public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) {
4236 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -05004237 if (result.hasOptionalNestedMessage &&
Jon Skeet82bb0f12011-04-03 20:17:12 +01004238 result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) {
4239 result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial();
4240 } else {
4241 result.optionalNestedMessage_ = value;
4242 }
4243 result.hasOptionalNestedMessage = true;
4244 return this;
4245 }
4246 public Builder ClearOptionalNestedMessage() {
4247 result.hasOptionalNestedMessage = false;
4248 result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance;
4249 return this;
4250 }
4251
4252 public bool HasOptionalForeignMessage {
csharptestc671a4b2011-06-08 11:51:24 -05004253 get { return result.hasOptionalForeignMessage; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004254 }
4255 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage OptionalForeignMessage {
4256 get { return result.OptionalForeignMessage; }
4257 set { SetOptionalForeignMessage(value); }
4258 }
4259 public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
4260 pb::ThrowHelper.ThrowIfNull(value, "value");
4261 result.hasOptionalForeignMessage = true;
4262 result.optionalForeignMessage_ = value;
4263 return this;
4264 }
4265 public Builder SetOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) {
4266 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4267 result.hasOptionalForeignMessage = true;
4268 result.optionalForeignMessage_ = builderForValue.Build();
4269 return this;
4270 }
4271 public Builder MergeOptionalForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
4272 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -05004273 if (result.hasOptionalForeignMessage &&
Jon Skeet82bb0f12011-04-03 20:17:12 +01004274 result.optionalForeignMessage_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) {
4275 result.optionalForeignMessage_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.optionalForeignMessage_).MergeFrom(value).BuildPartial();
4276 } else {
4277 result.optionalForeignMessage_ = value;
4278 }
4279 result.hasOptionalForeignMessage = true;
4280 return this;
4281 }
4282 public Builder ClearOptionalForeignMessage() {
4283 result.hasOptionalForeignMessage = false;
4284 result.optionalForeignMessage_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance;
4285 return this;
4286 }
4287
4288 public bool HasOptionalImportMessage {
csharptestc671a4b2011-06-08 11:51:24 -05004289 get { return result.hasOptionalImportMessage; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004290 }
4291 public global::Google.ProtocolBuffers.TestProtos.ImportMessage OptionalImportMessage {
4292 get { return result.OptionalImportMessage; }
4293 set { SetOptionalImportMessage(value); }
4294 }
4295 public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) {
4296 pb::ThrowHelper.ThrowIfNull(value, "value");
4297 result.hasOptionalImportMessage = true;
4298 result.optionalImportMessage_ = value;
4299 return this;
4300 }
4301 public Builder SetOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) {
4302 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4303 result.hasOptionalImportMessage = true;
4304 result.optionalImportMessage_ = builderForValue.Build();
4305 return this;
4306 }
4307 public Builder MergeOptionalImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) {
4308 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -05004309 if (result.hasOptionalImportMessage &&
Jon Skeet82bb0f12011-04-03 20:17:12 +01004310 result.optionalImportMessage_ != global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance) {
4311 result.optionalImportMessage_ = global::Google.ProtocolBuffers.TestProtos.ImportMessage.CreateBuilder(result.optionalImportMessage_).MergeFrom(value).BuildPartial();
4312 } else {
4313 result.optionalImportMessage_ = value;
4314 }
4315 result.hasOptionalImportMessage = true;
4316 return this;
4317 }
4318 public Builder ClearOptionalImportMessage() {
4319 result.hasOptionalImportMessage = false;
4320 result.optionalImportMessage_ = global::Google.ProtocolBuffers.TestProtos.ImportMessage.DefaultInstance;
4321 return this;
4322 }
4323
4324 public bool HasOptionalNestedEnum {
csharptestc671a4b2011-06-08 11:51:24 -05004325 get { return result.hasOptionalNestedEnum; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004326 }
4327 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum OptionalNestedEnum {
4328 get { return result.OptionalNestedEnum; }
4329 set { SetOptionalNestedEnum(value); }
4330 }
4331 public Builder SetOptionalNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) {
4332 result.hasOptionalNestedEnum = true;
4333 result.optionalNestedEnum_ = value;
4334 return this;
4335 }
4336 public Builder ClearOptionalNestedEnum() {
4337 result.hasOptionalNestedEnum = false;
4338 result.optionalNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.FOO;
4339 return this;
4340 }
4341
4342 public bool HasOptionalForeignEnum {
csharptestc671a4b2011-06-08 11:51:24 -05004343 get { return result.hasOptionalForeignEnum; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004344 }
4345 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum OptionalForeignEnum {
4346 get { return result.OptionalForeignEnum; }
4347 set { SetOptionalForeignEnum(value); }
4348 }
4349 public Builder SetOptionalForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
4350 result.hasOptionalForeignEnum = true;
4351 result.optionalForeignEnum_ = value;
4352 return this;
4353 }
4354 public Builder ClearOptionalForeignEnum() {
4355 result.hasOptionalForeignEnum = false;
4356 result.optionalForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO;
4357 return this;
4358 }
4359
4360 public bool HasOptionalImportEnum {
csharptestc671a4b2011-06-08 11:51:24 -05004361 get { return result.hasOptionalImportEnum; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004362 }
4363 public global::Google.ProtocolBuffers.TestProtos.ImportEnum OptionalImportEnum {
4364 get { return result.OptionalImportEnum; }
4365 set { SetOptionalImportEnum(value); }
4366 }
4367 public Builder SetOptionalImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) {
4368 result.hasOptionalImportEnum = true;
4369 result.optionalImportEnum_ = value;
4370 return this;
4371 }
4372 public Builder ClearOptionalImportEnum() {
4373 result.hasOptionalImportEnum = false;
4374 result.optionalImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_FOO;
4375 return this;
4376 }
4377
4378 public bool HasOptionalStringPiece {
csharptestc671a4b2011-06-08 11:51:24 -05004379 get { return result.hasOptionalStringPiece; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004380 }
4381 public string OptionalStringPiece {
4382 get { return result.OptionalStringPiece; }
4383 set { SetOptionalStringPiece(value); }
4384 }
4385 public Builder SetOptionalStringPiece(string value) {
4386 pb::ThrowHelper.ThrowIfNull(value, "value");
4387 result.hasOptionalStringPiece = true;
4388 result.optionalStringPiece_ = value;
4389 return this;
4390 }
4391 public Builder ClearOptionalStringPiece() {
4392 result.hasOptionalStringPiece = false;
4393 result.optionalStringPiece_ = "";
4394 return this;
4395 }
4396
4397 public bool HasOptionalCord {
csharptestc671a4b2011-06-08 11:51:24 -05004398 get { return result.hasOptionalCord; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01004399 }
4400 public string OptionalCord {
4401 get { return result.OptionalCord; }
4402 set { SetOptionalCord(value); }
4403 }
4404 public Builder SetOptionalCord(string value) {
4405 pb::ThrowHelper.ThrowIfNull(value, "value");
4406 result.hasOptionalCord = true;
4407 result.optionalCord_ = value;
4408 return this;
4409 }
4410 public Builder ClearOptionalCord() {
4411 result.hasOptionalCord = false;
4412 result.optionalCord_ = "";
4413 return this;
4414 }
4415
4416 public pbc::IPopsicleList<int> RepeatedInt32List {
4417 get { return result.repeatedInt32_; }
4418 }
4419 public int RepeatedInt32Count {
4420 get { return result.RepeatedInt32Count; }
4421 }
4422 public int GetRepeatedInt32(int index) {
4423 return result.GetRepeatedInt32(index);
4424 }
4425 public Builder SetRepeatedInt32(int index, int value) {
4426 result.repeatedInt32_[index] = value;
4427 return this;
4428 }
4429 public Builder AddRepeatedInt32(int value) {
4430 result.repeatedInt32_.Add(value);
4431 return this;
4432 }
4433 public Builder AddRangeRepeatedInt32(scg::IEnumerable<int> values) {
4434 base.AddRange(values, result.repeatedInt32_);
4435 return this;
4436 }
4437 public Builder ClearRepeatedInt32() {
4438 result.repeatedInt32_.Clear();
4439 return this;
4440 }
4441
4442 public pbc::IPopsicleList<long> RepeatedInt64List {
4443 get { return result.repeatedInt64_; }
4444 }
4445 public int RepeatedInt64Count {
4446 get { return result.RepeatedInt64Count; }
4447 }
4448 public long GetRepeatedInt64(int index) {
4449 return result.GetRepeatedInt64(index);
4450 }
4451 public Builder SetRepeatedInt64(int index, long value) {
4452 result.repeatedInt64_[index] = value;
4453 return this;
4454 }
4455 public Builder AddRepeatedInt64(long value) {
4456 result.repeatedInt64_.Add(value);
4457 return this;
4458 }
4459 public Builder AddRangeRepeatedInt64(scg::IEnumerable<long> values) {
4460 base.AddRange(values, result.repeatedInt64_);
4461 return this;
4462 }
4463 public Builder ClearRepeatedInt64() {
4464 result.repeatedInt64_.Clear();
4465 return this;
4466 }
4467
4468 [global::System.CLSCompliant(false)]
4469 public pbc::IPopsicleList<uint> RepeatedUint32List {
4470 get { return result.repeatedUint32_; }
4471 }
4472 public int RepeatedUint32Count {
4473 get { return result.RepeatedUint32Count; }
4474 }
4475 [global::System.CLSCompliant(false)]
4476 public uint GetRepeatedUint32(int index) {
4477 return result.GetRepeatedUint32(index);
4478 }
4479 [global::System.CLSCompliant(false)]
4480 public Builder SetRepeatedUint32(int index, uint value) {
4481 result.repeatedUint32_[index] = value;
4482 return this;
4483 }
4484 [global::System.CLSCompliant(false)]
4485 public Builder AddRepeatedUint32(uint value) {
4486 result.repeatedUint32_.Add(value);
4487 return this;
4488 }
4489 [global::System.CLSCompliant(false)]
4490 public Builder AddRangeRepeatedUint32(scg::IEnumerable<uint> values) {
4491 base.AddRange(values, result.repeatedUint32_);
4492 return this;
4493 }
4494 public Builder ClearRepeatedUint32() {
4495 result.repeatedUint32_.Clear();
4496 return this;
4497 }
4498
4499 [global::System.CLSCompliant(false)]
4500 public pbc::IPopsicleList<ulong> RepeatedUint64List {
4501 get { return result.repeatedUint64_; }
4502 }
4503 public int RepeatedUint64Count {
4504 get { return result.RepeatedUint64Count; }
4505 }
4506 [global::System.CLSCompliant(false)]
4507 public ulong GetRepeatedUint64(int index) {
4508 return result.GetRepeatedUint64(index);
4509 }
4510 [global::System.CLSCompliant(false)]
4511 public Builder SetRepeatedUint64(int index, ulong value) {
4512 result.repeatedUint64_[index] = value;
4513 return this;
4514 }
4515 [global::System.CLSCompliant(false)]
4516 public Builder AddRepeatedUint64(ulong value) {
4517 result.repeatedUint64_.Add(value);
4518 return this;
4519 }
4520 [global::System.CLSCompliant(false)]
4521 public Builder AddRangeRepeatedUint64(scg::IEnumerable<ulong> values) {
4522 base.AddRange(values, result.repeatedUint64_);
4523 return this;
4524 }
4525 public Builder ClearRepeatedUint64() {
4526 result.repeatedUint64_.Clear();
4527 return this;
4528 }
4529
4530 public pbc::IPopsicleList<int> RepeatedSint32List {
4531 get { return result.repeatedSint32_; }
4532 }
4533 public int RepeatedSint32Count {
4534 get { return result.RepeatedSint32Count; }
4535 }
4536 public int GetRepeatedSint32(int index) {
4537 return result.GetRepeatedSint32(index);
4538 }
4539 public Builder SetRepeatedSint32(int index, int value) {
4540 result.repeatedSint32_[index] = value;
4541 return this;
4542 }
4543 public Builder AddRepeatedSint32(int value) {
4544 result.repeatedSint32_.Add(value);
4545 return this;
4546 }
4547 public Builder AddRangeRepeatedSint32(scg::IEnumerable<int> values) {
4548 base.AddRange(values, result.repeatedSint32_);
4549 return this;
4550 }
4551 public Builder ClearRepeatedSint32() {
4552 result.repeatedSint32_.Clear();
4553 return this;
4554 }
4555
4556 public pbc::IPopsicleList<long> RepeatedSint64List {
4557 get { return result.repeatedSint64_; }
4558 }
4559 public int RepeatedSint64Count {
4560 get { return result.RepeatedSint64Count; }
4561 }
4562 public long GetRepeatedSint64(int index) {
4563 return result.GetRepeatedSint64(index);
4564 }
4565 public Builder SetRepeatedSint64(int index, long value) {
4566 result.repeatedSint64_[index] = value;
4567 return this;
4568 }
4569 public Builder AddRepeatedSint64(long value) {
4570 result.repeatedSint64_.Add(value);
4571 return this;
4572 }
4573 public Builder AddRangeRepeatedSint64(scg::IEnumerable<long> values) {
4574 base.AddRange(values, result.repeatedSint64_);
4575 return this;
4576 }
4577 public Builder ClearRepeatedSint64() {
4578 result.repeatedSint64_.Clear();
4579 return this;
4580 }
4581
4582 [global::System.CLSCompliant(false)]
4583 public pbc::IPopsicleList<uint> RepeatedFixed32List {
4584 get { return result.repeatedFixed32_; }
4585 }
4586 public int RepeatedFixed32Count {
4587 get { return result.RepeatedFixed32Count; }
4588 }
4589 [global::System.CLSCompliant(false)]
4590 public uint GetRepeatedFixed32(int index) {
4591 return result.GetRepeatedFixed32(index);
4592 }
4593 [global::System.CLSCompliant(false)]
4594 public Builder SetRepeatedFixed32(int index, uint value) {
4595 result.repeatedFixed32_[index] = value;
4596 return this;
4597 }
4598 [global::System.CLSCompliant(false)]
4599 public Builder AddRepeatedFixed32(uint value) {
4600 result.repeatedFixed32_.Add(value);
4601 return this;
4602 }
4603 [global::System.CLSCompliant(false)]
4604 public Builder AddRangeRepeatedFixed32(scg::IEnumerable<uint> values) {
4605 base.AddRange(values, result.repeatedFixed32_);
4606 return this;
4607 }
4608 public Builder ClearRepeatedFixed32() {
4609 result.repeatedFixed32_.Clear();
4610 return this;
4611 }
4612
4613 [global::System.CLSCompliant(false)]
4614 public pbc::IPopsicleList<ulong> RepeatedFixed64List {
4615 get { return result.repeatedFixed64_; }
4616 }
4617 public int RepeatedFixed64Count {
4618 get { return result.RepeatedFixed64Count; }
4619 }
4620 [global::System.CLSCompliant(false)]
4621 public ulong GetRepeatedFixed64(int index) {
4622 return result.GetRepeatedFixed64(index);
4623 }
4624 [global::System.CLSCompliant(false)]
4625 public Builder SetRepeatedFixed64(int index, ulong value) {
4626 result.repeatedFixed64_[index] = value;
4627 return this;
4628 }
4629 [global::System.CLSCompliant(false)]
4630 public Builder AddRepeatedFixed64(ulong value) {
4631 result.repeatedFixed64_.Add(value);
4632 return this;
4633 }
4634 [global::System.CLSCompliant(false)]
4635 public Builder AddRangeRepeatedFixed64(scg::IEnumerable<ulong> values) {
4636 base.AddRange(values, result.repeatedFixed64_);
4637 return this;
4638 }
4639 public Builder ClearRepeatedFixed64() {
4640 result.repeatedFixed64_.Clear();
4641 return this;
4642 }
4643
4644 public pbc::IPopsicleList<int> RepeatedSfixed32List {
4645 get { return result.repeatedSfixed32_; }
4646 }
4647 public int RepeatedSfixed32Count {
4648 get { return result.RepeatedSfixed32Count; }
4649 }
4650 public int GetRepeatedSfixed32(int index) {
4651 return result.GetRepeatedSfixed32(index);
4652 }
4653 public Builder SetRepeatedSfixed32(int index, int value) {
4654 result.repeatedSfixed32_[index] = value;
4655 return this;
4656 }
4657 public Builder AddRepeatedSfixed32(int value) {
4658 result.repeatedSfixed32_.Add(value);
4659 return this;
4660 }
4661 public Builder AddRangeRepeatedSfixed32(scg::IEnumerable<int> values) {
4662 base.AddRange(values, result.repeatedSfixed32_);
4663 return this;
4664 }
4665 public Builder ClearRepeatedSfixed32() {
4666 result.repeatedSfixed32_.Clear();
4667 return this;
4668 }
4669
4670 public pbc::IPopsicleList<long> RepeatedSfixed64List {
4671 get { return result.repeatedSfixed64_; }
4672 }
4673 public int RepeatedSfixed64Count {
4674 get { return result.RepeatedSfixed64Count; }
4675 }
4676 public long GetRepeatedSfixed64(int index) {
4677 return result.GetRepeatedSfixed64(index);
4678 }
4679 public Builder SetRepeatedSfixed64(int index, long value) {
4680 result.repeatedSfixed64_[index] = value;
4681 return this;
4682 }
4683 public Builder AddRepeatedSfixed64(long value) {
4684 result.repeatedSfixed64_.Add(value);
4685 return this;
4686 }
4687 public Builder AddRangeRepeatedSfixed64(scg::IEnumerable<long> values) {
4688 base.AddRange(values, result.repeatedSfixed64_);
4689 return this;
4690 }
4691 public Builder ClearRepeatedSfixed64() {
4692 result.repeatedSfixed64_.Clear();
4693 return this;
4694 }
4695
4696 public pbc::IPopsicleList<float> RepeatedFloatList {
4697 get { return result.repeatedFloat_; }
4698 }
4699 public int RepeatedFloatCount {
4700 get { return result.RepeatedFloatCount; }
4701 }
4702 public float GetRepeatedFloat(int index) {
4703 return result.GetRepeatedFloat(index);
4704 }
4705 public Builder SetRepeatedFloat(int index, float value) {
4706 result.repeatedFloat_[index] = value;
4707 return this;
4708 }
4709 public Builder AddRepeatedFloat(float value) {
4710 result.repeatedFloat_.Add(value);
4711 return this;
4712 }
4713 public Builder AddRangeRepeatedFloat(scg::IEnumerable<float> values) {
4714 base.AddRange(values, result.repeatedFloat_);
4715 return this;
4716 }
4717 public Builder ClearRepeatedFloat() {
4718 result.repeatedFloat_.Clear();
4719 return this;
4720 }
4721
4722 public pbc::IPopsicleList<double> RepeatedDoubleList {
4723 get { return result.repeatedDouble_; }
4724 }
4725 public int RepeatedDoubleCount {
4726 get { return result.RepeatedDoubleCount; }
4727 }
4728 public double GetRepeatedDouble(int index) {
4729 return result.GetRepeatedDouble(index);
4730 }
4731 public Builder SetRepeatedDouble(int index, double value) {
4732 result.repeatedDouble_[index] = value;
4733 return this;
4734 }
4735 public Builder AddRepeatedDouble(double value) {
4736 result.repeatedDouble_.Add(value);
4737 return this;
4738 }
4739 public Builder AddRangeRepeatedDouble(scg::IEnumerable<double> values) {
4740 base.AddRange(values, result.repeatedDouble_);
4741 return this;
4742 }
4743 public Builder ClearRepeatedDouble() {
4744 result.repeatedDouble_.Clear();
4745 return this;
4746 }
4747
4748 public pbc::IPopsicleList<bool> RepeatedBoolList {
4749 get { return result.repeatedBool_; }
4750 }
4751 public int RepeatedBoolCount {
4752 get { return result.RepeatedBoolCount; }
4753 }
4754 public bool GetRepeatedBool(int index) {
4755 return result.GetRepeatedBool(index);
4756 }
4757 public Builder SetRepeatedBool(int index, bool value) {
4758 result.repeatedBool_[index] = value;
4759 return this;
4760 }
4761 public Builder AddRepeatedBool(bool value) {
4762 result.repeatedBool_.Add(value);
4763 return this;
4764 }
4765 public Builder AddRangeRepeatedBool(scg::IEnumerable<bool> values) {
4766 base.AddRange(values, result.repeatedBool_);
4767 return this;
4768 }
4769 public Builder ClearRepeatedBool() {
4770 result.repeatedBool_.Clear();
4771 return this;
4772 }
4773
4774 public pbc::IPopsicleList<string> RepeatedStringList {
4775 get { return result.repeatedString_; }
4776 }
4777 public int RepeatedStringCount {
4778 get { return result.RepeatedStringCount; }
4779 }
4780 public string GetRepeatedString(int index) {
4781 return result.GetRepeatedString(index);
4782 }
4783 public Builder SetRepeatedString(int index, string value) {
4784 pb::ThrowHelper.ThrowIfNull(value, "value");
4785 result.repeatedString_[index] = value;
4786 return this;
4787 }
4788 public Builder AddRepeatedString(string value) {
4789 pb::ThrowHelper.ThrowIfNull(value, "value");
4790 result.repeatedString_.Add(value);
4791 return this;
4792 }
4793 public Builder AddRangeRepeatedString(scg::IEnumerable<string> values) {
4794 base.AddRange(values, result.repeatedString_);
4795 return this;
4796 }
4797 public Builder ClearRepeatedString() {
4798 result.repeatedString_.Clear();
4799 return this;
4800 }
4801
4802 public pbc::IPopsicleList<pb::ByteString> RepeatedBytesList {
4803 get { return result.repeatedBytes_; }
4804 }
4805 public int RepeatedBytesCount {
4806 get { return result.RepeatedBytesCount; }
4807 }
4808 public pb::ByteString GetRepeatedBytes(int index) {
4809 return result.GetRepeatedBytes(index);
4810 }
4811 public Builder SetRepeatedBytes(int index, pb::ByteString value) {
4812 pb::ThrowHelper.ThrowIfNull(value, "value");
4813 result.repeatedBytes_[index] = value;
4814 return this;
4815 }
4816 public Builder AddRepeatedBytes(pb::ByteString value) {
4817 pb::ThrowHelper.ThrowIfNull(value, "value");
4818 result.repeatedBytes_.Add(value);
4819 return this;
4820 }
4821 public Builder AddRangeRepeatedBytes(scg::IEnumerable<pb::ByteString> values) {
4822 base.AddRange(values, result.repeatedBytes_);
4823 return this;
4824 }
4825 public Builder ClearRepeatedBytes() {
4826 result.repeatedBytes_.Clear();
4827 return this;
4828 }
4829
4830 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup> RepeatedGroupList {
4831 get { return result.repeatedGroup_; }
4832 }
4833 public int RepeatedGroupCount {
4834 get { return result.RepeatedGroupCount; }
4835 }
4836 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup GetRepeatedGroup(int index) {
4837 return result.GetRepeatedGroup(index);
4838 }
4839 public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup value) {
4840 pb::ThrowHelper.ThrowIfNull(value, "value");
4841 result.repeatedGroup_[index] = value;
4842 return this;
4843 }
4844 public Builder SetRepeatedGroup(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder builderForValue) {
4845 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4846 result.repeatedGroup_[index] = builderForValue.Build();
4847 return this;
4848 }
4849 public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup value) {
4850 pb::ThrowHelper.ThrowIfNull(value, "value");
4851 result.repeatedGroup_.Add(value);
4852 return this;
4853 }
4854 public Builder AddRepeatedGroup(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup.Builder builderForValue) {
4855 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4856 result.repeatedGroup_.Add(builderForValue.Build());
4857 return this;
4858 }
4859 public Builder AddRangeRepeatedGroup(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.RepeatedGroup> values) {
4860 base.AddRange(values, result.repeatedGroup_);
4861 return this;
4862 }
4863 public Builder ClearRepeatedGroup() {
4864 result.repeatedGroup_.Clear();
4865 return this;
4866 }
4867
4868 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage> RepeatedNestedMessageList {
4869 get { return result.repeatedNestedMessage_; }
4870 }
4871 public int RepeatedNestedMessageCount {
4872 get { return result.RepeatedNestedMessageCount; }
4873 }
4874 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage GetRepeatedNestedMessage(int index) {
4875 return result.GetRepeatedNestedMessage(index);
4876 }
4877 public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) {
4878 pb::ThrowHelper.ThrowIfNull(value, "value");
4879 result.repeatedNestedMessage_[index] = value;
4880 return this;
4881 }
4882 public Builder SetRepeatedNestedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) {
4883 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4884 result.repeatedNestedMessage_[index] = builderForValue.Build();
4885 return this;
4886 }
4887 public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) {
4888 pb::ThrowHelper.ThrowIfNull(value, "value");
4889 result.repeatedNestedMessage_.Add(value);
4890 return this;
4891 }
4892 public Builder AddRepeatedNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) {
4893 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4894 result.repeatedNestedMessage_.Add(builderForValue.Build());
4895 return this;
4896 }
4897 public Builder AddRangeRepeatedNestedMessage(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage> values) {
4898 base.AddRange(values, result.repeatedNestedMessage_);
4899 return this;
4900 }
4901 public Builder ClearRepeatedNestedMessage() {
4902 result.repeatedNestedMessage_.Clear();
4903 return this;
4904 }
4905
4906 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> RepeatedForeignMessageList {
4907 get { return result.repeatedForeignMessage_; }
4908 }
4909 public int RepeatedForeignMessageCount {
4910 get { return result.RepeatedForeignMessageCount; }
4911 }
4912 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedForeignMessage(int index) {
4913 return result.GetRepeatedForeignMessage(index);
4914 }
4915 public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
4916 pb::ThrowHelper.ThrowIfNull(value, "value");
4917 result.repeatedForeignMessage_[index] = value;
4918 return this;
4919 }
4920 public Builder SetRepeatedForeignMessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) {
4921 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4922 result.repeatedForeignMessage_[index] = builderForValue.Build();
4923 return this;
4924 }
4925 public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
4926 pb::ThrowHelper.ThrowIfNull(value, "value");
4927 result.repeatedForeignMessage_.Add(value);
4928 return this;
4929 }
4930 public Builder AddRepeatedForeignMessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) {
4931 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4932 result.repeatedForeignMessage_.Add(builderForValue.Build());
4933 return this;
4934 }
4935 public Builder AddRangeRepeatedForeignMessage(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> values) {
4936 base.AddRange(values, result.repeatedForeignMessage_);
4937 return this;
4938 }
4939 public Builder ClearRepeatedForeignMessage() {
4940 result.repeatedForeignMessage_.Clear();
4941 return this;
4942 }
4943
4944 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.ImportMessage> RepeatedImportMessageList {
4945 get { return result.repeatedImportMessage_; }
4946 }
4947 public int RepeatedImportMessageCount {
4948 get { return result.RepeatedImportMessageCount; }
4949 }
4950 public global::Google.ProtocolBuffers.TestProtos.ImportMessage GetRepeatedImportMessage(int index) {
4951 return result.GetRepeatedImportMessage(index);
4952 }
4953 public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessage value) {
4954 pb::ThrowHelper.ThrowIfNull(value, "value");
4955 result.repeatedImportMessage_[index] = value;
4956 return this;
4957 }
4958 public Builder SetRepeatedImportMessage(int index, global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) {
4959 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4960 result.repeatedImportMessage_[index] = builderForValue.Build();
4961 return this;
4962 }
4963 public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage value) {
4964 pb::ThrowHelper.ThrowIfNull(value, "value");
4965 result.repeatedImportMessage_.Add(value);
4966 return this;
4967 }
4968 public Builder AddRepeatedImportMessage(global::Google.ProtocolBuffers.TestProtos.ImportMessage.Builder builderForValue) {
4969 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
4970 result.repeatedImportMessage_.Add(builderForValue.Build());
4971 return this;
4972 }
4973 public Builder AddRangeRepeatedImportMessage(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.ImportMessage> values) {
4974 base.AddRange(values, result.repeatedImportMessage_);
4975 return this;
4976 }
4977 public Builder ClearRepeatedImportMessage() {
4978 result.repeatedImportMessage_.Clear();
4979 return this;
4980 }
4981
4982 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum> RepeatedNestedEnumList {
4983 get { return result.repeatedNestedEnum_; }
4984 }
4985 public int RepeatedNestedEnumCount {
4986 get { return result.RepeatedNestedEnumCount; }
4987 }
4988 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum GetRepeatedNestedEnum(int index) {
4989 return result.GetRepeatedNestedEnum(index);
4990 }
4991 public Builder SetRepeatedNestedEnum(int index, global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) {
4992 result.repeatedNestedEnum_[index] = value;
4993 return this;
4994 }
4995 public Builder AddRepeatedNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) {
4996 result.repeatedNestedEnum_.Add(value);
4997 return this;
4998 }
4999 public Builder AddRangeRepeatedNestedEnum(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum> values) {
5000 base.AddRange(values, result.repeatedNestedEnum_);
5001 return this;
5002 }
5003 public Builder ClearRepeatedNestedEnum() {
5004 result.repeatedNestedEnum_.Clear();
5005 return this;
5006 }
5007
5008 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> RepeatedForeignEnumList {
5009 get { return result.repeatedForeignEnum_; }
5010 }
5011 public int RepeatedForeignEnumCount {
5012 get { return result.RepeatedForeignEnumCount; }
5013 }
5014 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedForeignEnum(int index) {
5015 return result.GetRepeatedForeignEnum(index);
5016 }
5017 public Builder SetRepeatedForeignEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
5018 result.repeatedForeignEnum_[index] = value;
5019 return this;
5020 }
5021 public Builder AddRepeatedForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
5022 result.repeatedForeignEnum_.Add(value);
5023 return this;
5024 }
5025 public Builder AddRangeRepeatedForeignEnum(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> values) {
5026 base.AddRange(values, result.repeatedForeignEnum_);
5027 return this;
5028 }
5029 public Builder ClearRepeatedForeignEnum() {
5030 result.repeatedForeignEnum_.Clear();
5031 return this;
5032 }
5033
5034 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.ImportEnum> RepeatedImportEnumList {
5035 get { return result.repeatedImportEnum_; }
5036 }
5037 public int RepeatedImportEnumCount {
5038 get { return result.RepeatedImportEnumCount; }
5039 }
5040 public global::Google.ProtocolBuffers.TestProtos.ImportEnum GetRepeatedImportEnum(int index) {
5041 return result.GetRepeatedImportEnum(index);
5042 }
5043 public Builder SetRepeatedImportEnum(int index, global::Google.ProtocolBuffers.TestProtos.ImportEnum value) {
5044 result.repeatedImportEnum_[index] = value;
5045 return this;
5046 }
5047 public Builder AddRepeatedImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) {
5048 result.repeatedImportEnum_.Add(value);
5049 return this;
5050 }
5051 public Builder AddRangeRepeatedImportEnum(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.ImportEnum> values) {
5052 base.AddRange(values, result.repeatedImportEnum_);
5053 return this;
5054 }
5055 public Builder ClearRepeatedImportEnum() {
5056 result.repeatedImportEnum_.Clear();
5057 return this;
5058 }
5059
5060 public pbc::IPopsicleList<string> RepeatedStringPieceList {
5061 get { return result.repeatedStringPiece_; }
5062 }
5063 public int RepeatedStringPieceCount {
5064 get { return result.RepeatedStringPieceCount; }
5065 }
5066 public string GetRepeatedStringPiece(int index) {
5067 return result.GetRepeatedStringPiece(index);
5068 }
5069 public Builder SetRepeatedStringPiece(int index, string value) {
5070 pb::ThrowHelper.ThrowIfNull(value, "value");
5071 result.repeatedStringPiece_[index] = value;
5072 return this;
5073 }
5074 public Builder AddRepeatedStringPiece(string value) {
5075 pb::ThrowHelper.ThrowIfNull(value, "value");
5076 result.repeatedStringPiece_.Add(value);
5077 return this;
5078 }
5079 public Builder AddRangeRepeatedStringPiece(scg::IEnumerable<string> values) {
5080 base.AddRange(values, result.repeatedStringPiece_);
5081 return this;
5082 }
5083 public Builder ClearRepeatedStringPiece() {
5084 result.repeatedStringPiece_.Clear();
5085 return this;
5086 }
5087
5088 public pbc::IPopsicleList<string> RepeatedCordList {
5089 get { return result.repeatedCord_; }
5090 }
5091 public int RepeatedCordCount {
5092 get { return result.RepeatedCordCount; }
5093 }
5094 public string GetRepeatedCord(int index) {
5095 return result.GetRepeatedCord(index);
5096 }
5097 public Builder SetRepeatedCord(int index, string value) {
5098 pb::ThrowHelper.ThrowIfNull(value, "value");
5099 result.repeatedCord_[index] = value;
5100 return this;
5101 }
5102 public Builder AddRepeatedCord(string value) {
5103 pb::ThrowHelper.ThrowIfNull(value, "value");
5104 result.repeatedCord_.Add(value);
5105 return this;
5106 }
5107 public Builder AddRangeRepeatedCord(scg::IEnumerable<string> values) {
5108 base.AddRange(values, result.repeatedCord_);
5109 return this;
5110 }
5111 public Builder ClearRepeatedCord() {
5112 result.repeatedCord_.Clear();
5113 return this;
5114 }
5115
5116 public bool HasDefaultInt32 {
csharptestc671a4b2011-06-08 11:51:24 -05005117 get { return result.hasDefaultInt32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005118 }
5119 public int DefaultInt32 {
5120 get { return result.DefaultInt32; }
5121 set { SetDefaultInt32(value); }
5122 }
5123 public Builder SetDefaultInt32(int value) {
5124 result.hasDefaultInt32 = true;
5125 result.defaultInt32_ = value;
5126 return this;
5127 }
5128 public Builder ClearDefaultInt32() {
5129 result.hasDefaultInt32 = false;
5130 result.defaultInt32_ = 41;
5131 return this;
5132 }
5133
5134 public bool HasDefaultInt64 {
csharptestc671a4b2011-06-08 11:51:24 -05005135 get { return result.hasDefaultInt64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005136 }
5137 public long DefaultInt64 {
5138 get { return result.DefaultInt64; }
5139 set { SetDefaultInt64(value); }
5140 }
5141 public Builder SetDefaultInt64(long value) {
5142 result.hasDefaultInt64 = true;
5143 result.defaultInt64_ = value;
5144 return this;
5145 }
5146 public Builder ClearDefaultInt64() {
5147 result.hasDefaultInt64 = false;
5148 result.defaultInt64_ = 42L;
5149 return this;
5150 }
5151
5152 public bool HasDefaultUint32 {
csharptestc671a4b2011-06-08 11:51:24 -05005153 get { return result.hasDefaultUint32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005154 }
5155 [global::System.CLSCompliant(false)]
5156 public uint DefaultUint32 {
5157 get { return result.DefaultUint32; }
5158 set { SetDefaultUint32(value); }
5159 }
5160 [global::System.CLSCompliant(false)]
5161 public Builder SetDefaultUint32(uint value) {
5162 result.hasDefaultUint32 = true;
5163 result.defaultUint32_ = value;
5164 return this;
5165 }
5166 public Builder ClearDefaultUint32() {
5167 result.hasDefaultUint32 = false;
5168 result.defaultUint32_ = 43;
5169 return this;
5170 }
5171
5172 public bool HasDefaultUint64 {
csharptestc671a4b2011-06-08 11:51:24 -05005173 get { return result.hasDefaultUint64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005174 }
5175 [global::System.CLSCompliant(false)]
5176 public ulong DefaultUint64 {
5177 get { return result.DefaultUint64; }
5178 set { SetDefaultUint64(value); }
5179 }
5180 [global::System.CLSCompliant(false)]
5181 public Builder SetDefaultUint64(ulong value) {
5182 result.hasDefaultUint64 = true;
5183 result.defaultUint64_ = value;
5184 return this;
5185 }
5186 public Builder ClearDefaultUint64() {
5187 result.hasDefaultUint64 = false;
5188 result.defaultUint64_ = 44UL;
5189 return this;
5190 }
5191
5192 public bool HasDefaultSint32 {
csharptestc671a4b2011-06-08 11:51:24 -05005193 get { return result.hasDefaultSint32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005194 }
5195 public int DefaultSint32 {
5196 get { return result.DefaultSint32; }
5197 set { SetDefaultSint32(value); }
5198 }
5199 public Builder SetDefaultSint32(int value) {
5200 result.hasDefaultSint32 = true;
5201 result.defaultSint32_ = value;
5202 return this;
5203 }
5204 public Builder ClearDefaultSint32() {
5205 result.hasDefaultSint32 = false;
5206 result.defaultSint32_ = -45;
5207 return this;
5208 }
5209
5210 public bool HasDefaultSint64 {
csharptestc671a4b2011-06-08 11:51:24 -05005211 get { return result.hasDefaultSint64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005212 }
5213 public long DefaultSint64 {
5214 get { return result.DefaultSint64; }
5215 set { SetDefaultSint64(value); }
5216 }
5217 public Builder SetDefaultSint64(long value) {
5218 result.hasDefaultSint64 = true;
5219 result.defaultSint64_ = value;
5220 return this;
5221 }
5222 public Builder ClearDefaultSint64() {
5223 result.hasDefaultSint64 = false;
5224 result.defaultSint64_ = 46;
5225 return this;
5226 }
5227
5228 public bool HasDefaultFixed32 {
csharptestc671a4b2011-06-08 11:51:24 -05005229 get { return result.hasDefaultFixed32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005230 }
5231 [global::System.CLSCompliant(false)]
5232 public uint DefaultFixed32 {
5233 get { return result.DefaultFixed32; }
5234 set { SetDefaultFixed32(value); }
5235 }
5236 [global::System.CLSCompliant(false)]
5237 public Builder SetDefaultFixed32(uint value) {
5238 result.hasDefaultFixed32 = true;
5239 result.defaultFixed32_ = value;
5240 return this;
5241 }
5242 public Builder ClearDefaultFixed32() {
5243 result.hasDefaultFixed32 = false;
5244 result.defaultFixed32_ = 47;
5245 return this;
5246 }
5247
5248 public bool HasDefaultFixed64 {
csharptestc671a4b2011-06-08 11:51:24 -05005249 get { return result.hasDefaultFixed64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005250 }
5251 [global::System.CLSCompliant(false)]
5252 public ulong DefaultFixed64 {
5253 get { return result.DefaultFixed64; }
5254 set { SetDefaultFixed64(value); }
5255 }
5256 [global::System.CLSCompliant(false)]
5257 public Builder SetDefaultFixed64(ulong value) {
5258 result.hasDefaultFixed64 = true;
5259 result.defaultFixed64_ = value;
5260 return this;
5261 }
5262 public Builder ClearDefaultFixed64() {
5263 result.hasDefaultFixed64 = false;
5264 result.defaultFixed64_ = 48;
5265 return this;
5266 }
5267
5268 public bool HasDefaultSfixed32 {
csharptestc671a4b2011-06-08 11:51:24 -05005269 get { return result.hasDefaultSfixed32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005270 }
5271 public int DefaultSfixed32 {
5272 get { return result.DefaultSfixed32; }
5273 set { SetDefaultSfixed32(value); }
5274 }
5275 public Builder SetDefaultSfixed32(int value) {
5276 result.hasDefaultSfixed32 = true;
5277 result.defaultSfixed32_ = value;
5278 return this;
5279 }
5280 public Builder ClearDefaultSfixed32() {
5281 result.hasDefaultSfixed32 = false;
5282 result.defaultSfixed32_ = 49;
5283 return this;
5284 }
5285
5286 public bool HasDefaultSfixed64 {
csharptestc671a4b2011-06-08 11:51:24 -05005287 get { return result.hasDefaultSfixed64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005288 }
5289 public long DefaultSfixed64 {
5290 get { return result.DefaultSfixed64; }
5291 set { SetDefaultSfixed64(value); }
5292 }
5293 public Builder SetDefaultSfixed64(long value) {
5294 result.hasDefaultSfixed64 = true;
5295 result.defaultSfixed64_ = value;
5296 return this;
5297 }
5298 public Builder ClearDefaultSfixed64() {
5299 result.hasDefaultSfixed64 = false;
5300 result.defaultSfixed64_ = -50;
5301 return this;
5302 }
5303
5304 public bool HasDefaultFloat {
csharptestc671a4b2011-06-08 11:51:24 -05005305 get { return result.hasDefaultFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005306 }
5307 public float DefaultFloat {
5308 get { return result.DefaultFloat; }
5309 set { SetDefaultFloat(value); }
5310 }
5311 public Builder SetDefaultFloat(float value) {
5312 result.hasDefaultFloat = true;
5313 result.defaultFloat_ = value;
5314 return this;
5315 }
5316 public Builder ClearDefaultFloat() {
5317 result.hasDefaultFloat = false;
5318 result.defaultFloat_ = 51.5F;
5319 return this;
5320 }
5321
5322 public bool HasDefaultDouble {
csharptestc671a4b2011-06-08 11:51:24 -05005323 get { return result.hasDefaultDouble; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005324 }
5325 public double DefaultDouble {
5326 get { return result.DefaultDouble; }
5327 set { SetDefaultDouble(value); }
5328 }
5329 public Builder SetDefaultDouble(double value) {
5330 result.hasDefaultDouble = true;
5331 result.defaultDouble_ = value;
5332 return this;
5333 }
5334 public Builder ClearDefaultDouble() {
5335 result.hasDefaultDouble = false;
5336 result.defaultDouble_ = 52000D;
5337 return this;
5338 }
5339
5340 public bool HasDefaultBool {
csharptestc671a4b2011-06-08 11:51:24 -05005341 get { return result.hasDefaultBool; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005342 }
5343 public bool DefaultBool {
5344 get { return result.DefaultBool; }
5345 set { SetDefaultBool(value); }
5346 }
5347 public Builder SetDefaultBool(bool value) {
5348 result.hasDefaultBool = true;
5349 result.defaultBool_ = value;
5350 return this;
5351 }
5352 public Builder ClearDefaultBool() {
5353 result.hasDefaultBool = false;
5354 result.defaultBool_ = true;
5355 return this;
5356 }
5357
5358 public bool HasDefaultString {
csharptestc671a4b2011-06-08 11:51:24 -05005359 get { return result.hasDefaultString; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005360 }
5361 public string DefaultString {
5362 get { return result.DefaultString; }
5363 set { SetDefaultString(value); }
5364 }
5365 public Builder SetDefaultString(string value) {
5366 pb::ThrowHelper.ThrowIfNull(value, "value");
5367 result.hasDefaultString = true;
5368 result.defaultString_ = value;
5369 return this;
5370 }
5371 public Builder ClearDefaultString() {
5372 result.hasDefaultString = false;
5373 result.defaultString_ = "hello";
5374 return this;
5375 }
5376
5377 public bool HasDefaultBytes {
csharptestc671a4b2011-06-08 11:51:24 -05005378 get { return result.hasDefaultBytes; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005379 }
5380 public pb::ByteString DefaultBytes {
5381 get { return result.DefaultBytes; }
5382 set { SetDefaultBytes(value); }
5383 }
5384 public Builder SetDefaultBytes(pb::ByteString value) {
5385 pb::ThrowHelper.ThrowIfNull(value, "value");
5386 result.hasDefaultBytes = true;
5387 result.defaultBytes_ = value;
5388 return this;
5389 }
5390 public Builder ClearDefaultBytes() {
5391 result.hasDefaultBytes = false;
5392 result.defaultBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Descriptor.Fields[62].DefaultValue;
5393 return this;
5394 }
5395
5396 public bool HasDefaultNestedEnum {
csharptestc671a4b2011-06-08 11:51:24 -05005397 get { return result.hasDefaultNestedEnum; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005398 }
5399 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum DefaultNestedEnum {
5400 get { return result.DefaultNestedEnum; }
5401 set { SetDefaultNestedEnum(value); }
5402 }
5403 public Builder SetDefaultNestedEnum(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum value) {
5404 result.hasDefaultNestedEnum = true;
5405 result.defaultNestedEnum_ = value;
5406 return this;
5407 }
5408 public Builder ClearDefaultNestedEnum() {
5409 result.hasDefaultNestedEnum = false;
5410 result.defaultNestedEnum_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedEnum.BAR;
5411 return this;
5412 }
5413
5414 public bool HasDefaultForeignEnum {
csharptestc671a4b2011-06-08 11:51:24 -05005415 get { return result.hasDefaultForeignEnum; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005416 }
5417 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum DefaultForeignEnum {
5418 get { return result.DefaultForeignEnum; }
5419 set { SetDefaultForeignEnum(value); }
5420 }
5421 public Builder SetDefaultForeignEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
5422 result.hasDefaultForeignEnum = true;
5423 result.defaultForeignEnum_ = value;
5424 return this;
5425 }
5426 public Builder ClearDefaultForeignEnum() {
5427 result.hasDefaultForeignEnum = false;
5428 result.defaultForeignEnum_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_BAR;
5429 return this;
5430 }
5431
5432 public bool HasDefaultImportEnum {
csharptestc671a4b2011-06-08 11:51:24 -05005433 get { return result.hasDefaultImportEnum; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005434 }
5435 public global::Google.ProtocolBuffers.TestProtos.ImportEnum DefaultImportEnum {
5436 get { return result.DefaultImportEnum; }
5437 set { SetDefaultImportEnum(value); }
5438 }
5439 public Builder SetDefaultImportEnum(global::Google.ProtocolBuffers.TestProtos.ImportEnum value) {
5440 result.hasDefaultImportEnum = true;
5441 result.defaultImportEnum_ = value;
5442 return this;
5443 }
5444 public Builder ClearDefaultImportEnum() {
5445 result.hasDefaultImportEnum = false;
5446 result.defaultImportEnum_ = global::Google.ProtocolBuffers.TestProtos.ImportEnum.IMPORT_BAR;
5447 return this;
5448 }
5449
5450 public bool HasDefaultStringPiece {
csharptestc671a4b2011-06-08 11:51:24 -05005451 get { return result.hasDefaultStringPiece; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005452 }
5453 public string DefaultStringPiece {
5454 get { return result.DefaultStringPiece; }
5455 set { SetDefaultStringPiece(value); }
5456 }
5457 public Builder SetDefaultStringPiece(string value) {
5458 pb::ThrowHelper.ThrowIfNull(value, "value");
5459 result.hasDefaultStringPiece = true;
5460 result.defaultStringPiece_ = value;
5461 return this;
5462 }
5463 public Builder ClearDefaultStringPiece() {
5464 result.hasDefaultStringPiece = false;
5465 result.defaultStringPiece_ = "abc";
5466 return this;
5467 }
5468
5469 public bool HasDefaultCord {
csharptestc671a4b2011-06-08 11:51:24 -05005470 get { return result.hasDefaultCord; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005471 }
5472 public string DefaultCord {
5473 get { return result.DefaultCord; }
5474 set { SetDefaultCord(value); }
5475 }
5476 public Builder SetDefaultCord(string value) {
5477 pb::ThrowHelper.ThrowIfNull(value, "value");
5478 result.hasDefaultCord = true;
5479 result.defaultCord_ = value;
5480 return this;
5481 }
5482 public Builder ClearDefaultCord() {
5483 result.hasDefaultCord = false;
5484 result.defaultCord_ = "123";
5485 return this;
5486 }
5487 }
5488 static TestAllTypes() {
5489 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
5490 }
5491 }
5492
csharptest445bdce2011-05-20 15:50:54 -05005493 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
5494 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
5495 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01005496 public sealed partial class TestDeprecatedFields : pb::GeneratedMessage<TestDeprecatedFields, TestDeprecatedFields.Builder> {
5497 private static readonly TestDeprecatedFields defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05005498 private static readonly string[] _testDeprecatedFieldsFieldNames = new string[] { "deprecated_int32" };
5499 private static readonly uint[] _testDeprecatedFieldsFieldTags = new uint[] { 8 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01005500 public static TestDeprecatedFields DefaultInstance {
5501 get { return defaultInstance; }
5502 }
5503
5504 public override TestDeprecatedFields DefaultInstanceForType {
5505 get { return defaultInstance; }
5506 }
5507
5508 protected override TestDeprecatedFields ThisMessage {
5509 get { return this; }
5510 }
5511
5512 public static pbd::MessageDescriptor Descriptor {
5513 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDeprecatedFields__Descriptor; }
5514 }
5515
5516 protected override pb::FieldAccess.FieldAccessorTable<TestDeprecatedFields, TestDeprecatedFields.Builder> InternalFieldAccessors {
5517 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDeprecatedFields__FieldAccessorTable; }
5518 }
5519
5520 public const int DeprecatedInt32FieldNumber = 1;
5521 private bool hasDeprecatedInt32;
csharptestced18e12011-06-09 19:47:56 -05005522 private int deprecatedInt32_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01005523 public bool HasDeprecatedInt32 {
5524 get { return hasDeprecatedInt32; }
5525 }
5526 public int DeprecatedInt32 {
5527 get { return deprecatedInt32_; }
5528 }
5529
5530 public override bool IsInitialized {
5531 get {
5532 return true;
5533 }
5534 }
5535
csharptestffafdaa2011-06-03 12:58:14 -05005536 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005537 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05005538 string[] field_names = _testDeprecatedFieldsFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05005539 if (hasDeprecatedInt32) {
csharptest920b09a2011-06-08 20:13:29 -05005540 output.WriteInt32(1, field_names[0], DeprecatedInt32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01005541 }
5542 UnknownFields.WriteTo(output);
5543 }
5544
5545 private int memoizedSerializedSize = -1;
5546 public override int SerializedSize {
5547 get {
5548 int size = memoizedSerializedSize;
5549 if (size != -1) return size;
5550
5551 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05005552 if (hasDeprecatedInt32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005553 size += pb::CodedOutputStream.ComputeInt32Size(1, DeprecatedInt32);
5554 }
5555 size += UnknownFields.SerializedSize;
5556 memoizedSerializedSize = size;
5557 return size;
5558 }
5559 }
5560
5561 public static TestDeprecatedFields ParseFrom(pb::ByteString data) {
5562 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
5563 }
5564 public static TestDeprecatedFields ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
5565 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
5566 }
5567 public static TestDeprecatedFields ParseFrom(byte[] data) {
5568 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
5569 }
5570 public static TestDeprecatedFields ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
5571 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
5572 }
5573 public static TestDeprecatedFields ParseFrom(global::System.IO.Stream input) {
5574 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
5575 }
5576 public static TestDeprecatedFields ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
5577 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
5578 }
5579 public static TestDeprecatedFields ParseDelimitedFrom(global::System.IO.Stream input) {
5580 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
5581 }
5582 public static TestDeprecatedFields ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
5583 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
5584 }
csharptest17699c22011-06-03 21:57:15 -05005585 public static TestDeprecatedFields ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005586 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
5587 }
csharptest17699c22011-06-03 21:57:15 -05005588 public static TestDeprecatedFields ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005589 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
5590 }
5591 public static Builder CreateBuilder() { return new Builder(); }
5592 public override Builder ToBuilder() { return CreateBuilder(this); }
5593 public override Builder CreateBuilderForType() { return new Builder(); }
5594 public static Builder CreateBuilder(TestDeprecatedFields prototype) {
5595 return (Builder) new Builder().MergeFrom(prototype);
5596 }
5597
csharptest445bdce2011-05-20 15:50:54 -05005598 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
5599 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
5600 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01005601 public sealed partial class Builder : pb::GeneratedBuilder<TestDeprecatedFields, Builder> {
5602 protected override Builder ThisBuilder {
5603 get { return this; }
5604 }
5605 public Builder() {}
5606
5607 TestDeprecatedFields result = new TestDeprecatedFields();
5608
5609 protected override TestDeprecatedFields MessageBeingBuilt {
5610 get { return result; }
5611 }
5612
5613 public override Builder Clear() {
5614 result = new TestDeprecatedFields();
5615 return this;
5616 }
5617
5618 public override Builder Clone() {
5619 return new Builder().MergeFrom(result);
5620 }
5621
5622 public override pbd::MessageDescriptor DescriptorForType {
5623 get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.Descriptor; }
5624 }
5625
5626 public override TestDeprecatedFields DefaultInstanceForType {
5627 get { return global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.DefaultInstance; }
5628 }
5629
5630 public override TestDeprecatedFields BuildPartial() {
5631 if (result == null) {
5632 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
5633 }
5634 TestDeprecatedFields returnMe = result;
5635 result = null;
5636 return returnMe;
5637 }
5638
5639 public override Builder MergeFrom(pb::IMessage other) {
5640 if (other is TestDeprecatedFields) {
5641 return MergeFrom((TestDeprecatedFields) other);
5642 } else {
5643 base.MergeFrom(other);
5644 return this;
5645 }
5646 }
5647
5648 public override Builder MergeFrom(TestDeprecatedFields other) {
5649 if (other == global::Google.ProtocolBuffers.TestProtos.TestDeprecatedFields.DefaultInstance) return this;
5650 if (other.HasDeprecatedInt32) {
5651 DeprecatedInt32 = other.DeprecatedInt32;
5652 }
5653 this.MergeUnknownFields(other.UnknownFields);
5654 return this;
5655 }
5656
csharptest17699c22011-06-03 21:57:15 -05005657 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005658 return MergeFrom(input, pb::ExtensionRegistry.Empty);
5659 }
5660
csharptest17699c22011-06-03 21:57:15 -05005661 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005662 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05005663 uint tag;
5664 string field_name;
5665 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05005666 if(tag == 0 && field_name != null) {
5667 int field_ordinal = global::System.Array.BinarySearch(_testDeprecatedFieldsFieldNames, field_name, global::System.StringComparer.Ordinal);
5668 if(field_ordinal >= 0)
5669 tag = _testDeprecatedFieldsFieldTags[field_ordinal];
5670 else {
5671 if (unknownFields == null) {
5672 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
5673 }
5674 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
5675 continue;
5676 }
5677 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005678 switch (tag) {
5679 case 0: {
csharptest99284412011-06-03 14:51:06 -05005680 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01005681 }
5682 default: {
5683 if (pb::WireFormat.IsEndGroupTag(tag)) {
5684 if (unknownFields != null) {
5685 this.UnknownFields = unknownFields.Build();
5686 }
5687 return this;
5688 }
5689 if (unknownFields == null) {
5690 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
5691 }
csharptestd2af9e92011-06-03 21:35:02 -05005692 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01005693 break;
5694 }
5695 case 8: {
csharptest920b09a2011-06-08 20:13:29 -05005696 result.hasDeprecatedInt32 = input.ReadInt32(ref result.deprecatedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01005697 break;
5698 }
5699 }
5700 }
csharptest123e5342011-06-03 14:15:21 -05005701
5702 if (unknownFields != null) {
5703 this.UnknownFields = unknownFields.Build();
5704 }
5705 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01005706 }
5707
5708
5709 public bool HasDeprecatedInt32 {
csharptestc671a4b2011-06-08 11:51:24 -05005710 get { return result.hasDeprecatedInt32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005711 }
5712 public int DeprecatedInt32 {
5713 get { return result.DeprecatedInt32; }
5714 set { SetDeprecatedInt32(value); }
5715 }
5716 public Builder SetDeprecatedInt32(int value) {
5717 result.hasDeprecatedInt32 = true;
5718 result.deprecatedInt32_ = value;
5719 return this;
5720 }
5721 public Builder ClearDeprecatedInt32() {
5722 result.hasDeprecatedInt32 = false;
5723 result.deprecatedInt32_ = 0;
5724 return this;
5725 }
5726 }
5727 static TestDeprecatedFields() {
5728 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
5729 }
5730 }
5731
csharptest445bdce2011-05-20 15:50:54 -05005732 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
5733 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
5734 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01005735 public sealed partial class ForeignMessage : pb::GeneratedMessage<ForeignMessage, ForeignMessage.Builder> {
5736 private static readonly ForeignMessage defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05005737 private static readonly string[] _foreignMessageFieldNames = new string[] { "c" };
5738 private static readonly uint[] _foreignMessageFieldTags = new uint[] { 8 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01005739 public static ForeignMessage DefaultInstance {
5740 get { return defaultInstance; }
5741 }
5742
5743 public override ForeignMessage DefaultInstanceForType {
5744 get { return defaultInstance; }
5745 }
5746
5747 protected override ForeignMessage ThisMessage {
5748 get { return this; }
5749 }
5750
5751 public static pbd::MessageDescriptor Descriptor {
5752 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_ForeignMessage__Descriptor; }
5753 }
5754
5755 protected override pb::FieldAccess.FieldAccessorTable<ForeignMessage, ForeignMessage.Builder> InternalFieldAccessors {
5756 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_ForeignMessage__FieldAccessorTable; }
5757 }
5758
5759 public const int CFieldNumber = 1;
5760 private bool hasC;
csharptestced18e12011-06-09 19:47:56 -05005761 private int c_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01005762 public bool HasC {
5763 get { return hasC; }
5764 }
5765 public int C {
5766 get { return c_; }
5767 }
5768
5769 public override bool IsInitialized {
5770 get {
5771 return true;
5772 }
5773 }
5774
csharptestffafdaa2011-06-03 12:58:14 -05005775 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005776 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05005777 string[] field_names = _foreignMessageFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05005778 if (hasC) {
csharptest920b09a2011-06-08 20:13:29 -05005779 output.WriteInt32(1, field_names[0], C);
Jon Skeet82bb0f12011-04-03 20:17:12 +01005780 }
5781 UnknownFields.WriteTo(output);
5782 }
5783
5784 private int memoizedSerializedSize = -1;
5785 public override int SerializedSize {
5786 get {
5787 int size = memoizedSerializedSize;
5788 if (size != -1) return size;
5789
5790 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05005791 if (hasC) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005792 size += pb::CodedOutputStream.ComputeInt32Size(1, C);
5793 }
5794 size += UnknownFields.SerializedSize;
5795 memoizedSerializedSize = size;
5796 return size;
5797 }
5798 }
5799
5800 public static ForeignMessage ParseFrom(pb::ByteString data) {
5801 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
5802 }
5803 public static ForeignMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
5804 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
5805 }
5806 public static ForeignMessage ParseFrom(byte[] data) {
5807 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
5808 }
5809 public static ForeignMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
5810 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
5811 }
5812 public static ForeignMessage ParseFrom(global::System.IO.Stream input) {
5813 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
5814 }
5815 public static ForeignMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
5816 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
5817 }
5818 public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input) {
5819 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
5820 }
5821 public static ForeignMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
5822 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
5823 }
csharptest17699c22011-06-03 21:57:15 -05005824 public static ForeignMessage ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005825 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
5826 }
csharptest17699c22011-06-03 21:57:15 -05005827 public static ForeignMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005828 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
5829 }
5830 public static Builder CreateBuilder() { return new Builder(); }
5831 public override Builder ToBuilder() { return CreateBuilder(this); }
5832 public override Builder CreateBuilderForType() { return new Builder(); }
5833 public static Builder CreateBuilder(ForeignMessage prototype) {
5834 return (Builder) new Builder().MergeFrom(prototype);
5835 }
5836
csharptest445bdce2011-05-20 15:50:54 -05005837 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
5838 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
5839 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01005840 public sealed partial class Builder : pb::GeneratedBuilder<ForeignMessage, Builder> {
5841 protected override Builder ThisBuilder {
5842 get { return this; }
5843 }
5844 public Builder() {}
5845
5846 ForeignMessage result = new ForeignMessage();
5847
5848 protected override ForeignMessage MessageBeingBuilt {
5849 get { return result; }
5850 }
5851
5852 public override Builder Clear() {
5853 result = new ForeignMessage();
5854 return this;
5855 }
5856
5857 public override Builder Clone() {
5858 return new Builder().MergeFrom(result);
5859 }
5860
5861 public override pbd::MessageDescriptor DescriptorForType {
5862 get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Descriptor; }
5863 }
5864
5865 public override ForeignMessage DefaultInstanceForType {
5866 get { return global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance; }
5867 }
5868
5869 public override ForeignMessage BuildPartial() {
5870 if (result == null) {
5871 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
5872 }
5873 ForeignMessage returnMe = result;
5874 result = null;
5875 return returnMe;
5876 }
5877
5878 public override Builder MergeFrom(pb::IMessage other) {
5879 if (other is ForeignMessage) {
5880 return MergeFrom((ForeignMessage) other);
5881 } else {
5882 base.MergeFrom(other);
5883 return this;
5884 }
5885 }
5886
5887 public override Builder MergeFrom(ForeignMessage other) {
5888 if (other == global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) return this;
5889 if (other.HasC) {
5890 C = other.C;
5891 }
5892 this.MergeUnknownFields(other.UnknownFields);
5893 return this;
5894 }
5895
csharptest17699c22011-06-03 21:57:15 -05005896 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005897 return MergeFrom(input, pb::ExtensionRegistry.Empty);
5898 }
5899
csharptest17699c22011-06-03 21:57:15 -05005900 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01005901 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05005902 uint tag;
5903 string field_name;
5904 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05005905 if(tag == 0 && field_name != null) {
5906 int field_ordinal = global::System.Array.BinarySearch(_foreignMessageFieldNames, field_name, global::System.StringComparer.Ordinal);
5907 if(field_ordinal >= 0)
5908 tag = _foreignMessageFieldTags[field_ordinal];
5909 else {
5910 if (unknownFields == null) {
5911 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
5912 }
5913 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
5914 continue;
5915 }
5916 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005917 switch (tag) {
5918 case 0: {
csharptest99284412011-06-03 14:51:06 -05005919 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01005920 }
5921 default: {
5922 if (pb::WireFormat.IsEndGroupTag(tag)) {
5923 if (unknownFields != null) {
5924 this.UnknownFields = unknownFields.Build();
5925 }
5926 return this;
5927 }
5928 if (unknownFields == null) {
5929 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
5930 }
csharptestd2af9e92011-06-03 21:35:02 -05005931 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01005932 break;
5933 }
5934 case 8: {
csharptest920b09a2011-06-08 20:13:29 -05005935 result.hasC = input.ReadInt32(ref result.c_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01005936 break;
5937 }
5938 }
5939 }
csharptest123e5342011-06-03 14:15:21 -05005940
5941 if (unknownFields != null) {
5942 this.UnknownFields = unknownFields.Build();
5943 }
5944 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01005945 }
5946
5947
5948 public bool HasC {
csharptestc671a4b2011-06-08 11:51:24 -05005949 get { return result.hasC; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01005950 }
5951 public int C {
5952 get { return result.C; }
5953 set { SetC(value); }
5954 }
5955 public Builder SetC(int value) {
5956 result.hasC = true;
5957 result.c_ = value;
5958 return this;
5959 }
5960 public Builder ClearC() {
5961 result.hasC = false;
5962 result.c_ = 0;
5963 return this;
5964 }
5965 }
5966 static ForeignMessage() {
5967 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
5968 }
5969 }
5970
csharptest445bdce2011-05-20 15:50:54 -05005971 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
5972 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
5973 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01005974 public sealed partial class TestAllExtensions : pb::ExtendableMessage<TestAllExtensions, TestAllExtensions.Builder> {
5975 private static readonly TestAllExtensions defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05005976 private static readonly string[] _testAllExtensionsFieldNames = new string[] { };
5977 private static readonly uint[] _testAllExtensionsFieldTags = new uint[] { };
Jon Skeet82bb0f12011-04-03 20:17:12 +01005978 public static TestAllExtensions DefaultInstance {
5979 get { return defaultInstance; }
5980 }
5981
5982 public override TestAllExtensions DefaultInstanceForType {
5983 get { return defaultInstance; }
5984 }
5985
5986 protected override TestAllExtensions ThisMessage {
5987 get { return this; }
5988 }
5989
5990 public static pbd::MessageDescriptor Descriptor {
5991 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllExtensions__Descriptor; }
5992 }
5993
5994 protected override pb::FieldAccess.FieldAccessorTable<TestAllExtensions, TestAllExtensions.Builder> InternalFieldAccessors {
5995 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestAllExtensions__FieldAccessorTable; }
5996 }
5997
5998 public override bool IsInitialized {
5999 get {
6000 if (!ExtensionsAreInitialized) return false;
6001 return true;
6002 }
6003 }
6004
csharptestffafdaa2011-06-03 12:58:14 -05006005 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006006 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05006007 string[] field_names = _testAllExtensionsFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006008 pb::ExtendableMessage<TestAllExtensions, TestAllExtensions.Builder>.ExtensionWriter extensionWriter = CreateExtensionWriter(this);
6009 extensionWriter.WriteUntil(536870912, output);
6010 UnknownFields.WriteTo(output);
6011 }
6012
6013 private int memoizedSerializedSize = -1;
6014 public override int SerializedSize {
6015 get {
6016 int size = memoizedSerializedSize;
6017 if (size != -1) return size;
6018
6019 size = 0;
6020 size += ExtensionsSerializedSize;
6021 size += UnknownFields.SerializedSize;
6022 memoizedSerializedSize = size;
6023 return size;
6024 }
6025 }
6026
6027 public static TestAllExtensions ParseFrom(pb::ByteString data) {
6028 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
6029 }
6030 public static TestAllExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
6031 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
6032 }
6033 public static TestAllExtensions ParseFrom(byte[] data) {
6034 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
6035 }
6036 public static TestAllExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
6037 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
6038 }
6039 public static TestAllExtensions ParseFrom(global::System.IO.Stream input) {
6040 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
6041 }
6042 public static TestAllExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
6043 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
6044 }
6045 public static TestAllExtensions ParseDelimitedFrom(global::System.IO.Stream input) {
6046 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
6047 }
6048 public static TestAllExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
6049 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
6050 }
csharptest17699c22011-06-03 21:57:15 -05006051 public static TestAllExtensions ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006052 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
6053 }
csharptest17699c22011-06-03 21:57:15 -05006054 public static TestAllExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006055 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
6056 }
6057 public static Builder CreateBuilder() { return new Builder(); }
6058 public override Builder ToBuilder() { return CreateBuilder(this); }
6059 public override Builder CreateBuilderForType() { return new Builder(); }
6060 public static Builder CreateBuilder(TestAllExtensions prototype) {
6061 return (Builder) new Builder().MergeFrom(prototype);
6062 }
6063
csharptest445bdce2011-05-20 15:50:54 -05006064 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
6065 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
6066 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01006067 public sealed partial class Builder : pb::ExtendableBuilder<TestAllExtensions, Builder> {
6068 protected override Builder ThisBuilder {
6069 get { return this; }
6070 }
6071 public Builder() {}
6072
6073 TestAllExtensions result = new TestAllExtensions();
6074
6075 protected override TestAllExtensions MessageBeingBuilt {
6076 get { return result; }
6077 }
6078
6079 public override Builder Clear() {
6080 result = new TestAllExtensions();
6081 return this;
6082 }
6083
6084 public override Builder Clone() {
6085 return new Builder().MergeFrom(result);
6086 }
6087
6088 public override pbd::MessageDescriptor DescriptorForType {
6089 get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.Descriptor; }
6090 }
6091
6092 public override TestAllExtensions DefaultInstanceForType {
6093 get { return global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.DefaultInstance; }
6094 }
6095
6096 public override TestAllExtensions BuildPartial() {
6097 if (result == null) {
6098 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
6099 }
6100 TestAllExtensions returnMe = result;
6101 result = null;
6102 return returnMe;
6103 }
6104
6105 public override Builder MergeFrom(pb::IMessage other) {
6106 if (other is TestAllExtensions) {
6107 return MergeFrom((TestAllExtensions) other);
6108 } else {
6109 base.MergeFrom(other);
6110 return this;
6111 }
6112 }
6113
6114 public override Builder MergeFrom(TestAllExtensions other) {
6115 if (other == global::Google.ProtocolBuffers.TestProtos.TestAllExtensions.DefaultInstance) return this;
6116 this.MergeExtensionFields(other);
6117 this.MergeUnknownFields(other.UnknownFields);
6118 return this;
6119 }
6120
csharptest17699c22011-06-03 21:57:15 -05006121 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006122 return MergeFrom(input, pb::ExtensionRegistry.Empty);
6123 }
6124
csharptest17699c22011-06-03 21:57:15 -05006125 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006126 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05006127 uint tag;
6128 string field_name;
6129 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05006130 if(tag == 0 && field_name != null) {
6131 int field_ordinal = global::System.Array.BinarySearch(_testAllExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal);
6132 if(field_ordinal >= 0)
6133 tag = _testAllExtensionsFieldTags[field_ordinal];
6134 else {
6135 if (unknownFields == null) {
6136 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
6137 }
6138 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
6139 continue;
6140 }
6141 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01006142 switch (tag) {
6143 case 0: {
csharptest99284412011-06-03 14:51:06 -05006144 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01006145 }
6146 default: {
6147 if (pb::WireFormat.IsEndGroupTag(tag)) {
6148 if (unknownFields != null) {
6149 this.UnknownFields = unknownFields.Build();
6150 }
6151 return this;
6152 }
6153 if (unknownFields == null) {
6154 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
6155 }
csharptestd2af9e92011-06-03 21:35:02 -05006156 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01006157 break;
6158 }
6159 }
6160 }
csharptest123e5342011-06-03 14:15:21 -05006161
6162 if (unknownFields != null) {
6163 this.UnknownFields = unknownFields.Build();
6164 }
6165 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006166 }
6167
6168 }
6169 static TestAllExtensions() {
6170 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
6171 }
6172 }
6173
csharptest445bdce2011-05-20 15:50:54 -05006174 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
6175 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
6176 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01006177 public sealed partial class OptionalGroup_extension : pb::GeneratedMessage<OptionalGroup_extension, OptionalGroup_extension.Builder> {
6178 private static readonly OptionalGroup_extension defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05006179 private static readonly string[] _optionalGroupExtensionFieldNames = new string[] { "a" };
6180 private static readonly uint[] _optionalGroupExtensionFieldTags = new uint[] { 136 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01006181 public static OptionalGroup_extension DefaultInstance {
6182 get { return defaultInstance; }
6183 }
6184
6185 public override OptionalGroup_extension DefaultInstanceForType {
6186 get { return defaultInstance; }
6187 }
6188
6189 protected override OptionalGroup_extension ThisMessage {
6190 get { return this; }
6191 }
6192
6193 public static pbd::MessageDescriptor Descriptor {
6194 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OptionalGroup_extension__Descriptor; }
6195 }
6196
6197 protected override pb::FieldAccess.FieldAccessorTable<OptionalGroup_extension, OptionalGroup_extension.Builder> InternalFieldAccessors {
6198 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OptionalGroup_extension__FieldAccessorTable; }
6199 }
6200
6201 public const int AFieldNumber = 17;
6202 private bool hasA;
csharptestced18e12011-06-09 19:47:56 -05006203 private int a_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006204 public bool HasA {
6205 get { return hasA; }
6206 }
6207 public int A {
6208 get { return a_; }
6209 }
6210
6211 public override bool IsInitialized {
6212 get {
6213 return true;
6214 }
6215 }
6216
csharptestffafdaa2011-06-03 12:58:14 -05006217 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006218 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05006219 string[] field_names = _optionalGroupExtensionFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05006220 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -05006221 output.WriteInt32(17, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +01006222 }
6223 UnknownFields.WriteTo(output);
6224 }
6225
6226 private int memoizedSerializedSize = -1;
6227 public override int SerializedSize {
6228 get {
6229 int size = memoizedSerializedSize;
6230 if (size != -1) return size;
6231
6232 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05006233 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006234 size += pb::CodedOutputStream.ComputeInt32Size(17, A);
6235 }
6236 size += UnknownFields.SerializedSize;
6237 memoizedSerializedSize = size;
6238 return size;
6239 }
6240 }
6241
6242 public static OptionalGroup_extension ParseFrom(pb::ByteString data) {
6243 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
6244 }
6245 public static OptionalGroup_extension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
6246 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
6247 }
6248 public static OptionalGroup_extension ParseFrom(byte[] data) {
6249 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
6250 }
6251 public static OptionalGroup_extension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
6252 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
6253 }
6254 public static OptionalGroup_extension ParseFrom(global::System.IO.Stream input) {
6255 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
6256 }
6257 public static OptionalGroup_extension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
6258 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
6259 }
6260 public static OptionalGroup_extension ParseDelimitedFrom(global::System.IO.Stream input) {
6261 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
6262 }
6263 public static OptionalGroup_extension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
6264 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
6265 }
csharptest17699c22011-06-03 21:57:15 -05006266 public static OptionalGroup_extension ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006267 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
6268 }
csharptest17699c22011-06-03 21:57:15 -05006269 public static OptionalGroup_extension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006270 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
6271 }
6272 public static Builder CreateBuilder() { return new Builder(); }
6273 public override Builder ToBuilder() { return CreateBuilder(this); }
6274 public override Builder CreateBuilderForType() { return new Builder(); }
6275 public static Builder CreateBuilder(OptionalGroup_extension prototype) {
6276 return (Builder) new Builder().MergeFrom(prototype);
6277 }
6278
csharptest445bdce2011-05-20 15:50:54 -05006279 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
6280 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
6281 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01006282 public sealed partial class Builder : pb::GeneratedBuilder<OptionalGroup_extension, Builder> {
6283 protected override Builder ThisBuilder {
6284 get { return this; }
6285 }
6286 public Builder() {}
6287
6288 OptionalGroup_extension result = new OptionalGroup_extension();
6289
6290 protected override OptionalGroup_extension MessageBeingBuilt {
6291 get { return result; }
6292 }
6293
6294 public override Builder Clear() {
6295 result = new OptionalGroup_extension();
6296 return this;
6297 }
6298
6299 public override Builder Clone() {
6300 return new Builder().MergeFrom(result);
6301 }
6302
6303 public override pbd::MessageDescriptor DescriptorForType {
6304 get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.Descriptor; }
6305 }
6306
6307 public override OptionalGroup_extension DefaultInstanceForType {
6308 get { return global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.DefaultInstance; }
6309 }
6310
6311 public override OptionalGroup_extension BuildPartial() {
6312 if (result == null) {
6313 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
6314 }
6315 OptionalGroup_extension returnMe = result;
6316 result = null;
6317 return returnMe;
6318 }
6319
6320 public override Builder MergeFrom(pb::IMessage other) {
6321 if (other is OptionalGroup_extension) {
6322 return MergeFrom((OptionalGroup_extension) other);
6323 } else {
6324 base.MergeFrom(other);
6325 return this;
6326 }
6327 }
6328
6329 public override Builder MergeFrom(OptionalGroup_extension other) {
6330 if (other == global::Google.ProtocolBuffers.TestProtos.OptionalGroup_extension.DefaultInstance) return this;
6331 if (other.HasA) {
6332 A = other.A;
6333 }
6334 this.MergeUnknownFields(other.UnknownFields);
6335 return this;
6336 }
6337
csharptest17699c22011-06-03 21:57:15 -05006338 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006339 return MergeFrom(input, pb::ExtensionRegistry.Empty);
6340 }
6341
csharptest17699c22011-06-03 21:57:15 -05006342 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006343 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05006344 uint tag;
6345 string field_name;
6346 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05006347 if(tag == 0 && field_name != null) {
6348 int field_ordinal = global::System.Array.BinarySearch(_optionalGroupExtensionFieldNames, field_name, global::System.StringComparer.Ordinal);
6349 if(field_ordinal >= 0)
6350 tag = _optionalGroupExtensionFieldTags[field_ordinal];
6351 else {
6352 if (unknownFields == null) {
6353 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
6354 }
6355 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
6356 continue;
6357 }
6358 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01006359 switch (tag) {
6360 case 0: {
csharptest99284412011-06-03 14:51:06 -05006361 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01006362 }
6363 default: {
6364 if (pb::WireFormat.IsEndGroupTag(tag)) {
6365 if (unknownFields != null) {
6366 this.UnknownFields = unknownFields.Build();
6367 }
6368 return this;
6369 }
6370 if (unknownFields == null) {
6371 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
6372 }
csharptestd2af9e92011-06-03 21:35:02 -05006373 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01006374 break;
6375 }
6376 case 136: {
csharptest920b09a2011-06-08 20:13:29 -05006377 result.hasA = input.ReadInt32(ref result.a_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01006378 break;
6379 }
6380 }
6381 }
csharptest123e5342011-06-03 14:15:21 -05006382
6383 if (unknownFields != null) {
6384 this.UnknownFields = unknownFields.Build();
6385 }
6386 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006387 }
6388
6389
6390 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -05006391 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01006392 }
6393 public int A {
6394 get { return result.A; }
6395 set { SetA(value); }
6396 }
6397 public Builder SetA(int value) {
6398 result.hasA = true;
6399 result.a_ = value;
6400 return this;
6401 }
6402 public Builder ClearA() {
6403 result.hasA = false;
6404 result.a_ = 0;
6405 return this;
6406 }
6407 }
6408 static OptionalGroup_extension() {
6409 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
6410 }
6411 }
6412
csharptest445bdce2011-05-20 15:50:54 -05006413 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
6414 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
6415 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01006416 public sealed partial class RepeatedGroup_extension : pb::GeneratedMessage<RepeatedGroup_extension, RepeatedGroup_extension.Builder> {
6417 private static readonly RepeatedGroup_extension defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05006418 private static readonly string[] _repeatedGroupExtensionFieldNames = new string[] { "a" };
6419 private static readonly uint[] _repeatedGroupExtensionFieldTags = new uint[] { 376 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01006420 public static RepeatedGroup_extension DefaultInstance {
6421 get { return defaultInstance; }
6422 }
6423
6424 public override RepeatedGroup_extension DefaultInstanceForType {
6425 get { return defaultInstance; }
6426 }
6427
6428 protected override RepeatedGroup_extension ThisMessage {
6429 get { return this; }
6430 }
6431
6432 public static pbd::MessageDescriptor Descriptor {
6433 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_RepeatedGroup_extension__Descriptor; }
6434 }
6435
6436 protected override pb::FieldAccess.FieldAccessorTable<RepeatedGroup_extension, RepeatedGroup_extension.Builder> InternalFieldAccessors {
6437 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_RepeatedGroup_extension__FieldAccessorTable; }
6438 }
6439
6440 public const int AFieldNumber = 47;
6441 private bool hasA;
csharptestced18e12011-06-09 19:47:56 -05006442 private int a_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006443 public bool HasA {
6444 get { return hasA; }
6445 }
6446 public int A {
6447 get { return a_; }
6448 }
6449
6450 public override bool IsInitialized {
6451 get {
6452 return true;
6453 }
6454 }
6455
csharptestffafdaa2011-06-03 12:58:14 -05006456 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006457 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05006458 string[] field_names = _repeatedGroupExtensionFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05006459 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -05006460 output.WriteInt32(47, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +01006461 }
6462 UnknownFields.WriteTo(output);
6463 }
6464
6465 private int memoizedSerializedSize = -1;
6466 public override int SerializedSize {
6467 get {
6468 int size = memoizedSerializedSize;
6469 if (size != -1) return size;
6470
6471 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05006472 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006473 size += pb::CodedOutputStream.ComputeInt32Size(47, A);
6474 }
6475 size += UnknownFields.SerializedSize;
6476 memoizedSerializedSize = size;
6477 return size;
6478 }
6479 }
6480
6481 public static RepeatedGroup_extension ParseFrom(pb::ByteString data) {
6482 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
6483 }
6484 public static RepeatedGroup_extension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
6485 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
6486 }
6487 public static RepeatedGroup_extension ParseFrom(byte[] data) {
6488 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
6489 }
6490 public static RepeatedGroup_extension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
6491 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
6492 }
6493 public static RepeatedGroup_extension ParseFrom(global::System.IO.Stream input) {
6494 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
6495 }
6496 public static RepeatedGroup_extension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
6497 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
6498 }
6499 public static RepeatedGroup_extension ParseDelimitedFrom(global::System.IO.Stream input) {
6500 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
6501 }
6502 public static RepeatedGroup_extension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
6503 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
6504 }
csharptest17699c22011-06-03 21:57:15 -05006505 public static RepeatedGroup_extension ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006506 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
6507 }
csharptest17699c22011-06-03 21:57:15 -05006508 public static RepeatedGroup_extension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006509 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
6510 }
6511 public static Builder CreateBuilder() { return new Builder(); }
6512 public override Builder ToBuilder() { return CreateBuilder(this); }
6513 public override Builder CreateBuilderForType() { return new Builder(); }
6514 public static Builder CreateBuilder(RepeatedGroup_extension prototype) {
6515 return (Builder) new Builder().MergeFrom(prototype);
6516 }
6517
csharptest445bdce2011-05-20 15:50:54 -05006518 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
6519 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
6520 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01006521 public sealed partial class Builder : pb::GeneratedBuilder<RepeatedGroup_extension, Builder> {
6522 protected override Builder ThisBuilder {
6523 get { return this; }
6524 }
6525 public Builder() {}
6526
6527 RepeatedGroup_extension result = new RepeatedGroup_extension();
6528
6529 protected override RepeatedGroup_extension MessageBeingBuilt {
6530 get { return result; }
6531 }
6532
6533 public override Builder Clear() {
6534 result = new RepeatedGroup_extension();
6535 return this;
6536 }
6537
6538 public override Builder Clone() {
6539 return new Builder().MergeFrom(result);
6540 }
6541
6542 public override pbd::MessageDescriptor DescriptorForType {
6543 get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.Descriptor; }
6544 }
6545
6546 public override RepeatedGroup_extension DefaultInstanceForType {
6547 get { return global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.DefaultInstance; }
6548 }
6549
6550 public override RepeatedGroup_extension BuildPartial() {
6551 if (result == null) {
6552 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
6553 }
6554 RepeatedGroup_extension returnMe = result;
6555 result = null;
6556 return returnMe;
6557 }
6558
6559 public override Builder MergeFrom(pb::IMessage other) {
6560 if (other is RepeatedGroup_extension) {
6561 return MergeFrom((RepeatedGroup_extension) other);
6562 } else {
6563 base.MergeFrom(other);
6564 return this;
6565 }
6566 }
6567
6568 public override Builder MergeFrom(RepeatedGroup_extension other) {
6569 if (other == global::Google.ProtocolBuffers.TestProtos.RepeatedGroup_extension.DefaultInstance) return this;
6570 if (other.HasA) {
6571 A = other.A;
6572 }
6573 this.MergeUnknownFields(other.UnknownFields);
6574 return this;
6575 }
6576
csharptest17699c22011-06-03 21:57:15 -05006577 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006578 return MergeFrom(input, pb::ExtensionRegistry.Empty);
6579 }
6580
csharptest17699c22011-06-03 21:57:15 -05006581 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006582 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05006583 uint tag;
6584 string field_name;
6585 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05006586 if(tag == 0 && field_name != null) {
6587 int field_ordinal = global::System.Array.BinarySearch(_repeatedGroupExtensionFieldNames, field_name, global::System.StringComparer.Ordinal);
6588 if(field_ordinal >= 0)
6589 tag = _repeatedGroupExtensionFieldTags[field_ordinal];
6590 else {
6591 if (unknownFields == null) {
6592 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
6593 }
6594 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
6595 continue;
6596 }
6597 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01006598 switch (tag) {
6599 case 0: {
csharptest99284412011-06-03 14:51:06 -05006600 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01006601 }
6602 default: {
6603 if (pb::WireFormat.IsEndGroupTag(tag)) {
6604 if (unknownFields != null) {
6605 this.UnknownFields = unknownFields.Build();
6606 }
6607 return this;
6608 }
6609 if (unknownFields == null) {
6610 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
6611 }
csharptestd2af9e92011-06-03 21:35:02 -05006612 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01006613 break;
6614 }
6615 case 376: {
csharptest920b09a2011-06-08 20:13:29 -05006616 result.hasA = input.ReadInt32(ref result.a_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01006617 break;
6618 }
6619 }
6620 }
csharptest123e5342011-06-03 14:15:21 -05006621
6622 if (unknownFields != null) {
6623 this.UnknownFields = unknownFields.Build();
6624 }
6625 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006626 }
6627
6628
6629 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -05006630 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01006631 }
6632 public int A {
6633 get { return result.A; }
6634 set { SetA(value); }
6635 }
6636 public Builder SetA(int value) {
6637 result.hasA = true;
6638 result.a_ = value;
6639 return this;
6640 }
6641 public Builder ClearA() {
6642 result.hasA = false;
6643 result.a_ = 0;
6644 return this;
6645 }
6646 }
6647 static RepeatedGroup_extension() {
6648 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
6649 }
6650 }
6651
csharptest445bdce2011-05-20 15:50:54 -05006652 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
6653 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
6654 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01006655 public sealed partial class TestNestedExtension : pb::GeneratedMessage<TestNestedExtension, TestNestedExtension.Builder> {
6656 private static readonly TestNestedExtension defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05006657 private static readonly string[] _testNestedExtensionFieldNames = new string[] { };
6658 private static readonly uint[] _testNestedExtensionFieldTags = new uint[] { };
Jon Skeet82bb0f12011-04-03 20:17:12 +01006659 public static TestNestedExtension DefaultInstance {
6660 get { return defaultInstance; }
6661 }
6662
6663 public override TestNestedExtension DefaultInstanceForType {
6664 get { return defaultInstance; }
6665 }
6666
6667 protected override TestNestedExtension ThisMessage {
6668 get { return this; }
6669 }
6670
6671 public static pbd::MessageDescriptor Descriptor {
6672 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedExtension__Descriptor; }
6673 }
6674
6675 protected override pb::FieldAccess.FieldAccessorTable<TestNestedExtension, TestNestedExtension.Builder> InternalFieldAccessors {
6676 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedExtension__FieldAccessorTable; }
6677 }
6678
6679 public const int TestFieldNumber = 1002;
6680 public static pb::GeneratedExtensionBase<string> Test;
6681 public override bool IsInitialized {
6682 get {
6683 return true;
6684 }
6685 }
6686
csharptestffafdaa2011-06-03 12:58:14 -05006687 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006688 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05006689 string[] field_names = _testNestedExtensionFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006690 UnknownFields.WriteTo(output);
6691 }
6692
6693 private int memoizedSerializedSize = -1;
6694 public override int SerializedSize {
6695 get {
6696 int size = memoizedSerializedSize;
6697 if (size != -1) return size;
6698
6699 size = 0;
6700 size += UnknownFields.SerializedSize;
6701 memoizedSerializedSize = size;
6702 return size;
6703 }
6704 }
6705
6706 public static TestNestedExtension ParseFrom(pb::ByteString data) {
6707 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
6708 }
6709 public static TestNestedExtension ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
6710 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
6711 }
6712 public static TestNestedExtension ParseFrom(byte[] data) {
6713 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
6714 }
6715 public static TestNestedExtension ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
6716 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
6717 }
6718 public static TestNestedExtension ParseFrom(global::System.IO.Stream input) {
6719 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
6720 }
6721 public static TestNestedExtension ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
6722 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
6723 }
6724 public static TestNestedExtension ParseDelimitedFrom(global::System.IO.Stream input) {
6725 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
6726 }
6727 public static TestNestedExtension ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
6728 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
6729 }
csharptest17699c22011-06-03 21:57:15 -05006730 public static TestNestedExtension ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006731 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
6732 }
csharptest17699c22011-06-03 21:57:15 -05006733 public static TestNestedExtension ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006734 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
6735 }
6736 public static Builder CreateBuilder() { return new Builder(); }
6737 public override Builder ToBuilder() { return CreateBuilder(this); }
6738 public override Builder CreateBuilderForType() { return new Builder(); }
6739 public static Builder CreateBuilder(TestNestedExtension prototype) {
6740 return (Builder) new Builder().MergeFrom(prototype);
6741 }
6742
csharptest445bdce2011-05-20 15:50:54 -05006743 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
6744 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
6745 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01006746 public sealed partial class Builder : pb::GeneratedBuilder<TestNestedExtension, Builder> {
6747 protected override Builder ThisBuilder {
6748 get { return this; }
6749 }
6750 public Builder() {}
6751
6752 TestNestedExtension result = new TestNestedExtension();
6753
6754 protected override TestNestedExtension MessageBeingBuilt {
6755 get { return result; }
6756 }
6757
6758 public override Builder Clear() {
6759 result = new TestNestedExtension();
6760 return this;
6761 }
6762
6763 public override Builder Clone() {
6764 return new Builder().MergeFrom(result);
6765 }
6766
6767 public override pbd::MessageDescriptor DescriptorForType {
6768 get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.Descriptor; }
6769 }
6770
6771 public override TestNestedExtension DefaultInstanceForType {
6772 get { return global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.DefaultInstance; }
6773 }
6774
6775 public override TestNestedExtension BuildPartial() {
6776 if (result == null) {
6777 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
6778 }
6779 TestNestedExtension returnMe = result;
6780 result = null;
6781 return returnMe;
6782 }
6783
6784 public override Builder MergeFrom(pb::IMessage other) {
6785 if (other is TestNestedExtension) {
6786 return MergeFrom((TestNestedExtension) other);
6787 } else {
6788 base.MergeFrom(other);
6789 return this;
6790 }
6791 }
6792
6793 public override Builder MergeFrom(TestNestedExtension other) {
6794 if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedExtension.DefaultInstance) return this;
6795 this.MergeUnknownFields(other.UnknownFields);
6796 return this;
6797 }
6798
csharptest17699c22011-06-03 21:57:15 -05006799 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006800 return MergeFrom(input, pb::ExtensionRegistry.Empty);
6801 }
6802
csharptest17699c22011-06-03 21:57:15 -05006803 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01006804 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05006805 uint tag;
6806 string field_name;
6807 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05006808 if(tag == 0 && field_name != null) {
6809 int field_ordinal = global::System.Array.BinarySearch(_testNestedExtensionFieldNames, field_name, global::System.StringComparer.Ordinal);
6810 if(field_ordinal >= 0)
6811 tag = _testNestedExtensionFieldTags[field_ordinal];
6812 else {
6813 if (unknownFields == null) {
6814 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
6815 }
6816 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
6817 continue;
6818 }
6819 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01006820 switch (tag) {
6821 case 0: {
csharptest99284412011-06-03 14:51:06 -05006822 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01006823 }
6824 default: {
6825 if (pb::WireFormat.IsEndGroupTag(tag)) {
6826 if (unknownFields != null) {
6827 this.UnknownFields = unknownFields.Build();
6828 }
6829 return this;
6830 }
6831 if (unknownFields == null) {
6832 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
6833 }
csharptestd2af9e92011-06-03 21:35:02 -05006834 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01006835 break;
6836 }
6837 }
6838 }
csharptest123e5342011-06-03 14:15:21 -05006839
6840 if (unknownFields != null) {
6841 this.UnknownFields = unknownFields.Build();
6842 }
6843 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006844 }
6845
6846 }
6847 static TestNestedExtension() {
6848 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
6849 }
6850 }
6851
csharptest445bdce2011-05-20 15:50:54 -05006852 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
6853 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
6854 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01006855 public sealed partial class TestRequired : pb::GeneratedMessage<TestRequired, TestRequired.Builder> {
6856 private static readonly TestRequired defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05006857 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" };
6858 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 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01006859 public static TestRequired DefaultInstance {
6860 get { return defaultInstance; }
6861 }
6862
6863 public override TestRequired DefaultInstanceForType {
6864 get { return defaultInstance; }
6865 }
6866
6867 protected override TestRequired ThisMessage {
6868 get { return this; }
6869 }
6870
6871 public static pbd::MessageDescriptor Descriptor {
6872 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRequired__Descriptor; }
6873 }
6874
6875 protected override pb::FieldAccess.FieldAccessorTable<TestRequired, TestRequired.Builder> InternalFieldAccessors {
6876 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRequired__FieldAccessorTable; }
6877 }
6878
6879 public const int SingleFieldNumber = 1000;
6880 public static pb::GeneratedExtensionBase<global::Google.ProtocolBuffers.TestProtos.TestRequired> Single;
6881 public const int MultiFieldNumber = 1001;
6882 public static pb::GeneratedExtensionBase<scg::IList<global::Google.ProtocolBuffers.TestProtos.TestRequired>> Multi;
6883 public const int AFieldNumber = 1;
6884 private bool hasA;
csharptestced18e12011-06-09 19:47:56 -05006885 private int a_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006886 public bool HasA {
6887 get { return hasA; }
6888 }
6889 public int A {
6890 get { return a_; }
6891 }
6892
6893 public const int Dummy2FieldNumber = 2;
6894 private bool hasDummy2;
csharptestced18e12011-06-09 19:47:56 -05006895 private int dummy2_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006896 public bool HasDummy2 {
6897 get { return hasDummy2; }
6898 }
6899 public int Dummy2 {
6900 get { return dummy2_; }
6901 }
6902
6903 public const int BFieldNumber = 3;
6904 private bool hasB;
csharptestced18e12011-06-09 19:47:56 -05006905 private int b_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006906 public bool HasB {
6907 get { return hasB; }
6908 }
6909 public int B {
6910 get { return b_; }
6911 }
6912
6913 public const int Dummy4FieldNumber = 4;
6914 private bool hasDummy4;
csharptestced18e12011-06-09 19:47:56 -05006915 private int dummy4_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006916 public bool HasDummy4 {
6917 get { return hasDummy4; }
6918 }
6919 public int Dummy4 {
6920 get { return dummy4_; }
6921 }
6922
6923 public const int Dummy5FieldNumber = 5;
6924 private bool hasDummy5;
csharptestced18e12011-06-09 19:47:56 -05006925 private int dummy5_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006926 public bool HasDummy5 {
6927 get { return hasDummy5; }
6928 }
6929 public int Dummy5 {
6930 get { return dummy5_; }
6931 }
6932
6933 public const int Dummy6FieldNumber = 6;
6934 private bool hasDummy6;
csharptestced18e12011-06-09 19:47:56 -05006935 private int dummy6_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006936 public bool HasDummy6 {
6937 get { return hasDummy6; }
6938 }
6939 public int Dummy6 {
6940 get { return dummy6_; }
6941 }
6942
6943 public const int Dummy7FieldNumber = 7;
6944 private bool hasDummy7;
csharptestced18e12011-06-09 19:47:56 -05006945 private int dummy7_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006946 public bool HasDummy7 {
6947 get { return hasDummy7; }
6948 }
6949 public int Dummy7 {
6950 get { return dummy7_; }
6951 }
6952
6953 public const int Dummy8FieldNumber = 8;
6954 private bool hasDummy8;
csharptestced18e12011-06-09 19:47:56 -05006955 private int dummy8_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006956 public bool HasDummy8 {
6957 get { return hasDummy8; }
6958 }
6959 public int Dummy8 {
6960 get { return dummy8_; }
6961 }
6962
6963 public const int Dummy9FieldNumber = 9;
6964 private bool hasDummy9;
csharptestced18e12011-06-09 19:47:56 -05006965 private int dummy9_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006966 public bool HasDummy9 {
6967 get { return hasDummy9; }
6968 }
6969 public int Dummy9 {
6970 get { return dummy9_; }
6971 }
6972
6973 public const int Dummy10FieldNumber = 10;
6974 private bool hasDummy10;
csharptestced18e12011-06-09 19:47:56 -05006975 private int dummy10_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006976 public bool HasDummy10 {
6977 get { return hasDummy10; }
6978 }
6979 public int Dummy10 {
6980 get { return dummy10_; }
6981 }
6982
6983 public const int Dummy11FieldNumber = 11;
6984 private bool hasDummy11;
csharptestced18e12011-06-09 19:47:56 -05006985 private int dummy11_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006986 public bool HasDummy11 {
6987 get { return hasDummy11; }
6988 }
6989 public int Dummy11 {
6990 get { return dummy11_; }
6991 }
6992
6993 public const int Dummy12FieldNumber = 12;
6994 private bool hasDummy12;
csharptestced18e12011-06-09 19:47:56 -05006995 private int dummy12_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01006996 public bool HasDummy12 {
6997 get { return hasDummy12; }
6998 }
6999 public int Dummy12 {
7000 get { return dummy12_; }
7001 }
7002
7003 public const int Dummy13FieldNumber = 13;
7004 private bool hasDummy13;
csharptestced18e12011-06-09 19:47:56 -05007005 private int dummy13_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007006 public bool HasDummy13 {
7007 get { return hasDummy13; }
7008 }
7009 public int Dummy13 {
7010 get { return dummy13_; }
7011 }
7012
7013 public const int Dummy14FieldNumber = 14;
7014 private bool hasDummy14;
csharptestced18e12011-06-09 19:47:56 -05007015 private int dummy14_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007016 public bool HasDummy14 {
7017 get { return hasDummy14; }
7018 }
7019 public int Dummy14 {
7020 get { return dummy14_; }
7021 }
7022
7023 public const int Dummy15FieldNumber = 15;
7024 private bool hasDummy15;
csharptestced18e12011-06-09 19:47:56 -05007025 private int dummy15_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007026 public bool HasDummy15 {
7027 get { return hasDummy15; }
7028 }
7029 public int Dummy15 {
7030 get { return dummy15_; }
7031 }
7032
7033 public const int Dummy16FieldNumber = 16;
7034 private bool hasDummy16;
csharptestced18e12011-06-09 19:47:56 -05007035 private int dummy16_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007036 public bool HasDummy16 {
7037 get { return hasDummy16; }
7038 }
7039 public int Dummy16 {
7040 get { return dummy16_; }
7041 }
7042
7043 public const int Dummy17FieldNumber = 17;
7044 private bool hasDummy17;
csharptestced18e12011-06-09 19:47:56 -05007045 private int dummy17_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007046 public bool HasDummy17 {
7047 get { return hasDummy17; }
7048 }
7049 public int Dummy17 {
7050 get { return dummy17_; }
7051 }
7052
7053 public const int Dummy18FieldNumber = 18;
7054 private bool hasDummy18;
csharptestced18e12011-06-09 19:47:56 -05007055 private int dummy18_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007056 public bool HasDummy18 {
7057 get { return hasDummy18; }
7058 }
7059 public int Dummy18 {
7060 get { return dummy18_; }
7061 }
7062
7063 public const int Dummy19FieldNumber = 19;
7064 private bool hasDummy19;
csharptestced18e12011-06-09 19:47:56 -05007065 private int dummy19_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007066 public bool HasDummy19 {
7067 get { return hasDummy19; }
7068 }
7069 public int Dummy19 {
7070 get { return dummy19_; }
7071 }
7072
7073 public const int Dummy20FieldNumber = 20;
7074 private bool hasDummy20;
csharptestced18e12011-06-09 19:47:56 -05007075 private int dummy20_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007076 public bool HasDummy20 {
7077 get { return hasDummy20; }
7078 }
7079 public int Dummy20 {
7080 get { return dummy20_; }
7081 }
7082
7083 public const int Dummy21FieldNumber = 21;
7084 private bool hasDummy21;
csharptestced18e12011-06-09 19:47:56 -05007085 private int dummy21_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007086 public bool HasDummy21 {
7087 get { return hasDummy21; }
7088 }
7089 public int Dummy21 {
7090 get { return dummy21_; }
7091 }
7092
7093 public const int Dummy22FieldNumber = 22;
7094 private bool hasDummy22;
csharptestced18e12011-06-09 19:47:56 -05007095 private int dummy22_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007096 public bool HasDummy22 {
7097 get { return hasDummy22; }
7098 }
7099 public int Dummy22 {
7100 get { return dummy22_; }
7101 }
7102
7103 public const int Dummy23FieldNumber = 23;
7104 private bool hasDummy23;
csharptestced18e12011-06-09 19:47:56 -05007105 private int dummy23_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007106 public bool HasDummy23 {
7107 get { return hasDummy23; }
7108 }
7109 public int Dummy23 {
7110 get { return dummy23_; }
7111 }
7112
7113 public const int Dummy24FieldNumber = 24;
7114 private bool hasDummy24;
csharptestced18e12011-06-09 19:47:56 -05007115 private int dummy24_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007116 public bool HasDummy24 {
7117 get { return hasDummy24; }
7118 }
7119 public int Dummy24 {
7120 get { return dummy24_; }
7121 }
7122
7123 public const int Dummy25FieldNumber = 25;
7124 private bool hasDummy25;
csharptestced18e12011-06-09 19:47:56 -05007125 private int dummy25_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007126 public bool HasDummy25 {
7127 get { return hasDummy25; }
7128 }
7129 public int Dummy25 {
7130 get { return dummy25_; }
7131 }
7132
7133 public const int Dummy26FieldNumber = 26;
7134 private bool hasDummy26;
csharptestced18e12011-06-09 19:47:56 -05007135 private int dummy26_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007136 public bool HasDummy26 {
7137 get { return hasDummy26; }
7138 }
7139 public int Dummy26 {
7140 get { return dummy26_; }
7141 }
7142
7143 public const int Dummy27FieldNumber = 27;
7144 private bool hasDummy27;
csharptestced18e12011-06-09 19:47:56 -05007145 private int dummy27_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007146 public bool HasDummy27 {
7147 get { return hasDummy27; }
7148 }
7149 public int Dummy27 {
7150 get { return dummy27_; }
7151 }
7152
7153 public const int Dummy28FieldNumber = 28;
7154 private bool hasDummy28;
csharptestced18e12011-06-09 19:47:56 -05007155 private int dummy28_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007156 public bool HasDummy28 {
7157 get { return hasDummy28; }
7158 }
7159 public int Dummy28 {
7160 get { return dummy28_; }
7161 }
7162
7163 public const int Dummy29FieldNumber = 29;
7164 private bool hasDummy29;
csharptestced18e12011-06-09 19:47:56 -05007165 private int dummy29_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007166 public bool HasDummy29 {
7167 get { return hasDummy29; }
7168 }
7169 public int Dummy29 {
7170 get { return dummy29_; }
7171 }
7172
7173 public const int Dummy30FieldNumber = 30;
7174 private bool hasDummy30;
csharptestced18e12011-06-09 19:47:56 -05007175 private int dummy30_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007176 public bool HasDummy30 {
7177 get { return hasDummy30; }
7178 }
7179 public int Dummy30 {
7180 get { return dummy30_; }
7181 }
7182
7183 public const int Dummy31FieldNumber = 31;
7184 private bool hasDummy31;
csharptestced18e12011-06-09 19:47:56 -05007185 private int dummy31_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007186 public bool HasDummy31 {
7187 get { return hasDummy31; }
7188 }
7189 public int Dummy31 {
7190 get { return dummy31_; }
7191 }
7192
7193 public const int Dummy32FieldNumber = 32;
7194 private bool hasDummy32;
csharptestced18e12011-06-09 19:47:56 -05007195 private int dummy32_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007196 public bool HasDummy32 {
7197 get { return hasDummy32; }
7198 }
7199 public int Dummy32 {
7200 get { return dummy32_; }
7201 }
7202
7203 public const int CFieldNumber = 33;
7204 private bool hasC;
csharptestced18e12011-06-09 19:47:56 -05007205 private int c_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007206 public bool HasC {
7207 get { return hasC; }
7208 }
7209 public int C {
7210 get { return c_; }
7211 }
7212
7213 public override bool IsInitialized {
7214 get {
7215 if (!hasA) return false;
7216 if (!hasB) return false;
7217 if (!hasC) return false;
7218 return true;
7219 }
7220 }
7221
csharptestffafdaa2011-06-03 12:58:14 -05007222 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007223 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05007224 string[] field_names = _testRequiredFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05007225 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -05007226 output.WriteInt32(1, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007227 }
csharptestc671a4b2011-06-08 11:51:24 -05007228 if (hasDummy2) {
csharptest920b09a2011-06-08 20:13:29 -05007229 output.WriteInt32(2, field_names[13], Dummy2);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007230 }
csharptestc671a4b2011-06-08 11:51:24 -05007231 if (hasB) {
csharptest920b09a2011-06-08 20:13:29 -05007232 output.WriteInt32(3, field_names[1], B);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007233 }
csharptestc671a4b2011-06-08 11:51:24 -05007234 if (hasDummy4) {
csharptest920b09a2011-06-08 20:13:29 -05007235 output.WriteInt32(4, field_names[27], Dummy4);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007236 }
csharptestc671a4b2011-06-08 11:51:24 -05007237 if (hasDummy5) {
csharptest920b09a2011-06-08 20:13:29 -05007238 output.WriteInt32(5, field_names[28], Dummy5);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007239 }
csharptestc671a4b2011-06-08 11:51:24 -05007240 if (hasDummy6) {
csharptest920b09a2011-06-08 20:13:29 -05007241 output.WriteInt32(6, field_names[29], Dummy6);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007242 }
csharptestc671a4b2011-06-08 11:51:24 -05007243 if (hasDummy7) {
csharptest920b09a2011-06-08 20:13:29 -05007244 output.WriteInt32(7, field_names[30], Dummy7);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007245 }
csharptestc671a4b2011-06-08 11:51:24 -05007246 if (hasDummy8) {
csharptest920b09a2011-06-08 20:13:29 -05007247 output.WriteInt32(8, field_names[31], Dummy8);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007248 }
csharptestc671a4b2011-06-08 11:51:24 -05007249 if (hasDummy9) {
csharptest920b09a2011-06-08 20:13:29 -05007250 output.WriteInt32(9, field_names[32], Dummy9);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007251 }
csharptestc671a4b2011-06-08 11:51:24 -05007252 if (hasDummy10) {
csharptest920b09a2011-06-08 20:13:29 -05007253 output.WriteInt32(10, field_names[3], Dummy10);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007254 }
csharptestc671a4b2011-06-08 11:51:24 -05007255 if (hasDummy11) {
csharptest920b09a2011-06-08 20:13:29 -05007256 output.WriteInt32(11, field_names[4], Dummy11);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007257 }
csharptestc671a4b2011-06-08 11:51:24 -05007258 if (hasDummy12) {
csharptest920b09a2011-06-08 20:13:29 -05007259 output.WriteInt32(12, field_names[5], Dummy12);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007260 }
csharptestc671a4b2011-06-08 11:51:24 -05007261 if (hasDummy13) {
csharptest920b09a2011-06-08 20:13:29 -05007262 output.WriteInt32(13, field_names[6], Dummy13);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007263 }
csharptestc671a4b2011-06-08 11:51:24 -05007264 if (hasDummy14) {
csharptest920b09a2011-06-08 20:13:29 -05007265 output.WriteInt32(14, field_names[7], Dummy14);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007266 }
csharptestc671a4b2011-06-08 11:51:24 -05007267 if (hasDummy15) {
csharptest920b09a2011-06-08 20:13:29 -05007268 output.WriteInt32(15, field_names[8], Dummy15);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007269 }
csharptestc671a4b2011-06-08 11:51:24 -05007270 if (hasDummy16) {
csharptest920b09a2011-06-08 20:13:29 -05007271 output.WriteInt32(16, field_names[9], Dummy16);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007272 }
csharptestc671a4b2011-06-08 11:51:24 -05007273 if (hasDummy17) {
csharptest920b09a2011-06-08 20:13:29 -05007274 output.WriteInt32(17, field_names[10], Dummy17);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007275 }
csharptestc671a4b2011-06-08 11:51:24 -05007276 if (hasDummy18) {
csharptest920b09a2011-06-08 20:13:29 -05007277 output.WriteInt32(18, field_names[11], Dummy18);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007278 }
csharptestc671a4b2011-06-08 11:51:24 -05007279 if (hasDummy19) {
csharptest920b09a2011-06-08 20:13:29 -05007280 output.WriteInt32(19, field_names[12], Dummy19);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007281 }
csharptestc671a4b2011-06-08 11:51:24 -05007282 if (hasDummy20) {
csharptest920b09a2011-06-08 20:13:29 -05007283 output.WriteInt32(20, field_names[14], Dummy20);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007284 }
csharptestc671a4b2011-06-08 11:51:24 -05007285 if (hasDummy21) {
csharptest920b09a2011-06-08 20:13:29 -05007286 output.WriteInt32(21, field_names[15], Dummy21);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007287 }
csharptestc671a4b2011-06-08 11:51:24 -05007288 if (hasDummy22) {
csharptest920b09a2011-06-08 20:13:29 -05007289 output.WriteInt32(22, field_names[16], Dummy22);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007290 }
csharptestc671a4b2011-06-08 11:51:24 -05007291 if (hasDummy23) {
csharptest920b09a2011-06-08 20:13:29 -05007292 output.WriteInt32(23, field_names[17], Dummy23);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007293 }
csharptestc671a4b2011-06-08 11:51:24 -05007294 if (hasDummy24) {
csharptest920b09a2011-06-08 20:13:29 -05007295 output.WriteInt32(24, field_names[18], Dummy24);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007296 }
csharptestc671a4b2011-06-08 11:51:24 -05007297 if (hasDummy25) {
csharptest920b09a2011-06-08 20:13:29 -05007298 output.WriteInt32(25, field_names[19], Dummy25);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007299 }
csharptestc671a4b2011-06-08 11:51:24 -05007300 if (hasDummy26) {
csharptest920b09a2011-06-08 20:13:29 -05007301 output.WriteInt32(26, field_names[20], Dummy26);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007302 }
csharptestc671a4b2011-06-08 11:51:24 -05007303 if (hasDummy27) {
csharptest920b09a2011-06-08 20:13:29 -05007304 output.WriteInt32(27, field_names[21], Dummy27);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007305 }
csharptestc671a4b2011-06-08 11:51:24 -05007306 if (hasDummy28) {
csharptest920b09a2011-06-08 20:13:29 -05007307 output.WriteInt32(28, field_names[22], Dummy28);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007308 }
csharptestc671a4b2011-06-08 11:51:24 -05007309 if (hasDummy29) {
csharptest920b09a2011-06-08 20:13:29 -05007310 output.WriteInt32(29, field_names[23], Dummy29);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007311 }
csharptestc671a4b2011-06-08 11:51:24 -05007312 if (hasDummy30) {
csharptest920b09a2011-06-08 20:13:29 -05007313 output.WriteInt32(30, field_names[24], Dummy30);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007314 }
csharptestc671a4b2011-06-08 11:51:24 -05007315 if (hasDummy31) {
csharptest920b09a2011-06-08 20:13:29 -05007316 output.WriteInt32(31, field_names[25], Dummy31);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007317 }
csharptestc671a4b2011-06-08 11:51:24 -05007318 if (hasDummy32) {
csharptest920b09a2011-06-08 20:13:29 -05007319 output.WriteInt32(32, field_names[26], Dummy32);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007320 }
csharptestc671a4b2011-06-08 11:51:24 -05007321 if (hasC) {
csharptest920b09a2011-06-08 20:13:29 -05007322 output.WriteInt32(33, field_names[2], C);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007323 }
7324 UnknownFields.WriteTo(output);
7325 }
7326
7327 private int memoizedSerializedSize = -1;
7328 public override int SerializedSize {
7329 get {
7330 int size = memoizedSerializedSize;
7331 if (size != -1) return size;
7332
7333 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05007334 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007335 size += pb::CodedOutputStream.ComputeInt32Size(1, A);
7336 }
csharptestc671a4b2011-06-08 11:51:24 -05007337 if (hasDummy2) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007338 size += pb::CodedOutputStream.ComputeInt32Size(2, Dummy2);
7339 }
csharptestc671a4b2011-06-08 11:51:24 -05007340 if (hasB) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007341 size += pb::CodedOutputStream.ComputeInt32Size(3, B);
7342 }
csharptestc671a4b2011-06-08 11:51:24 -05007343 if (hasDummy4) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007344 size += pb::CodedOutputStream.ComputeInt32Size(4, Dummy4);
7345 }
csharptestc671a4b2011-06-08 11:51:24 -05007346 if (hasDummy5) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007347 size += pb::CodedOutputStream.ComputeInt32Size(5, Dummy5);
7348 }
csharptestc671a4b2011-06-08 11:51:24 -05007349 if (hasDummy6) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007350 size += pb::CodedOutputStream.ComputeInt32Size(6, Dummy6);
7351 }
csharptestc671a4b2011-06-08 11:51:24 -05007352 if (hasDummy7) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007353 size += pb::CodedOutputStream.ComputeInt32Size(7, Dummy7);
7354 }
csharptestc671a4b2011-06-08 11:51:24 -05007355 if (hasDummy8) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007356 size += pb::CodedOutputStream.ComputeInt32Size(8, Dummy8);
7357 }
csharptestc671a4b2011-06-08 11:51:24 -05007358 if (hasDummy9) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007359 size += pb::CodedOutputStream.ComputeInt32Size(9, Dummy9);
7360 }
csharptestc671a4b2011-06-08 11:51:24 -05007361 if (hasDummy10) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007362 size += pb::CodedOutputStream.ComputeInt32Size(10, Dummy10);
7363 }
csharptestc671a4b2011-06-08 11:51:24 -05007364 if (hasDummy11) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007365 size += pb::CodedOutputStream.ComputeInt32Size(11, Dummy11);
7366 }
csharptestc671a4b2011-06-08 11:51:24 -05007367 if (hasDummy12) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007368 size += pb::CodedOutputStream.ComputeInt32Size(12, Dummy12);
7369 }
csharptestc671a4b2011-06-08 11:51:24 -05007370 if (hasDummy13) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007371 size += pb::CodedOutputStream.ComputeInt32Size(13, Dummy13);
7372 }
csharptestc671a4b2011-06-08 11:51:24 -05007373 if (hasDummy14) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007374 size += pb::CodedOutputStream.ComputeInt32Size(14, Dummy14);
7375 }
csharptestc671a4b2011-06-08 11:51:24 -05007376 if (hasDummy15) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007377 size += pb::CodedOutputStream.ComputeInt32Size(15, Dummy15);
7378 }
csharptestc671a4b2011-06-08 11:51:24 -05007379 if (hasDummy16) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007380 size += pb::CodedOutputStream.ComputeInt32Size(16, Dummy16);
7381 }
csharptestc671a4b2011-06-08 11:51:24 -05007382 if (hasDummy17) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007383 size += pb::CodedOutputStream.ComputeInt32Size(17, Dummy17);
7384 }
csharptestc671a4b2011-06-08 11:51:24 -05007385 if (hasDummy18) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007386 size += pb::CodedOutputStream.ComputeInt32Size(18, Dummy18);
7387 }
csharptestc671a4b2011-06-08 11:51:24 -05007388 if (hasDummy19) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007389 size += pb::CodedOutputStream.ComputeInt32Size(19, Dummy19);
7390 }
csharptestc671a4b2011-06-08 11:51:24 -05007391 if (hasDummy20) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007392 size += pb::CodedOutputStream.ComputeInt32Size(20, Dummy20);
7393 }
csharptestc671a4b2011-06-08 11:51:24 -05007394 if (hasDummy21) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007395 size += pb::CodedOutputStream.ComputeInt32Size(21, Dummy21);
7396 }
csharptestc671a4b2011-06-08 11:51:24 -05007397 if (hasDummy22) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007398 size += pb::CodedOutputStream.ComputeInt32Size(22, Dummy22);
7399 }
csharptestc671a4b2011-06-08 11:51:24 -05007400 if (hasDummy23) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007401 size += pb::CodedOutputStream.ComputeInt32Size(23, Dummy23);
7402 }
csharptestc671a4b2011-06-08 11:51:24 -05007403 if (hasDummy24) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007404 size += pb::CodedOutputStream.ComputeInt32Size(24, Dummy24);
7405 }
csharptestc671a4b2011-06-08 11:51:24 -05007406 if (hasDummy25) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007407 size += pb::CodedOutputStream.ComputeInt32Size(25, Dummy25);
7408 }
csharptestc671a4b2011-06-08 11:51:24 -05007409 if (hasDummy26) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007410 size += pb::CodedOutputStream.ComputeInt32Size(26, Dummy26);
7411 }
csharptestc671a4b2011-06-08 11:51:24 -05007412 if (hasDummy27) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007413 size += pb::CodedOutputStream.ComputeInt32Size(27, Dummy27);
7414 }
csharptestc671a4b2011-06-08 11:51:24 -05007415 if (hasDummy28) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007416 size += pb::CodedOutputStream.ComputeInt32Size(28, Dummy28);
7417 }
csharptestc671a4b2011-06-08 11:51:24 -05007418 if (hasDummy29) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007419 size += pb::CodedOutputStream.ComputeInt32Size(29, Dummy29);
7420 }
csharptestc671a4b2011-06-08 11:51:24 -05007421 if (hasDummy30) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007422 size += pb::CodedOutputStream.ComputeInt32Size(30, Dummy30);
7423 }
csharptestc671a4b2011-06-08 11:51:24 -05007424 if (hasDummy31) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007425 size += pb::CodedOutputStream.ComputeInt32Size(31, Dummy31);
7426 }
csharptestc671a4b2011-06-08 11:51:24 -05007427 if (hasDummy32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007428 size += pb::CodedOutputStream.ComputeInt32Size(32, Dummy32);
7429 }
csharptestc671a4b2011-06-08 11:51:24 -05007430 if (hasC) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007431 size += pb::CodedOutputStream.ComputeInt32Size(33, C);
7432 }
7433 size += UnknownFields.SerializedSize;
7434 memoizedSerializedSize = size;
7435 return size;
7436 }
7437 }
7438
7439 public static TestRequired ParseFrom(pb::ByteString data) {
7440 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
7441 }
7442 public static TestRequired ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
7443 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
7444 }
7445 public static TestRequired ParseFrom(byte[] data) {
7446 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
7447 }
7448 public static TestRequired ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
7449 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
7450 }
7451 public static TestRequired ParseFrom(global::System.IO.Stream input) {
7452 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
7453 }
7454 public static TestRequired ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
7455 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
7456 }
7457 public static TestRequired ParseDelimitedFrom(global::System.IO.Stream input) {
7458 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
7459 }
7460 public static TestRequired ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
7461 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
7462 }
csharptest17699c22011-06-03 21:57:15 -05007463 public static TestRequired ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007464 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
7465 }
csharptest17699c22011-06-03 21:57:15 -05007466 public static TestRequired ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007467 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
7468 }
7469 public static Builder CreateBuilder() { return new Builder(); }
7470 public override Builder ToBuilder() { return CreateBuilder(this); }
7471 public override Builder CreateBuilderForType() { return new Builder(); }
7472 public static Builder CreateBuilder(TestRequired prototype) {
7473 return (Builder) new Builder().MergeFrom(prototype);
7474 }
7475
csharptest445bdce2011-05-20 15:50:54 -05007476 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
7477 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
7478 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01007479 public sealed partial class Builder : pb::GeneratedBuilder<TestRequired, Builder> {
7480 protected override Builder ThisBuilder {
7481 get { return this; }
7482 }
7483 public Builder() {}
7484
7485 TestRequired result = new TestRequired();
7486
7487 protected override TestRequired MessageBeingBuilt {
7488 get { return result; }
7489 }
7490
7491 public override Builder Clear() {
7492 result = new TestRequired();
7493 return this;
7494 }
7495
7496 public override Builder Clone() {
7497 return new Builder().MergeFrom(result);
7498 }
7499
7500 public override pbd::MessageDescriptor DescriptorForType {
7501 get { return global::Google.ProtocolBuffers.TestProtos.TestRequired.Descriptor; }
7502 }
7503
7504 public override TestRequired DefaultInstanceForType {
7505 get { return global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance; }
7506 }
7507
7508 public override TestRequired BuildPartial() {
7509 if (result == null) {
7510 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
7511 }
7512 TestRequired returnMe = result;
7513 result = null;
7514 return returnMe;
7515 }
7516
7517 public override Builder MergeFrom(pb::IMessage other) {
7518 if (other is TestRequired) {
7519 return MergeFrom((TestRequired) other);
7520 } else {
7521 base.MergeFrom(other);
7522 return this;
7523 }
7524 }
7525
7526 public override Builder MergeFrom(TestRequired other) {
7527 if (other == global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) return this;
7528 if (other.HasA) {
7529 A = other.A;
7530 }
7531 if (other.HasDummy2) {
7532 Dummy2 = other.Dummy2;
7533 }
7534 if (other.HasB) {
7535 B = other.B;
7536 }
7537 if (other.HasDummy4) {
7538 Dummy4 = other.Dummy4;
7539 }
7540 if (other.HasDummy5) {
7541 Dummy5 = other.Dummy5;
7542 }
7543 if (other.HasDummy6) {
7544 Dummy6 = other.Dummy6;
7545 }
7546 if (other.HasDummy7) {
7547 Dummy7 = other.Dummy7;
7548 }
7549 if (other.HasDummy8) {
7550 Dummy8 = other.Dummy8;
7551 }
7552 if (other.HasDummy9) {
7553 Dummy9 = other.Dummy9;
7554 }
7555 if (other.HasDummy10) {
7556 Dummy10 = other.Dummy10;
7557 }
7558 if (other.HasDummy11) {
7559 Dummy11 = other.Dummy11;
7560 }
7561 if (other.HasDummy12) {
7562 Dummy12 = other.Dummy12;
7563 }
7564 if (other.HasDummy13) {
7565 Dummy13 = other.Dummy13;
7566 }
7567 if (other.HasDummy14) {
7568 Dummy14 = other.Dummy14;
7569 }
7570 if (other.HasDummy15) {
7571 Dummy15 = other.Dummy15;
7572 }
7573 if (other.HasDummy16) {
7574 Dummy16 = other.Dummy16;
7575 }
7576 if (other.HasDummy17) {
7577 Dummy17 = other.Dummy17;
7578 }
7579 if (other.HasDummy18) {
7580 Dummy18 = other.Dummy18;
7581 }
7582 if (other.HasDummy19) {
7583 Dummy19 = other.Dummy19;
7584 }
7585 if (other.HasDummy20) {
7586 Dummy20 = other.Dummy20;
7587 }
7588 if (other.HasDummy21) {
7589 Dummy21 = other.Dummy21;
7590 }
7591 if (other.HasDummy22) {
7592 Dummy22 = other.Dummy22;
7593 }
7594 if (other.HasDummy23) {
7595 Dummy23 = other.Dummy23;
7596 }
7597 if (other.HasDummy24) {
7598 Dummy24 = other.Dummy24;
7599 }
7600 if (other.HasDummy25) {
7601 Dummy25 = other.Dummy25;
7602 }
7603 if (other.HasDummy26) {
7604 Dummy26 = other.Dummy26;
7605 }
7606 if (other.HasDummy27) {
7607 Dummy27 = other.Dummy27;
7608 }
7609 if (other.HasDummy28) {
7610 Dummy28 = other.Dummy28;
7611 }
7612 if (other.HasDummy29) {
7613 Dummy29 = other.Dummy29;
7614 }
7615 if (other.HasDummy30) {
7616 Dummy30 = other.Dummy30;
7617 }
7618 if (other.HasDummy31) {
7619 Dummy31 = other.Dummy31;
7620 }
7621 if (other.HasDummy32) {
7622 Dummy32 = other.Dummy32;
7623 }
7624 if (other.HasC) {
7625 C = other.C;
7626 }
7627 this.MergeUnknownFields(other.UnknownFields);
7628 return this;
7629 }
7630
csharptest17699c22011-06-03 21:57:15 -05007631 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007632 return MergeFrom(input, pb::ExtensionRegistry.Empty);
7633 }
7634
csharptest17699c22011-06-03 21:57:15 -05007635 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01007636 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05007637 uint tag;
7638 string field_name;
7639 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05007640 if(tag == 0 && field_name != null) {
7641 int field_ordinal = global::System.Array.BinarySearch(_testRequiredFieldNames, field_name, global::System.StringComparer.Ordinal);
7642 if(field_ordinal >= 0)
7643 tag = _testRequiredFieldTags[field_ordinal];
7644 else {
7645 if (unknownFields == null) {
7646 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
7647 }
7648 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
7649 continue;
7650 }
7651 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007652 switch (tag) {
7653 case 0: {
csharptest99284412011-06-03 14:51:06 -05007654 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01007655 }
7656 default: {
7657 if (pb::WireFormat.IsEndGroupTag(tag)) {
7658 if (unknownFields != null) {
7659 this.UnknownFields = unknownFields.Build();
7660 }
7661 return this;
7662 }
7663 if (unknownFields == null) {
7664 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
7665 }
csharptestd2af9e92011-06-03 21:35:02 -05007666 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007667 break;
7668 }
7669 case 8: {
csharptest920b09a2011-06-08 20:13:29 -05007670 result.hasA = input.ReadInt32(ref result.a_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007671 break;
7672 }
7673 case 16: {
csharptest920b09a2011-06-08 20:13:29 -05007674 result.hasDummy2 = input.ReadInt32(ref result.dummy2_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007675 break;
7676 }
7677 case 24: {
csharptest920b09a2011-06-08 20:13:29 -05007678 result.hasB = input.ReadInt32(ref result.b_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007679 break;
7680 }
7681 case 32: {
csharptest920b09a2011-06-08 20:13:29 -05007682 result.hasDummy4 = input.ReadInt32(ref result.dummy4_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007683 break;
7684 }
7685 case 40: {
csharptest920b09a2011-06-08 20:13:29 -05007686 result.hasDummy5 = input.ReadInt32(ref result.dummy5_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007687 break;
7688 }
7689 case 48: {
csharptest920b09a2011-06-08 20:13:29 -05007690 result.hasDummy6 = input.ReadInt32(ref result.dummy6_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007691 break;
7692 }
7693 case 56: {
csharptest920b09a2011-06-08 20:13:29 -05007694 result.hasDummy7 = input.ReadInt32(ref result.dummy7_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007695 break;
7696 }
7697 case 64: {
csharptest920b09a2011-06-08 20:13:29 -05007698 result.hasDummy8 = input.ReadInt32(ref result.dummy8_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007699 break;
7700 }
7701 case 72: {
csharptest920b09a2011-06-08 20:13:29 -05007702 result.hasDummy9 = input.ReadInt32(ref result.dummy9_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007703 break;
7704 }
7705 case 80: {
csharptest920b09a2011-06-08 20:13:29 -05007706 result.hasDummy10 = input.ReadInt32(ref result.dummy10_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007707 break;
7708 }
7709 case 88: {
csharptest920b09a2011-06-08 20:13:29 -05007710 result.hasDummy11 = input.ReadInt32(ref result.dummy11_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007711 break;
7712 }
7713 case 96: {
csharptest920b09a2011-06-08 20:13:29 -05007714 result.hasDummy12 = input.ReadInt32(ref result.dummy12_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007715 break;
7716 }
7717 case 104: {
csharptest920b09a2011-06-08 20:13:29 -05007718 result.hasDummy13 = input.ReadInt32(ref result.dummy13_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007719 break;
7720 }
7721 case 112: {
csharptest920b09a2011-06-08 20:13:29 -05007722 result.hasDummy14 = input.ReadInt32(ref result.dummy14_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007723 break;
7724 }
7725 case 120: {
csharptest920b09a2011-06-08 20:13:29 -05007726 result.hasDummy15 = input.ReadInt32(ref result.dummy15_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007727 break;
7728 }
7729 case 128: {
csharptest920b09a2011-06-08 20:13:29 -05007730 result.hasDummy16 = input.ReadInt32(ref result.dummy16_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007731 break;
7732 }
7733 case 136: {
csharptest920b09a2011-06-08 20:13:29 -05007734 result.hasDummy17 = input.ReadInt32(ref result.dummy17_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007735 break;
7736 }
7737 case 144: {
csharptest920b09a2011-06-08 20:13:29 -05007738 result.hasDummy18 = input.ReadInt32(ref result.dummy18_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007739 break;
7740 }
7741 case 152: {
csharptest920b09a2011-06-08 20:13:29 -05007742 result.hasDummy19 = input.ReadInt32(ref result.dummy19_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007743 break;
7744 }
7745 case 160: {
csharptest920b09a2011-06-08 20:13:29 -05007746 result.hasDummy20 = input.ReadInt32(ref result.dummy20_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007747 break;
7748 }
7749 case 168: {
csharptest920b09a2011-06-08 20:13:29 -05007750 result.hasDummy21 = input.ReadInt32(ref result.dummy21_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007751 break;
7752 }
7753 case 176: {
csharptest920b09a2011-06-08 20:13:29 -05007754 result.hasDummy22 = input.ReadInt32(ref result.dummy22_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007755 break;
7756 }
7757 case 184: {
csharptest920b09a2011-06-08 20:13:29 -05007758 result.hasDummy23 = input.ReadInt32(ref result.dummy23_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007759 break;
7760 }
7761 case 192: {
csharptest920b09a2011-06-08 20:13:29 -05007762 result.hasDummy24 = input.ReadInt32(ref result.dummy24_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007763 break;
7764 }
7765 case 200: {
csharptest920b09a2011-06-08 20:13:29 -05007766 result.hasDummy25 = input.ReadInt32(ref result.dummy25_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007767 break;
7768 }
7769 case 208: {
csharptest920b09a2011-06-08 20:13:29 -05007770 result.hasDummy26 = input.ReadInt32(ref result.dummy26_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007771 break;
7772 }
7773 case 216: {
csharptest920b09a2011-06-08 20:13:29 -05007774 result.hasDummy27 = input.ReadInt32(ref result.dummy27_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007775 break;
7776 }
7777 case 224: {
csharptest920b09a2011-06-08 20:13:29 -05007778 result.hasDummy28 = input.ReadInt32(ref result.dummy28_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007779 break;
7780 }
7781 case 232: {
csharptest920b09a2011-06-08 20:13:29 -05007782 result.hasDummy29 = input.ReadInt32(ref result.dummy29_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007783 break;
7784 }
7785 case 240: {
csharptest920b09a2011-06-08 20:13:29 -05007786 result.hasDummy30 = input.ReadInt32(ref result.dummy30_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007787 break;
7788 }
7789 case 248: {
csharptest920b09a2011-06-08 20:13:29 -05007790 result.hasDummy31 = input.ReadInt32(ref result.dummy31_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007791 break;
7792 }
7793 case 256: {
csharptest920b09a2011-06-08 20:13:29 -05007794 result.hasDummy32 = input.ReadInt32(ref result.dummy32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007795 break;
7796 }
7797 case 264: {
csharptest920b09a2011-06-08 20:13:29 -05007798 result.hasC = input.ReadInt32(ref result.c_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01007799 break;
7800 }
7801 }
7802 }
csharptest123e5342011-06-03 14:15:21 -05007803
7804 if (unknownFields != null) {
7805 this.UnknownFields = unknownFields.Build();
7806 }
7807 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01007808 }
7809
7810
7811 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -05007812 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007813 }
7814 public int A {
7815 get { return result.A; }
7816 set { SetA(value); }
7817 }
7818 public Builder SetA(int value) {
7819 result.hasA = true;
7820 result.a_ = value;
7821 return this;
7822 }
7823 public Builder ClearA() {
7824 result.hasA = false;
7825 result.a_ = 0;
7826 return this;
7827 }
7828
7829 public bool HasDummy2 {
csharptestc671a4b2011-06-08 11:51:24 -05007830 get { return result.hasDummy2; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007831 }
7832 public int Dummy2 {
7833 get { return result.Dummy2; }
7834 set { SetDummy2(value); }
7835 }
7836 public Builder SetDummy2(int value) {
7837 result.hasDummy2 = true;
7838 result.dummy2_ = value;
7839 return this;
7840 }
7841 public Builder ClearDummy2() {
7842 result.hasDummy2 = false;
7843 result.dummy2_ = 0;
7844 return this;
7845 }
7846
7847 public bool HasB {
csharptestc671a4b2011-06-08 11:51:24 -05007848 get { return result.hasB; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007849 }
7850 public int B {
7851 get { return result.B; }
7852 set { SetB(value); }
7853 }
7854 public Builder SetB(int value) {
7855 result.hasB = true;
7856 result.b_ = value;
7857 return this;
7858 }
7859 public Builder ClearB() {
7860 result.hasB = false;
7861 result.b_ = 0;
7862 return this;
7863 }
7864
7865 public bool HasDummy4 {
csharptestc671a4b2011-06-08 11:51:24 -05007866 get { return result.hasDummy4; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007867 }
7868 public int Dummy4 {
7869 get { return result.Dummy4; }
7870 set { SetDummy4(value); }
7871 }
7872 public Builder SetDummy4(int value) {
7873 result.hasDummy4 = true;
7874 result.dummy4_ = value;
7875 return this;
7876 }
7877 public Builder ClearDummy4() {
7878 result.hasDummy4 = false;
7879 result.dummy4_ = 0;
7880 return this;
7881 }
7882
7883 public bool HasDummy5 {
csharptestc671a4b2011-06-08 11:51:24 -05007884 get { return result.hasDummy5; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007885 }
7886 public int Dummy5 {
7887 get { return result.Dummy5; }
7888 set { SetDummy5(value); }
7889 }
7890 public Builder SetDummy5(int value) {
7891 result.hasDummy5 = true;
7892 result.dummy5_ = value;
7893 return this;
7894 }
7895 public Builder ClearDummy5() {
7896 result.hasDummy5 = false;
7897 result.dummy5_ = 0;
7898 return this;
7899 }
7900
7901 public bool HasDummy6 {
csharptestc671a4b2011-06-08 11:51:24 -05007902 get { return result.hasDummy6; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007903 }
7904 public int Dummy6 {
7905 get { return result.Dummy6; }
7906 set { SetDummy6(value); }
7907 }
7908 public Builder SetDummy6(int value) {
7909 result.hasDummy6 = true;
7910 result.dummy6_ = value;
7911 return this;
7912 }
7913 public Builder ClearDummy6() {
7914 result.hasDummy6 = false;
7915 result.dummy6_ = 0;
7916 return this;
7917 }
7918
7919 public bool HasDummy7 {
csharptestc671a4b2011-06-08 11:51:24 -05007920 get { return result.hasDummy7; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007921 }
7922 public int Dummy7 {
7923 get { return result.Dummy7; }
7924 set { SetDummy7(value); }
7925 }
7926 public Builder SetDummy7(int value) {
7927 result.hasDummy7 = true;
7928 result.dummy7_ = value;
7929 return this;
7930 }
7931 public Builder ClearDummy7() {
7932 result.hasDummy7 = false;
7933 result.dummy7_ = 0;
7934 return this;
7935 }
7936
7937 public bool HasDummy8 {
csharptestc671a4b2011-06-08 11:51:24 -05007938 get { return result.hasDummy8; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007939 }
7940 public int Dummy8 {
7941 get { return result.Dummy8; }
7942 set { SetDummy8(value); }
7943 }
7944 public Builder SetDummy8(int value) {
7945 result.hasDummy8 = true;
7946 result.dummy8_ = value;
7947 return this;
7948 }
7949 public Builder ClearDummy8() {
7950 result.hasDummy8 = false;
7951 result.dummy8_ = 0;
7952 return this;
7953 }
7954
7955 public bool HasDummy9 {
csharptestc671a4b2011-06-08 11:51:24 -05007956 get { return result.hasDummy9; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007957 }
7958 public int Dummy9 {
7959 get { return result.Dummy9; }
7960 set { SetDummy9(value); }
7961 }
7962 public Builder SetDummy9(int value) {
7963 result.hasDummy9 = true;
7964 result.dummy9_ = value;
7965 return this;
7966 }
7967 public Builder ClearDummy9() {
7968 result.hasDummy9 = false;
7969 result.dummy9_ = 0;
7970 return this;
7971 }
7972
7973 public bool HasDummy10 {
csharptestc671a4b2011-06-08 11:51:24 -05007974 get { return result.hasDummy10; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007975 }
7976 public int Dummy10 {
7977 get { return result.Dummy10; }
7978 set { SetDummy10(value); }
7979 }
7980 public Builder SetDummy10(int value) {
7981 result.hasDummy10 = true;
7982 result.dummy10_ = value;
7983 return this;
7984 }
7985 public Builder ClearDummy10() {
7986 result.hasDummy10 = false;
7987 result.dummy10_ = 0;
7988 return this;
7989 }
7990
7991 public bool HasDummy11 {
csharptestc671a4b2011-06-08 11:51:24 -05007992 get { return result.hasDummy11; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01007993 }
7994 public int Dummy11 {
7995 get { return result.Dummy11; }
7996 set { SetDummy11(value); }
7997 }
7998 public Builder SetDummy11(int value) {
7999 result.hasDummy11 = true;
8000 result.dummy11_ = value;
8001 return this;
8002 }
8003 public Builder ClearDummy11() {
8004 result.hasDummy11 = false;
8005 result.dummy11_ = 0;
8006 return this;
8007 }
8008
8009 public bool HasDummy12 {
csharptestc671a4b2011-06-08 11:51:24 -05008010 get { return result.hasDummy12; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008011 }
8012 public int Dummy12 {
8013 get { return result.Dummy12; }
8014 set { SetDummy12(value); }
8015 }
8016 public Builder SetDummy12(int value) {
8017 result.hasDummy12 = true;
8018 result.dummy12_ = value;
8019 return this;
8020 }
8021 public Builder ClearDummy12() {
8022 result.hasDummy12 = false;
8023 result.dummy12_ = 0;
8024 return this;
8025 }
8026
8027 public bool HasDummy13 {
csharptestc671a4b2011-06-08 11:51:24 -05008028 get { return result.hasDummy13; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008029 }
8030 public int Dummy13 {
8031 get { return result.Dummy13; }
8032 set { SetDummy13(value); }
8033 }
8034 public Builder SetDummy13(int value) {
8035 result.hasDummy13 = true;
8036 result.dummy13_ = value;
8037 return this;
8038 }
8039 public Builder ClearDummy13() {
8040 result.hasDummy13 = false;
8041 result.dummy13_ = 0;
8042 return this;
8043 }
8044
8045 public bool HasDummy14 {
csharptestc671a4b2011-06-08 11:51:24 -05008046 get { return result.hasDummy14; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008047 }
8048 public int Dummy14 {
8049 get { return result.Dummy14; }
8050 set { SetDummy14(value); }
8051 }
8052 public Builder SetDummy14(int value) {
8053 result.hasDummy14 = true;
8054 result.dummy14_ = value;
8055 return this;
8056 }
8057 public Builder ClearDummy14() {
8058 result.hasDummy14 = false;
8059 result.dummy14_ = 0;
8060 return this;
8061 }
8062
8063 public bool HasDummy15 {
csharptestc671a4b2011-06-08 11:51:24 -05008064 get { return result.hasDummy15; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008065 }
8066 public int Dummy15 {
8067 get { return result.Dummy15; }
8068 set { SetDummy15(value); }
8069 }
8070 public Builder SetDummy15(int value) {
8071 result.hasDummy15 = true;
8072 result.dummy15_ = value;
8073 return this;
8074 }
8075 public Builder ClearDummy15() {
8076 result.hasDummy15 = false;
8077 result.dummy15_ = 0;
8078 return this;
8079 }
8080
8081 public bool HasDummy16 {
csharptestc671a4b2011-06-08 11:51:24 -05008082 get { return result.hasDummy16; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008083 }
8084 public int Dummy16 {
8085 get { return result.Dummy16; }
8086 set { SetDummy16(value); }
8087 }
8088 public Builder SetDummy16(int value) {
8089 result.hasDummy16 = true;
8090 result.dummy16_ = value;
8091 return this;
8092 }
8093 public Builder ClearDummy16() {
8094 result.hasDummy16 = false;
8095 result.dummy16_ = 0;
8096 return this;
8097 }
8098
8099 public bool HasDummy17 {
csharptestc671a4b2011-06-08 11:51:24 -05008100 get { return result.hasDummy17; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008101 }
8102 public int Dummy17 {
8103 get { return result.Dummy17; }
8104 set { SetDummy17(value); }
8105 }
8106 public Builder SetDummy17(int value) {
8107 result.hasDummy17 = true;
8108 result.dummy17_ = value;
8109 return this;
8110 }
8111 public Builder ClearDummy17() {
8112 result.hasDummy17 = false;
8113 result.dummy17_ = 0;
8114 return this;
8115 }
8116
8117 public bool HasDummy18 {
csharptestc671a4b2011-06-08 11:51:24 -05008118 get { return result.hasDummy18; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008119 }
8120 public int Dummy18 {
8121 get { return result.Dummy18; }
8122 set { SetDummy18(value); }
8123 }
8124 public Builder SetDummy18(int value) {
8125 result.hasDummy18 = true;
8126 result.dummy18_ = value;
8127 return this;
8128 }
8129 public Builder ClearDummy18() {
8130 result.hasDummy18 = false;
8131 result.dummy18_ = 0;
8132 return this;
8133 }
8134
8135 public bool HasDummy19 {
csharptestc671a4b2011-06-08 11:51:24 -05008136 get { return result.hasDummy19; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008137 }
8138 public int Dummy19 {
8139 get { return result.Dummy19; }
8140 set { SetDummy19(value); }
8141 }
8142 public Builder SetDummy19(int value) {
8143 result.hasDummy19 = true;
8144 result.dummy19_ = value;
8145 return this;
8146 }
8147 public Builder ClearDummy19() {
8148 result.hasDummy19 = false;
8149 result.dummy19_ = 0;
8150 return this;
8151 }
8152
8153 public bool HasDummy20 {
csharptestc671a4b2011-06-08 11:51:24 -05008154 get { return result.hasDummy20; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008155 }
8156 public int Dummy20 {
8157 get { return result.Dummy20; }
8158 set { SetDummy20(value); }
8159 }
8160 public Builder SetDummy20(int value) {
8161 result.hasDummy20 = true;
8162 result.dummy20_ = value;
8163 return this;
8164 }
8165 public Builder ClearDummy20() {
8166 result.hasDummy20 = false;
8167 result.dummy20_ = 0;
8168 return this;
8169 }
8170
8171 public bool HasDummy21 {
csharptestc671a4b2011-06-08 11:51:24 -05008172 get { return result.hasDummy21; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008173 }
8174 public int Dummy21 {
8175 get { return result.Dummy21; }
8176 set { SetDummy21(value); }
8177 }
8178 public Builder SetDummy21(int value) {
8179 result.hasDummy21 = true;
8180 result.dummy21_ = value;
8181 return this;
8182 }
8183 public Builder ClearDummy21() {
8184 result.hasDummy21 = false;
8185 result.dummy21_ = 0;
8186 return this;
8187 }
8188
8189 public bool HasDummy22 {
csharptestc671a4b2011-06-08 11:51:24 -05008190 get { return result.hasDummy22; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008191 }
8192 public int Dummy22 {
8193 get { return result.Dummy22; }
8194 set { SetDummy22(value); }
8195 }
8196 public Builder SetDummy22(int value) {
8197 result.hasDummy22 = true;
8198 result.dummy22_ = value;
8199 return this;
8200 }
8201 public Builder ClearDummy22() {
8202 result.hasDummy22 = false;
8203 result.dummy22_ = 0;
8204 return this;
8205 }
8206
8207 public bool HasDummy23 {
csharptestc671a4b2011-06-08 11:51:24 -05008208 get { return result.hasDummy23; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008209 }
8210 public int Dummy23 {
8211 get { return result.Dummy23; }
8212 set { SetDummy23(value); }
8213 }
8214 public Builder SetDummy23(int value) {
8215 result.hasDummy23 = true;
8216 result.dummy23_ = value;
8217 return this;
8218 }
8219 public Builder ClearDummy23() {
8220 result.hasDummy23 = false;
8221 result.dummy23_ = 0;
8222 return this;
8223 }
8224
8225 public bool HasDummy24 {
csharptestc671a4b2011-06-08 11:51:24 -05008226 get { return result.hasDummy24; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008227 }
8228 public int Dummy24 {
8229 get { return result.Dummy24; }
8230 set { SetDummy24(value); }
8231 }
8232 public Builder SetDummy24(int value) {
8233 result.hasDummy24 = true;
8234 result.dummy24_ = value;
8235 return this;
8236 }
8237 public Builder ClearDummy24() {
8238 result.hasDummy24 = false;
8239 result.dummy24_ = 0;
8240 return this;
8241 }
8242
8243 public bool HasDummy25 {
csharptestc671a4b2011-06-08 11:51:24 -05008244 get { return result.hasDummy25; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008245 }
8246 public int Dummy25 {
8247 get { return result.Dummy25; }
8248 set { SetDummy25(value); }
8249 }
8250 public Builder SetDummy25(int value) {
8251 result.hasDummy25 = true;
8252 result.dummy25_ = value;
8253 return this;
8254 }
8255 public Builder ClearDummy25() {
8256 result.hasDummy25 = false;
8257 result.dummy25_ = 0;
8258 return this;
8259 }
8260
8261 public bool HasDummy26 {
csharptestc671a4b2011-06-08 11:51:24 -05008262 get { return result.hasDummy26; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008263 }
8264 public int Dummy26 {
8265 get { return result.Dummy26; }
8266 set { SetDummy26(value); }
8267 }
8268 public Builder SetDummy26(int value) {
8269 result.hasDummy26 = true;
8270 result.dummy26_ = value;
8271 return this;
8272 }
8273 public Builder ClearDummy26() {
8274 result.hasDummy26 = false;
8275 result.dummy26_ = 0;
8276 return this;
8277 }
8278
8279 public bool HasDummy27 {
csharptestc671a4b2011-06-08 11:51:24 -05008280 get { return result.hasDummy27; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008281 }
8282 public int Dummy27 {
8283 get { return result.Dummy27; }
8284 set { SetDummy27(value); }
8285 }
8286 public Builder SetDummy27(int value) {
8287 result.hasDummy27 = true;
8288 result.dummy27_ = value;
8289 return this;
8290 }
8291 public Builder ClearDummy27() {
8292 result.hasDummy27 = false;
8293 result.dummy27_ = 0;
8294 return this;
8295 }
8296
8297 public bool HasDummy28 {
csharptestc671a4b2011-06-08 11:51:24 -05008298 get { return result.hasDummy28; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008299 }
8300 public int Dummy28 {
8301 get { return result.Dummy28; }
8302 set { SetDummy28(value); }
8303 }
8304 public Builder SetDummy28(int value) {
8305 result.hasDummy28 = true;
8306 result.dummy28_ = value;
8307 return this;
8308 }
8309 public Builder ClearDummy28() {
8310 result.hasDummy28 = false;
8311 result.dummy28_ = 0;
8312 return this;
8313 }
8314
8315 public bool HasDummy29 {
csharptestc671a4b2011-06-08 11:51:24 -05008316 get { return result.hasDummy29; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008317 }
8318 public int Dummy29 {
8319 get { return result.Dummy29; }
8320 set { SetDummy29(value); }
8321 }
8322 public Builder SetDummy29(int value) {
8323 result.hasDummy29 = true;
8324 result.dummy29_ = value;
8325 return this;
8326 }
8327 public Builder ClearDummy29() {
8328 result.hasDummy29 = false;
8329 result.dummy29_ = 0;
8330 return this;
8331 }
8332
8333 public bool HasDummy30 {
csharptestc671a4b2011-06-08 11:51:24 -05008334 get { return result.hasDummy30; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008335 }
8336 public int Dummy30 {
8337 get { return result.Dummy30; }
8338 set { SetDummy30(value); }
8339 }
8340 public Builder SetDummy30(int value) {
8341 result.hasDummy30 = true;
8342 result.dummy30_ = value;
8343 return this;
8344 }
8345 public Builder ClearDummy30() {
8346 result.hasDummy30 = false;
8347 result.dummy30_ = 0;
8348 return this;
8349 }
8350
8351 public bool HasDummy31 {
csharptestc671a4b2011-06-08 11:51:24 -05008352 get { return result.hasDummy31; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008353 }
8354 public int Dummy31 {
8355 get { return result.Dummy31; }
8356 set { SetDummy31(value); }
8357 }
8358 public Builder SetDummy31(int value) {
8359 result.hasDummy31 = true;
8360 result.dummy31_ = value;
8361 return this;
8362 }
8363 public Builder ClearDummy31() {
8364 result.hasDummy31 = false;
8365 result.dummy31_ = 0;
8366 return this;
8367 }
8368
8369 public bool HasDummy32 {
csharptestc671a4b2011-06-08 11:51:24 -05008370 get { return result.hasDummy32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008371 }
8372 public int Dummy32 {
8373 get { return result.Dummy32; }
8374 set { SetDummy32(value); }
8375 }
8376 public Builder SetDummy32(int value) {
8377 result.hasDummy32 = true;
8378 result.dummy32_ = value;
8379 return this;
8380 }
8381 public Builder ClearDummy32() {
8382 result.hasDummy32 = false;
8383 result.dummy32_ = 0;
8384 return this;
8385 }
8386
8387 public bool HasC {
csharptestc671a4b2011-06-08 11:51:24 -05008388 get { return result.hasC; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008389 }
8390 public int C {
8391 get { return result.C; }
8392 set { SetC(value); }
8393 }
8394 public Builder SetC(int value) {
8395 result.hasC = true;
8396 result.c_ = value;
8397 return this;
8398 }
8399 public Builder ClearC() {
8400 result.hasC = false;
8401 result.c_ = 0;
8402 return this;
8403 }
8404 }
8405 static TestRequired() {
8406 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
8407 }
8408 }
8409
csharptest445bdce2011-05-20 15:50:54 -05008410 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
8411 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
8412 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01008413 public sealed partial class TestRequiredForeign : pb::GeneratedMessage<TestRequiredForeign, TestRequiredForeign.Builder> {
8414 private static readonly TestRequiredForeign defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05008415 private static readonly string[] _testRequiredForeignFieldNames = new string[] { "dummy", "optional_message", "repeated_message" };
8416 private static readonly uint[] _testRequiredForeignFieldTags = new uint[] { 24, 10, 18 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01008417 public static TestRequiredForeign DefaultInstance {
8418 get { return defaultInstance; }
8419 }
8420
8421 public override TestRequiredForeign DefaultInstanceForType {
8422 get { return defaultInstance; }
8423 }
8424
8425 protected override TestRequiredForeign ThisMessage {
8426 get { return this; }
8427 }
8428
8429 public static pbd::MessageDescriptor Descriptor {
8430 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRequiredForeign__Descriptor; }
8431 }
8432
8433 protected override pb::FieldAccess.FieldAccessorTable<TestRequiredForeign, TestRequiredForeign.Builder> InternalFieldAccessors {
8434 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRequiredForeign__FieldAccessorTable; }
8435 }
8436
8437 public const int OptionalMessageFieldNumber = 1;
8438 private bool hasOptionalMessage;
8439 private global::Google.ProtocolBuffers.TestProtos.TestRequired optionalMessage_ = global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance;
8440 public bool HasOptionalMessage {
8441 get { return hasOptionalMessage; }
8442 }
8443 public global::Google.ProtocolBuffers.TestProtos.TestRequired OptionalMessage {
8444 get { return optionalMessage_; }
8445 }
8446
8447 public const int RepeatedMessageFieldNumber = 2;
8448 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.TestRequired> repeatedMessage_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.TestRequired>();
8449 public scg::IList<global::Google.ProtocolBuffers.TestProtos.TestRequired> RepeatedMessageList {
8450 get { return repeatedMessage_; }
8451 }
8452 public int RepeatedMessageCount {
8453 get { return repeatedMessage_.Count; }
8454 }
8455 public global::Google.ProtocolBuffers.TestProtos.TestRequired GetRepeatedMessage(int index) {
8456 return repeatedMessage_[index];
8457 }
8458
8459 public const int DummyFieldNumber = 3;
8460 private bool hasDummy;
csharptestced18e12011-06-09 19:47:56 -05008461 private int dummy_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01008462 public bool HasDummy {
8463 get { return hasDummy; }
8464 }
8465 public int Dummy {
8466 get { return dummy_; }
8467 }
8468
8469 public override bool IsInitialized {
8470 get {
8471 if (HasOptionalMessage) {
8472 if (!OptionalMessage.IsInitialized) return false;
8473 }
8474 foreach (global::Google.ProtocolBuffers.TestProtos.TestRequired element in RepeatedMessageList) {
8475 if (!element.IsInitialized) return false;
8476 }
8477 return true;
8478 }
8479 }
8480
csharptestffafdaa2011-06-03 12:58:14 -05008481 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008482 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05008483 string[] field_names = _testRequiredForeignFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05008484 if (hasOptionalMessage) {
csharptest920b09a2011-06-08 20:13:29 -05008485 output.WriteMessage(1, field_names[1], OptionalMessage);
Jon Skeet82bb0f12011-04-03 20:17:12 +01008486 }
csharptest90922db2011-06-03 11:57:47 -05008487 if (repeatedMessage_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -05008488 output.WriteArray(pbd::FieldType.Message, 2, field_names[2], repeatedMessage_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01008489 }
csharptestc671a4b2011-06-08 11:51:24 -05008490 if (hasDummy) {
csharptest920b09a2011-06-08 20:13:29 -05008491 output.WriteInt32(3, field_names[0], Dummy);
Jon Skeet82bb0f12011-04-03 20:17:12 +01008492 }
8493 UnknownFields.WriteTo(output);
8494 }
8495
8496 private int memoizedSerializedSize = -1;
8497 public override int SerializedSize {
8498 get {
8499 int size = memoizedSerializedSize;
8500 if (size != -1) return size;
8501
8502 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05008503 if (hasOptionalMessage) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008504 size += pb::CodedOutputStream.ComputeMessageSize(1, OptionalMessage);
8505 }
8506 foreach (global::Google.ProtocolBuffers.TestProtos.TestRequired element in RepeatedMessageList) {
8507 size += pb::CodedOutputStream.ComputeMessageSize(2, element);
8508 }
csharptestc671a4b2011-06-08 11:51:24 -05008509 if (hasDummy) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008510 size += pb::CodedOutputStream.ComputeInt32Size(3, Dummy);
8511 }
8512 size += UnknownFields.SerializedSize;
8513 memoizedSerializedSize = size;
8514 return size;
8515 }
8516 }
8517
8518 public static TestRequiredForeign ParseFrom(pb::ByteString data) {
8519 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
8520 }
8521 public static TestRequiredForeign ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
8522 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
8523 }
8524 public static TestRequiredForeign ParseFrom(byte[] data) {
8525 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
8526 }
8527 public static TestRequiredForeign ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
8528 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
8529 }
8530 public static TestRequiredForeign ParseFrom(global::System.IO.Stream input) {
8531 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
8532 }
8533 public static TestRequiredForeign ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
8534 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
8535 }
8536 public static TestRequiredForeign ParseDelimitedFrom(global::System.IO.Stream input) {
8537 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
8538 }
8539 public static TestRequiredForeign ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
8540 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
8541 }
csharptest17699c22011-06-03 21:57:15 -05008542 public static TestRequiredForeign ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008543 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
8544 }
csharptest17699c22011-06-03 21:57:15 -05008545 public static TestRequiredForeign ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008546 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
8547 }
8548 public static Builder CreateBuilder() { return new Builder(); }
8549 public override Builder ToBuilder() { return CreateBuilder(this); }
8550 public override Builder CreateBuilderForType() { return new Builder(); }
8551 public static Builder CreateBuilder(TestRequiredForeign prototype) {
8552 return (Builder) new Builder().MergeFrom(prototype);
8553 }
8554
csharptest445bdce2011-05-20 15:50:54 -05008555 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
8556 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
8557 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01008558 public sealed partial class Builder : pb::GeneratedBuilder<TestRequiredForeign, Builder> {
8559 protected override Builder ThisBuilder {
8560 get { return this; }
8561 }
8562 public Builder() {}
8563
8564 TestRequiredForeign result = new TestRequiredForeign();
8565
8566 protected override TestRequiredForeign MessageBeingBuilt {
8567 get { return result; }
8568 }
8569
8570 public override Builder Clear() {
8571 result = new TestRequiredForeign();
8572 return this;
8573 }
8574
8575 public override Builder Clone() {
8576 return new Builder().MergeFrom(result);
8577 }
8578
8579 public override pbd::MessageDescriptor DescriptorForType {
8580 get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.Descriptor; }
8581 }
8582
8583 public override TestRequiredForeign DefaultInstanceForType {
8584 get { return global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.DefaultInstance; }
8585 }
8586
8587 public override TestRequiredForeign BuildPartial() {
8588 if (result == null) {
8589 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
8590 }
8591 result.repeatedMessage_.MakeReadOnly();
8592 TestRequiredForeign returnMe = result;
8593 result = null;
8594 return returnMe;
8595 }
8596
8597 public override Builder MergeFrom(pb::IMessage other) {
8598 if (other is TestRequiredForeign) {
8599 return MergeFrom((TestRequiredForeign) other);
8600 } else {
8601 base.MergeFrom(other);
8602 return this;
8603 }
8604 }
8605
8606 public override Builder MergeFrom(TestRequiredForeign other) {
8607 if (other == global::Google.ProtocolBuffers.TestProtos.TestRequiredForeign.DefaultInstance) return this;
8608 if (other.HasOptionalMessage) {
8609 MergeOptionalMessage(other.OptionalMessage);
8610 }
8611 if (other.repeatedMessage_.Count != 0) {
8612 base.AddRange(other.repeatedMessage_, result.repeatedMessage_);
8613 }
8614 if (other.HasDummy) {
8615 Dummy = other.Dummy;
8616 }
8617 this.MergeUnknownFields(other.UnknownFields);
8618 return this;
8619 }
8620
csharptest17699c22011-06-03 21:57:15 -05008621 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008622 return MergeFrom(input, pb::ExtensionRegistry.Empty);
8623 }
8624
csharptest17699c22011-06-03 21:57:15 -05008625 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008626 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05008627 uint tag;
8628 string field_name;
8629 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05008630 if(tag == 0 && field_name != null) {
8631 int field_ordinal = global::System.Array.BinarySearch(_testRequiredForeignFieldNames, field_name, global::System.StringComparer.Ordinal);
8632 if(field_ordinal >= 0)
8633 tag = _testRequiredForeignFieldTags[field_ordinal];
8634 else {
8635 if (unknownFields == null) {
8636 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
8637 }
8638 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
8639 continue;
8640 }
8641 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008642 switch (tag) {
8643 case 0: {
csharptest99284412011-06-03 14:51:06 -05008644 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01008645 }
8646 default: {
8647 if (pb::WireFormat.IsEndGroupTag(tag)) {
8648 if (unknownFields != null) {
8649 this.UnknownFields = unknownFields.Build();
8650 }
8651 return this;
8652 }
8653 if (unknownFields == null) {
8654 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
8655 }
csharptestd2af9e92011-06-03 21:35:02 -05008656 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01008657 break;
8658 }
8659 case 10: {
8660 global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -05008661 if (result.hasOptionalMessage) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008662 subBuilder.MergeFrom(OptionalMessage);
8663 }
8664 input.ReadMessage(subBuilder, extensionRegistry);
8665 OptionalMessage = subBuilder.BuildPartial();
8666 break;
8667 }
8668 case 18: {
csharptestd2af9e92011-06-03 21:35:02 -05008669 input.ReadMessageArray(tag, field_name, result.repeatedMessage_, global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance, extensionRegistry);
Jon Skeet82bb0f12011-04-03 20:17:12 +01008670 break;
8671 }
8672 case 24: {
csharptest920b09a2011-06-08 20:13:29 -05008673 result.hasDummy = input.ReadInt32(ref result.dummy_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01008674 break;
8675 }
8676 }
8677 }
csharptest123e5342011-06-03 14:15:21 -05008678
8679 if (unknownFields != null) {
8680 this.UnknownFields = unknownFields.Build();
8681 }
8682 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01008683 }
8684
8685
8686 public bool HasOptionalMessage {
csharptestc671a4b2011-06-08 11:51:24 -05008687 get { return result.hasOptionalMessage; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008688 }
8689 public global::Google.ProtocolBuffers.TestProtos.TestRequired OptionalMessage {
8690 get { return result.OptionalMessage; }
8691 set { SetOptionalMessage(value); }
8692 }
8693 public Builder SetOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) {
8694 pb::ThrowHelper.ThrowIfNull(value, "value");
8695 result.hasOptionalMessage = true;
8696 result.optionalMessage_ = value;
8697 return this;
8698 }
8699 public Builder SetOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) {
8700 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
8701 result.hasOptionalMessage = true;
8702 result.optionalMessage_ = builderForValue.Build();
8703 return this;
8704 }
8705 public Builder MergeOptionalMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) {
8706 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -05008707 if (result.hasOptionalMessage &&
Jon Skeet82bb0f12011-04-03 20:17:12 +01008708 result.optionalMessage_ != global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance) {
8709 result.optionalMessage_ = global::Google.ProtocolBuffers.TestProtos.TestRequired.CreateBuilder(result.optionalMessage_).MergeFrom(value).BuildPartial();
8710 } else {
8711 result.optionalMessage_ = value;
8712 }
8713 result.hasOptionalMessage = true;
8714 return this;
8715 }
8716 public Builder ClearOptionalMessage() {
8717 result.hasOptionalMessage = false;
8718 result.optionalMessage_ = global::Google.ProtocolBuffers.TestProtos.TestRequired.DefaultInstance;
8719 return this;
8720 }
8721
8722 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.TestRequired> RepeatedMessageList {
8723 get { return result.repeatedMessage_; }
8724 }
8725 public int RepeatedMessageCount {
8726 get { return result.RepeatedMessageCount; }
8727 }
8728 public global::Google.ProtocolBuffers.TestProtos.TestRequired GetRepeatedMessage(int index) {
8729 return result.GetRepeatedMessage(index);
8730 }
8731 public Builder SetRepeatedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestRequired value) {
8732 pb::ThrowHelper.ThrowIfNull(value, "value");
8733 result.repeatedMessage_[index] = value;
8734 return this;
8735 }
8736 public Builder SetRepeatedMessage(int index, global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) {
8737 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
8738 result.repeatedMessage_[index] = builderForValue.Build();
8739 return this;
8740 }
8741 public Builder AddRepeatedMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired value) {
8742 pb::ThrowHelper.ThrowIfNull(value, "value");
8743 result.repeatedMessage_.Add(value);
8744 return this;
8745 }
8746 public Builder AddRepeatedMessage(global::Google.ProtocolBuffers.TestProtos.TestRequired.Builder builderForValue) {
8747 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
8748 result.repeatedMessage_.Add(builderForValue.Build());
8749 return this;
8750 }
8751 public Builder AddRangeRepeatedMessage(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.TestRequired> values) {
8752 base.AddRange(values, result.repeatedMessage_);
8753 return this;
8754 }
8755 public Builder ClearRepeatedMessage() {
8756 result.repeatedMessage_.Clear();
8757 return this;
8758 }
8759
8760 public bool HasDummy {
csharptestc671a4b2011-06-08 11:51:24 -05008761 get { return result.hasDummy; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008762 }
8763 public int Dummy {
8764 get { return result.Dummy; }
8765 set { SetDummy(value); }
8766 }
8767 public Builder SetDummy(int value) {
8768 result.hasDummy = true;
8769 result.dummy_ = value;
8770 return this;
8771 }
8772 public Builder ClearDummy() {
8773 result.hasDummy = false;
8774 result.dummy_ = 0;
8775 return this;
8776 }
8777 }
8778 static TestRequiredForeign() {
8779 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
8780 }
8781 }
8782
csharptest445bdce2011-05-20 15:50:54 -05008783 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
8784 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
8785 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01008786 public sealed partial class TestForeignNested : pb::GeneratedMessage<TestForeignNested, TestForeignNested.Builder> {
8787 private static readonly TestForeignNested defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05008788 private static readonly string[] _testForeignNestedFieldNames = new string[] { "foreign_nested" };
8789 private static readonly uint[] _testForeignNestedFieldTags = new uint[] { 10 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01008790 public static TestForeignNested DefaultInstance {
8791 get { return defaultInstance; }
8792 }
8793
8794 public override TestForeignNested DefaultInstanceForType {
8795 get { return defaultInstance; }
8796 }
8797
8798 protected override TestForeignNested ThisMessage {
8799 get { return this; }
8800 }
8801
8802 public static pbd::MessageDescriptor Descriptor {
8803 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestForeignNested__Descriptor; }
8804 }
8805
8806 protected override pb::FieldAccess.FieldAccessorTable<TestForeignNested, TestForeignNested.Builder> InternalFieldAccessors {
8807 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestForeignNested__FieldAccessorTable; }
8808 }
8809
8810 public const int ForeignNestedFieldNumber = 1;
8811 private bool hasForeignNested;
8812 private global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage foreignNested_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance;
8813 public bool HasForeignNested {
8814 get { return hasForeignNested; }
8815 }
8816 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage ForeignNested {
8817 get { return foreignNested_; }
8818 }
8819
8820 public override bool IsInitialized {
8821 get {
8822 return true;
8823 }
8824 }
8825
csharptestffafdaa2011-06-03 12:58:14 -05008826 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008827 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05008828 string[] field_names = _testForeignNestedFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05008829 if (hasForeignNested) {
csharptest920b09a2011-06-08 20:13:29 -05008830 output.WriteMessage(1, field_names[0], ForeignNested);
Jon Skeet82bb0f12011-04-03 20:17:12 +01008831 }
8832 UnknownFields.WriteTo(output);
8833 }
8834
8835 private int memoizedSerializedSize = -1;
8836 public override int SerializedSize {
8837 get {
8838 int size = memoizedSerializedSize;
8839 if (size != -1) return size;
8840
8841 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05008842 if (hasForeignNested) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008843 size += pb::CodedOutputStream.ComputeMessageSize(1, ForeignNested);
8844 }
8845 size += UnknownFields.SerializedSize;
8846 memoizedSerializedSize = size;
8847 return size;
8848 }
8849 }
8850
8851 public static TestForeignNested ParseFrom(pb::ByteString data) {
8852 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
8853 }
8854 public static TestForeignNested ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
8855 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
8856 }
8857 public static TestForeignNested ParseFrom(byte[] data) {
8858 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
8859 }
8860 public static TestForeignNested ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
8861 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
8862 }
8863 public static TestForeignNested ParseFrom(global::System.IO.Stream input) {
8864 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
8865 }
8866 public static TestForeignNested ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
8867 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
8868 }
8869 public static TestForeignNested ParseDelimitedFrom(global::System.IO.Stream input) {
8870 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
8871 }
8872 public static TestForeignNested ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
8873 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
8874 }
csharptest17699c22011-06-03 21:57:15 -05008875 public static TestForeignNested ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008876 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
8877 }
csharptest17699c22011-06-03 21:57:15 -05008878 public static TestForeignNested ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008879 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
8880 }
8881 public static Builder CreateBuilder() { return new Builder(); }
8882 public override Builder ToBuilder() { return CreateBuilder(this); }
8883 public override Builder CreateBuilderForType() { return new Builder(); }
8884 public static Builder CreateBuilder(TestForeignNested prototype) {
8885 return (Builder) new Builder().MergeFrom(prototype);
8886 }
8887
csharptest445bdce2011-05-20 15:50:54 -05008888 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
8889 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
8890 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01008891 public sealed partial class Builder : pb::GeneratedBuilder<TestForeignNested, Builder> {
8892 protected override Builder ThisBuilder {
8893 get { return this; }
8894 }
8895 public Builder() {}
8896
8897 TestForeignNested result = new TestForeignNested();
8898
8899 protected override TestForeignNested MessageBeingBuilt {
8900 get { return result; }
8901 }
8902
8903 public override Builder Clear() {
8904 result = new TestForeignNested();
8905 return this;
8906 }
8907
8908 public override Builder Clone() {
8909 return new Builder().MergeFrom(result);
8910 }
8911
8912 public override pbd::MessageDescriptor DescriptorForType {
8913 get { return global::Google.ProtocolBuffers.TestProtos.TestForeignNested.Descriptor; }
8914 }
8915
8916 public override TestForeignNested DefaultInstanceForType {
8917 get { return global::Google.ProtocolBuffers.TestProtos.TestForeignNested.DefaultInstance; }
8918 }
8919
8920 public override TestForeignNested BuildPartial() {
8921 if (result == null) {
8922 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
8923 }
8924 TestForeignNested returnMe = result;
8925 result = null;
8926 return returnMe;
8927 }
8928
8929 public override Builder MergeFrom(pb::IMessage other) {
8930 if (other is TestForeignNested) {
8931 return MergeFrom((TestForeignNested) other);
8932 } else {
8933 base.MergeFrom(other);
8934 return this;
8935 }
8936 }
8937
8938 public override Builder MergeFrom(TestForeignNested other) {
8939 if (other == global::Google.ProtocolBuffers.TestProtos.TestForeignNested.DefaultInstance) return this;
8940 if (other.HasForeignNested) {
8941 MergeForeignNested(other.ForeignNested);
8942 }
8943 this.MergeUnknownFields(other.UnknownFields);
8944 return this;
8945 }
8946
csharptest17699c22011-06-03 21:57:15 -05008947 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008948 return MergeFrom(input, pb::ExtensionRegistry.Empty);
8949 }
8950
csharptest17699c22011-06-03 21:57:15 -05008951 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008952 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05008953 uint tag;
8954 string field_name;
8955 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05008956 if(tag == 0 && field_name != null) {
8957 int field_ordinal = global::System.Array.BinarySearch(_testForeignNestedFieldNames, field_name, global::System.StringComparer.Ordinal);
8958 if(field_ordinal >= 0)
8959 tag = _testForeignNestedFieldTags[field_ordinal];
8960 else {
8961 if (unknownFields == null) {
8962 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
8963 }
8964 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
8965 continue;
8966 }
8967 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01008968 switch (tag) {
8969 case 0: {
csharptest99284412011-06-03 14:51:06 -05008970 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01008971 }
8972 default: {
8973 if (pb::WireFormat.IsEndGroupTag(tag)) {
8974 if (unknownFields != null) {
8975 this.UnknownFields = unknownFields.Build();
8976 }
8977 return this;
8978 }
8979 if (unknownFields == null) {
8980 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
8981 }
csharptestd2af9e92011-06-03 21:35:02 -05008982 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01008983 break;
8984 }
8985 case 10: {
8986 global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -05008987 if (result.hasForeignNested) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01008988 subBuilder.MergeFrom(ForeignNested);
8989 }
8990 input.ReadMessage(subBuilder, extensionRegistry);
8991 ForeignNested = subBuilder.BuildPartial();
8992 break;
8993 }
8994 }
8995 }
csharptest123e5342011-06-03 14:15:21 -05008996
8997 if (unknownFields != null) {
8998 this.UnknownFields = unknownFields.Build();
8999 }
9000 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009001 }
9002
9003
9004 public bool HasForeignNested {
csharptestc671a4b2011-06-08 11:51:24 -05009005 get { return result.hasForeignNested; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01009006 }
9007 public global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage ForeignNested {
9008 get { return result.ForeignNested; }
9009 set { SetForeignNested(value); }
9010 }
9011 public Builder SetForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) {
9012 pb::ThrowHelper.ThrowIfNull(value, "value");
9013 result.hasForeignNested = true;
9014 result.foreignNested_ = value;
9015 return this;
9016 }
9017 public Builder SetForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.Builder builderForValue) {
9018 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
9019 result.hasForeignNested = true;
9020 result.foreignNested_ = builderForValue.Build();
9021 return this;
9022 }
9023 public Builder MergeForeignNested(global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage value) {
9024 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -05009025 if (result.hasForeignNested &&
Jon Skeet82bb0f12011-04-03 20:17:12 +01009026 result.foreignNested_ != global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance) {
9027 result.foreignNested_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.CreateBuilder(result.foreignNested_).MergeFrom(value).BuildPartial();
9028 } else {
9029 result.foreignNested_ = value;
9030 }
9031 result.hasForeignNested = true;
9032 return this;
9033 }
9034 public Builder ClearForeignNested() {
9035 result.hasForeignNested = false;
9036 result.foreignNested_ = global::Google.ProtocolBuffers.TestProtos.TestAllTypes.Types.NestedMessage.DefaultInstance;
9037 return this;
9038 }
9039 }
9040 static TestForeignNested() {
9041 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
9042 }
9043 }
9044
csharptest445bdce2011-05-20 15:50:54 -05009045 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
9046 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
9047 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01009048 public sealed partial class TestEmptyMessage : pb::GeneratedMessage<TestEmptyMessage, TestEmptyMessage.Builder> {
9049 private static readonly TestEmptyMessage defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05009050 private static readonly string[] _testEmptyMessageFieldNames = new string[] { };
9051 private static readonly uint[] _testEmptyMessageFieldTags = new uint[] { };
Jon Skeet82bb0f12011-04-03 20:17:12 +01009052 public static TestEmptyMessage DefaultInstance {
9053 get { return defaultInstance; }
9054 }
9055
9056 public override TestEmptyMessage DefaultInstanceForType {
9057 get { return defaultInstance; }
9058 }
9059
9060 protected override TestEmptyMessage ThisMessage {
9061 get { return this; }
9062 }
9063
9064 public static pbd::MessageDescriptor Descriptor {
9065 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestEmptyMessage__Descriptor; }
9066 }
9067
9068 protected override pb::FieldAccess.FieldAccessorTable<TestEmptyMessage, TestEmptyMessage.Builder> InternalFieldAccessors {
9069 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestEmptyMessage__FieldAccessorTable; }
9070 }
9071
9072 public override bool IsInitialized {
9073 get {
9074 return true;
9075 }
9076 }
9077
csharptestffafdaa2011-06-03 12:58:14 -05009078 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009079 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05009080 string[] field_names = _testEmptyMessageFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009081 UnknownFields.WriteTo(output);
9082 }
9083
9084 private int memoizedSerializedSize = -1;
9085 public override int SerializedSize {
9086 get {
9087 int size = memoizedSerializedSize;
9088 if (size != -1) return size;
9089
9090 size = 0;
9091 size += UnknownFields.SerializedSize;
9092 memoizedSerializedSize = size;
9093 return size;
9094 }
9095 }
9096
9097 public static TestEmptyMessage ParseFrom(pb::ByteString data) {
9098 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
9099 }
9100 public static TestEmptyMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
9101 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
9102 }
9103 public static TestEmptyMessage ParseFrom(byte[] data) {
9104 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
9105 }
9106 public static TestEmptyMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
9107 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
9108 }
9109 public static TestEmptyMessage ParseFrom(global::System.IO.Stream input) {
9110 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
9111 }
9112 public static TestEmptyMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
9113 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
9114 }
9115 public static TestEmptyMessage ParseDelimitedFrom(global::System.IO.Stream input) {
9116 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
9117 }
9118 public static TestEmptyMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
9119 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
9120 }
csharptest17699c22011-06-03 21:57:15 -05009121 public static TestEmptyMessage ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009122 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
9123 }
csharptest17699c22011-06-03 21:57:15 -05009124 public static TestEmptyMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009125 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
9126 }
9127 public static Builder CreateBuilder() { return new Builder(); }
9128 public override Builder ToBuilder() { return CreateBuilder(this); }
9129 public override Builder CreateBuilderForType() { return new Builder(); }
9130 public static Builder CreateBuilder(TestEmptyMessage prototype) {
9131 return (Builder) new Builder().MergeFrom(prototype);
9132 }
9133
csharptest445bdce2011-05-20 15:50:54 -05009134 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
9135 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
9136 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01009137 public sealed partial class Builder : pb::GeneratedBuilder<TestEmptyMessage, Builder> {
9138 protected override Builder ThisBuilder {
9139 get { return this; }
9140 }
9141 public Builder() {}
9142
9143 TestEmptyMessage result = new TestEmptyMessage();
9144
9145 protected override TestEmptyMessage MessageBeingBuilt {
9146 get { return result; }
9147 }
9148
9149 public override Builder Clear() {
9150 result = new TestEmptyMessage();
9151 return this;
9152 }
9153
9154 public override Builder Clone() {
9155 return new Builder().MergeFrom(result);
9156 }
9157
9158 public override pbd::MessageDescriptor DescriptorForType {
9159 get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.Descriptor; }
9160 }
9161
9162 public override TestEmptyMessage DefaultInstanceForType {
9163 get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.DefaultInstance; }
9164 }
9165
9166 public override TestEmptyMessage BuildPartial() {
9167 if (result == null) {
9168 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
9169 }
9170 TestEmptyMessage returnMe = result;
9171 result = null;
9172 return returnMe;
9173 }
9174
9175 public override Builder MergeFrom(pb::IMessage other) {
9176 if (other is TestEmptyMessage) {
9177 return MergeFrom((TestEmptyMessage) other);
9178 } else {
9179 base.MergeFrom(other);
9180 return this;
9181 }
9182 }
9183
9184 public override Builder MergeFrom(TestEmptyMessage other) {
9185 if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessage.DefaultInstance) return this;
9186 this.MergeUnknownFields(other.UnknownFields);
9187 return this;
9188 }
9189
csharptest17699c22011-06-03 21:57:15 -05009190 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009191 return MergeFrom(input, pb::ExtensionRegistry.Empty);
9192 }
9193
csharptest17699c22011-06-03 21:57:15 -05009194 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009195 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05009196 uint tag;
9197 string field_name;
9198 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05009199 if(tag == 0 && field_name != null) {
9200 int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageFieldNames, field_name, global::System.StringComparer.Ordinal);
9201 if(field_ordinal >= 0)
9202 tag = _testEmptyMessageFieldTags[field_ordinal];
9203 else {
9204 if (unknownFields == null) {
9205 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
9206 }
9207 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
9208 continue;
9209 }
9210 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01009211 switch (tag) {
9212 case 0: {
csharptest99284412011-06-03 14:51:06 -05009213 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01009214 }
9215 default: {
9216 if (pb::WireFormat.IsEndGroupTag(tag)) {
9217 if (unknownFields != null) {
9218 this.UnknownFields = unknownFields.Build();
9219 }
9220 return this;
9221 }
9222 if (unknownFields == null) {
9223 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
9224 }
csharptestd2af9e92011-06-03 21:35:02 -05009225 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01009226 break;
9227 }
9228 }
9229 }
csharptest123e5342011-06-03 14:15:21 -05009230
9231 if (unknownFields != null) {
9232 this.UnknownFields = unknownFields.Build();
9233 }
9234 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009235 }
9236
9237 }
9238 static TestEmptyMessage() {
9239 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
9240 }
9241 }
9242
csharptest445bdce2011-05-20 15:50:54 -05009243 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
9244 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
9245 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01009246 public sealed partial class TestEmptyMessageWithExtensions : pb::ExtendableMessage<TestEmptyMessageWithExtensions, TestEmptyMessageWithExtensions.Builder> {
9247 private static readonly TestEmptyMessageWithExtensions defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05009248 private static readonly string[] _testEmptyMessageWithExtensionsFieldNames = new string[] { };
9249 private static readonly uint[] _testEmptyMessageWithExtensionsFieldTags = new uint[] { };
Jon Skeet82bb0f12011-04-03 20:17:12 +01009250 public static TestEmptyMessageWithExtensions DefaultInstance {
9251 get { return defaultInstance; }
9252 }
9253
9254 public override TestEmptyMessageWithExtensions DefaultInstanceForType {
9255 get { return defaultInstance; }
9256 }
9257
9258 protected override TestEmptyMessageWithExtensions ThisMessage {
9259 get { return this; }
9260 }
9261
9262 public static pbd::MessageDescriptor Descriptor {
9263 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__Descriptor; }
9264 }
9265
9266 protected override pb::FieldAccess.FieldAccessorTable<TestEmptyMessageWithExtensions, TestEmptyMessageWithExtensions.Builder> InternalFieldAccessors {
9267 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestEmptyMessageWithExtensions__FieldAccessorTable; }
9268 }
9269
9270 public override bool IsInitialized {
9271 get {
9272 if (!ExtensionsAreInitialized) return false;
9273 return true;
9274 }
9275 }
9276
csharptestffafdaa2011-06-03 12:58:14 -05009277 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009278 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05009279 string[] field_names = _testEmptyMessageWithExtensionsFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009280 pb::ExtendableMessage<TestEmptyMessageWithExtensions, TestEmptyMessageWithExtensions.Builder>.ExtensionWriter extensionWriter = CreateExtensionWriter(this);
9281 extensionWriter.WriteUntil(536870912, output);
9282 UnknownFields.WriteTo(output);
9283 }
9284
9285 private int memoizedSerializedSize = -1;
9286 public override int SerializedSize {
9287 get {
9288 int size = memoizedSerializedSize;
9289 if (size != -1) return size;
9290
9291 size = 0;
9292 size += ExtensionsSerializedSize;
9293 size += UnknownFields.SerializedSize;
9294 memoizedSerializedSize = size;
9295 return size;
9296 }
9297 }
9298
9299 public static TestEmptyMessageWithExtensions ParseFrom(pb::ByteString data) {
9300 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
9301 }
9302 public static TestEmptyMessageWithExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
9303 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
9304 }
9305 public static TestEmptyMessageWithExtensions ParseFrom(byte[] data) {
9306 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
9307 }
9308 public static TestEmptyMessageWithExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
9309 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
9310 }
9311 public static TestEmptyMessageWithExtensions ParseFrom(global::System.IO.Stream input) {
9312 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
9313 }
9314 public static TestEmptyMessageWithExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
9315 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
9316 }
9317 public static TestEmptyMessageWithExtensions ParseDelimitedFrom(global::System.IO.Stream input) {
9318 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
9319 }
9320 public static TestEmptyMessageWithExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
9321 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
9322 }
csharptest17699c22011-06-03 21:57:15 -05009323 public static TestEmptyMessageWithExtensions ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009324 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
9325 }
csharptest17699c22011-06-03 21:57:15 -05009326 public static TestEmptyMessageWithExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009327 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
9328 }
9329 public static Builder CreateBuilder() { return new Builder(); }
9330 public override Builder ToBuilder() { return CreateBuilder(this); }
9331 public override Builder CreateBuilderForType() { return new Builder(); }
9332 public static Builder CreateBuilder(TestEmptyMessageWithExtensions prototype) {
9333 return (Builder) new Builder().MergeFrom(prototype);
9334 }
9335
csharptest445bdce2011-05-20 15:50:54 -05009336 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
9337 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
9338 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01009339 public sealed partial class Builder : pb::ExtendableBuilder<TestEmptyMessageWithExtensions, Builder> {
9340 protected override Builder ThisBuilder {
9341 get { return this; }
9342 }
9343 public Builder() {}
9344
9345 TestEmptyMessageWithExtensions result = new TestEmptyMessageWithExtensions();
9346
9347 protected override TestEmptyMessageWithExtensions MessageBeingBuilt {
9348 get { return result; }
9349 }
9350
9351 public override Builder Clear() {
9352 result = new TestEmptyMessageWithExtensions();
9353 return this;
9354 }
9355
9356 public override Builder Clone() {
9357 return new Builder().MergeFrom(result);
9358 }
9359
9360 public override pbd::MessageDescriptor DescriptorForType {
9361 get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.Descriptor; }
9362 }
9363
9364 public override TestEmptyMessageWithExtensions DefaultInstanceForType {
9365 get { return global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.DefaultInstance; }
9366 }
9367
9368 public override TestEmptyMessageWithExtensions BuildPartial() {
9369 if (result == null) {
9370 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
9371 }
9372 TestEmptyMessageWithExtensions returnMe = result;
9373 result = null;
9374 return returnMe;
9375 }
9376
9377 public override Builder MergeFrom(pb::IMessage other) {
9378 if (other is TestEmptyMessageWithExtensions) {
9379 return MergeFrom((TestEmptyMessageWithExtensions) other);
9380 } else {
9381 base.MergeFrom(other);
9382 return this;
9383 }
9384 }
9385
9386 public override Builder MergeFrom(TestEmptyMessageWithExtensions other) {
9387 if (other == global::Google.ProtocolBuffers.TestProtos.TestEmptyMessageWithExtensions.DefaultInstance) return this;
9388 this.MergeExtensionFields(other);
9389 this.MergeUnknownFields(other.UnknownFields);
9390 return this;
9391 }
9392
csharptest17699c22011-06-03 21:57:15 -05009393 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009394 return MergeFrom(input, pb::ExtensionRegistry.Empty);
9395 }
9396
csharptest17699c22011-06-03 21:57:15 -05009397 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009398 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05009399 uint tag;
9400 string field_name;
9401 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05009402 if(tag == 0 && field_name != null) {
9403 int field_ordinal = global::System.Array.BinarySearch(_testEmptyMessageWithExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal);
9404 if(field_ordinal >= 0)
9405 tag = _testEmptyMessageWithExtensionsFieldTags[field_ordinal];
9406 else {
9407 if (unknownFields == null) {
9408 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
9409 }
9410 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
9411 continue;
9412 }
9413 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01009414 switch (tag) {
9415 case 0: {
csharptest99284412011-06-03 14:51:06 -05009416 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01009417 }
9418 default: {
9419 if (pb::WireFormat.IsEndGroupTag(tag)) {
9420 if (unknownFields != null) {
9421 this.UnknownFields = unknownFields.Build();
9422 }
9423 return this;
9424 }
9425 if (unknownFields == null) {
9426 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
9427 }
csharptestd2af9e92011-06-03 21:35:02 -05009428 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01009429 break;
9430 }
9431 }
9432 }
csharptest123e5342011-06-03 14:15:21 -05009433
9434 if (unknownFields != null) {
9435 this.UnknownFields = unknownFields.Build();
9436 }
9437 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009438 }
9439
9440 }
9441 static TestEmptyMessageWithExtensions() {
9442 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
9443 }
9444 }
9445
csharptest445bdce2011-05-20 15:50:54 -05009446 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
9447 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
9448 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01009449 public sealed partial class TestMultipleExtensionRanges : pb::ExtendableMessage<TestMultipleExtensionRanges, TestMultipleExtensionRanges.Builder> {
9450 private static readonly TestMultipleExtensionRanges defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05009451 private static readonly string[] _testMultipleExtensionRangesFieldNames = new string[] { };
9452 private static readonly uint[] _testMultipleExtensionRangesFieldTags = new uint[] { };
Jon Skeet82bb0f12011-04-03 20:17:12 +01009453 public static TestMultipleExtensionRanges DefaultInstance {
9454 get { return defaultInstance; }
9455 }
9456
9457 public override TestMultipleExtensionRanges DefaultInstanceForType {
9458 get { return defaultInstance; }
9459 }
9460
9461 protected override TestMultipleExtensionRanges ThisMessage {
9462 get { return this; }
9463 }
9464
9465 public static pbd::MessageDescriptor Descriptor {
9466 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMultipleExtensionRanges__Descriptor; }
9467 }
9468
9469 protected override pb::FieldAccess.FieldAccessorTable<TestMultipleExtensionRanges, TestMultipleExtensionRanges.Builder> InternalFieldAccessors {
9470 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMultipleExtensionRanges__FieldAccessorTable; }
9471 }
9472
9473 public override bool IsInitialized {
9474 get {
9475 if (!ExtensionsAreInitialized) return false;
9476 return true;
9477 }
9478 }
9479
csharptestffafdaa2011-06-03 12:58:14 -05009480 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009481 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05009482 string[] field_names = _testMultipleExtensionRangesFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009483 pb::ExtendableMessage<TestMultipleExtensionRanges, TestMultipleExtensionRanges.Builder>.ExtensionWriter extensionWriter = CreateExtensionWriter(this);
9484 extensionWriter.WriteUntil(43, output);
9485 extensionWriter.WriteUntil(4244, output);
9486 extensionWriter.WriteUntil(536870912, output);
9487 UnknownFields.WriteTo(output);
9488 }
9489
9490 private int memoizedSerializedSize = -1;
9491 public override int SerializedSize {
9492 get {
9493 int size = memoizedSerializedSize;
9494 if (size != -1) return size;
9495
9496 size = 0;
9497 size += ExtensionsSerializedSize;
9498 size += UnknownFields.SerializedSize;
9499 memoizedSerializedSize = size;
9500 return size;
9501 }
9502 }
9503
9504 public static TestMultipleExtensionRanges ParseFrom(pb::ByteString data) {
9505 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
9506 }
9507 public static TestMultipleExtensionRanges ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
9508 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
9509 }
9510 public static TestMultipleExtensionRanges ParseFrom(byte[] data) {
9511 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
9512 }
9513 public static TestMultipleExtensionRanges ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
9514 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
9515 }
9516 public static TestMultipleExtensionRanges ParseFrom(global::System.IO.Stream input) {
9517 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
9518 }
9519 public static TestMultipleExtensionRanges ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
9520 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
9521 }
9522 public static TestMultipleExtensionRanges ParseDelimitedFrom(global::System.IO.Stream input) {
9523 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
9524 }
9525 public static TestMultipleExtensionRanges ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
9526 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
9527 }
csharptest17699c22011-06-03 21:57:15 -05009528 public static TestMultipleExtensionRanges ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009529 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
9530 }
csharptest17699c22011-06-03 21:57:15 -05009531 public static TestMultipleExtensionRanges ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009532 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
9533 }
9534 public static Builder CreateBuilder() { return new Builder(); }
9535 public override Builder ToBuilder() { return CreateBuilder(this); }
9536 public override Builder CreateBuilderForType() { return new Builder(); }
9537 public static Builder CreateBuilder(TestMultipleExtensionRanges prototype) {
9538 return (Builder) new Builder().MergeFrom(prototype);
9539 }
9540
csharptest445bdce2011-05-20 15:50:54 -05009541 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
9542 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
9543 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01009544 public sealed partial class Builder : pb::ExtendableBuilder<TestMultipleExtensionRanges, Builder> {
9545 protected override Builder ThisBuilder {
9546 get { return this; }
9547 }
9548 public Builder() {}
9549
9550 TestMultipleExtensionRanges result = new TestMultipleExtensionRanges();
9551
9552 protected override TestMultipleExtensionRanges MessageBeingBuilt {
9553 get { return result; }
9554 }
9555
9556 public override Builder Clear() {
9557 result = new TestMultipleExtensionRanges();
9558 return this;
9559 }
9560
9561 public override Builder Clone() {
9562 return new Builder().MergeFrom(result);
9563 }
9564
9565 public override pbd::MessageDescriptor DescriptorForType {
9566 get { return global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.Descriptor; }
9567 }
9568
9569 public override TestMultipleExtensionRanges DefaultInstanceForType {
9570 get { return global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.DefaultInstance; }
9571 }
9572
9573 public override TestMultipleExtensionRanges BuildPartial() {
9574 if (result == null) {
9575 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
9576 }
9577 TestMultipleExtensionRanges returnMe = result;
9578 result = null;
9579 return returnMe;
9580 }
9581
9582 public override Builder MergeFrom(pb::IMessage other) {
9583 if (other is TestMultipleExtensionRanges) {
9584 return MergeFrom((TestMultipleExtensionRanges) other);
9585 } else {
9586 base.MergeFrom(other);
9587 return this;
9588 }
9589 }
9590
9591 public override Builder MergeFrom(TestMultipleExtensionRanges other) {
9592 if (other == global::Google.ProtocolBuffers.TestProtos.TestMultipleExtensionRanges.DefaultInstance) return this;
9593 this.MergeExtensionFields(other);
9594 this.MergeUnknownFields(other.UnknownFields);
9595 return this;
9596 }
9597
csharptest17699c22011-06-03 21:57:15 -05009598 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009599 return MergeFrom(input, pb::ExtensionRegistry.Empty);
9600 }
9601
csharptest17699c22011-06-03 21:57:15 -05009602 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009603 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05009604 uint tag;
9605 string field_name;
9606 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05009607 if(tag == 0 && field_name != null) {
9608 int field_ordinal = global::System.Array.BinarySearch(_testMultipleExtensionRangesFieldNames, field_name, global::System.StringComparer.Ordinal);
9609 if(field_ordinal >= 0)
9610 tag = _testMultipleExtensionRangesFieldTags[field_ordinal];
9611 else {
9612 if (unknownFields == null) {
9613 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
9614 }
9615 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
9616 continue;
9617 }
9618 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01009619 switch (tag) {
9620 case 0: {
csharptest99284412011-06-03 14:51:06 -05009621 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01009622 }
9623 default: {
9624 if (pb::WireFormat.IsEndGroupTag(tag)) {
9625 if (unknownFields != null) {
9626 this.UnknownFields = unknownFields.Build();
9627 }
9628 return this;
9629 }
9630 if (unknownFields == null) {
9631 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
9632 }
csharptestd2af9e92011-06-03 21:35:02 -05009633 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01009634 break;
9635 }
9636 }
9637 }
csharptest123e5342011-06-03 14:15:21 -05009638
9639 if (unknownFields != null) {
9640 this.UnknownFields = unknownFields.Build();
9641 }
9642 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009643 }
9644
9645 }
9646 static TestMultipleExtensionRanges() {
9647 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
9648 }
9649 }
9650
csharptest445bdce2011-05-20 15:50:54 -05009651 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
9652 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
9653 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01009654 public sealed partial class TestReallyLargeTagNumber : pb::GeneratedMessage<TestReallyLargeTagNumber, TestReallyLargeTagNumber.Builder> {
9655 private static readonly TestReallyLargeTagNumber defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05009656 private static readonly string[] _testReallyLargeTagNumberFieldNames = new string[] { "a", "bb" };
9657 private static readonly uint[] _testReallyLargeTagNumberFieldTags = new uint[] { 8, 2147483640 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01009658 public static TestReallyLargeTagNumber DefaultInstance {
9659 get { return defaultInstance; }
9660 }
9661
9662 public override TestReallyLargeTagNumber DefaultInstanceForType {
9663 get { return defaultInstance; }
9664 }
9665
9666 protected override TestReallyLargeTagNumber ThisMessage {
9667 get { return this; }
9668 }
9669
9670 public static pbd::MessageDescriptor Descriptor {
9671 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestReallyLargeTagNumber__Descriptor; }
9672 }
9673
9674 protected override pb::FieldAccess.FieldAccessorTable<TestReallyLargeTagNumber, TestReallyLargeTagNumber.Builder> InternalFieldAccessors {
9675 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestReallyLargeTagNumber__FieldAccessorTable; }
9676 }
9677
9678 public const int AFieldNumber = 1;
9679 private bool hasA;
csharptestced18e12011-06-09 19:47:56 -05009680 private int a_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009681 public bool HasA {
9682 get { return hasA; }
9683 }
9684 public int A {
9685 get { return a_; }
9686 }
9687
9688 public const int BbFieldNumber = 268435455;
9689 private bool hasBb;
csharptestced18e12011-06-09 19:47:56 -05009690 private int bb_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009691 public bool HasBb {
9692 get { return hasBb; }
9693 }
9694 public int Bb {
9695 get { return bb_; }
9696 }
9697
9698 public override bool IsInitialized {
9699 get {
9700 return true;
9701 }
9702 }
9703
csharptestffafdaa2011-06-03 12:58:14 -05009704 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009705 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05009706 string[] field_names = _testReallyLargeTagNumberFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05009707 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -05009708 output.WriteInt32(1, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +01009709 }
csharptestc671a4b2011-06-08 11:51:24 -05009710 if (hasBb) {
csharptest920b09a2011-06-08 20:13:29 -05009711 output.WriteInt32(268435455, field_names[1], Bb);
Jon Skeet82bb0f12011-04-03 20:17:12 +01009712 }
9713 UnknownFields.WriteTo(output);
9714 }
9715
9716 private int memoizedSerializedSize = -1;
9717 public override int SerializedSize {
9718 get {
9719 int size = memoizedSerializedSize;
9720 if (size != -1) return size;
9721
9722 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -05009723 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009724 size += pb::CodedOutputStream.ComputeInt32Size(1, A);
9725 }
csharptestc671a4b2011-06-08 11:51:24 -05009726 if (hasBb) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009727 size += pb::CodedOutputStream.ComputeInt32Size(268435455, Bb);
9728 }
9729 size += UnknownFields.SerializedSize;
9730 memoizedSerializedSize = size;
9731 return size;
9732 }
9733 }
9734
9735 public static TestReallyLargeTagNumber ParseFrom(pb::ByteString data) {
9736 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
9737 }
9738 public static TestReallyLargeTagNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
9739 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
9740 }
9741 public static TestReallyLargeTagNumber ParseFrom(byte[] data) {
9742 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
9743 }
9744 public static TestReallyLargeTagNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
9745 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
9746 }
9747 public static TestReallyLargeTagNumber ParseFrom(global::System.IO.Stream input) {
9748 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
9749 }
9750 public static TestReallyLargeTagNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
9751 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
9752 }
9753 public static TestReallyLargeTagNumber ParseDelimitedFrom(global::System.IO.Stream input) {
9754 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
9755 }
9756 public static TestReallyLargeTagNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
9757 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
9758 }
csharptest17699c22011-06-03 21:57:15 -05009759 public static TestReallyLargeTagNumber ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009760 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
9761 }
csharptest17699c22011-06-03 21:57:15 -05009762 public static TestReallyLargeTagNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009763 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
9764 }
9765 public static Builder CreateBuilder() { return new Builder(); }
9766 public override Builder ToBuilder() { return CreateBuilder(this); }
9767 public override Builder CreateBuilderForType() { return new Builder(); }
9768 public static Builder CreateBuilder(TestReallyLargeTagNumber prototype) {
9769 return (Builder) new Builder().MergeFrom(prototype);
9770 }
9771
csharptest445bdce2011-05-20 15:50:54 -05009772 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
9773 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
9774 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01009775 public sealed partial class Builder : pb::GeneratedBuilder<TestReallyLargeTagNumber, Builder> {
9776 protected override Builder ThisBuilder {
9777 get { return this; }
9778 }
9779 public Builder() {}
9780
9781 TestReallyLargeTagNumber result = new TestReallyLargeTagNumber();
9782
9783 protected override TestReallyLargeTagNumber MessageBeingBuilt {
9784 get { return result; }
9785 }
9786
9787 public override Builder Clear() {
9788 result = new TestReallyLargeTagNumber();
9789 return this;
9790 }
9791
9792 public override Builder Clone() {
9793 return new Builder().MergeFrom(result);
9794 }
9795
9796 public override pbd::MessageDescriptor DescriptorForType {
9797 get { return global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.Descriptor; }
9798 }
9799
9800 public override TestReallyLargeTagNumber DefaultInstanceForType {
9801 get { return global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.DefaultInstance; }
9802 }
9803
9804 public override TestReallyLargeTagNumber BuildPartial() {
9805 if (result == null) {
9806 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
9807 }
9808 TestReallyLargeTagNumber returnMe = result;
9809 result = null;
9810 return returnMe;
9811 }
9812
9813 public override Builder MergeFrom(pb::IMessage other) {
9814 if (other is TestReallyLargeTagNumber) {
9815 return MergeFrom((TestReallyLargeTagNumber) other);
9816 } else {
9817 base.MergeFrom(other);
9818 return this;
9819 }
9820 }
9821
9822 public override Builder MergeFrom(TestReallyLargeTagNumber other) {
9823 if (other == global::Google.ProtocolBuffers.TestProtos.TestReallyLargeTagNumber.DefaultInstance) return this;
9824 if (other.HasA) {
9825 A = other.A;
9826 }
9827 if (other.HasBb) {
9828 Bb = other.Bb;
9829 }
9830 this.MergeUnknownFields(other.UnknownFields);
9831 return this;
9832 }
9833
csharptest17699c22011-06-03 21:57:15 -05009834 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009835 return MergeFrom(input, pb::ExtensionRegistry.Empty);
9836 }
9837
csharptest17699c22011-06-03 21:57:15 -05009838 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009839 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -05009840 uint tag;
9841 string field_name;
9842 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -05009843 if(tag == 0 && field_name != null) {
9844 int field_ordinal = global::System.Array.BinarySearch(_testReallyLargeTagNumberFieldNames, field_name, global::System.StringComparer.Ordinal);
9845 if(field_ordinal >= 0)
9846 tag = _testReallyLargeTagNumberFieldTags[field_ordinal];
9847 else {
9848 if (unknownFields == null) {
9849 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
9850 }
9851 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
9852 continue;
9853 }
9854 }
Jon Skeet82bb0f12011-04-03 20:17:12 +01009855 switch (tag) {
9856 case 0: {
csharptest99284412011-06-03 14:51:06 -05009857 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +01009858 }
9859 default: {
9860 if (pb::WireFormat.IsEndGroupTag(tag)) {
9861 if (unknownFields != null) {
9862 this.UnknownFields = unknownFields.Build();
9863 }
9864 return this;
9865 }
9866 if (unknownFields == null) {
9867 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
9868 }
csharptestd2af9e92011-06-03 21:35:02 -05009869 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +01009870 break;
9871 }
9872 case 8: {
csharptest920b09a2011-06-08 20:13:29 -05009873 result.hasA = input.ReadInt32(ref result.a_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01009874 break;
9875 }
9876 case 2147483640: {
csharptest920b09a2011-06-08 20:13:29 -05009877 result.hasBb = input.ReadInt32(ref result.bb_);
Jon Skeet82bb0f12011-04-03 20:17:12 +01009878 break;
9879 }
9880 }
9881 }
csharptest123e5342011-06-03 14:15:21 -05009882
9883 if (unknownFields != null) {
9884 this.UnknownFields = unknownFields.Build();
9885 }
9886 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009887 }
9888
9889
9890 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -05009891 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01009892 }
9893 public int A {
9894 get { return result.A; }
9895 set { SetA(value); }
9896 }
9897 public Builder SetA(int value) {
9898 result.hasA = true;
9899 result.a_ = value;
9900 return this;
9901 }
9902 public Builder ClearA() {
9903 result.hasA = false;
9904 result.a_ = 0;
9905 return this;
9906 }
9907
9908 public bool HasBb {
csharptestc671a4b2011-06-08 11:51:24 -05009909 get { return result.hasBb; }
Jon Skeet82bb0f12011-04-03 20:17:12 +01009910 }
9911 public int Bb {
9912 get { return result.Bb; }
9913 set { SetBb(value); }
9914 }
9915 public Builder SetBb(int value) {
9916 result.hasBb = true;
9917 result.bb_ = value;
9918 return this;
9919 }
9920 public Builder ClearBb() {
9921 result.hasBb = false;
9922 result.bb_ = 0;
9923 return this;
9924 }
9925 }
9926 static TestReallyLargeTagNumber() {
9927 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
9928 }
9929 }
9930
csharptest445bdce2011-05-20 15:50:54 -05009931 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
9932 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
9933 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +01009934 public sealed partial class TestRecursiveMessage : pb::GeneratedMessage<TestRecursiveMessage, TestRecursiveMessage.Builder> {
9935 private static readonly TestRecursiveMessage defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -05009936 private static readonly string[] _testRecursiveMessageFieldNames = new string[] { "a", "i" };
9937 private static readonly uint[] _testRecursiveMessageFieldTags = new uint[] { 10, 16 };
Jon Skeet82bb0f12011-04-03 20:17:12 +01009938 public static TestRecursiveMessage DefaultInstance {
9939 get { return defaultInstance; }
9940 }
9941
9942 public override TestRecursiveMessage DefaultInstanceForType {
9943 get { return defaultInstance; }
9944 }
9945
9946 protected override TestRecursiveMessage ThisMessage {
9947 get { return this; }
9948 }
9949
9950 public static pbd::MessageDescriptor Descriptor {
9951 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRecursiveMessage__Descriptor; }
9952 }
9953
9954 protected override pb::FieldAccess.FieldAccessorTable<TestRecursiveMessage, TestRecursiveMessage.Builder> InternalFieldAccessors {
9955 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRecursiveMessage__FieldAccessorTable; }
9956 }
9957
9958 public const int AFieldNumber = 1;
9959 private bool hasA;
9960 private global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage a_ = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance;
9961 public bool HasA {
9962 get { return hasA; }
9963 }
9964 public global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage A {
9965 get { return a_; }
9966 }
9967
9968 public const int IFieldNumber = 2;
9969 private bool hasI;
csharptestced18e12011-06-09 19:47:56 -05009970 private int i_;
Jon Skeet82bb0f12011-04-03 20:17:12 +01009971 public bool HasI {
9972 get { return hasI; }
9973 }
9974 public int I {
9975 get { return i_; }
9976 }
9977
9978 public override bool IsInitialized {
9979 get {
9980 return true;
9981 }
9982 }
9983
csharptestffafdaa2011-06-03 12:58:14 -05009984 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +01009985 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -05009986 string[] field_names = _testRecursiveMessageFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -05009987 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -05009988 output.WriteMessage(1, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +01009989 }
csharptestc671a4b2011-06-08 11:51:24 -05009990 if (hasI) {
csharptest920b09a2011-06-08 20:13:29 -05009991 output.WriteInt32(2, field_names[1], I);
Jon Skeet82bb0f12011-04-03 20:17:12 +01009992 }
9993 UnknownFields.WriteTo(output);
9994 }
9995
9996 private int memoizedSerializedSize = -1;
9997 public override int SerializedSize {
9998 get {
9999 int size = memoizedSerializedSize;
10000 if (size != -1) return size;
10001
10002 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050010003 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010004 size += pb::CodedOutputStream.ComputeMessageSize(1, A);
10005 }
csharptestc671a4b2011-06-08 11:51:24 -050010006 if (hasI) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010007 size += pb::CodedOutputStream.ComputeInt32Size(2, I);
10008 }
10009 size += UnknownFields.SerializedSize;
10010 memoizedSerializedSize = size;
10011 return size;
10012 }
10013 }
10014
10015 public static TestRecursiveMessage ParseFrom(pb::ByteString data) {
10016 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
10017 }
10018 public static TestRecursiveMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
10019 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
10020 }
10021 public static TestRecursiveMessage ParseFrom(byte[] data) {
10022 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
10023 }
10024 public static TestRecursiveMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
10025 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
10026 }
10027 public static TestRecursiveMessage ParseFrom(global::System.IO.Stream input) {
10028 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
10029 }
10030 public static TestRecursiveMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
10031 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
10032 }
10033 public static TestRecursiveMessage ParseDelimitedFrom(global::System.IO.Stream input) {
10034 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
10035 }
10036 public static TestRecursiveMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
10037 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
10038 }
csharptest17699c22011-06-03 21:57:15 -050010039 public static TestRecursiveMessage ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010040 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
10041 }
csharptest17699c22011-06-03 21:57:15 -050010042 public static TestRecursiveMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010043 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
10044 }
10045 public static Builder CreateBuilder() { return new Builder(); }
10046 public override Builder ToBuilder() { return CreateBuilder(this); }
10047 public override Builder CreateBuilderForType() { return new Builder(); }
10048 public static Builder CreateBuilder(TestRecursiveMessage prototype) {
10049 return (Builder) new Builder().MergeFrom(prototype);
10050 }
10051
csharptest445bdce2011-05-20 15:50:54 -050010052 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
10053 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
10054 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010010055 public sealed partial class Builder : pb::GeneratedBuilder<TestRecursiveMessage, Builder> {
10056 protected override Builder ThisBuilder {
10057 get { return this; }
10058 }
10059 public Builder() {}
10060
10061 TestRecursiveMessage result = new TestRecursiveMessage();
10062
10063 protected override TestRecursiveMessage MessageBeingBuilt {
10064 get { return result; }
10065 }
10066
10067 public override Builder Clear() {
10068 result = new TestRecursiveMessage();
10069 return this;
10070 }
10071
10072 public override Builder Clone() {
10073 return new Builder().MergeFrom(result);
10074 }
10075
10076 public override pbd::MessageDescriptor DescriptorForType {
10077 get { return global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Descriptor; }
10078 }
10079
10080 public override TestRecursiveMessage DefaultInstanceForType {
10081 get { return global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance; }
10082 }
10083
10084 public override TestRecursiveMessage BuildPartial() {
10085 if (result == null) {
10086 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
10087 }
10088 TestRecursiveMessage returnMe = result;
10089 result = null;
10090 return returnMe;
10091 }
10092
10093 public override Builder MergeFrom(pb::IMessage other) {
10094 if (other is TestRecursiveMessage) {
10095 return MergeFrom((TestRecursiveMessage) other);
10096 } else {
10097 base.MergeFrom(other);
10098 return this;
10099 }
10100 }
10101
10102 public override Builder MergeFrom(TestRecursiveMessage other) {
10103 if (other == global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance) return this;
10104 if (other.HasA) {
10105 MergeA(other.A);
10106 }
10107 if (other.HasI) {
10108 I = other.I;
10109 }
10110 this.MergeUnknownFields(other.UnknownFields);
10111 return this;
10112 }
10113
csharptest17699c22011-06-03 21:57:15 -050010114 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010115 return MergeFrom(input, pb::ExtensionRegistry.Empty);
10116 }
10117
csharptest17699c22011-06-03 21:57:15 -050010118 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010119 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050010120 uint tag;
10121 string field_name;
10122 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050010123 if(tag == 0 && field_name != null) {
10124 int field_ordinal = global::System.Array.BinarySearch(_testRecursiveMessageFieldNames, field_name, global::System.StringComparer.Ordinal);
10125 if(field_ordinal >= 0)
10126 tag = _testRecursiveMessageFieldTags[field_ordinal];
10127 else {
10128 if (unknownFields == null) {
10129 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
10130 }
10131 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
10132 continue;
10133 }
10134 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010010135 switch (tag) {
10136 case 0: {
csharptest99284412011-06-03 14:51:06 -050010137 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010010138 }
10139 default: {
10140 if (pb::WireFormat.IsEndGroupTag(tag)) {
10141 if (unknownFields != null) {
10142 this.UnknownFields = unknownFields.Build();
10143 }
10144 return this;
10145 }
10146 if (unknownFields == null) {
10147 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
10148 }
csharptestd2af9e92011-06-03 21:35:02 -050010149 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010010150 break;
10151 }
10152 case 10: {
10153 global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -050010154 if (result.hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010155 subBuilder.MergeFrom(A);
10156 }
10157 input.ReadMessage(subBuilder, extensionRegistry);
10158 A = subBuilder.BuildPartial();
10159 break;
10160 }
10161 case 16: {
csharptest920b09a2011-06-08 20:13:29 -050010162 result.hasI = input.ReadInt32(ref result.i_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010010163 break;
10164 }
10165 }
10166 }
csharptest123e5342011-06-03 14:15:21 -050010167
10168 if (unknownFields != null) {
10169 this.UnknownFields = unknownFields.Build();
10170 }
10171 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010010172 }
10173
10174
10175 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -050010176 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010010177 }
10178 public global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage A {
10179 get { return result.A; }
10180 set { SetA(value); }
10181 }
10182 public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage value) {
10183 pb::ThrowHelper.ThrowIfNull(value, "value");
10184 result.hasA = true;
10185 result.a_ = value;
10186 return this;
10187 }
10188 public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.Builder builderForValue) {
10189 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
10190 result.hasA = true;
10191 result.a_ = builderForValue.Build();
10192 return this;
10193 }
10194 public Builder MergeA(global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage value) {
10195 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -050010196 if (result.hasA &&
Jon Skeet82bb0f12011-04-03 20:17:12 +010010197 result.a_ != global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance) {
10198 result.a_ = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.CreateBuilder(result.a_).MergeFrom(value).BuildPartial();
10199 } else {
10200 result.a_ = value;
10201 }
10202 result.hasA = true;
10203 return this;
10204 }
10205 public Builder ClearA() {
10206 result.hasA = false;
10207 result.a_ = global::Google.ProtocolBuffers.TestProtos.TestRecursiveMessage.DefaultInstance;
10208 return this;
10209 }
10210
10211 public bool HasI {
csharptestc671a4b2011-06-08 11:51:24 -050010212 get { return result.hasI; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010010213 }
10214 public int I {
10215 get { return result.I; }
10216 set { SetI(value); }
10217 }
10218 public Builder SetI(int value) {
10219 result.hasI = true;
10220 result.i_ = value;
10221 return this;
10222 }
10223 public Builder ClearI() {
10224 result.hasI = false;
10225 result.i_ = 0;
10226 return this;
10227 }
10228 }
10229 static TestRecursiveMessage() {
10230 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
10231 }
10232 }
10233
csharptest445bdce2011-05-20 15:50:54 -050010234 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
10235 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
10236 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010010237 public sealed partial class TestMutualRecursionA : pb::GeneratedMessage<TestMutualRecursionA, TestMutualRecursionA.Builder> {
10238 private static readonly TestMutualRecursionA defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050010239 private static readonly string[] _testMutualRecursionAFieldNames = new string[] { "bb" };
10240 private static readonly uint[] _testMutualRecursionAFieldTags = new uint[] { 10 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010010241 public static TestMutualRecursionA DefaultInstance {
10242 get { return defaultInstance; }
10243 }
10244
10245 public override TestMutualRecursionA DefaultInstanceForType {
10246 get { return defaultInstance; }
10247 }
10248
10249 protected override TestMutualRecursionA ThisMessage {
10250 get { return this; }
10251 }
10252
10253 public static pbd::MessageDescriptor Descriptor {
10254 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMutualRecursionA__Descriptor; }
10255 }
10256
10257 protected override pb::FieldAccess.FieldAccessorTable<TestMutualRecursionA, TestMutualRecursionA.Builder> InternalFieldAccessors {
10258 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMutualRecursionA__FieldAccessorTable; }
10259 }
10260
10261 public const int BbFieldNumber = 1;
10262 private bool hasBb;
10263 private global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB bb_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance;
10264 public bool HasBb {
10265 get { return hasBb; }
10266 }
10267 public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB Bb {
10268 get { return bb_; }
10269 }
10270
10271 public override bool IsInitialized {
10272 get {
10273 return true;
10274 }
10275 }
10276
csharptestffafdaa2011-06-03 12:58:14 -050010277 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010278 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050010279 string[] field_names = _testMutualRecursionAFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050010280 if (hasBb) {
csharptest920b09a2011-06-08 20:13:29 -050010281 output.WriteMessage(1, field_names[0], Bb);
Jon Skeet82bb0f12011-04-03 20:17:12 +010010282 }
10283 UnknownFields.WriteTo(output);
10284 }
10285
10286 private int memoizedSerializedSize = -1;
10287 public override int SerializedSize {
10288 get {
10289 int size = memoizedSerializedSize;
10290 if (size != -1) return size;
10291
10292 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050010293 if (hasBb) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010294 size += pb::CodedOutputStream.ComputeMessageSize(1, Bb);
10295 }
10296 size += UnknownFields.SerializedSize;
10297 memoizedSerializedSize = size;
10298 return size;
10299 }
10300 }
10301
10302 public static TestMutualRecursionA ParseFrom(pb::ByteString data) {
10303 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
10304 }
10305 public static TestMutualRecursionA ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
10306 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
10307 }
10308 public static TestMutualRecursionA ParseFrom(byte[] data) {
10309 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
10310 }
10311 public static TestMutualRecursionA ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
10312 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
10313 }
10314 public static TestMutualRecursionA ParseFrom(global::System.IO.Stream input) {
10315 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
10316 }
10317 public static TestMutualRecursionA ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
10318 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
10319 }
10320 public static TestMutualRecursionA ParseDelimitedFrom(global::System.IO.Stream input) {
10321 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
10322 }
10323 public static TestMutualRecursionA ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
10324 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
10325 }
csharptest17699c22011-06-03 21:57:15 -050010326 public static TestMutualRecursionA ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010327 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
10328 }
csharptest17699c22011-06-03 21:57:15 -050010329 public static TestMutualRecursionA ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010330 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
10331 }
10332 public static Builder CreateBuilder() { return new Builder(); }
10333 public override Builder ToBuilder() { return CreateBuilder(this); }
10334 public override Builder CreateBuilderForType() { return new Builder(); }
10335 public static Builder CreateBuilder(TestMutualRecursionA prototype) {
10336 return (Builder) new Builder().MergeFrom(prototype);
10337 }
10338
csharptest445bdce2011-05-20 15:50:54 -050010339 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
10340 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
10341 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010010342 public sealed partial class Builder : pb::GeneratedBuilder<TestMutualRecursionA, Builder> {
10343 protected override Builder ThisBuilder {
10344 get { return this; }
10345 }
10346 public Builder() {}
10347
10348 TestMutualRecursionA result = new TestMutualRecursionA();
10349
10350 protected override TestMutualRecursionA MessageBeingBuilt {
10351 get { return result; }
10352 }
10353
10354 public override Builder Clear() {
10355 result = new TestMutualRecursionA();
10356 return this;
10357 }
10358
10359 public override Builder Clone() {
10360 return new Builder().MergeFrom(result);
10361 }
10362
10363 public override pbd::MessageDescriptor DescriptorForType {
10364 get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Descriptor; }
10365 }
10366
10367 public override TestMutualRecursionA DefaultInstanceForType {
10368 get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance; }
10369 }
10370
10371 public override TestMutualRecursionA BuildPartial() {
10372 if (result == null) {
10373 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
10374 }
10375 TestMutualRecursionA returnMe = result;
10376 result = null;
10377 return returnMe;
10378 }
10379
10380 public override Builder MergeFrom(pb::IMessage other) {
10381 if (other is TestMutualRecursionA) {
10382 return MergeFrom((TestMutualRecursionA) other);
10383 } else {
10384 base.MergeFrom(other);
10385 return this;
10386 }
10387 }
10388
10389 public override Builder MergeFrom(TestMutualRecursionA other) {
10390 if (other == global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance) return this;
10391 if (other.HasBb) {
10392 MergeBb(other.Bb);
10393 }
10394 this.MergeUnknownFields(other.UnknownFields);
10395 return this;
10396 }
10397
csharptest17699c22011-06-03 21:57:15 -050010398 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010399 return MergeFrom(input, pb::ExtensionRegistry.Empty);
10400 }
10401
csharptest17699c22011-06-03 21:57:15 -050010402 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010403 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050010404 uint tag;
10405 string field_name;
10406 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050010407 if(tag == 0 && field_name != null) {
10408 int field_ordinal = global::System.Array.BinarySearch(_testMutualRecursionAFieldNames, field_name, global::System.StringComparer.Ordinal);
10409 if(field_ordinal >= 0)
10410 tag = _testMutualRecursionAFieldTags[field_ordinal];
10411 else {
10412 if (unknownFields == null) {
10413 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
10414 }
10415 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
10416 continue;
10417 }
10418 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010010419 switch (tag) {
10420 case 0: {
csharptest99284412011-06-03 14:51:06 -050010421 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010010422 }
10423 default: {
10424 if (pb::WireFormat.IsEndGroupTag(tag)) {
10425 if (unknownFields != null) {
10426 this.UnknownFields = unknownFields.Build();
10427 }
10428 return this;
10429 }
10430 if (unknownFields == null) {
10431 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
10432 }
csharptestd2af9e92011-06-03 21:35:02 -050010433 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010010434 break;
10435 }
10436 case 10: {
10437 global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -050010438 if (result.hasBb) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010439 subBuilder.MergeFrom(Bb);
10440 }
10441 input.ReadMessage(subBuilder, extensionRegistry);
10442 Bb = subBuilder.BuildPartial();
10443 break;
10444 }
10445 }
10446 }
csharptest123e5342011-06-03 14:15:21 -050010447
10448 if (unknownFields != null) {
10449 this.UnknownFields = unknownFields.Build();
10450 }
10451 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010010452 }
10453
10454
10455 public bool HasBb {
csharptestc671a4b2011-06-08 11:51:24 -050010456 get { return result.hasBb; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010010457 }
10458 public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB Bb {
10459 get { return result.Bb; }
10460 set { SetBb(value); }
10461 }
10462 public Builder SetBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB value) {
10463 pb::ThrowHelper.ThrowIfNull(value, "value");
10464 result.hasBb = true;
10465 result.bb_ = value;
10466 return this;
10467 }
10468 public Builder SetBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Builder builderForValue) {
10469 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
10470 result.hasBb = true;
10471 result.bb_ = builderForValue.Build();
10472 return this;
10473 }
10474 public Builder MergeBb(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB value) {
10475 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -050010476 if (result.hasBb &&
Jon Skeet82bb0f12011-04-03 20:17:12 +010010477 result.bb_ != global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance) {
10478 result.bb_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.CreateBuilder(result.bb_).MergeFrom(value).BuildPartial();
10479 } else {
10480 result.bb_ = value;
10481 }
10482 result.hasBb = true;
10483 return this;
10484 }
10485 public Builder ClearBb() {
10486 result.hasBb = false;
10487 result.bb_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance;
10488 return this;
10489 }
10490 }
10491 static TestMutualRecursionA() {
10492 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
10493 }
10494 }
10495
csharptest445bdce2011-05-20 15:50:54 -050010496 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
10497 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
10498 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010010499 public sealed partial class TestMutualRecursionB : pb::GeneratedMessage<TestMutualRecursionB, TestMutualRecursionB.Builder> {
10500 private static readonly TestMutualRecursionB defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050010501 private static readonly string[] _testMutualRecursionBFieldNames = new string[] { "a", "optional_int32" };
10502 private static readonly uint[] _testMutualRecursionBFieldTags = new uint[] { 10, 16 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010010503 public static TestMutualRecursionB DefaultInstance {
10504 get { return defaultInstance; }
10505 }
10506
10507 public override TestMutualRecursionB DefaultInstanceForType {
10508 get { return defaultInstance; }
10509 }
10510
10511 protected override TestMutualRecursionB ThisMessage {
10512 get { return this; }
10513 }
10514
10515 public static pbd::MessageDescriptor Descriptor {
10516 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMutualRecursionB__Descriptor; }
10517 }
10518
10519 protected override pb::FieldAccess.FieldAccessorTable<TestMutualRecursionB, TestMutualRecursionB.Builder> InternalFieldAccessors {
10520 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestMutualRecursionB__FieldAccessorTable; }
10521 }
10522
10523 public const int AFieldNumber = 1;
10524 private bool hasA;
10525 private global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA a_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance;
10526 public bool HasA {
10527 get { return hasA; }
10528 }
10529 public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA A {
10530 get { return a_; }
10531 }
10532
10533 public const int OptionalInt32FieldNumber = 2;
10534 private bool hasOptionalInt32;
csharptestced18e12011-06-09 19:47:56 -050010535 private int optionalInt32_;
Jon Skeet82bb0f12011-04-03 20:17:12 +010010536 public bool HasOptionalInt32 {
10537 get { return hasOptionalInt32; }
10538 }
10539 public int OptionalInt32 {
10540 get { return optionalInt32_; }
10541 }
10542
10543 public override bool IsInitialized {
10544 get {
10545 return true;
10546 }
10547 }
10548
csharptestffafdaa2011-06-03 12:58:14 -050010549 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010550 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050010551 string[] field_names = _testMutualRecursionBFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050010552 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -050010553 output.WriteMessage(1, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +010010554 }
csharptestc671a4b2011-06-08 11:51:24 -050010555 if (hasOptionalInt32) {
csharptest920b09a2011-06-08 20:13:29 -050010556 output.WriteInt32(2, field_names[1], OptionalInt32);
Jon Skeet82bb0f12011-04-03 20:17:12 +010010557 }
10558 UnknownFields.WriteTo(output);
10559 }
10560
10561 private int memoizedSerializedSize = -1;
10562 public override int SerializedSize {
10563 get {
10564 int size = memoizedSerializedSize;
10565 if (size != -1) return size;
10566
10567 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050010568 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010569 size += pb::CodedOutputStream.ComputeMessageSize(1, A);
10570 }
csharptestc671a4b2011-06-08 11:51:24 -050010571 if (hasOptionalInt32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010572 size += pb::CodedOutputStream.ComputeInt32Size(2, OptionalInt32);
10573 }
10574 size += UnknownFields.SerializedSize;
10575 memoizedSerializedSize = size;
10576 return size;
10577 }
10578 }
10579
10580 public static TestMutualRecursionB ParseFrom(pb::ByteString data) {
10581 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
10582 }
10583 public static TestMutualRecursionB ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
10584 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
10585 }
10586 public static TestMutualRecursionB ParseFrom(byte[] data) {
10587 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
10588 }
10589 public static TestMutualRecursionB ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
10590 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
10591 }
10592 public static TestMutualRecursionB ParseFrom(global::System.IO.Stream input) {
10593 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
10594 }
10595 public static TestMutualRecursionB ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
10596 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
10597 }
10598 public static TestMutualRecursionB ParseDelimitedFrom(global::System.IO.Stream input) {
10599 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
10600 }
10601 public static TestMutualRecursionB ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
10602 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
10603 }
csharptest17699c22011-06-03 21:57:15 -050010604 public static TestMutualRecursionB ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010605 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
10606 }
csharptest17699c22011-06-03 21:57:15 -050010607 public static TestMutualRecursionB ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010608 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
10609 }
10610 public static Builder CreateBuilder() { return new Builder(); }
10611 public override Builder ToBuilder() { return CreateBuilder(this); }
10612 public override Builder CreateBuilderForType() { return new Builder(); }
10613 public static Builder CreateBuilder(TestMutualRecursionB prototype) {
10614 return (Builder) new Builder().MergeFrom(prototype);
10615 }
10616
csharptest445bdce2011-05-20 15:50:54 -050010617 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
10618 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
10619 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010010620 public sealed partial class Builder : pb::GeneratedBuilder<TestMutualRecursionB, Builder> {
10621 protected override Builder ThisBuilder {
10622 get { return this; }
10623 }
10624 public Builder() {}
10625
10626 TestMutualRecursionB result = new TestMutualRecursionB();
10627
10628 protected override TestMutualRecursionB MessageBeingBuilt {
10629 get { return result; }
10630 }
10631
10632 public override Builder Clear() {
10633 result = new TestMutualRecursionB();
10634 return this;
10635 }
10636
10637 public override Builder Clone() {
10638 return new Builder().MergeFrom(result);
10639 }
10640
10641 public override pbd::MessageDescriptor DescriptorForType {
10642 get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.Descriptor; }
10643 }
10644
10645 public override TestMutualRecursionB DefaultInstanceForType {
10646 get { return global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance; }
10647 }
10648
10649 public override TestMutualRecursionB BuildPartial() {
10650 if (result == null) {
10651 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
10652 }
10653 TestMutualRecursionB returnMe = result;
10654 result = null;
10655 return returnMe;
10656 }
10657
10658 public override Builder MergeFrom(pb::IMessage other) {
10659 if (other is TestMutualRecursionB) {
10660 return MergeFrom((TestMutualRecursionB) other);
10661 } else {
10662 base.MergeFrom(other);
10663 return this;
10664 }
10665 }
10666
10667 public override Builder MergeFrom(TestMutualRecursionB other) {
10668 if (other == global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionB.DefaultInstance) return this;
10669 if (other.HasA) {
10670 MergeA(other.A);
10671 }
10672 if (other.HasOptionalInt32) {
10673 OptionalInt32 = other.OptionalInt32;
10674 }
10675 this.MergeUnknownFields(other.UnknownFields);
10676 return this;
10677 }
10678
csharptest17699c22011-06-03 21:57:15 -050010679 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010680 return MergeFrom(input, pb::ExtensionRegistry.Empty);
10681 }
10682
csharptest17699c22011-06-03 21:57:15 -050010683 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010684 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050010685 uint tag;
10686 string field_name;
10687 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050010688 if(tag == 0 && field_name != null) {
10689 int field_ordinal = global::System.Array.BinarySearch(_testMutualRecursionBFieldNames, field_name, global::System.StringComparer.Ordinal);
10690 if(field_ordinal >= 0)
10691 tag = _testMutualRecursionBFieldTags[field_ordinal];
10692 else {
10693 if (unknownFields == null) {
10694 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
10695 }
10696 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
10697 continue;
10698 }
10699 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010010700 switch (tag) {
10701 case 0: {
csharptest99284412011-06-03 14:51:06 -050010702 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010010703 }
10704 default: {
10705 if (pb::WireFormat.IsEndGroupTag(tag)) {
10706 if (unknownFields != null) {
10707 this.UnknownFields = unknownFields.Build();
10708 }
10709 return this;
10710 }
10711 if (unknownFields == null) {
10712 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
10713 }
csharptestd2af9e92011-06-03 21:35:02 -050010714 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010010715 break;
10716 }
10717 case 10: {
10718 global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -050010719 if (result.hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010720 subBuilder.MergeFrom(A);
10721 }
10722 input.ReadMessage(subBuilder, extensionRegistry);
10723 A = subBuilder.BuildPartial();
10724 break;
10725 }
10726 case 16: {
csharptest920b09a2011-06-08 20:13:29 -050010727 result.hasOptionalInt32 = input.ReadInt32(ref result.optionalInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010010728 break;
10729 }
10730 }
10731 }
csharptest123e5342011-06-03 14:15:21 -050010732
10733 if (unknownFields != null) {
10734 this.UnknownFields = unknownFields.Build();
10735 }
10736 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010010737 }
10738
10739
10740 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -050010741 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010010742 }
10743 public global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA A {
10744 get { return result.A; }
10745 set { SetA(value); }
10746 }
10747 public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA value) {
10748 pb::ThrowHelper.ThrowIfNull(value, "value");
10749 result.hasA = true;
10750 result.a_ = value;
10751 return this;
10752 }
10753 public Builder SetA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.Builder builderForValue) {
10754 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
10755 result.hasA = true;
10756 result.a_ = builderForValue.Build();
10757 return this;
10758 }
10759 public Builder MergeA(global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA value) {
10760 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -050010761 if (result.hasA &&
Jon Skeet82bb0f12011-04-03 20:17:12 +010010762 result.a_ != global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance) {
10763 result.a_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.CreateBuilder(result.a_).MergeFrom(value).BuildPartial();
10764 } else {
10765 result.a_ = value;
10766 }
10767 result.hasA = true;
10768 return this;
10769 }
10770 public Builder ClearA() {
10771 result.hasA = false;
10772 result.a_ = global::Google.ProtocolBuffers.TestProtos.TestMutualRecursionA.DefaultInstance;
10773 return this;
10774 }
10775
10776 public bool HasOptionalInt32 {
csharptestc671a4b2011-06-08 11:51:24 -050010777 get { return result.hasOptionalInt32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010010778 }
10779 public int OptionalInt32 {
10780 get { return result.OptionalInt32; }
10781 set { SetOptionalInt32(value); }
10782 }
10783 public Builder SetOptionalInt32(int value) {
10784 result.hasOptionalInt32 = true;
10785 result.optionalInt32_ = value;
10786 return this;
10787 }
10788 public Builder ClearOptionalInt32() {
10789 result.hasOptionalInt32 = false;
10790 result.optionalInt32_ = 0;
10791 return this;
10792 }
10793 }
10794 static TestMutualRecursionB() {
10795 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
10796 }
10797 }
10798
csharptest445bdce2011-05-20 15:50:54 -050010799 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
10800 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
10801 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010010802 public sealed partial class TestDupFieldNumber : pb::GeneratedMessage<TestDupFieldNumber, TestDupFieldNumber.Builder> {
10803 private static readonly TestDupFieldNumber defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050010804 private static readonly string[] _testDupFieldNumberFieldNames = new string[] { "a", "bar", "foo" };
10805 private static readonly uint[] _testDupFieldNumberFieldTags = new uint[] { 8, 27, 19 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010010806 public static TestDupFieldNumber DefaultInstance {
10807 get { return defaultInstance; }
10808 }
10809
10810 public override TestDupFieldNumber DefaultInstanceForType {
10811 get { return defaultInstance; }
10812 }
10813
10814 protected override TestDupFieldNumber ThisMessage {
10815 get { return this; }
10816 }
10817
10818 public static pbd::MessageDescriptor Descriptor {
10819 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber__Descriptor; }
10820 }
10821
10822 protected override pb::FieldAccess.FieldAccessorTable<TestDupFieldNumber, TestDupFieldNumber.Builder> InternalFieldAccessors {
10823 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber__FieldAccessorTable; }
10824 }
10825
10826 #region Nested types
csharptest445bdce2011-05-20 15:50:54 -050010827 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
10828 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
10829 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010010830 public static class Types {
csharptest445bdce2011-05-20 15:50:54 -050010831 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
10832 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
10833 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010010834 public sealed partial class Foo : pb::GeneratedMessage<Foo, Foo.Builder> {
10835 private static readonly Foo defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050010836 private static readonly string[] _fooFieldNames = new string[] { "a" };
10837 private static readonly uint[] _fooFieldTags = new uint[] { 8 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010010838 public static Foo DefaultInstance {
10839 get { return defaultInstance; }
10840 }
10841
10842 public override Foo DefaultInstanceForType {
10843 get { return defaultInstance; }
10844 }
10845
10846 protected override Foo ThisMessage {
10847 get { return this; }
10848 }
10849
10850 public static pbd::MessageDescriptor Descriptor {
10851 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber_Foo__Descriptor; }
10852 }
10853
10854 protected override pb::FieldAccess.FieldAccessorTable<Foo, Foo.Builder> InternalFieldAccessors {
10855 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber_Foo__FieldAccessorTable; }
10856 }
10857
10858 public const int AFieldNumber = 1;
10859 private bool hasA;
csharptestced18e12011-06-09 19:47:56 -050010860 private int a_;
Jon Skeet82bb0f12011-04-03 20:17:12 +010010861 public bool HasA {
10862 get { return hasA; }
10863 }
10864 public int A {
10865 get { return a_; }
10866 }
10867
10868 public override bool IsInitialized {
10869 get {
10870 return true;
10871 }
10872 }
10873
csharptestffafdaa2011-06-03 12:58:14 -050010874 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010875 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050010876 string[] field_names = _fooFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050010877 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -050010878 output.WriteInt32(1, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +010010879 }
10880 UnknownFields.WriteTo(output);
10881 }
10882
10883 private int memoizedSerializedSize = -1;
10884 public override int SerializedSize {
10885 get {
10886 int size = memoizedSerializedSize;
10887 if (size != -1) return size;
10888
10889 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050010890 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010891 size += pb::CodedOutputStream.ComputeInt32Size(1, A);
10892 }
10893 size += UnknownFields.SerializedSize;
10894 memoizedSerializedSize = size;
10895 return size;
10896 }
10897 }
10898
10899 public static Foo ParseFrom(pb::ByteString data) {
10900 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
10901 }
10902 public static Foo ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
10903 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
10904 }
10905 public static Foo ParseFrom(byte[] data) {
10906 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
10907 }
10908 public static Foo ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
10909 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
10910 }
10911 public static Foo ParseFrom(global::System.IO.Stream input) {
10912 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
10913 }
10914 public static Foo ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
10915 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
10916 }
10917 public static Foo ParseDelimitedFrom(global::System.IO.Stream input) {
10918 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
10919 }
10920 public static Foo ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
10921 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
10922 }
csharptest17699c22011-06-03 21:57:15 -050010923 public static Foo ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010924 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
10925 }
csharptest17699c22011-06-03 21:57:15 -050010926 public static Foo ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010927 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
10928 }
10929 public static Builder CreateBuilder() { return new Builder(); }
10930 public override Builder ToBuilder() { return CreateBuilder(this); }
10931 public override Builder CreateBuilderForType() { return new Builder(); }
10932 public static Builder CreateBuilder(Foo prototype) {
10933 return (Builder) new Builder().MergeFrom(prototype);
10934 }
10935
csharptest445bdce2011-05-20 15:50:54 -050010936 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
10937 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
10938 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010010939 public sealed partial class Builder : pb::GeneratedBuilder<Foo, Builder> {
10940 protected override Builder ThisBuilder {
10941 get { return this; }
10942 }
10943 public Builder() {}
10944
10945 Foo result = new Foo();
10946
10947 protected override Foo MessageBeingBuilt {
10948 get { return result; }
10949 }
10950
10951 public override Builder Clear() {
10952 result = new Foo();
10953 return this;
10954 }
10955
10956 public override Builder Clone() {
10957 return new Builder().MergeFrom(result);
10958 }
10959
10960 public override pbd::MessageDescriptor DescriptorForType {
10961 get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Descriptor; }
10962 }
10963
10964 public override Foo DefaultInstanceForType {
10965 get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance; }
10966 }
10967
10968 public override Foo BuildPartial() {
10969 if (result == null) {
10970 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
10971 }
10972 Foo returnMe = result;
10973 result = null;
10974 return returnMe;
10975 }
10976
10977 public override Builder MergeFrom(pb::IMessage other) {
10978 if (other is Foo) {
10979 return MergeFrom((Foo) other);
10980 } else {
10981 base.MergeFrom(other);
10982 return this;
10983 }
10984 }
10985
10986 public override Builder MergeFrom(Foo other) {
10987 if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance) return this;
10988 if (other.HasA) {
10989 A = other.A;
10990 }
10991 this.MergeUnknownFields(other.UnknownFields);
10992 return this;
10993 }
10994
csharptest17699c22011-06-03 21:57:15 -050010995 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010010996 return MergeFrom(input, pb::ExtensionRegistry.Empty);
10997 }
10998
csharptest17699c22011-06-03 21:57:15 -050010999 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011000 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050011001 uint tag;
11002 string field_name;
11003 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050011004 if(tag == 0 && field_name != null) {
11005 int field_ordinal = global::System.Array.BinarySearch(_fooFieldNames, field_name, global::System.StringComparer.Ordinal);
11006 if(field_ordinal >= 0)
11007 tag = _fooFieldTags[field_ordinal];
11008 else {
11009 if (unknownFields == null) {
11010 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
11011 }
11012 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
11013 continue;
11014 }
11015 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010011016 switch (tag) {
11017 case 0: {
csharptest99284412011-06-03 14:51:06 -050011018 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010011019 }
11020 default: {
11021 if (pb::WireFormat.IsEndGroupTag(tag)) {
11022 if (unknownFields != null) {
11023 this.UnknownFields = unknownFields.Build();
11024 }
11025 return this;
11026 }
11027 if (unknownFields == null) {
11028 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
11029 }
csharptestd2af9e92011-06-03 21:35:02 -050011030 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011031 break;
11032 }
11033 case 8: {
csharptest920b09a2011-06-08 20:13:29 -050011034 result.hasA = input.ReadInt32(ref result.a_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011035 break;
11036 }
11037 }
11038 }
csharptest123e5342011-06-03 14:15:21 -050011039
11040 if (unknownFields != null) {
11041 this.UnknownFields = unknownFields.Build();
11042 }
11043 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010011044 }
11045
11046
11047 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -050011048 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010011049 }
11050 public int A {
11051 get { return result.A; }
11052 set { SetA(value); }
11053 }
11054 public Builder SetA(int value) {
11055 result.hasA = true;
11056 result.a_ = value;
11057 return this;
11058 }
11059 public Builder ClearA() {
11060 result.hasA = false;
11061 result.a_ = 0;
11062 return this;
11063 }
11064 }
11065 static Foo() {
11066 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
11067 }
11068 }
11069
csharptest445bdce2011-05-20 15:50:54 -050011070 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
11071 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
11072 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010011073 public sealed partial class Bar : pb::GeneratedMessage<Bar, Bar.Builder> {
11074 private static readonly Bar defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050011075 private static readonly string[] _barFieldNames = new string[] { "a" };
11076 private static readonly uint[] _barFieldTags = new uint[] { 8 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010011077 public static Bar DefaultInstance {
11078 get { return defaultInstance; }
11079 }
11080
11081 public override Bar DefaultInstanceForType {
11082 get { return defaultInstance; }
11083 }
11084
11085 protected override Bar ThisMessage {
11086 get { return this; }
11087 }
11088
11089 public static pbd::MessageDescriptor Descriptor {
11090 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber_Bar__Descriptor; }
11091 }
11092
11093 protected override pb::FieldAccess.FieldAccessorTable<Bar, Bar.Builder> InternalFieldAccessors {
11094 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDupFieldNumber_Bar__FieldAccessorTable; }
11095 }
11096
11097 public const int AFieldNumber = 1;
11098 private bool hasA;
csharptestced18e12011-06-09 19:47:56 -050011099 private int a_;
Jon Skeet82bb0f12011-04-03 20:17:12 +010011100 public bool HasA {
11101 get { return hasA; }
11102 }
11103 public int A {
11104 get { return a_; }
11105 }
11106
11107 public override bool IsInitialized {
11108 get {
11109 return true;
11110 }
11111 }
11112
csharptestffafdaa2011-06-03 12:58:14 -050011113 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011114 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050011115 string[] field_names = _barFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050011116 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -050011117 output.WriteInt32(1, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011118 }
11119 UnknownFields.WriteTo(output);
11120 }
11121
11122 private int memoizedSerializedSize = -1;
11123 public override int SerializedSize {
11124 get {
11125 int size = memoizedSerializedSize;
11126 if (size != -1) return size;
11127
11128 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050011129 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011130 size += pb::CodedOutputStream.ComputeInt32Size(1, A);
11131 }
11132 size += UnknownFields.SerializedSize;
11133 memoizedSerializedSize = size;
11134 return size;
11135 }
11136 }
11137
11138 public static Bar ParseFrom(pb::ByteString data) {
11139 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
11140 }
11141 public static Bar ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
11142 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
11143 }
11144 public static Bar ParseFrom(byte[] data) {
11145 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
11146 }
11147 public static Bar ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
11148 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
11149 }
11150 public static Bar ParseFrom(global::System.IO.Stream input) {
11151 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
11152 }
11153 public static Bar ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
11154 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
11155 }
11156 public static Bar ParseDelimitedFrom(global::System.IO.Stream input) {
11157 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
11158 }
11159 public static Bar ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
11160 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
11161 }
csharptest17699c22011-06-03 21:57:15 -050011162 public static Bar ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011163 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
11164 }
csharptest17699c22011-06-03 21:57:15 -050011165 public static Bar ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011166 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
11167 }
11168 public static Builder CreateBuilder() { return new Builder(); }
11169 public override Builder ToBuilder() { return CreateBuilder(this); }
11170 public override Builder CreateBuilderForType() { return new Builder(); }
11171 public static Builder CreateBuilder(Bar prototype) {
11172 return (Builder) new Builder().MergeFrom(prototype);
11173 }
11174
csharptest445bdce2011-05-20 15:50:54 -050011175 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
11176 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
11177 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010011178 public sealed partial class Builder : pb::GeneratedBuilder<Bar, Builder> {
11179 protected override Builder ThisBuilder {
11180 get { return this; }
11181 }
11182 public Builder() {}
11183
11184 Bar result = new Bar();
11185
11186 protected override Bar MessageBeingBuilt {
11187 get { return result; }
11188 }
11189
11190 public override Builder Clear() {
11191 result = new Bar();
11192 return this;
11193 }
11194
11195 public override Builder Clone() {
11196 return new Builder().MergeFrom(result);
11197 }
11198
11199 public override pbd::MessageDescriptor DescriptorForType {
11200 get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Descriptor; }
11201 }
11202
11203 public override Bar DefaultInstanceForType {
11204 get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance; }
11205 }
11206
11207 public override Bar BuildPartial() {
11208 if (result == null) {
11209 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
11210 }
11211 Bar returnMe = result;
11212 result = null;
11213 return returnMe;
11214 }
11215
11216 public override Builder MergeFrom(pb::IMessage other) {
11217 if (other is Bar) {
11218 return MergeFrom((Bar) other);
11219 } else {
11220 base.MergeFrom(other);
11221 return this;
11222 }
11223 }
11224
11225 public override Builder MergeFrom(Bar other) {
11226 if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance) return this;
11227 if (other.HasA) {
11228 A = other.A;
11229 }
11230 this.MergeUnknownFields(other.UnknownFields);
11231 return this;
11232 }
11233
csharptest17699c22011-06-03 21:57:15 -050011234 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011235 return MergeFrom(input, pb::ExtensionRegistry.Empty);
11236 }
11237
csharptest17699c22011-06-03 21:57:15 -050011238 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011239 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050011240 uint tag;
11241 string field_name;
11242 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050011243 if(tag == 0 && field_name != null) {
11244 int field_ordinal = global::System.Array.BinarySearch(_barFieldNames, field_name, global::System.StringComparer.Ordinal);
11245 if(field_ordinal >= 0)
11246 tag = _barFieldTags[field_ordinal];
11247 else {
11248 if (unknownFields == null) {
11249 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
11250 }
11251 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
11252 continue;
11253 }
11254 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010011255 switch (tag) {
11256 case 0: {
csharptest99284412011-06-03 14:51:06 -050011257 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010011258 }
11259 default: {
11260 if (pb::WireFormat.IsEndGroupTag(tag)) {
11261 if (unknownFields != null) {
11262 this.UnknownFields = unknownFields.Build();
11263 }
11264 return this;
11265 }
11266 if (unknownFields == null) {
11267 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
11268 }
csharptestd2af9e92011-06-03 21:35:02 -050011269 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011270 break;
11271 }
11272 case 8: {
csharptest920b09a2011-06-08 20:13:29 -050011273 result.hasA = input.ReadInt32(ref result.a_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011274 break;
11275 }
11276 }
11277 }
csharptest123e5342011-06-03 14:15:21 -050011278
11279 if (unknownFields != null) {
11280 this.UnknownFields = unknownFields.Build();
11281 }
11282 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010011283 }
11284
11285
11286 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -050011287 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010011288 }
11289 public int A {
11290 get { return result.A; }
11291 set { SetA(value); }
11292 }
11293 public Builder SetA(int value) {
11294 result.hasA = true;
11295 result.a_ = value;
11296 return this;
11297 }
11298 public Builder ClearA() {
11299 result.hasA = false;
11300 result.a_ = 0;
11301 return this;
11302 }
11303 }
11304 static Bar() {
11305 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
11306 }
11307 }
11308
11309 }
11310 #endregion
11311
11312 public const int AFieldNumber = 1;
11313 private bool hasA;
csharptestced18e12011-06-09 19:47:56 -050011314 private int a_;
Jon Skeet82bb0f12011-04-03 20:17:12 +010011315 public bool HasA {
11316 get { return hasA; }
11317 }
11318 public int A {
11319 get { return a_; }
11320 }
11321
11322 public const int FooFieldNumber = 2;
11323 private bool hasFoo;
11324 private global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo foo_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance;
11325 public bool HasFoo {
11326 get { return hasFoo; }
11327 }
11328 public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo Foo {
11329 get { return foo_; }
11330 }
11331
11332 public const int BarFieldNumber = 3;
11333 private bool hasBar;
11334 private global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar bar_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance;
11335 public bool HasBar {
11336 get { return hasBar; }
11337 }
11338 public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar Bar {
11339 get { return bar_; }
11340 }
11341
11342 public override bool IsInitialized {
11343 get {
11344 return true;
11345 }
11346 }
11347
csharptestffafdaa2011-06-03 12:58:14 -050011348 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011349 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050011350 string[] field_names = _testDupFieldNumberFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050011351 if (hasA) {
csharptest920b09a2011-06-08 20:13:29 -050011352 output.WriteInt32(1, field_names[0], A);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011353 }
csharptestc671a4b2011-06-08 11:51:24 -050011354 if (hasFoo) {
csharptest920b09a2011-06-08 20:13:29 -050011355 output.WriteGroup(2, field_names[2], Foo);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011356 }
csharptestc671a4b2011-06-08 11:51:24 -050011357 if (hasBar) {
csharptest920b09a2011-06-08 20:13:29 -050011358 output.WriteGroup(3, field_names[1], Bar);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011359 }
11360 UnknownFields.WriteTo(output);
11361 }
11362
11363 private int memoizedSerializedSize = -1;
11364 public override int SerializedSize {
11365 get {
11366 int size = memoizedSerializedSize;
11367 if (size != -1) return size;
11368
11369 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050011370 if (hasA) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011371 size += pb::CodedOutputStream.ComputeInt32Size(1, A);
11372 }
csharptestc671a4b2011-06-08 11:51:24 -050011373 if (hasFoo) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011374 size += pb::CodedOutputStream.ComputeGroupSize(2, Foo);
11375 }
csharptestc671a4b2011-06-08 11:51:24 -050011376 if (hasBar) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011377 size += pb::CodedOutputStream.ComputeGroupSize(3, Bar);
11378 }
11379 size += UnknownFields.SerializedSize;
11380 memoizedSerializedSize = size;
11381 return size;
11382 }
11383 }
11384
11385 public static TestDupFieldNumber ParseFrom(pb::ByteString data) {
11386 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
11387 }
11388 public static TestDupFieldNumber ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
11389 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
11390 }
11391 public static TestDupFieldNumber ParseFrom(byte[] data) {
11392 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
11393 }
11394 public static TestDupFieldNumber ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
11395 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
11396 }
11397 public static TestDupFieldNumber ParseFrom(global::System.IO.Stream input) {
11398 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
11399 }
11400 public static TestDupFieldNumber ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
11401 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
11402 }
11403 public static TestDupFieldNumber ParseDelimitedFrom(global::System.IO.Stream input) {
11404 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
11405 }
11406 public static TestDupFieldNumber ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
11407 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
11408 }
csharptest17699c22011-06-03 21:57:15 -050011409 public static TestDupFieldNumber ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011410 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
11411 }
csharptest17699c22011-06-03 21:57:15 -050011412 public static TestDupFieldNumber ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011413 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
11414 }
11415 public static Builder CreateBuilder() { return new Builder(); }
11416 public override Builder ToBuilder() { return CreateBuilder(this); }
11417 public override Builder CreateBuilderForType() { return new Builder(); }
11418 public static Builder CreateBuilder(TestDupFieldNumber prototype) {
11419 return (Builder) new Builder().MergeFrom(prototype);
11420 }
11421
csharptest445bdce2011-05-20 15:50:54 -050011422 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
11423 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
11424 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010011425 public sealed partial class Builder : pb::GeneratedBuilder<TestDupFieldNumber, Builder> {
11426 protected override Builder ThisBuilder {
11427 get { return this; }
11428 }
11429 public Builder() {}
11430
11431 TestDupFieldNumber result = new TestDupFieldNumber();
11432
11433 protected override TestDupFieldNumber MessageBeingBuilt {
11434 get { return result; }
11435 }
11436
11437 public override Builder Clear() {
11438 result = new TestDupFieldNumber();
11439 return this;
11440 }
11441
11442 public override Builder Clone() {
11443 return new Builder().MergeFrom(result);
11444 }
11445
11446 public override pbd::MessageDescriptor DescriptorForType {
11447 get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Descriptor; }
11448 }
11449
11450 public override TestDupFieldNumber DefaultInstanceForType {
11451 get { return global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.DefaultInstance; }
11452 }
11453
11454 public override TestDupFieldNumber BuildPartial() {
11455 if (result == null) {
11456 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
11457 }
11458 TestDupFieldNumber returnMe = result;
11459 result = null;
11460 return returnMe;
11461 }
11462
11463 public override Builder MergeFrom(pb::IMessage other) {
11464 if (other is TestDupFieldNumber) {
11465 return MergeFrom((TestDupFieldNumber) other);
11466 } else {
11467 base.MergeFrom(other);
11468 return this;
11469 }
11470 }
11471
11472 public override Builder MergeFrom(TestDupFieldNumber other) {
11473 if (other == global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.DefaultInstance) return this;
11474 if (other.HasA) {
11475 A = other.A;
11476 }
11477 if (other.HasFoo) {
11478 MergeFoo(other.Foo);
11479 }
11480 if (other.HasBar) {
11481 MergeBar(other.Bar);
11482 }
11483 this.MergeUnknownFields(other.UnknownFields);
11484 return this;
11485 }
11486
csharptest17699c22011-06-03 21:57:15 -050011487 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011488 return MergeFrom(input, pb::ExtensionRegistry.Empty);
11489 }
11490
csharptest17699c22011-06-03 21:57:15 -050011491 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011492 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050011493 uint tag;
11494 string field_name;
11495 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050011496 if(tag == 0 && field_name != null) {
11497 int field_ordinal = global::System.Array.BinarySearch(_testDupFieldNumberFieldNames, field_name, global::System.StringComparer.Ordinal);
11498 if(field_ordinal >= 0)
11499 tag = _testDupFieldNumberFieldTags[field_ordinal];
11500 else {
11501 if (unknownFields == null) {
11502 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
11503 }
11504 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
11505 continue;
11506 }
11507 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010011508 switch (tag) {
11509 case 0: {
csharptest99284412011-06-03 14:51:06 -050011510 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010011511 }
11512 default: {
11513 if (pb::WireFormat.IsEndGroupTag(tag)) {
11514 if (unknownFields != null) {
11515 this.UnknownFields = unknownFields.Build();
11516 }
11517 return this;
11518 }
11519 if (unknownFields == null) {
11520 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
11521 }
csharptestd2af9e92011-06-03 21:35:02 -050011522 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011523 break;
11524 }
11525 case 8: {
csharptest920b09a2011-06-08 20:13:29 -050011526 result.hasA = input.ReadInt32(ref result.a_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011527 break;
11528 }
11529 case 19: {
11530 global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -050011531 if (result.hasFoo) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011532 subBuilder.MergeFrom(Foo);
11533 }
11534 input.ReadGroup(2, subBuilder, extensionRegistry);
11535 Foo = subBuilder.BuildPartial();
11536 break;
11537 }
11538 case 27: {
11539 global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -050011540 if (result.hasBar) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011541 subBuilder.MergeFrom(Bar);
11542 }
11543 input.ReadGroup(3, subBuilder, extensionRegistry);
11544 Bar = subBuilder.BuildPartial();
11545 break;
11546 }
11547 }
11548 }
csharptest123e5342011-06-03 14:15:21 -050011549
11550 if (unknownFields != null) {
11551 this.UnknownFields = unknownFields.Build();
11552 }
11553 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010011554 }
11555
11556
11557 public bool HasA {
csharptestc671a4b2011-06-08 11:51:24 -050011558 get { return result.hasA; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010011559 }
11560 public int A {
11561 get { return result.A; }
11562 set { SetA(value); }
11563 }
11564 public Builder SetA(int value) {
11565 result.hasA = true;
11566 result.a_ = value;
11567 return this;
11568 }
11569 public Builder ClearA() {
11570 result.hasA = false;
11571 result.a_ = 0;
11572 return this;
11573 }
11574
11575 public bool HasFoo {
csharptestc671a4b2011-06-08 11:51:24 -050011576 get { return result.hasFoo; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010011577 }
11578 public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo Foo {
11579 get { return result.Foo; }
11580 set { SetFoo(value); }
11581 }
11582 public Builder SetFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo value) {
11583 pb::ThrowHelper.ThrowIfNull(value, "value");
11584 result.hasFoo = true;
11585 result.foo_ = value;
11586 return this;
11587 }
11588 public Builder SetFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.Builder builderForValue) {
11589 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
11590 result.hasFoo = true;
11591 result.foo_ = builderForValue.Build();
11592 return this;
11593 }
11594 public Builder MergeFoo(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo value) {
11595 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -050011596 if (result.hasFoo &&
Jon Skeet82bb0f12011-04-03 20:17:12 +010011597 result.foo_ != global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance) {
11598 result.foo_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.CreateBuilder(result.foo_).MergeFrom(value).BuildPartial();
11599 } else {
11600 result.foo_ = value;
11601 }
11602 result.hasFoo = true;
11603 return this;
11604 }
11605 public Builder ClearFoo() {
11606 result.hasFoo = false;
11607 result.foo_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Foo.DefaultInstance;
11608 return this;
11609 }
11610
11611 public bool HasBar {
csharptestc671a4b2011-06-08 11:51:24 -050011612 get { return result.hasBar; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010011613 }
11614 public global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar Bar {
11615 get { return result.Bar; }
11616 set { SetBar(value); }
11617 }
11618 public Builder SetBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar value) {
11619 pb::ThrowHelper.ThrowIfNull(value, "value");
11620 result.hasBar = true;
11621 result.bar_ = value;
11622 return this;
11623 }
11624 public Builder SetBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.Builder builderForValue) {
11625 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
11626 result.hasBar = true;
11627 result.bar_ = builderForValue.Build();
11628 return this;
11629 }
11630 public Builder MergeBar(global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar value) {
11631 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -050011632 if (result.hasBar &&
Jon Skeet82bb0f12011-04-03 20:17:12 +010011633 result.bar_ != global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance) {
11634 result.bar_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.CreateBuilder(result.bar_).MergeFrom(value).BuildPartial();
11635 } else {
11636 result.bar_ = value;
11637 }
11638 result.hasBar = true;
11639 return this;
11640 }
11641 public Builder ClearBar() {
11642 result.hasBar = false;
11643 result.bar_ = global::Google.ProtocolBuffers.TestProtos.TestDupFieldNumber.Types.Bar.DefaultInstance;
11644 return this;
11645 }
11646 }
11647 static TestDupFieldNumber() {
11648 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
11649 }
11650 }
11651
csharptest445bdce2011-05-20 15:50:54 -050011652 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
11653 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
11654 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010011655 public sealed partial class TestNestedMessageHasBits : pb::GeneratedMessage<TestNestedMessageHasBits, TestNestedMessageHasBits.Builder> {
11656 private static readonly TestNestedMessageHasBits defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050011657 private static readonly string[] _testNestedMessageHasBitsFieldNames = new string[] { "optional_nested_message" };
11658 private static readonly uint[] _testNestedMessageHasBitsFieldTags = new uint[] { 10 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010011659 public static TestNestedMessageHasBits DefaultInstance {
11660 get { return defaultInstance; }
11661 }
11662
11663 public override TestNestedMessageHasBits DefaultInstanceForType {
11664 get { return defaultInstance; }
11665 }
11666
11667 protected override TestNestedMessageHasBits ThisMessage {
11668 get { return this; }
11669 }
11670
11671 public static pbd::MessageDescriptor Descriptor {
11672 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedMessageHasBits__Descriptor; }
11673 }
11674
11675 protected override pb::FieldAccess.FieldAccessorTable<TestNestedMessageHasBits, TestNestedMessageHasBits.Builder> InternalFieldAccessors {
11676 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedMessageHasBits__FieldAccessorTable; }
11677 }
11678
11679 #region Nested types
csharptest445bdce2011-05-20 15:50:54 -050011680 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
11681 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
11682 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010011683 public static class Types {
csharptest445bdce2011-05-20 15:50:54 -050011684 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
11685 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
11686 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010011687 public sealed partial class NestedMessage : pb::GeneratedMessage<NestedMessage, NestedMessage.Builder> {
11688 private static readonly NestedMessage defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050011689 private static readonly string[] _nestedMessageFieldNames = new string[] { "nestedmessage_repeated_foreignmessage", "nestedmessage_repeated_int32" };
11690 private static readonly uint[] _nestedMessageFieldTags = new uint[] { 18, 8 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010011691 public static NestedMessage DefaultInstance {
11692 get { return defaultInstance; }
11693 }
11694
11695 public override NestedMessage DefaultInstanceForType {
11696 get { return defaultInstance; }
11697 }
11698
11699 protected override NestedMessage ThisMessage {
11700 get { return this; }
11701 }
11702
11703 public static pbd::MessageDescriptor Descriptor {
11704 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__Descriptor; }
11705 }
11706
11707 protected override pb::FieldAccess.FieldAccessorTable<NestedMessage, NestedMessage.Builder> InternalFieldAccessors {
11708 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestNestedMessageHasBits_NestedMessage__FieldAccessorTable; }
11709 }
11710
11711 public const int NestedmessageRepeatedInt32FieldNumber = 1;
11712 private pbc::PopsicleList<int> nestedmessageRepeatedInt32_ = new pbc::PopsicleList<int>();
11713 public scg::IList<int> NestedmessageRepeatedInt32List {
11714 get { return pbc::Lists.AsReadOnly(nestedmessageRepeatedInt32_); }
11715 }
11716 public int NestedmessageRepeatedInt32Count {
11717 get { return nestedmessageRepeatedInt32_.Count; }
11718 }
11719 public int GetNestedmessageRepeatedInt32(int index) {
11720 return nestedmessageRepeatedInt32_[index];
11721 }
11722
11723 public const int NestedmessageRepeatedForeignmessageFieldNumber = 2;
11724 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> nestedmessageRepeatedForeignmessage_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage>();
11725 public scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> NestedmessageRepeatedForeignmessageList {
11726 get { return nestedmessageRepeatedForeignmessage_; }
11727 }
11728 public int NestedmessageRepeatedForeignmessageCount {
11729 get { return nestedmessageRepeatedForeignmessage_.Count; }
11730 }
11731 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetNestedmessageRepeatedForeignmessage(int index) {
11732 return nestedmessageRepeatedForeignmessage_[index];
11733 }
11734
11735 public override bool IsInitialized {
11736 get {
11737 return true;
11738 }
11739 }
11740
csharptestffafdaa2011-06-03 12:58:14 -050011741 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011742 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050011743 string[] field_names = _nestedMessageFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +010011744 if (nestedmessageRepeatedInt32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050011745 output.WriteArray(pbd::FieldType.Int32, 1, field_names[1], nestedmessageRepeatedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011746 }
csharptest90922db2011-06-03 11:57:47 -050011747 if (nestedmessageRepeatedForeignmessage_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050011748 output.WriteArray(pbd::FieldType.Message, 2, field_names[0], nestedmessageRepeatedForeignmessage_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011749 }
11750 UnknownFields.WriteTo(output);
11751 }
11752
11753 private int memoizedSerializedSize = -1;
11754 public override int SerializedSize {
11755 get {
11756 int size = memoizedSerializedSize;
11757 if (size != -1) return size;
11758
11759 size = 0;
11760 {
11761 int dataSize = 0;
11762 foreach (int element in NestedmessageRepeatedInt32List) {
11763 dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element);
11764 }
11765 size += dataSize;
11766 size += 1 * nestedmessageRepeatedInt32_.Count;
11767 }
11768 foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in NestedmessageRepeatedForeignmessageList) {
11769 size += pb::CodedOutputStream.ComputeMessageSize(2, element);
11770 }
11771 size += UnknownFields.SerializedSize;
11772 memoizedSerializedSize = size;
11773 return size;
11774 }
11775 }
11776
11777 public static NestedMessage ParseFrom(pb::ByteString data) {
11778 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
11779 }
11780 public static NestedMessage ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
11781 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
11782 }
11783 public static NestedMessage ParseFrom(byte[] data) {
11784 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
11785 }
11786 public static NestedMessage ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
11787 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
11788 }
11789 public static NestedMessage ParseFrom(global::System.IO.Stream input) {
11790 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
11791 }
11792 public static NestedMessage ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
11793 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
11794 }
11795 public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input) {
11796 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
11797 }
11798 public static NestedMessage ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
11799 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
11800 }
csharptest17699c22011-06-03 21:57:15 -050011801 public static NestedMessage ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011802 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
11803 }
csharptest17699c22011-06-03 21:57:15 -050011804 public static NestedMessage ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011805 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
11806 }
11807 public static Builder CreateBuilder() { return new Builder(); }
11808 public override Builder ToBuilder() { return CreateBuilder(this); }
11809 public override Builder CreateBuilderForType() { return new Builder(); }
11810 public static Builder CreateBuilder(NestedMessage prototype) {
11811 return (Builder) new Builder().MergeFrom(prototype);
11812 }
11813
csharptest445bdce2011-05-20 15:50:54 -050011814 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
11815 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
11816 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010011817 public sealed partial class Builder : pb::GeneratedBuilder<NestedMessage, Builder> {
11818 protected override Builder ThisBuilder {
11819 get { return this; }
11820 }
11821 public Builder() {}
11822
11823 NestedMessage result = new NestedMessage();
11824
11825 protected override NestedMessage MessageBeingBuilt {
11826 get { return result; }
11827 }
11828
11829 public override Builder Clear() {
11830 result = new NestedMessage();
11831 return this;
11832 }
11833
11834 public override Builder Clone() {
11835 return new Builder().MergeFrom(result);
11836 }
11837
11838 public override pbd::MessageDescriptor DescriptorForType {
11839 get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Descriptor; }
11840 }
11841
11842 public override NestedMessage DefaultInstanceForType {
11843 get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance; }
11844 }
11845
11846 public override NestedMessage BuildPartial() {
11847 if (result == null) {
11848 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
11849 }
11850 result.nestedmessageRepeatedInt32_.MakeReadOnly();
11851 result.nestedmessageRepeatedForeignmessage_.MakeReadOnly();
11852 NestedMessage returnMe = result;
11853 result = null;
11854 return returnMe;
11855 }
11856
11857 public override Builder MergeFrom(pb::IMessage other) {
11858 if (other is NestedMessage) {
11859 return MergeFrom((NestedMessage) other);
11860 } else {
11861 base.MergeFrom(other);
11862 return this;
11863 }
11864 }
11865
11866 public override Builder MergeFrom(NestedMessage other) {
11867 if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance) return this;
11868 if (other.nestedmessageRepeatedInt32_.Count != 0) {
11869 base.AddRange(other.nestedmessageRepeatedInt32_, result.nestedmessageRepeatedInt32_);
11870 }
11871 if (other.nestedmessageRepeatedForeignmessage_.Count != 0) {
11872 base.AddRange(other.nestedmessageRepeatedForeignmessage_, result.nestedmessageRepeatedForeignmessage_);
11873 }
11874 this.MergeUnknownFields(other.UnknownFields);
11875 return this;
11876 }
11877
csharptest17699c22011-06-03 21:57:15 -050011878 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011879 return MergeFrom(input, pb::ExtensionRegistry.Empty);
11880 }
11881
csharptest17699c22011-06-03 21:57:15 -050011882 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010011883 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050011884 uint tag;
11885 string field_name;
11886 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050011887 if(tag == 0 && field_name != null) {
11888 int field_ordinal = global::System.Array.BinarySearch(_nestedMessageFieldNames, field_name, global::System.StringComparer.Ordinal);
11889 if(field_ordinal >= 0)
11890 tag = _nestedMessageFieldTags[field_ordinal];
11891 else {
11892 if (unknownFields == null) {
11893 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
11894 }
11895 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
11896 continue;
11897 }
11898 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010011899 switch (tag) {
11900 case 0: {
csharptest99284412011-06-03 14:51:06 -050011901 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010011902 }
11903 default: {
11904 if (pb::WireFormat.IsEndGroupTag(tag)) {
11905 if (unknownFields != null) {
11906 this.UnknownFields = unknownFields.Build();
11907 }
11908 return this;
11909 }
11910 if (unknownFields == null) {
11911 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
11912 }
csharptestd2af9e92011-06-03 21:35:02 -050011913 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011914 break;
11915 }
csharptest6da31702011-06-04 12:52:57 -050011916 case 10:
Jon Skeet82bb0f12011-04-03 20:17:12 +010011917 case 8: {
csharptestd2af9e92011-06-03 21:35:02 -050011918 input.ReadPrimitiveArray(pbd::FieldType.Int32, tag, field_name, result.nestedmessageRepeatedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011919 break;
11920 }
11921 case 18: {
csharptestd2af9e92011-06-03 21:35:02 -050011922 input.ReadMessageArray(tag, field_name, result.nestedmessageRepeatedForeignmessage_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry);
Jon Skeet82bb0f12011-04-03 20:17:12 +010011923 break;
11924 }
11925 }
11926 }
csharptest123e5342011-06-03 14:15:21 -050011927
11928 if (unknownFields != null) {
11929 this.UnknownFields = unknownFields.Build();
11930 }
11931 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010011932 }
11933
11934
11935 public pbc::IPopsicleList<int> NestedmessageRepeatedInt32List {
11936 get { return result.nestedmessageRepeatedInt32_; }
11937 }
11938 public int NestedmessageRepeatedInt32Count {
11939 get { return result.NestedmessageRepeatedInt32Count; }
11940 }
11941 public int GetNestedmessageRepeatedInt32(int index) {
11942 return result.GetNestedmessageRepeatedInt32(index);
11943 }
11944 public Builder SetNestedmessageRepeatedInt32(int index, int value) {
11945 result.nestedmessageRepeatedInt32_[index] = value;
11946 return this;
11947 }
11948 public Builder AddNestedmessageRepeatedInt32(int value) {
11949 result.nestedmessageRepeatedInt32_.Add(value);
11950 return this;
11951 }
11952 public Builder AddRangeNestedmessageRepeatedInt32(scg::IEnumerable<int> values) {
11953 base.AddRange(values, result.nestedmessageRepeatedInt32_);
11954 return this;
11955 }
11956 public Builder ClearNestedmessageRepeatedInt32() {
11957 result.nestedmessageRepeatedInt32_.Clear();
11958 return this;
11959 }
11960
11961 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> NestedmessageRepeatedForeignmessageList {
11962 get { return result.nestedmessageRepeatedForeignmessage_; }
11963 }
11964 public int NestedmessageRepeatedForeignmessageCount {
11965 get { return result.NestedmessageRepeatedForeignmessageCount; }
11966 }
11967 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetNestedmessageRepeatedForeignmessage(int index) {
11968 return result.GetNestedmessageRepeatedForeignmessage(index);
11969 }
11970 public Builder SetNestedmessageRepeatedForeignmessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
11971 pb::ThrowHelper.ThrowIfNull(value, "value");
11972 result.nestedmessageRepeatedForeignmessage_[index] = value;
11973 return this;
11974 }
11975 public Builder SetNestedmessageRepeatedForeignmessage(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) {
11976 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
11977 result.nestedmessageRepeatedForeignmessage_[index] = builderForValue.Build();
11978 return this;
11979 }
11980 public Builder AddNestedmessageRepeatedForeignmessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
11981 pb::ThrowHelper.ThrowIfNull(value, "value");
11982 result.nestedmessageRepeatedForeignmessage_.Add(value);
11983 return this;
11984 }
11985 public Builder AddNestedmessageRepeatedForeignmessage(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) {
11986 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
11987 result.nestedmessageRepeatedForeignmessage_.Add(builderForValue.Build());
11988 return this;
11989 }
11990 public Builder AddRangeNestedmessageRepeatedForeignmessage(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> values) {
11991 base.AddRange(values, result.nestedmessageRepeatedForeignmessage_);
11992 return this;
11993 }
11994 public Builder ClearNestedmessageRepeatedForeignmessage() {
11995 result.nestedmessageRepeatedForeignmessage_.Clear();
11996 return this;
11997 }
11998 }
11999 static NestedMessage() {
12000 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
12001 }
12002 }
12003
12004 }
12005 #endregion
12006
12007 public const int OptionalNestedMessageFieldNumber = 1;
12008 private bool hasOptionalNestedMessage;
12009 private global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance;
12010 public bool HasOptionalNestedMessage {
12011 get { return hasOptionalNestedMessage; }
12012 }
12013 public global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage OptionalNestedMessage {
12014 get { return optionalNestedMessage_; }
12015 }
12016
12017 public override bool IsInitialized {
12018 get {
12019 return true;
12020 }
12021 }
12022
csharptestffafdaa2011-06-03 12:58:14 -050012023 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012024 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050012025 string[] field_names = _testNestedMessageHasBitsFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050012026 if (hasOptionalNestedMessage) {
csharptest920b09a2011-06-08 20:13:29 -050012027 output.WriteMessage(1, field_names[0], OptionalNestedMessage);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012028 }
12029 UnknownFields.WriteTo(output);
12030 }
12031
12032 private int memoizedSerializedSize = -1;
12033 public override int SerializedSize {
12034 get {
12035 int size = memoizedSerializedSize;
12036 if (size != -1) return size;
12037
12038 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050012039 if (hasOptionalNestedMessage) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012040 size += pb::CodedOutputStream.ComputeMessageSize(1, OptionalNestedMessage);
12041 }
12042 size += UnknownFields.SerializedSize;
12043 memoizedSerializedSize = size;
12044 return size;
12045 }
12046 }
12047
12048 public static TestNestedMessageHasBits ParseFrom(pb::ByteString data) {
12049 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
12050 }
12051 public static TestNestedMessageHasBits ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
12052 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
12053 }
12054 public static TestNestedMessageHasBits ParseFrom(byte[] data) {
12055 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
12056 }
12057 public static TestNestedMessageHasBits ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
12058 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
12059 }
12060 public static TestNestedMessageHasBits ParseFrom(global::System.IO.Stream input) {
12061 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
12062 }
12063 public static TestNestedMessageHasBits ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
12064 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
12065 }
12066 public static TestNestedMessageHasBits ParseDelimitedFrom(global::System.IO.Stream input) {
12067 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
12068 }
12069 public static TestNestedMessageHasBits ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
12070 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
12071 }
csharptest17699c22011-06-03 21:57:15 -050012072 public static TestNestedMessageHasBits ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012073 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
12074 }
csharptest17699c22011-06-03 21:57:15 -050012075 public static TestNestedMessageHasBits ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012076 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
12077 }
12078 public static Builder CreateBuilder() { return new Builder(); }
12079 public override Builder ToBuilder() { return CreateBuilder(this); }
12080 public override Builder CreateBuilderForType() { return new Builder(); }
12081 public static Builder CreateBuilder(TestNestedMessageHasBits prototype) {
12082 return (Builder) new Builder().MergeFrom(prototype);
12083 }
12084
csharptest445bdce2011-05-20 15:50:54 -050012085 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
12086 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
12087 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010012088 public sealed partial class Builder : pb::GeneratedBuilder<TestNestedMessageHasBits, Builder> {
12089 protected override Builder ThisBuilder {
12090 get { return this; }
12091 }
12092 public Builder() {}
12093
12094 TestNestedMessageHasBits result = new TestNestedMessageHasBits();
12095
12096 protected override TestNestedMessageHasBits MessageBeingBuilt {
12097 get { return result; }
12098 }
12099
12100 public override Builder Clear() {
12101 result = new TestNestedMessageHasBits();
12102 return this;
12103 }
12104
12105 public override Builder Clone() {
12106 return new Builder().MergeFrom(result);
12107 }
12108
12109 public override pbd::MessageDescriptor DescriptorForType {
12110 get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Descriptor; }
12111 }
12112
12113 public override TestNestedMessageHasBits DefaultInstanceForType {
12114 get { return global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.DefaultInstance; }
12115 }
12116
12117 public override TestNestedMessageHasBits BuildPartial() {
12118 if (result == null) {
12119 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
12120 }
12121 TestNestedMessageHasBits returnMe = result;
12122 result = null;
12123 return returnMe;
12124 }
12125
12126 public override Builder MergeFrom(pb::IMessage other) {
12127 if (other is TestNestedMessageHasBits) {
12128 return MergeFrom((TestNestedMessageHasBits) other);
12129 } else {
12130 base.MergeFrom(other);
12131 return this;
12132 }
12133 }
12134
12135 public override Builder MergeFrom(TestNestedMessageHasBits other) {
12136 if (other == global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.DefaultInstance) return this;
12137 if (other.HasOptionalNestedMessage) {
12138 MergeOptionalNestedMessage(other.OptionalNestedMessage);
12139 }
12140 this.MergeUnknownFields(other.UnknownFields);
12141 return this;
12142 }
12143
csharptest17699c22011-06-03 21:57:15 -050012144 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012145 return MergeFrom(input, pb::ExtensionRegistry.Empty);
12146 }
12147
csharptest17699c22011-06-03 21:57:15 -050012148 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012149 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050012150 uint tag;
12151 string field_name;
12152 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050012153 if(tag == 0 && field_name != null) {
12154 int field_ordinal = global::System.Array.BinarySearch(_testNestedMessageHasBitsFieldNames, field_name, global::System.StringComparer.Ordinal);
12155 if(field_ordinal >= 0)
12156 tag = _testNestedMessageHasBitsFieldTags[field_ordinal];
12157 else {
12158 if (unknownFields == null) {
12159 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
12160 }
12161 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
12162 continue;
12163 }
12164 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010012165 switch (tag) {
12166 case 0: {
csharptest99284412011-06-03 14:51:06 -050012167 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010012168 }
12169 default: {
12170 if (pb::WireFormat.IsEndGroupTag(tag)) {
12171 if (unknownFields != null) {
12172 this.UnknownFields = unknownFields.Build();
12173 }
12174 return this;
12175 }
12176 if (unknownFields == null) {
12177 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
12178 }
csharptestd2af9e92011-06-03 21:35:02 -050012179 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012180 break;
12181 }
12182 case 10: {
12183 global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -050012184 if (result.hasOptionalNestedMessage) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012185 subBuilder.MergeFrom(OptionalNestedMessage);
12186 }
12187 input.ReadMessage(subBuilder, extensionRegistry);
12188 OptionalNestedMessage = subBuilder.BuildPartial();
12189 break;
12190 }
12191 }
12192 }
csharptest123e5342011-06-03 14:15:21 -050012193
12194 if (unknownFields != null) {
12195 this.UnknownFields = unknownFields.Build();
12196 }
12197 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010012198 }
12199
12200
12201 public bool HasOptionalNestedMessage {
csharptestc671a4b2011-06-08 11:51:24 -050012202 get { return result.hasOptionalNestedMessage; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010012203 }
12204 public global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage OptionalNestedMessage {
12205 get { return result.OptionalNestedMessage; }
12206 set { SetOptionalNestedMessage(value); }
12207 }
12208 public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage value) {
12209 pb::ThrowHelper.ThrowIfNull(value, "value");
12210 result.hasOptionalNestedMessage = true;
12211 result.optionalNestedMessage_ = value;
12212 return this;
12213 }
12214 public Builder SetOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.Builder builderForValue) {
12215 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
12216 result.hasOptionalNestedMessage = true;
12217 result.optionalNestedMessage_ = builderForValue.Build();
12218 return this;
12219 }
12220 public Builder MergeOptionalNestedMessage(global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage value) {
12221 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -050012222 if (result.hasOptionalNestedMessage &&
Jon Skeet82bb0f12011-04-03 20:17:12 +010012223 result.optionalNestedMessage_ != global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance) {
12224 result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.CreateBuilder(result.optionalNestedMessage_).MergeFrom(value).BuildPartial();
12225 } else {
12226 result.optionalNestedMessage_ = value;
12227 }
12228 result.hasOptionalNestedMessage = true;
12229 return this;
12230 }
12231 public Builder ClearOptionalNestedMessage() {
12232 result.hasOptionalNestedMessage = false;
12233 result.optionalNestedMessage_ = global::Google.ProtocolBuffers.TestProtos.TestNestedMessageHasBits.Types.NestedMessage.DefaultInstance;
12234 return this;
12235 }
12236 }
12237 static TestNestedMessageHasBits() {
12238 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
12239 }
12240 }
12241
csharptest445bdce2011-05-20 15:50:54 -050012242 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
12243 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
12244 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010012245 public sealed partial class TestCamelCaseFieldNames : pb::GeneratedMessage<TestCamelCaseFieldNames, TestCamelCaseFieldNames.Builder> {
12246 private static readonly TestCamelCaseFieldNames defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050012247 private static readonly string[] _testCamelCaseFieldNamesFieldNames = new string[] { "CordField", "EnumField", "MessageField", "PrimitiveField", "RepeatedCordField", "RepeatedEnumField", "RepeatedMessageField", "RepeatedPrimitiveField", "RepeatedStringField", "RepeatedStringPieceField", "StringField", "StringPieceField" };
12248 private static readonly uint[] _testCamelCaseFieldNamesFieldTags = new uint[] { 50, 24, 34, 8, 98, 72, 82, 56, 66, 90, 18, 42 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010012249 public static TestCamelCaseFieldNames DefaultInstance {
12250 get { return defaultInstance; }
12251 }
12252
12253 public override TestCamelCaseFieldNames DefaultInstanceForType {
12254 get { return defaultInstance; }
12255 }
12256
12257 protected override TestCamelCaseFieldNames ThisMessage {
12258 get { return this; }
12259 }
12260
12261 public static pbd::MessageDescriptor Descriptor {
12262 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestCamelCaseFieldNames__Descriptor; }
12263 }
12264
12265 protected override pb::FieldAccess.FieldAccessorTable<TestCamelCaseFieldNames, TestCamelCaseFieldNames.Builder> InternalFieldAccessors {
12266 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestCamelCaseFieldNames__FieldAccessorTable; }
12267 }
12268
12269 public const int PrimitiveFieldFieldNumber = 1;
12270 private bool hasPrimitiveField;
csharptestced18e12011-06-09 19:47:56 -050012271 private int primitiveField_;
Jon Skeet82bb0f12011-04-03 20:17:12 +010012272 public bool HasPrimitiveField {
12273 get { return hasPrimitiveField; }
12274 }
12275 public int PrimitiveField {
12276 get { return primitiveField_; }
12277 }
12278
12279 public const int StringFieldFieldNumber = 2;
12280 private bool hasStringField;
12281 private string stringField_ = "";
12282 public bool HasStringField {
12283 get { return hasStringField; }
12284 }
12285 public string StringField {
12286 get { return stringField_; }
12287 }
12288
12289 public const int EnumFieldFieldNumber = 3;
12290 private bool hasEnumField;
12291 private global::Google.ProtocolBuffers.TestProtos.ForeignEnum enumField_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO;
12292 public bool HasEnumField {
12293 get { return hasEnumField; }
12294 }
12295 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumField {
12296 get { return enumField_; }
12297 }
12298
12299 public const int MessageFieldFieldNumber = 4;
12300 private bool hasMessageField;
12301 private global::Google.ProtocolBuffers.TestProtos.ForeignMessage messageField_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance;
12302 public bool HasMessageField {
12303 get { return hasMessageField; }
12304 }
12305 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageField {
12306 get { return messageField_; }
12307 }
12308
12309 public const int StringPieceFieldFieldNumber = 5;
12310 private bool hasStringPieceField;
12311 private string stringPieceField_ = "";
12312 public bool HasStringPieceField {
12313 get { return hasStringPieceField; }
12314 }
12315 public string StringPieceField {
12316 get { return stringPieceField_; }
12317 }
12318
12319 public const int CordFieldFieldNumber = 6;
12320 private bool hasCordField;
12321 private string cordField_ = "";
12322 public bool HasCordField {
12323 get { return hasCordField; }
12324 }
12325 public string CordField {
12326 get { return cordField_; }
12327 }
12328
12329 public const int RepeatedPrimitiveFieldFieldNumber = 7;
12330 private pbc::PopsicleList<int> repeatedPrimitiveField_ = new pbc::PopsicleList<int>();
12331 public scg::IList<int> RepeatedPrimitiveFieldList {
12332 get { return pbc::Lists.AsReadOnly(repeatedPrimitiveField_); }
12333 }
12334 public int RepeatedPrimitiveFieldCount {
12335 get { return repeatedPrimitiveField_.Count; }
12336 }
12337 public int GetRepeatedPrimitiveField(int index) {
12338 return repeatedPrimitiveField_[index];
12339 }
12340
12341 public const int RepeatedStringFieldFieldNumber = 8;
12342 private pbc::PopsicleList<string> repeatedStringField_ = new pbc::PopsicleList<string>();
12343 public scg::IList<string> RepeatedStringFieldList {
12344 get { return pbc::Lists.AsReadOnly(repeatedStringField_); }
12345 }
12346 public int RepeatedStringFieldCount {
12347 get { return repeatedStringField_.Count; }
12348 }
12349 public string GetRepeatedStringField(int index) {
12350 return repeatedStringField_[index];
12351 }
12352
12353 public const int RepeatedEnumFieldFieldNumber = 9;
12354 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> repeatedEnumField_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>();
12355 public scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> RepeatedEnumFieldList {
12356 get { return pbc::Lists.AsReadOnly(repeatedEnumField_); }
12357 }
12358 public int RepeatedEnumFieldCount {
12359 get { return repeatedEnumField_.Count; }
12360 }
12361 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedEnumField(int index) {
12362 return repeatedEnumField_[index];
12363 }
12364
12365 public const int RepeatedMessageFieldFieldNumber = 10;
12366 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> repeatedMessageField_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage>();
12367 public scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> RepeatedMessageFieldList {
12368 get { return repeatedMessageField_; }
12369 }
12370 public int RepeatedMessageFieldCount {
12371 get { return repeatedMessageField_.Count; }
12372 }
12373 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedMessageField(int index) {
12374 return repeatedMessageField_[index];
12375 }
12376
12377 public const int RepeatedStringPieceFieldFieldNumber = 11;
12378 private pbc::PopsicleList<string> repeatedStringPieceField_ = new pbc::PopsicleList<string>();
12379 public scg::IList<string> RepeatedStringPieceFieldList {
12380 get { return pbc::Lists.AsReadOnly(repeatedStringPieceField_); }
12381 }
12382 public int RepeatedStringPieceFieldCount {
12383 get { return repeatedStringPieceField_.Count; }
12384 }
12385 public string GetRepeatedStringPieceField(int index) {
12386 return repeatedStringPieceField_[index];
12387 }
12388
12389 public const int RepeatedCordFieldFieldNumber = 12;
12390 private pbc::PopsicleList<string> repeatedCordField_ = new pbc::PopsicleList<string>();
12391 public scg::IList<string> RepeatedCordFieldList {
12392 get { return pbc::Lists.AsReadOnly(repeatedCordField_); }
12393 }
12394 public int RepeatedCordFieldCount {
12395 get { return repeatedCordField_.Count; }
12396 }
12397 public string GetRepeatedCordField(int index) {
12398 return repeatedCordField_[index];
12399 }
12400
12401 public override bool IsInitialized {
12402 get {
12403 return true;
12404 }
12405 }
12406
csharptestffafdaa2011-06-03 12:58:14 -050012407 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012408 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050012409 string[] field_names = _testCamelCaseFieldNamesFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050012410 if (hasPrimitiveField) {
csharptest920b09a2011-06-08 20:13:29 -050012411 output.WriteInt32(1, field_names[3], PrimitiveField);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012412 }
csharptestc671a4b2011-06-08 11:51:24 -050012413 if (hasStringField) {
csharptest920b09a2011-06-08 20:13:29 -050012414 output.WriteString(2, field_names[10], StringField);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012415 }
csharptestc671a4b2011-06-08 11:51:24 -050012416 if (hasEnumField) {
csharptestced18e12011-06-09 19:47:56 -050012417 output.WriteEnum(3, field_names[1], (int) EnumField, EnumField);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012418 }
csharptestc671a4b2011-06-08 11:51:24 -050012419 if (hasMessageField) {
csharptest920b09a2011-06-08 20:13:29 -050012420 output.WriteMessage(4, field_names[2], MessageField);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012421 }
csharptestc671a4b2011-06-08 11:51:24 -050012422 if (hasStringPieceField) {
csharptest920b09a2011-06-08 20:13:29 -050012423 output.WriteString(5, field_names[11], StringPieceField);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012424 }
csharptestc671a4b2011-06-08 11:51:24 -050012425 if (hasCordField) {
csharptest920b09a2011-06-08 20:13:29 -050012426 output.WriteString(6, field_names[0], CordField);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012427 }
12428 if (repeatedPrimitiveField_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050012429 output.WriteArray(pbd::FieldType.Int32, 7, field_names[7], repeatedPrimitiveField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012430 }
12431 if (repeatedStringField_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050012432 output.WriteArray(pbd::FieldType.String, 8, field_names[8], repeatedStringField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012433 }
12434 if (repeatedEnumField_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050012435 output.WriteArray(pbd::FieldType.Enum, 9, field_names[5], repeatedEnumField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012436 }
csharptest90922db2011-06-03 11:57:47 -050012437 if (repeatedMessageField_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050012438 output.WriteArray(pbd::FieldType.Message, 10, field_names[6], repeatedMessageField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012439 }
12440 if (repeatedStringPieceField_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050012441 output.WriteArray(pbd::FieldType.String, 11, field_names[9], repeatedStringPieceField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012442 }
12443 if (repeatedCordField_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050012444 output.WriteArray(pbd::FieldType.String, 12, field_names[4], repeatedCordField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012445 }
12446 UnknownFields.WriteTo(output);
12447 }
12448
12449 private int memoizedSerializedSize = -1;
12450 public override int SerializedSize {
12451 get {
12452 int size = memoizedSerializedSize;
12453 if (size != -1) return size;
12454
12455 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050012456 if (hasPrimitiveField) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012457 size += pb::CodedOutputStream.ComputeInt32Size(1, PrimitiveField);
12458 }
csharptestc671a4b2011-06-08 11:51:24 -050012459 if (hasStringField) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012460 size += pb::CodedOutputStream.ComputeStringSize(2, StringField);
12461 }
csharptestc671a4b2011-06-08 11:51:24 -050012462 if (hasEnumField) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012463 size += pb::CodedOutputStream.ComputeEnumSize(3, (int) EnumField);
12464 }
csharptestc671a4b2011-06-08 11:51:24 -050012465 if (hasMessageField) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012466 size += pb::CodedOutputStream.ComputeMessageSize(4, MessageField);
12467 }
csharptestc671a4b2011-06-08 11:51:24 -050012468 if (hasStringPieceField) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012469 size += pb::CodedOutputStream.ComputeStringSize(5, StringPieceField);
12470 }
csharptestc671a4b2011-06-08 11:51:24 -050012471 if (hasCordField) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012472 size += pb::CodedOutputStream.ComputeStringSize(6, CordField);
12473 }
12474 {
12475 int dataSize = 0;
12476 foreach (int element in RepeatedPrimitiveFieldList) {
12477 dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element);
12478 }
12479 size += dataSize;
12480 size += 1 * repeatedPrimitiveField_.Count;
12481 }
12482 {
12483 int dataSize = 0;
12484 foreach (string element in RepeatedStringFieldList) {
12485 dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element);
12486 }
12487 size += dataSize;
12488 size += 1 * repeatedStringField_.Count;
12489 }
12490 {
12491 int dataSize = 0;
12492 if (repeatedEnumField_.Count > 0) {
12493 foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in repeatedEnumField_) {
12494 dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element);
12495 }
12496 size += dataSize;
12497 size += 1 * repeatedEnumField_.Count;
12498 }
12499 }
12500 foreach (global::Google.ProtocolBuffers.TestProtos.ForeignMessage element in RepeatedMessageFieldList) {
12501 size += pb::CodedOutputStream.ComputeMessageSize(10, element);
12502 }
12503 {
12504 int dataSize = 0;
12505 foreach (string element in RepeatedStringPieceFieldList) {
12506 dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element);
12507 }
12508 size += dataSize;
12509 size += 1 * repeatedStringPieceField_.Count;
12510 }
12511 {
12512 int dataSize = 0;
12513 foreach (string element in RepeatedCordFieldList) {
12514 dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element);
12515 }
12516 size += dataSize;
12517 size += 1 * repeatedCordField_.Count;
12518 }
12519 size += UnknownFields.SerializedSize;
12520 memoizedSerializedSize = size;
12521 return size;
12522 }
12523 }
12524
12525 public static TestCamelCaseFieldNames ParseFrom(pb::ByteString data) {
12526 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
12527 }
12528 public static TestCamelCaseFieldNames ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
12529 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
12530 }
12531 public static TestCamelCaseFieldNames ParseFrom(byte[] data) {
12532 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
12533 }
12534 public static TestCamelCaseFieldNames ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
12535 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
12536 }
12537 public static TestCamelCaseFieldNames ParseFrom(global::System.IO.Stream input) {
12538 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
12539 }
12540 public static TestCamelCaseFieldNames ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
12541 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
12542 }
12543 public static TestCamelCaseFieldNames ParseDelimitedFrom(global::System.IO.Stream input) {
12544 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
12545 }
12546 public static TestCamelCaseFieldNames ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
12547 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
12548 }
csharptest17699c22011-06-03 21:57:15 -050012549 public static TestCamelCaseFieldNames ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012550 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
12551 }
csharptest17699c22011-06-03 21:57:15 -050012552 public static TestCamelCaseFieldNames ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012553 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
12554 }
12555 public static Builder CreateBuilder() { return new Builder(); }
12556 public override Builder ToBuilder() { return CreateBuilder(this); }
12557 public override Builder CreateBuilderForType() { return new Builder(); }
12558 public static Builder CreateBuilder(TestCamelCaseFieldNames prototype) {
12559 return (Builder) new Builder().MergeFrom(prototype);
12560 }
12561
csharptest445bdce2011-05-20 15:50:54 -050012562 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
12563 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
12564 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010012565 public sealed partial class Builder : pb::GeneratedBuilder<TestCamelCaseFieldNames, Builder> {
12566 protected override Builder ThisBuilder {
12567 get { return this; }
12568 }
12569 public Builder() {}
12570
12571 TestCamelCaseFieldNames result = new TestCamelCaseFieldNames();
12572
12573 protected override TestCamelCaseFieldNames MessageBeingBuilt {
12574 get { return result; }
12575 }
12576
12577 public override Builder Clear() {
12578 result = new TestCamelCaseFieldNames();
12579 return this;
12580 }
12581
12582 public override Builder Clone() {
12583 return new Builder().MergeFrom(result);
12584 }
12585
12586 public override pbd::MessageDescriptor DescriptorForType {
12587 get { return global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.Descriptor; }
12588 }
12589
12590 public override TestCamelCaseFieldNames DefaultInstanceForType {
12591 get { return global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.DefaultInstance; }
12592 }
12593
12594 public override TestCamelCaseFieldNames BuildPartial() {
12595 if (result == null) {
12596 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
12597 }
12598 result.repeatedPrimitiveField_.MakeReadOnly();
12599 result.repeatedStringField_.MakeReadOnly();
12600 result.repeatedEnumField_.MakeReadOnly();
12601 result.repeatedMessageField_.MakeReadOnly();
12602 result.repeatedStringPieceField_.MakeReadOnly();
12603 result.repeatedCordField_.MakeReadOnly();
12604 TestCamelCaseFieldNames returnMe = result;
12605 result = null;
12606 return returnMe;
12607 }
12608
12609 public override Builder MergeFrom(pb::IMessage other) {
12610 if (other is TestCamelCaseFieldNames) {
12611 return MergeFrom((TestCamelCaseFieldNames) other);
12612 } else {
12613 base.MergeFrom(other);
12614 return this;
12615 }
12616 }
12617
12618 public override Builder MergeFrom(TestCamelCaseFieldNames other) {
12619 if (other == global::Google.ProtocolBuffers.TestProtos.TestCamelCaseFieldNames.DefaultInstance) return this;
12620 if (other.HasPrimitiveField) {
12621 PrimitiveField = other.PrimitiveField;
12622 }
12623 if (other.HasStringField) {
12624 StringField = other.StringField;
12625 }
12626 if (other.HasEnumField) {
12627 EnumField = other.EnumField;
12628 }
12629 if (other.HasMessageField) {
12630 MergeMessageField(other.MessageField);
12631 }
12632 if (other.HasStringPieceField) {
12633 StringPieceField = other.StringPieceField;
12634 }
12635 if (other.HasCordField) {
12636 CordField = other.CordField;
12637 }
12638 if (other.repeatedPrimitiveField_.Count != 0) {
12639 base.AddRange(other.repeatedPrimitiveField_, result.repeatedPrimitiveField_);
12640 }
12641 if (other.repeatedStringField_.Count != 0) {
12642 base.AddRange(other.repeatedStringField_, result.repeatedStringField_);
12643 }
12644 if (other.repeatedEnumField_.Count != 0) {
12645 base.AddRange(other.repeatedEnumField_, result.repeatedEnumField_);
12646 }
12647 if (other.repeatedMessageField_.Count != 0) {
12648 base.AddRange(other.repeatedMessageField_, result.repeatedMessageField_);
12649 }
12650 if (other.repeatedStringPieceField_.Count != 0) {
12651 base.AddRange(other.repeatedStringPieceField_, result.repeatedStringPieceField_);
12652 }
12653 if (other.repeatedCordField_.Count != 0) {
12654 base.AddRange(other.repeatedCordField_, result.repeatedCordField_);
12655 }
12656 this.MergeUnknownFields(other.UnknownFields);
12657 return this;
12658 }
12659
csharptest17699c22011-06-03 21:57:15 -050012660 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012661 return MergeFrom(input, pb::ExtensionRegistry.Empty);
12662 }
12663
csharptest17699c22011-06-03 21:57:15 -050012664 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012665 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050012666 uint tag;
12667 string field_name;
12668 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050012669 if(tag == 0 && field_name != null) {
12670 int field_ordinal = global::System.Array.BinarySearch(_testCamelCaseFieldNamesFieldNames, field_name, global::System.StringComparer.Ordinal);
12671 if(field_ordinal >= 0)
12672 tag = _testCamelCaseFieldNamesFieldTags[field_ordinal];
12673 else {
12674 if (unknownFields == null) {
12675 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
12676 }
12677 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
12678 continue;
12679 }
12680 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010012681 switch (tag) {
12682 case 0: {
csharptest99284412011-06-03 14:51:06 -050012683 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010012684 }
12685 default: {
12686 if (pb::WireFormat.IsEndGroupTag(tag)) {
12687 if (unknownFields != null) {
12688 this.UnknownFields = unknownFields.Build();
12689 }
12690 return this;
12691 }
12692 if (unknownFields == null) {
12693 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
12694 }
csharptestd2af9e92011-06-03 21:35:02 -050012695 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012696 break;
12697 }
12698 case 8: {
csharptest920b09a2011-06-08 20:13:29 -050012699 result.hasPrimitiveField = input.ReadInt32(ref result.primitiveField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012700 break;
12701 }
12702 case 18: {
csharptest920b09a2011-06-08 20:13:29 -050012703 result.hasStringField = input.ReadString(ref result.stringField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012704 break;
12705 }
12706 case 24: {
csharptestd2af9e92011-06-03 21:35:02 -050012707 object unknown;
12708 if(input.ReadEnum(ref result.enumField_, out unknown)) {
12709 result.hasEnumField = true;
12710 } else if(unknown is int) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012711 if (unknownFields == null) {
12712 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
12713 }
csharptestd2af9e92011-06-03 21:35:02 -050012714 unknownFields.MergeVarintField(3, (ulong)(int)unknown);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012715 }
12716 break;
12717 }
12718 case 34: {
12719 global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -050012720 if (result.hasMessageField) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012721 subBuilder.MergeFrom(MessageField);
12722 }
12723 input.ReadMessage(subBuilder, extensionRegistry);
12724 MessageField = subBuilder.BuildPartial();
12725 break;
12726 }
12727 case 42: {
csharptest920b09a2011-06-08 20:13:29 -050012728 result.hasStringPieceField = input.ReadString(ref result.stringPieceField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012729 break;
12730 }
12731 case 50: {
csharptest920b09a2011-06-08 20:13:29 -050012732 result.hasCordField = input.ReadString(ref result.cordField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012733 break;
12734 }
csharptest6da31702011-06-04 12:52:57 -050012735 case 58:
Jon Skeet82bb0f12011-04-03 20:17:12 +010012736 case 56: {
csharptestd2af9e92011-06-03 21:35:02 -050012737 input.ReadPrimitiveArray(pbd::FieldType.Int32, tag, field_name, result.repeatedPrimitiveField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012738 break;
12739 }
12740 case 66: {
csharptestd2af9e92011-06-03 21:35:02 -050012741 input.ReadPrimitiveArray(pbd::FieldType.String, tag, field_name, result.repeatedStringField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012742 break;
12743 }
csharptest6da31702011-06-04 12:52:57 -050012744 case 74:
Jon Skeet82bb0f12011-04-03 20:17:12 +010012745 case 72: {
csharptestd2af9e92011-06-03 21:35:02 -050012746 scg::ICollection<object> unknownItems;
12747 input.ReadEnumArray<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>(tag, field_name, result.repeatedEnumField_, out unknownItems);
12748 if (unknownItems != null) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010012749 if (unknownFields == null) {
12750 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
12751 }
csharptestd2af9e92011-06-03 21:35:02 -050012752 foreach (object rawValue in unknownItems)
12753 if (rawValue is int)
12754 unknownFields.MergeVarintField(9, (ulong)(int)rawValue);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012755 }
12756 break;
12757 }
12758 case 82: {
csharptestd2af9e92011-06-03 21:35:02 -050012759 input.ReadMessageArray(tag, field_name, result.repeatedMessageField_, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance, extensionRegistry);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012760 break;
12761 }
12762 case 90: {
csharptestd2af9e92011-06-03 21:35:02 -050012763 input.ReadPrimitiveArray(pbd::FieldType.String, tag, field_name, result.repeatedStringPieceField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012764 break;
12765 }
12766 case 98: {
csharptestd2af9e92011-06-03 21:35:02 -050012767 input.ReadPrimitiveArray(pbd::FieldType.String, tag, field_name, result.repeatedCordField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010012768 break;
12769 }
12770 }
12771 }
csharptest123e5342011-06-03 14:15:21 -050012772
12773 if (unknownFields != null) {
12774 this.UnknownFields = unknownFields.Build();
12775 }
12776 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010012777 }
12778
12779
12780 public bool HasPrimitiveField {
csharptestc671a4b2011-06-08 11:51:24 -050012781 get { return result.hasPrimitiveField; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010012782 }
12783 public int PrimitiveField {
12784 get { return result.PrimitiveField; }
12785 set { SetPrimitiveField(value); }
12786 }
12787 public Builder SetPrimitiveField(int value) {
12788 result.hasPrimitiveField = true;
12789 result.primitiveField_ = value;
12790 return this;
12791 }
12792 public Builder ClearPrimitiveField() {
12793 result.hasPrimitiveField = false;
12794 result.primitiveField_ = 0;
12795 return this;
12796 }
12797
12798 public bool HasStringField {
csharptestc671a4b2011-06-08 11:51:24 -050012799 get { return result.hasStringField; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010012800 }
12801 public string StringField {
12802 get { return result.StringField; }
12803 set { SetStringField(value); }
12804 }
12805 public Builder SetStringField(string value) {
12806 pb::ThrowHelper.ThrowIfNull(value, "value");
12807 result.hasStringField = true;
12808 result.stringField_ = value;
12809 return this;
12810 }
12811 public Builder ClearStringField() {
12812 result.hasStringField = false;
12813 result.stringField_ = "";
12814 return this;
12815 }
12816
12817 public bool HasEnumField {
csharptestc671a4b2011-06-08 11:51:24 -050012818 get { return result.hasEnumField; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010012819 }
12820 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumField {
12821 get { return result.EnumField; }
12822 set { SetEnumField(value); }
12823 }
12824 public Builder SetEnumField(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
12825 result.hasEnumField = true;
12826 result.enumField_ = value;
12827 return this;
12828 }
12829 public Builder ClearEnumField() {
12830 result.hasEnumField = false;
12831 result.enumField_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO;
12832 return this;
12833 }
12834
12835 public bool HasMessageField {
csharptestc671a4b2011-06-08 11:51:24 -050012836 get { return result.hasMessageField; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010012837 }
12838 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageField {
12839 get { return result.MessageField; }
12840 set { SetMessageField(value); }
12841 }
12842 public Builder SetMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
12843 pb::ThrowHelper.ThrowIfNull(value, "value");
12844 result.hasMessageField = true;
12845 result.messageField_ = value;
12846 return this;
12847 }
12848 public Builder SetMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) {
12849 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
12850 result.hasMessageField = true;
12851 result.messageField_ = builderForValue.Build();
12852 return this;
12853 }
12854 public Builder MergeMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
12855 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -050012856 if (result.hasMessageField &&
Jon Skeet82bb0f12011-04-03 20:17:12 +010012857 result.messageField_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) {
12858 result.messageField_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.messageField_).MergeFrom(value).BuildPartial();
12859 } else {
12860 result.messageField_ = value;
12861 }
12862 result.hasMessageField = true;
12863 return this;
12864 }
12865 public Builder ClearMessageField() {
12866 result.hasMessageField = false;
12867 result.messageField_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance;
12868 return this;
12869 }
12870
12871 public bool HasStringPieceField {
csharptestc671a4b2011-06-08 11:51:24 -050012872 get { return result.hasStringPieceField; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010012873 }
12874 public string StringPieceField {
12875 get { return result.StringPieceField; }
12876 set { SetStringPieceField(value); }
12877 }
12878 public Builder SetStringPieceField(string value) {
12879 pb::ThrowHelper.ThrowIfNull(value, "value");
12880 result.hasStringPieceField = true;
12881 result.stringPieceField_ = value;
12882 return this;
12883 }
12884 public Builder ClearStringPieceField() {
12885 result.hasStringPieceField = false;
12886 result.stringPieceField_ = "";
12887 return this;
12888 }
12889
12890 public bool HasCordField {
csharptestc671a4b2011-06-08 11:51:24 -050012891 get { return result.hasCordField; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010012892 }
12893 public string CordField {
12894 get { return result.CordField; }
12895 set { SetCordField(value); }
12896 }
12897 public Builder SetCordField(string value) {
12898 pb::ThrowHelper.ThrowIfNull(value, "value");
12899 result.hasCordField = true;
12900 result.cordField_ = value;
12901 return this;
12902 }
12903 public Builder ClearCordField() {
12904 result.hasCordField = false;
12905 result.cordField_ = "";
12906 return this;
12907 }
12908
12909 public pbc::IPopsicleList<int> RepeatedPrimitiveFieldList {
12910 get { return result.repeatedPrimitiveField_; }
12911 }
12912 public int RepeatedPrimitiveFieldCount {
12913 get { return result.RepeatedPrimitiveFieldCount; }
12914 }
12915 public int GetRepeatedPrimitiveField(int index) {
12916 return result.GetRepeatedPrimitiveField(index);
12917 }
12918 public Builder SetRepeatedPrimitiveField(int index, int value) {
12919 result.repeatedPrimitiveField_[index] = value;
12920 return this;
12921 }
12922 public Builder AddRepeatedPrimitiveField(int value) {
12923 result.repeatedPrimitiveField_.Add(value);
12924 return this;
12925 }
12926 public Builder AddRangeRepeatedPrimitiveField(scg::IEnumerable<int> values) {
12927 base.AddRange(values, result.repeatedPrimitiveField_);
12928 return this;
12929 }
12930 public Builder ClearRepeatedPrimitiveField() {
12931 result.repeatedPrimitiveField_.Clear();
12932 return this;
12933 }
12934
12935 public pbc::IPopsicleList<string> RepeatedStringFieldList {
12936 get { return result.repeatedStringField_; }
12937 }
12938 public int RepeatedStringFieldCount {
12939 get { return result.RepeatedStringFieldCount; }
12940 }
12941 public string GetRepeatedStringField(int index) {
12942 return result.GetRepeatedStringField(index);
12943 }
12944 public Builder SetRepeatedStringField(int index, string value) {
12945 pb::ThrowHelper.ThrowIfNull(value, "value");
12946 result.repeatedStringField_[index] = value;
12947 return this;
12948 }
12949 public Builder AddRepeatedStringField(string value) {
12950 pb::ThrowHelper.ThrowIfNull(value, "value");
12951 result.repeatedStringField_.Add(value);
12952 return this;
12953 }
12954 public Builder AddRangeRepeatedStringField(scg::IEnumerable<string> values) {
12955 base.AddRange(values, result.repeatedStringField_);
12956 return this;
12957 }
12958 public Builder ClearRepeatedStringField() {
12959 result.repeatedStringField_.Clear();
12960 return this;
12961 }
12962
12963 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> RepeatedEnumFieldList {
12964 get { return result.repeatedEnumField_; }
12965 }
12966 public int RepeatedEnumFieldCount {
12967 get { return result.RepeatedEnumFieldCount; }
12968 }
12969 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetRepeatedEnumField(int index) {
12970 return result.GetRepeatedEnumField(index);
12971 }
12972 public Builder SetRepeatedEnumField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
12973 result.repeatedEnumField_[index] = value;
12974 return this;
12975 }
12976 public Builder AddRepeatedEnumField(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
12977 result.repeatedEnumField_.Add(value);
12978 return this;
12979 }
12980 public Builder AddRangeRepeatedEnumField(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> values) {
12981 base.AddRange(values, result.repeatedEnumField_);
12982 return this;
12983 }
12984 public Builder ClearRepeatedEnumField() {
12985 result.repeatedEnumField_.Clear();
12986 return this;
12987 }
12988
12989 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> RepeatedMessageFieldList {
12990 get { return result.repeatedMessageField_; }
12991 }
12992 public int RepeatedMessageFieldCount {
12993 get { return result.RepeatedMessageFieldCount; }
12994 }
12995 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage GetRepeatedMessageField(int index) {
12996 return result.GetRepeatedMessageField(index);
12997 }
12998 public Builder SetRepeatedMessageField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
12999 pb::ThrowHelper.ThrowIfNull(value, "value");
13000 result.repeatedMessageField_[index] = value;
13001 return this;
13002 }
13003 public Builder SetRepeatedMessageField(int index, global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) {
13004 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
13005 result.repeatedMessageField_[index] = builderForValue.Build();
13006 return this;
13007 }
13008 public Builder AddRepeatedMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
13009 pb::ThrowHelper.ThrowIfNull(value, "value");
13010 result.repeatedMessageField_.Add(value);
13011 return this;
13012 }
13013 public Builder AddRepeatedMessageField(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) {
13014 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
13015 result.repeatedMessageField_.Add(builderForValue.Build());
13016 return this;
13017 }
13018 public Builder AddRangeRepeatedMessageField(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.ForeignMessage> values) {
13019 base.AddRange(values, result.repeatedMessageField_);
13020 return this;
13021 }
13022 public Builder ClearRepeatedMessageField() {
13023 result.repeatedMessageField_.Clear();
13024 return this;
13025 }
13026
13027 public pbc::IPopsicleList<string> RepeatedStringPieceFieldList {
13028 get { return result.repeatedStringPieceField_; }
13029 }
13030 public int RepeatedStringPieceFieldCount {
13031 get { return result.RepeatedStringPieceFieldCount; }
13032 }
13033 public string GetRepeatedStringPieceField(int index) {
13034 return result.GetRepeatedStringPieceField(index);
13035 }
13036 public Builder SetRepeatedStringPieceField(int index, string value) {
13037 pb::ThrowHelper.ThrowIfNull(value, "value");
13038 result.repeatedStringPieceField_[index] = value;
13039 return this;
13040 }
13041 public Builder AddRepeatedStringPieceField(string value) {
13042 pb::ThrowHelper.ThrowIfNull(value, "value");
13043 result.repeatedStringPieceField_.Add(value);
13044 return this;
13045 }
13046 public Builder AddRangeRepeatedStringPieceField(scg::IEnumerable<string> values) {
13047 base.AddRange(values, result.repeatedStringPieceField_);
13048 return this;
13049 }
13050 public Builder ClearRepeatedStringPieceField() {
13051 result.repeatedStringPieceField_.Clear();
13052 return this;
13053 }
13054
13055 public pbc::IPopsicleList<string> RepeatedCordFieldList {
13056 get { return result.repeatedCordField_; }
13057 }
13058 public int RepeatedCordFieldCount {
13059 get { return result.RepeatedCordFieldCount; }
13060 }
13061 public string GetRepeatedCordField(int index) {
13062 return result.GetRepeatedCordField(index);
13063 }
13064 public Builder SetRepeatedCordField(int index, string value) {
13065 pb::ThrowHelper.ThrowIfNull(value, "value");
13066 result.repeatedCordField_[index] = value;
13067 return this;
13068 }
13069 public Builder AddRepeatedCordField(string value) {
13070 pb::ThrowHelper.ThrowIfNull(value, "value");
13071 result.repeatedCordField_.Add(value);
13072 return this;
13073 }
13074 public Builder AddRangeRepeatedCordField(scg::IEnumerable<string> values) {
13075 base.AddRange(values, result.repeatedCordField_);
13076 return this;
13077 }
13078 public Builder ClearRepeatedCordField() {
13079 result.repeatedCordField_.Clear();
13080 return this;
13081 }
13082 }
13083 static TestCamelCaseFieldNames() {
13084 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
13085 }
13086 }
13087
csharptest445bdce2011-05-20 15:50:54 -050013088 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
13089 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
13090 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010013091 public sealed partial class TestFieldOrderings : pb::ExtendableMessage<TestFieldOrderings, TestFieldOrderings.Builder> {
13092 private static readonly TestFieldOrderings defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050013093 private static readonly string[] _testFieldOrderingsFieldNames = new string[] { "my_float", "my_int", "my_string" };
13094 private static readonly uint[] _testFieldOrderingsFieldTags = new uint[] { 813, 8, 90 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010013095 public static TestFieldOrderings DefaultInstance {
13096 get { return defaultInstance; }
13097 }
13098
13099 public override TestFieldOrderings DefaultInstanceForType {
13100 get { return defaultInstance; }
13101 }
13102
13103 protected override TestFieldOrderings ThisMessage {
13104 get { return this; }
13105 }
13106
13107 public static pbd::MessageDescriptor Descriptor {
13108 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestFieldOrderings__Descriptor; }
13109 }
13110
13111 protected override pb::FieldAccess.FieldAccessorTable<TestFieldOrderings, TestFieldOrderings.Builder> InternalFieldAccessors {
13112 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestFieldOrderings__FieldAccessorTable; }
13113 }
13114
13115 public const int MyStringFieldNumber = 11;
13116 private bool hasMyString;
13117 private string myString_ = "";
13118 public bool HasMyString {
13119 get { return hasMyString; }
13120 }
13121 public string MyString {
13122 get { return myString_; }
13123 }
13124
13125 public const int MyIntFieldNumber = 1;
13126 private bool hasMyInt;
csharptestced18e12011-06-09 19:47:56 -050013127 private long myInt_;
Jon Skeet82bb0f12011-04-03 20:17:12 +010013128 public bool HasMyInt {
13129 get { return hasMyInt; }
13130 }
13131 public long MyInt {
13132 get { return myInt_; }
13133 }
13134
13135 public const int MyFloatFieldNumber = 101;
13136 private bool hasMyFloat;
csharptestced18e12011-06-09 19:47:56 -050013137 private float myFloat_;
Jon Skeet82bb0f12011-04-03 20:17:12 +010013138 public bool HasMyFloat {
13139 get { return hasMyFloat; }
13140 }
13141 public float MyFloat {
13142 get { return myFloat_; }
13143 }
13144
13145 public override bool IsInitialized {
13146 get {
13147 if (!ExtensionsAreInitialized) return false;
13148 return true;
13149 }
13150 }
13151
csharptestffafdaa2011-06-03 12:58:14 -050013152 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013153 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050013154 string[] field_names = _testFieldOrderingsFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +010013155 pb::ExtendableMessage<TestFieldOrderings, TestFieldOrderings.Builder>.ExtensionWriter extensionWriter = CreateExtensionWriter(this);
csharptestc671a4b2011-06-08 11:51:24 -050013156 if (hasMyInt) {
csharptest920b09a2011-06-08 20:13:29 -050013157 output.WriteInt64(1, field_names[1], MyInt);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013158 }
13159 extensionWriter.WriteUntil(11, output);
csharptestc671a4b2011-06-08 11:51:24 -050013160 if (hasMyString) {
csharptest920b09a2011-06-08 20:13:29 -050013161 output.WriteString(11, field_names[2], MyString);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013162 }
13163 extensionWriter.WriteUntil(101, output);
csharptestc671a4b2011-06-08 11:51:24 -050013164 if (hasMyFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013165 output.WriteFloat(101, field_names[0], MyFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013166 }
13167 UnknownFields.WriteTo(output);
13168 }
13169
13170 private int memoizedSerializedSize = -1;
13171 public override int SerializedSize {
13172 get {
13173 int size = memoizedSerializedSize;
13174 if (size != -1) return size;
13175
13176 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050013177 if (hasMyString) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013178 size += pb::CodedOutputStream.ComputeStringSize(11, MyString);
13179 }
csharptestc671a4b2011-06-08 11:51:24 -050013180 if (hasMyInt) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013181 size += pb::CodedOutputStream.ComputeInt64Size(1, MyInt);
13182 }
csharptestc671a4b2011-06-08 11:51:24 -050013183 if (hasMyFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013184 size += pb::CodedOutputStream.ComputeFloatSize(101, MyFloat);
13185 }
13186 size += ExtensionsSerializedSize;
13187 size += UnknownFields.SerializedSize;
13188 memoizedSerializedSize = size;
13189 return size;
13190 }
13191 }
13192
13193 public static TestFieldOrderings ParseFrom(pb::ByteString data) {
13194 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
13195 }
13196 public static TestFieldOrderings ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
13197 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
13198 }
13199 public static TestFieldOrderings ParseFrom(byte[] data) {
13200 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
13201 }
13202 public static TestFieldOrderings ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
13203 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
13204 }
13205 public static TestFieldOrderings ParseFrom(global::System.IO.Stream input) {
13206 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
13207 }
13208 public static TestFieldOrderings ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
13209 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
13210 }
13211 public static TestFieldOrderings ParseDelimitedFrom(global::System.IO.Stream input) {
13212 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
13213 }
13214 public static TestFieldOrderings ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
13215 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
13216 }
csharptest17699c22011-06-03 21:57:15 -050013217 public static TestFieldOrderings ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013218 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
13219 }
csharptest17699c22011-06-03 21:57:15 -050013220 public static TestFieldOrderings ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013221 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
13222 }
13223 public static Builder CreateBuilder() { return new Builder(); }
13224 public override Builder ToBuilder() { return CreateBuilder(this); }
13225 public override Builder CreateBuilderForType() { return new Builder(); }
13226 public static Builder CreateBuilder(TestFieldOrderings prototype) {
13227 return (Builder) new Builder().MergeFrom(prototype);
13228 }
13229
csharptest445bdce2011-05-20 15:50:54 -050013230 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
13231 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
13232 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010013233 public sealed partial class Builder : pb::ExtendableBuilder<TestFieldOrderings, Builder> {
13234 protected override Builder ThisBuilder {
13235 get { return this; }
13236 }
13237 public Builder() {}
13238
13239 TestFieldOrderings result = new TestFieldOrderings();
13240
13241 protected override TestFieldOrderings MessageBeingBuilt {
13242 get { return result; }
13243 }
13244
13245 public override Builder Clear() {
13246 result = new TestFieldOrderings();
13247 return this;
13248 }
13249
13250 public override Builder Clone() {
13251 return new Builder().MergeFrom(result);
13252 }
13253
13254 public override pbd::MessageDescriptor DescriptorForType {
13255 get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.Descriptor; }
13256 }
13257
13258 public override TestFieldOrderings DefaultInstanceForType {
13259 get { return global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.DefaultInstance; }
13260 }
13261
13262 public override TestFieldOrderings BuildPartial() {
13263 if (result == null) {
13264 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
13265 }
13266 TestFieldOrderings returnMe = result;
13267 result = null;
13268 return returnMe;
13269 }
13270
13271 public override Builder MergeFrom(pb::IMessage other) {
13272 if (other is TestFieldOrderings) {
13273 return MergeFrom((TestFieldOrderings) other);
13274 } else {
13275 base.MergeFrom(other);
13276 return this;
13277 }
13278 }
13279
13280 public override Builder MergeFrom(TestFieldOrderings other) {
13281 if (other == global::Google.ProtocolBuffers.TestProtos.TestFieldOrderings.DefaultInstance) return this;
13282 if (other.HasMyString) {
13283 MyString = other.MyString;
13284 }
13285 if (other.HasMyInt) {
13286 MyInt = other.MyInt;
13287 }
13288 if (other.HasMyFloat) {
13289 MyFloat = other.MyFloat;
13290 }
13291 this.MergeExtensionFields(other);
13292 this.MergeUnknownFields(other.UnknownFields);
13293 return this;
13294 }
13295
csharptest17699c22011-06-03 21:57:15 -050013296 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013297 return MergeFrom(input, pb::ExtensionRegistry.Empty);
13298 }
13299
csharptest17699c22011-06-03 21:57:15 -050013300 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013301 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050013302 uint tag;
13303 string field_name;
13304 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050013305 if(tag == 0 && field_name != null) {
13306 int field_ordinal = global::System.Array.BinarySearch(_testFieldOrderingsFieldNames, field_name, global::System.StringComparer.Ordinal);
13307 if(field_ordinal >= 0)
13308 tag = _testFieldOrderingsFieldTags[field_ordinal];
13309 else {
13310 if (unknownFields == null) {
13311 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
13312 }
13313 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
13314 continue;
13315 }
13316 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010013317 switch (tag) {
13318 case 0: {
csharptest99284412011-06-03 14:51:06 -050013319 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010013320 }
13321 default: {
13322 if (pb::WireFormat.IsEndGroupTag(tag)) {
13323 if (unknownFields != null) {
13324 this.UnknownFields = unknownFields.Build();
13325 }
13326 return this;
13327 }
13328 if (unknownFields == null) {
13329 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
13330 }
csharptestd2af9e92011-06-03 21:35:02 -050013331 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013332 break;
13333 }
13334 case 8: {
csharptest920b09a2011-06-08 20:13:29 -050013335 result.hasMyInt = input.ReadInt64(ref result.myInt_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013336 break;
13337 }
13338 case 90: {
csharptest920b09a2011-06-08 20:13:29 -050013339 result.hasMyString = input.ReadString(ref result.myString_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013340 break;
13341 }
13342 case 813: {
csharptest920b09a2011-06-08 20:13:29 -050013343 result.hasMyFloat = input.ReadFloat(ref result.myFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013344 break;
13345 }
13346 }
13347 }
csharptest123e5342011-06-03 14:15:21 -050013348
13349 if (unknownFields != null) {
13350 this.UnknownFields = unknownFields.Build();
13351 }
13352 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010013353 }
13354
13355
13356 public bool HasMyString {
csharptestc671a4b2011-06-08 11:51:24 -050013357 get { return result.hasMyString; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010013358 }
13359 public string MyString {
13360 get { return result.MyString; }
13361 set { SetMyString(value); }
13362 }
13363 public Builder SetMyString(string value) {
13364 pb::ThrowHelper.ThrowIfNull(value, "value");
13365 result.hasMyString = true;
13366 result.myString_ = value;
13367 return this;
13368 }
13369 public Builder ClearMyString() {
13370 result.hasMyString = false;
13371 result.myString_ = "";
13372 return this;
13373 }
13374
13375 public bool HasMyInt {
csharptestc671a4b2011-06-08 11:51:24 -050013376 get { return result.hasMyInt; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010013377 }
13378 public long MyInt {
13379 get { return result.MyInt; }
13380 set { SetMyInt(value); }
13381 }
13382 public Builder SetMyInt(long value) {
13383 result.hasMyInt = true;
13384 result.myInt_ = value;
13385 return this;
13386 }
13387 public Builder ClearMyInt() {
13388 result.hasMyInt = false;
13389 result.myInt_ = 0L;
13390 return this;
13391 }
13392
13393 public bool HasMyFloat {
csharptestc671a4b2011-06-08 11:51:24 -050013394 get { return result.hasMyFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010013395 }
13396 public float MyFloat {
13397 get { return result.MyFloat; }
13398 set { SetMyFloat(value); }
13399 }
13400 public Builder SetMyFloat(float value) {
13401 result.hasMyFloat = true;
13402 result.myFloat_ = value;
13403 return this;
13404 }
13405 public Builder ClearMyFloat() {
13406 result.hasMyFloat = false;
13407 result.myFloat_ = 0F;
13408 return this;
13409 }
13410 }
13411 static TestFieldOrderings() {
13412 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
13413 }
13414 }
13415
csharptest445bdce2011-05-20 15:50:54 -050013416 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
13417 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
13418 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010013419 public sealed partial class TestExtremeDefaultValues : pb::GeneratedMessage<TestExtremeDefaultValues, TestExtremeDefaultValues.Builder> {
13420 private static readonly TestExtremeDefaultValues defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050013421 private static readonly string[] _testExtremeDefaultValuesFieldNames = new string[] { "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" };
13422 private static readonly uint[] _testExtremeDefaultValuesFieldTags = new uint[] { 10, 113, 141, 101, 16, 24, 129, 157, 121, 149, 93, 85, 69, 77, 32, 40, 109, 50, 61 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010013423 public static TestExtremeDefaultValues DefaultInstance {
13424 get { return defaultInstance; }
13425 }
13426
13427 public override TestExtremeDefaultValues DefaultInstanceForType {
13428 get { return defaultInstance; }
13429 }
13430
13431 protected override TestExtremeDefaultValues ThisMessage {
13432 get { return this; }
13433 }
13434
13435 public static pbd::MessageDescriptor Descriptor {
13436 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestExtremeDefaultValues__Descriptor; }
13437 }
13438
13439 protected override pb::FieldAccess.FieldAccessorTable<TestExtremeDefaultValues, TestExtremeDefaultValues.Builder> InternalFieldAccessors {
13440 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestExtremeDefaultValues__FieldAccessorTable; }
13441 }
13442
13443 public const int EscapedBytesFieldNumber = 1;
13444 private bool hasEscapedBytes;
13445 private pb::ByteString escapedBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[0].DefaultValue;
13446 public bool HasEscapedBytes {
13447 get { return hasEscapedBytes; }
13448 }
13449 public pb::ByteString EscapedBytes {
13450 get { return escapedBytes_; }
13451 }
13452
13453 public const int LargeUint32FieldNumber = 2;
13454 private bool hasLargeUint32;
13455 private uint largeUint32_ = 4294967295;
13456 public bool HasLargeUint32 {
13457 get { return hasLargeUint32; }
13458 }
13459 [global::System.CLSCompliant(false)]
13460 public uint LargeUint32 {
13461 get { return largeUint32_; }
13462 }
13463
13464 public const int LargeUint64FieldNumber = 3;
13465 private bool hasLargeUint64;
13466 private ulong largeUint64_ = 18446744073709551615UL;
13467 public bool HasLargeUint64 {
13468 get { return hasLargeUint64; }
13469 }
13470 [global::System.CLSCompliant(false)]
13471 public ulong LargeUint64 {
13472 get { return largeUint64_; }
13473 }
13474
13475 public const int SmallInt32FieldNumber = 4;
13476 private bool hasSmallInt32;
13477 private int smallInt32_ = -2147483647;
13478 public bool HasSmallInt32 {
13479 get { return hasSmallInt32; }
13480 }
13481 public int SmallInt32 {
13482 get { return smallInt32_; }
13483 }
13484
13485 public const int SmallInt64FieldNumber = 5;
13486 private bool hasSmallInt64;
13487 private long smallInt64_ = -9223372036854775807L;
13488 public bool HasSmallInt64 {
13489 get { return hasSmallInt64; }
13490 }
13491 public long SmallInt64 {
13492 get { return smallInt64_; }
13493 }
13494
13495 public const int Utf8StringFieldNumber = 6;
13496 private bool hasUtf8String;
13497 private string utf8String_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[5].DefaultValue;
13498 public bool HasUtf8String {
13499 get { return hasUtf8String; }
13500 }
13501 public string Utf8String {
13502 get { return utf8String_; }
13503 }
13504
13505 public const int ZeroFloatFieldNumber = 7;
13506 private bool hasZeroFloat;
csharptestced18e12011-06-09 19:47:56 -050013507 private float zeroFloat_;
Jon Skeet82bb0f12011-04-03 20:17:12 +010013508 public bool HasZeroFloat {
13509 get { return hasZeroFloat; }
13510 }
13511 public float ZeroFloat {
13512 get { return zeroFloat_; }
13513 }
13514
13515 public const int OneFloatFieldNumber = 8;
13516 private bool hasOneFloat;
13517 private float oneFloat_ = 1F;
13518 public bool HasOneFloat {
13519 get { return hasOneFloat; }
13520 }
13521 public float OneFloat {
13522 get { return oneFloat_; }
13523 }
13524
13525 public const int SmallFloatFieldNumber = 9;
13526 private bool hasSmallFloat;
13527 private float smallFloat_ = 1.5F;
13528 public bool HasSmallFloat {
13529 get { return hasSmallFloat; }
13530 }
13531 public float SmallFloat {
13532 get { return smallFloat_; }
13533 }
13534
13535 public const int NegativeOneFloatFieldNumber = 10;
13536 private bool hasNegativeOneFloat;
13537 private float negativeOneFloat_ = -1F;
13538 public bool HasNegativeOneFloat {
13539 get { return hasNegativeOneFloat; }
13540 }
13541 public float NegativeOneFloat {
13542 get { return negativeOneFloat_; }
13543 }
13544
13545 public const int NegativeFloatFieldNumber = 11;
13546 private bool hasNegativeFloat;
13547 private float negativeFloat_ = -1.5F;
13548 public bool HasNegativeFloat {
13549 get { return hasNegativeFloat; }
13550 }
13551 public float NegativeFloat {
13552 get { return negativeFloat_; }
13553 }
13554
13555 public const int LargeFloatFieldNumber = 12;
13556 private bool hasLargeFloat;
13557 private float largeFloat_ = 2E+08F;
13558 public bool HasLargeFloat {
13559 get { return hasLargeFloat; }
13560 }
13561 public float LargeFloat {
13562 get { return largeFloat_; }
13563 }
13564
13565 public const int SmallNegativeFloatFieldNumber = 13;
13566 private bool hasSmallNegativeFloat;
13567 private float smallNegativeFloat_ = -8E-28F;
13568 public bool HasSmallNegativeFloat {
13569 get { return hasSmallNegativeFloat; }
13570 }
13571 public float SmallNegativeFloat {
13572 get { return smallNegativeFloat_; }
13573 }
13574
13575 public const int InfDoubleFieldNumber = 14;
13576 private bool hasInfDouble;
13577 private double infDouble_ = double.PositiveInfinity;
13578 public bool HasInfDouble {
13579 get { return hasInfDouble; }
13580 }
13581 public double InfDouble {
13582 get { return infDouble_; }
13583 }
13584
13585 public const int NegInfDoubleFieldNumber = 15;
13586 private bool hasNegInfDouble;
13587 private double negInfDouble_ = double.NegativeInfinity;
13588 public bool HasNegInfDouble {
13589 get { return hasNegInfDouble; }
13590 }
13591 public double NegInfDouble {
13592 get { return negInfDouble_; }
13593 }
13594
13595 public const int NanDoubleFieldNumber = 16;
13596 private bool hasNanDouble;
13597 private double nanDouble_ = double.NaN;
13598 public bool HasNanDouble {
13599 get { return hasNanDouble; }
13600 }
13601 public double NanDouble {
13602 get { return nanDouble_; }
13603 }
13604
13605 public const int InfFloatFieldNumber = 17;
13606 private bool hasInfFloat;
13607 private float infFloat_ = float.PositiveInfinity;
13608 public bool HasInfFloat {
13609 get { return hasInfFloat; }
13610 }
13611 public float InfFloat {
13612 get { return infFloat_; }
13613 }
13614
13615 public const int NegInfFloatFieldNumber = 18;
13616 private bool hasNegInfFloat;
13617 private float negInfFloat_ = float.NegativeInfinity;
13618 public bool HasNegInfFloat {
13619 get { return hasNegInfFloat; }
13620 }
13621 public float NegInfFloat {
13622 get { return negInfFloat_; }
13623 }
13624
13625 public const int NanFloatFieldNumber = 19;
13626 private bool hasNanFloat;
13627 private float nanFloat_ = float.NaN;
13628 public bool HasNanFloat {
13629 get { return hasNanFloat; }
13630 }
13631 public float NanFloat {
13632 get { return nanFloat_; }
13633 }
13634
13635 public override bool IsInitialized {
13636 get {
13637 return true;
13638 }
13639 }
13640
csharptestffafdaa2011-06-03 12:58:14 -050013641 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013642 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050013643 string[] field_names = _testExtremeDefaultValuesFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050013644 if (hasEscapedBytes) {
csharptest920b09a2011-06-08 20:13:29 -050013645 output.WriteBytes(1, field_names[0], EscapedBytes);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013646 }
csharptestc671a4b2011-06-08 11:51:24 -050013647 if (hasLargeUint32) {
csharptest920b09a2011-06-08 20:13:29 -050013648 output.WriteUInt32(2, field_names[4], LargeUint32);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013649 }
csharptestc671a4b2011-06-08 11:51:24 -050013650 if (hasLargeUint64) {
csharptest920b09a2011-06-08 20:13:29 -050013651 output.WriteUInt64(3, field_names[5], LargeUint64);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013652 }
csharptestc671a4b2011-06-08 11:51:24 -050013653 if (hasSmallInt32) {
csharptest920b09a2011-06-08 20:13:29 -050013654 output.WriteInt32(4, field_names[14], SmallInt32);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013655 }
csharptestc671a4b2011-06-08 11:51:24 -050013656 if (hasSmallInt64) {
csharptest920b09a2011-06-08 20:13:29 -050013657 output.WriteInt64(5, field_names[15], SmallInt64);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013658 }
csharptestc671a4b2011-06-08 11:51:24 -050013659 if (hasUtf8String) {
csharptest920b09a2011-06-08 20:13:29 -050013660 output.WriteString(6, field_names[17], Utf8String);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013661 }
csharptestc671a4b2011-06-08 11:51:24 -050013662 if (hasZeroFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013663 output.WriteFloat(7, field_names[18], ZeroFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013664 }
csharptestc671a4b2011-06-08 11:51:24 -050013665 if (hasOneFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013666 output.WriteFloat(8, field_names[12], OneFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013667 }
csharptestc671a4b2011-06-08 11:51:24 -050013668 if (hasSmallFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013669 output.WriteFloat(9, field_names[13], SmallFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013670 }
csharptestc671a4b2011-06-08 11:51:24 -050013671 if (hasNegativeOneFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013672 output.WriteFloat(10, field_names[11], NegativeOneFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013673 }
csharptestc671a4b2011-06-08 11:51:24 -050013674 if (hasNegativeFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013675 output.WriteFloat(11, field_names[10], NegativeFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013676 }
csharptestc671a4b2011-06-08 11:51:24 -050013677 if (hasLargeFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013678 output.WriteFloat(12, field_names[3], LargeFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013679 }
csharptestc671a4b2011-06-08 11:51:24 -050013680 if (hasSmallNegativeFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013681 output.WriteFloat(13, field_names[16], SmallNegativeFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013682 }
csharptestc671a4b2011-06-08 11:51:24 -050013683 if (hasInfDouble) {
csharptest920b09a2011-06-08 20:13:29 -050013684 output.WriteDouble(14, field_names[1], InfDouble);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013685 }
csharptestc671a4b2011-06-08 11:51:24 -050013686 if (hasNegInfDouble) {
csharptest920b09a2011-06-08 20:13:29 -050013687 output.WriteDouble(15, field_names[8], NegInfDouble);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013688 }
csharptestc671a4b2011-06-08 11:51:24 -050013689 if (hasNanDouble) {
csharptest920b09a2011-06-08 20:13:29 -050013690 output.WriteDouble(16, field_names[6], NanDouble);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013691 }
csharptestc671a4b2011-06-08 11:51:24 -050013692 if (hasInfFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013693 output.WriteFloat(17, field_names[2], InfFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013694 }
csharptestc671a4b2011-06-08 11:51:24 -050013695 if (hasNegInfFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013696 output.WriteFloat(18, field_names[9], NegInfFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013697 }
csharptestc671a4b2011-06-08 11:51:24 -050013698 if (hasNanFloat) {
csharptest920b09a2011-06-08 20:13:29 -050013699 output.WriteFloat(19, field_names[7], NanFloat);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013700 }
13701 UnknownFields.WriteTo(output);
13702 }
13703
13704 private int memoizedSerializedSize = -1;
13705 public override int SerializedSize {
13706 get {
13707 int size = memoizedSerializedSize;
13708 if (size != -1) return size;
13709
13710 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050013711 if (hasEscapedBytes) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013712 size += pb::CodedOutputStream.ComputeBytesSize(1, EscapedBytes);
13713 }
csharptestc671a4b2011-06-08 11:51:24 -050013714 if (hasLargeUint32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013715 size += pb::CodedOutputStream.ComputeUInt32Size(2, LargeUint32);
13716 }
csharptestc671a4b2011-06-08 11:51:24 -050013717 if (hasLargeUint64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013718 size += pb::CodedOutputStream.ComputeUInt64Size(3, LargeUint64);
13719 }
csharptestc671a4b2011-06-08 11:51:24 -050013720 if (hasSmallInt32) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013721 size += pb::CodedOutputStream.ComputeInt32Size(4, SmallInt32);
13722 }
csharptestc671a4b2011-06-08 11:51:24 -050013723 if (hasSmallInt64) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013724 size += pb::CodedOutputStream.ComputeInt64Size(5, SmallInt64);
13725 }
csharptestc671a4b2011-06-08 11:51:24 -050013726 if (hasUtf8String) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013727 size += pb::CodedOutputStream.ComputeStringSize(6, Utf8String);
13728 }
csharptestc671a4b2011-06-08 11:51:24 -050013729 if (hasZeroFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013730 size += pb::CodedOutputStream.ComputeFloatSize(7, ZeroFloat);
13731 }
csharptestc671a4b2011-06-08 11:51:24 -050013732 if (hasOneFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013733 size += pb::CodedOutputStream.ComputeFloatSize(8, OneFloat);
13734 }
csharptestc671a4b2011-06-08 11:51:24 -050013735 if (hasSmallFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013736 size += pb::CodedOutputStream.ComputeFloatSize(9, SmallFloat);
13737 }
csharptestc671a4b2011-06-08 11:51:24 -050013738 if (hasNegativeOneFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013739 size += pb::CodedOutputStream.ComputeFloatSize(10, NegativeOneFloat);
13740 }
csharptestc671a4b2011-06-08 11:51:24 -050013741 if (hasNegativeFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013742 size += pb::CodedOutputStream.ComputeFloatSize(11, NegativeFloat);
13743 }
csharptestc671a4b2011-06-08 11:51:24 -050013744 if (hasLargeFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013745 size += pb::CodedOutputStream.ComputeFloatSize(12, LargeFloat);
13746 }
csharptestc671a4b2011-06-08 11:51:24 -050013747 if (hasSmallNegativeFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013748 size += pb::CodedOutputStream.ComputeFloatSize(13, SmallNegativeFloat);
13749 }
csharptestc671a4b2011-06-08 11:51:24 -050013750 if (hasInfDouble) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013751 size += pb::CodedOutputStream.ComputeDoubleSize(14, InfDouble);
13752 }
csharptestc671a4b2011-06-08 11:51:24 -050013753 if (hasNegInfDouble) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013754 size += pb::CodedOutputStream.ComputeDoubleSize(15, NegInfDouble);
13755 }
csharptestc671a4b2011-06-08 11:51:24 -050013756 if (hasNanDouble) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013757 size += pb::CodedOutputStream.ComputeDoubleSize(16, NanDouble);
13758 }
csharptestc671a4b2011-06-08 11:51:24 -050013759 if (hasInfFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013760 size += pb::CodedOutputStream.ComputeFloatSize(17, InfFloat);
13761 }
csharptestc671a4b2011-06-08 11:51:24 -050013762 if (hasNegInfFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013763 size += pb::CodedOutputStream.ComputeFloatSize(18, NegInfFloat);
13764 }
csharptestc671a4b2011-06-08 11:51:24 -050013765 if (hasNanFloat) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013766 size += pb::CodedOutputStream.ComputeFloatSize(19, NanFloat);
13767 }
13768 size += UnknownFields.SerializedSize;
13769 memoizedSerializedSize = size;
13770 return size;
13771 }
13772 }
13773
13774 public static TestExtremeDefaultValues ParseFrom(pb::ByteString data) {
13775 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
13776 }
13777 public static TestExtremeDefaultValues ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
13778 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
13779 }
13780 public static TestExtremeDefaultValues ParseFrom(byte[] data) {
13781 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
13782 }
13783 public static TestExtremeDefaultValues ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
13784 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
13785 }
13786 public static TestExtremeDefaultValues ParseFrom(global::System.IO.Stream input) {
13787 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
13788 }
13789 public static TestExtremeDefaultValues ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
13790 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
13791 }
13792 public static TestExtremeDefaultValues ParseDelimitedFrom(global::System.IO.Stream input) {
13793 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
13794 }
13795 public static TestExtremeDefaultValues ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
13796 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
13797 }
csharptest17699c22011-06-03 21:57:15 -050013798 public static TestExtremeDefaultValues ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013799 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
13800 }
csharptest17699c22011-06-03 21:57:15 -050013801 public static TestExtremeDefaultValues ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013802 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
13803 }
13804 public static Builder CreateBuilder() { return new Builder(); }
13805 public override Builder ToBuilder() { return CreateBuilder(this); }
13806 public override Builder CreateBuilderForType() { return new Builder(); }
13807 public static Builder CreateBuilder(TestExtremeDefaultValues prototype) {
13808 return (Builder) new Builder().MergeFrom(prototype);
13809 }
13810
csharptest445bdce2011-05-20 15:50:54 -050013811 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
13812 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
13813 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010013814 public sealed partial class Builder : pb::GeneratedBuilder<TestExtremeDefaultValues, Builder> {
13815 protected override Builder ThisBuilder {
13816 get { return this; }
13817 }
13818 public Builder() {}
13819
13820 TestExtremeDefaultValues result = new TestExtremeDefaultValues();
13821
13822 protected override TestExtremeDefaultValues MessageBeingBuilt {
13823 get { return result; }
13824 }
13825
13826 public override Builder Clear() {
13827 result = new TestExtremeDefaultValues();
13828 return this;
13829 }
13830
13831 public override Builder Clone() {
13832 return new Builder().MergeFrom(result);
13833 }
13834
13835 public override pbd::MessageDescriptor DescriptorForType {
13836 get { return global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor; }
13837 }
13838
13839 public override TestExtremeDefaultValues DefaultInstanceForType {
13840 get { return global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.DefaultInstance; }
13841 }
13842
13843 public override TestExtremeDefaultValues BuildPartial() {
13844 if (result == null) {
13845 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
13846 }
13847 TestExtremeDefaultValues returnMe = result;
13848 result = null;
13849 return returnMe;
13850 }
13851
13852 public override Builder MergeFrom(pb::IMessage other) {
13853 if (other is TestExtremeDefaultValues) {
13854 return MergeFrom((TestExtremeDefaultValues) other);
13855 } else {
13856 base.MergeFrom(other);
13857 return this;
13858 }
13859 }
13860
13861 public override Builder MergeFrom(TestExtremeDefaultValues other) {
13862 if (other == global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.DefaultInstance) return this;
13863 if (other.HasEscapedBytes) {
13864 EscapedBytes = other.EscapedBytes;
13865 }
13866 if (other.HasLargeUint32) {
13867 LargeUint32 = other.LargeUint32;
13868 }
13869 if (other.HasLargeUint64) {
13870 LargeUint64 = other.LargeUint64;
13871 }
13872 if (other.HasSmallInt32) {
13873 SmallInt32 = other.SmallInt32;
13874 }
13875 if (other.HasSmallInt64) {
13876 SmallInt64 = other.SmallInt64;
13877 }
13878 if (other.HasUtf8String) {
13879 Utf8String = other.Utf8String;
13880 }
13881 if (other.HasZeroFloat) {
13882 ZeroFloat = other.ZeroFloat;
13883 }
13884 if (other.HasOneFloat) {
13885 OneFloat = other.OneFloat;
13886 }
13887 if (other.HasSmallFloat) {
13888 SmallFloat = other.SmallFloat;
13889 }
13890 if (other.HasNegativeOneFloat) {
13891 NegativeOneFloat = other.NegativeOneFloat;
13892 }
13893 if (other.HasNegativeFloat) {
13894 NegativeFloat = other.NegativeFloat;
13895 }
13896 if (other.HasLargeFloat) {
13897 LargeFloat = other.LargeFloat;
13898 }
13899 if (other.HasSmallNegativeFloat) {
13900 SmallNegativeFloat = other.SmallNegativeFloat;
13901 }
13902 if (other.HasInfDouble) {
13903 InfDouble = other.InfDouble;
13904 }
13905 if (other.HasNegInfDouble) {
13906 NegInfDouble = other.NegInfDouble;
13907 }
13908 if (other.HasNanDouble) {
13909 NanDouble = other.NanDouble;
13910 }
13911 if (other.HasInfFloat) {
13912 InfFloat = other.InfFloat;
13913 }
13914 if (other.HasNegInfFloat) {
13915 NegInfFloat = other.NegInfFloat;
13916 }
13917 if (other.HasNanFloat) {
13918 NanFloat = other.NanFloat;
13919 }
13920 this.MergeUnknownFields(other.UnknownFields);
13921 return this;
13922 }
13923
csharptest17699c22011-06-03 21:57:15 -050013924 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013925 return MergeFrom(input, pb::ExtensionRegistry.Empty);
13926 }
13927
csharptest17699c22011-06-03 21:57:15 -050013928 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010013929 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050013930 uint tag;
13931 string field_name;
13932 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050013933 if(tag == 0 && field_name != null) {
13934 int field_ordinal = global::System.Array.BinarySearch(_testExtremeDefaultValuesFieldNames, field_name, global::System.StringComparer.Ordinal);
13935 if(field_ordinal >= 0)
13936 tag = _testExtremeDefaultValuesFieldTags[field_ordinal];
13937 else {
13938 if (unknownFields == null) {
13939 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
13940 }
13941 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
13942 continue;
13943 }
13944 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010013945 switch (tag) {
13946 case 0: {
csharptest99284412011-06-03 14:51:06 -050013947 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010013948 }
13949 default: {
13950 if (pb::WireFormat.IsEndGroupTag(tag)) {
13951 if (unknownFields != null) {
13952 this.UnknownFields = unknownFields.Build();
13953 }
13954 return this;
13955 }
13956 if (unknownFields == null) {
13957 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
13958 }
csharptestd2af9e92011-06-03 21:35:02 -050013959 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013960 break;
13961 }
13962 case 10: {
csharptest920b09a2011-06-08 20:13:29 -050013963 result.hasEscapedBytes = input.ReadBytes(ref result.escapedBytes_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013964 break;
13965 }
13966 case 16: {
csharptest920b09a2011-06-08 20:13:29 -050013967 result.hasLargeUint32 = input.ReadUInt32(ref result.largeUint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013968 break;
13969 }
13970 case 24: {
csharptest920b09a2011-06-08 20:13:29 -050013971 result.hasLargeUint64 = input.ReadUInt64(ref result.largeUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013972 break;
13973 }
13974 case 32: {
csharptest920b09a2011-06-08 20:13:29 -050013975 result.hasSmallInt32 = input.ReadInt32(ref result.smallInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013976 break;
13977 }
13978 case 40: {
csharptest920b09a2011-06-08 20:13:29 -050013979 result.hasSmallInt64 = input.ReadInt64(ref result.smallInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013980 break;
13981 }
13982 case 50: {
csharptest920b09a2011-06-08 20:13:29 -050013983 result.hasUtf8String = input.ReadString(ref result.utf8String_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013984 break;
13985 }
13986 case 61: {
csharptest920b09a2011-06-08 20:13:29 -050013987 result.hasZeroFloat = input.ReadFloat(ref result.zeroFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013988 break;
13989 }
13990 case 69: {
csharptest920b09a2011-06-08 20:13:29 -050013991 result.hasOneFloat = input.ReadFloat(ref result.oneFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013992 break;
13993 }
13994 case 77: {
csharptest920b09a2011-06-08 20:13:29 -050013995 result.hasSmallFloat = input.ReadFloat(ref result.smallFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010013996 break;
13997 }
13998 case 85: {
csharptest920b09a2011-06-08 20:13:29 -050013999 result.hasNegativeOneFloat = input.ReadFloat(ref result.negativeOneFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014000 break;
14001 }
14002 case 93: {
csharptest920b09a2011-06-08 20:13:29 -050014003 result.hasNegativeFloat = input.ReadFloat(ref result.negativeFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014004 break;
14005 }
14006 case 101: {
csharptest920b09a2011-06-08 20:13:29 -050014007 result.hasLargeFloat = input.ReadFloat(ref result.largeFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014008 break;
14009 }
14010 case 109: {
csharptest920b09a2011-06-08 20:13:29 -050014011 result.hasSmallNegativeFloat = input.ReadFloat(ref result.smallNegativeFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014012 break;
14013 }
14014 case 113: {
csharptest920b09a2011-06-08 20:13:29 -050014015 result.hasInfDouble = input.ReadDouble(ref result.infDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014016 break;
14017 }
14018 case 121: {
csharptest920b09a2011-06-08 20:13:29 -050014019 result.hasNegInfDouble = input.ReadDouble(ref result.negInfDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014020 break;
14021 }
14022 case 129: {
csharptest920b09a2011-06-08 20:13:29 -050014023 result.hasNanDouble = input.ReadDouble(ref result.nanDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014024 break;
14025 }
14026 case 141: {
csharptest920b09a2011-06-08 20:13:29 -050014027 result.hasInfFloat = input.ReadFloat(ref result.infFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014028 break;
14029 }
14030 case 149: {
csharptest920b09a2011-06-08 20:13:29 -050014031 result.hasNegInfFloat = input.ReadFloat(ref result.negInfFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014032 break;
14033 }
14034 case 157: {
csharptest920b09a2011-06-08 20:13:29 -050014035 result.hasNanFloat = input.ReadFloat(ref result.nanFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014036 break;
14037 }
14038 }
14039 }
csharptest123e5342011-06-03 14:15:21 -050014040
14041 if (unknownFields != null) {
14042 this.UnknownFields = unknownFields.Build();
14043 }
14044 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010014045 }
14046
14047
14048 public bool HasEscapedBytes {
csharptestc671a4b2011-06-08 11:51:24 -050014049 get { return result.hasEscapedBytes; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014050 }
14051 public pb::ByteString EscapedBytes {
14052 get { return result.EscapedBytes; }
14053 set { SetEscapedBytes(value); }
14054 }
14055 public Builder SetEscapedBytes(pb::ByteString value) {
14056 pb::ThrowHelper.ThrowIfNull(value, "value");
14057 result.hasEscapedBytes = true;
14058 result.escapedBytes_ = value;
14059 return this;
14060 }
14061 public Builder ClearEscapedBytes() {
14062 result.hasEscapedBytes = false;
14063 result.escapedBytes_ = (pb::ByteString) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[0].DefaultValue;
14064 return this;
14065 }
14066
14067 public bool HasLargeUint32 {
csharptestc671a4b2011-06-08 11:51:24 -050014068 get { return result.hasLargeUint32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014069 }
14070 [global::System.CLSCompliant(false)]
14071 public uint LargeUint32 {
14072 get { return result.LargeUint32; }
14073 set { SetLargeUint32(value); }
14074 }
14075 [global::System.CLSCompliant(false)]
14076 public Builder SetLargeUint32(uint value) {
14077 result.hasLargeUint32 = true;
14078 result.largeUint32_ = value;
14079 return this;
14080 }
14081 public Builder ClearLargeUint32() {
14082 result.hasLargeUint32 = false;
14083 result.largeUint32_ = 4294967295;
14084 return this;
14085 }
14086
14087 public bool HasLargeUint64 {
csharptestc671a4b2011-06-08 11:51:24 -050014088 get { return result.hasLargeUint64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014089 }
14090 [global::System.CLSCompliant(false)]
14091 public ulong LargeUint64 {
14092 get { return result.LargeUint64; }
14093 set { SetLargeUint64(value); }
14094 }
14095 [global::System.CLSCompliant(false)]
14096 public Builder SetLargeUint64(ulong value) {
14097 result.hasLargeUint64 = true;
14098 result.largeUint64_ = value;
14099 return this;
14100 }
14101 public Builder ClearLargeUint64() {
14102 result.hasLargeUint64 = false;
14103 result.largeUint64_ = 18446744073709551615UL;
14104 return this;
14105 }
14106
14107 public bool HasSmallInt32 {
csharptestc671a4b2011-06-08 11:51:24 -050014108 get { return result.hasSmallInt32; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014109 }
14110 public int SmallInt32 {
14111 get { return result.SmallInt32; }
14112 set { SetSmallInt32(value); }
14113 }
14114 public Builder SetSmallInt32(int value) {
14115 result.hasSmallInt32 = true;
14116 result.smallInt32_ = value;
14117 return this;
14118 }
14119 public Builder ClearSmallInt32() {
14120 result.hasSmallInt32 = false;
14121 result.smallInt32_ = -2147483647;
14122 return this;
14123 }
14124
14125 public bool HasSmallInt64 {
csharptestc671a4b2011-06-08 11:51:24 -050014126 get { return result.hasSmallInt64; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014127 }
14128 public long SmallInt64 {
14129 get { return result.SmallInt64; }
14130 set { SetSmallInt64(value); }
14131 }
14132 public Builder SetSmallInt64(long value) {
14133 result.hasSmallInt64 = true;
14134 result.smallInt64_ = value;
14135 return this;
14136 }
14137 public Builder ClearSmallInt64() {
14138 result.hasSmallInt64 = false;
14139 result.smallInt64_ = -9223372036854775807L;
14140 return this;
14141 }
14142
14143 public bool HasUtf8String {
csharptestc671a4b2011-06-08 11:51:24 -050014144 get { return result.hasUtf8String; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014145 }
14146 public string Utf8String {
14147 get { return result.Utf8String; }
14148 set { SetUtf8String(value); }
14149 }
14150 public Builder SetUtf8String(string value) {
14151 pb::ThrowHelper.ThrowIfNull(value, "value");
14152 result.hasUtf8String = true;
14153 result.utf8String_ = value;
14154 return this;
14155 }
14156 public Builder ClearUtf8String() {
14157 result.hasUtf8String = false;
14158 result.utf8String_ = (string) global::Google.ProtocolBuffers.TestProtos.TestExtremeDefaultValues.Descriptor.Fields[5].DefaultValue;
14159 return this;
14160 }
14161
14162 public bool HasZeroFloat {
csharptestc671a4b2011-06-08 11:51:24 -050014163 get { return result.hasZeroFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014164 }
14165 public float ZeroFloat {
14166 get { return result.ZeroFloat; }
14167 set { SetZeroFloat(value); }
14168 }
14169 public Builder SetZeroFloat(float value) {
14170 result.hasZeroFloat = true;
14171 result.zeroFloat_ = value;
14172 return this;
14173 }
14174 public Builder ClearZeroFloat() {
14175 result.hasZeroFloat = false;
14176 result.zeroFloat_ = 0F;
14177 return this;
14178 }
14179
14180 public bool HasOneFloat {
csharptestc671a4b2011-06-08 11:51:24 -050014181 get { return result.hasOneFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014182 }
14183 public float OneFloat {
14184 get { return result.OneFloat; }
14185 set { SetOneFloat(value); }
14186 }
14187 public Builder SetOneFloat(float value) {
14188 result.hasOneFloat = true;
14189 result.oneFloat_ = value;
14190 return this;
14191 }
14192 public Builder ClearOneFloat() {
14193 result.hasOneFloat = false;
14194 result.oneFloat_ = 1F;
14195 return this;
14196 }
14197
14198 public bool HasSmallFloat {
csharptestc671a4b2011-06-08 11:51:24 -050014199 get { return result.hasSmallFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014200 }
14201 public float SmallFloat {
14202 get { return result.SmallFloat; }
14203 set { SetSmallFloat(value); }
14204 }
14205 public Builder SetSmallFloat(float value) {
14206 result.hasSmallFloat = true;
14207 result.smallFloat_ = value;
14208 return this;
14209 }
14210 public Builder ClearSmallFloat() {
14211 result.hasSmallFloat = false;
14212 result.smallFloat_ = 1.5F;
14213 return this;
14214 }
14215
14216 public bool HasNegativeOneFloat {
csharptestc671a4b2011-06-08 11:51:24 -050014217 get { return result.hasNegativeOneFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014218 }
14219 public float NegativeOneFloat {
14220 get { return result.NegativeOneFloat; }
14221 set { SetNegativeOneFloat(value); }
14222 }
14223 public Builder SetNegativeOneFloat(float value) {
14224 result.hasNegativeOneFloat = true;
14225 result.negativeOneFloat_ = value;
14226 return this;
14227 }
14228 public Builder ClearNegativeOneFloat() {
14229 result.hasNegativeOneFloat = false;
14230 result.negativeOneFloat_ = -1F;
14231 return this;
14232 }
14233
14234 public bool HasNegativeFloat {
csharptestc671a4b2011-06-08 11:51:24 -050014235 get { return result.hasNegativeFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014236 }
14237 public float NegativeFloat {
14238 get { return result.NegativeFloat; }
14239 set { SetNegativeFloat(value); }
14240 }
14241 public Builder SetNegativeFloat(float value) {
14242 result.hasNegativeFloat = true;
14243 result.negativeFloat_ = value;
14244 return this;
14245 }
14246 public Builder ClearNegativeFloat() {
14247 result.hasNegativeFloat = false;
14248 result.negativeFloat_ = -1.5F;
14249 return this;
14250 }
14251
14252 public bool HasLargeFloat {
csharptestc671a4b2011-06-08 11:51:24 -050014253 get { return result.hasLargeFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014254 }
14255 public float LargeFloat {
14256 get { return result.LargeFloat; }
14257 set { SetLargeFloat(value); }
14258 }
14259 public Builder SetLargeFloat(float value) {
14260 result.hasLargeFloat = true;
14261 result.largeFloat_ = value;
14262 return this;
14263 }
14264 public Builder ClearLargeFloat() {
14265 result.hasLargeFloat = false;
14266 result.largeFloat_ = 2E+08F;
14267 return this;
14268 }
14269
14270 public bool HasSmallNegativeFloat {
csharptestc671a4b2011-06-08 11:51:24 -050014271 get { return result.hasSmallNegativeFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014272 }
14273 public float SmallNegativeFloat {
14274 get { return result.SmallNegativeFloat; }
14275 set { SetSmallNegativeFloat(value); }
14276 }
14277 public Builder SetSmallNegativeFloat(float value) {
14278 result.hasSmallNegativeFloat = true;
14279 result.smallNegativeFloat_ = value;
14280 return this;
14281 }
14282 public Builder ClearSmallNegativeFloat() {
14283 result.hasSmallNegativeFloat = false;
14284 result.smallNegativeFloat_ = -8E-28F;
14285 return this;
14286 }
14287
14288 public bool HasInfDouble {
csharptestc671a4b2011-06-08 11:51:24 -050014289 get { return result.hasInfDouble; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014290 }
14291 public double InfDouble {
14292 get { return result.InfDouble; }
14293 set { SetInfDouble(value); }
14294 }
14295 public Builder SetInfDouble(double value) {
14296 result.hasInfDouble = true;
14297 result.infDouble_ = value;
14298 return this;
14299 }
14300 public Builder ClearInfDouble() {
14301 result.hasInfDouble = false;
14302 result.infDouble_ = double.PositiveInfinity;
14303 return this;
14304 }
14305
14306 public bool HasNegInfDouble {
csharptestc671a4b2011-06-08 11:51:24 -050014307 get { return result.hasNegInfDouble; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014308 }
14309 public double NegInfDouble {
14310 get { return result.NegInfDouble; }
14311 set { SetNegInfDouble(value); }
14312 }
14313 public Builder SetNegInfDouble(double value) {
14314 result.hasNegInfDouble = true;
14315 result.negInfDouble_ = value;
14316 return this;
14317 }
14318 public Builder ClearNegInfDouble() {
14319 result.hasNegInfDouble = false;
14320 result.negInfDouble_ = double.NegativeInfinity;
14321 return this;
14322 }
14323
14324 public bool HasNanDouble {
csharptestc671a4b2011-06-08 11:51:24 -050014325 get { return result.hasNanDouble; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014326 }
14327 public double NanDouble {
14328 get { return result.NanDouble; }
14329 set { SetNanDouble(value); }
14330 }
14331 public Builder SetNanDouble(double value) {
14332 result.hasNanDouble = true;
14333 result.nanDouble_ = value;
14334 return this;
14335 }
14336 public Builder ClearNanDouble() {
14337 result.hasNanDouble = false;
14338 result.nanDouble_ = double.NaN;
14339 return this;
14340 }
14341
14342 public bool HasInfFloat {
csharptestc671a4b2011-06-08 11:51:24 -050014343 get { return result.hasInfFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014344 }
14345 public float InfFloat {
14346 get { return result.InfFloat; }
14347 set { SetInfFloat(value); }
14348 }
14349 public Builder SetInfFloat(float value) {
14350 result.hasInfFloat = true;
14351 result.infFloat_ = value;
14352 return this;
14353 }
14354 public Builder ClearInfFloat() {
14355 result.hasInfFloat = false;
14356 result.infFloat_ = float.PositiveInfinity;
14357 return this;
14358 }
14359
14360 public bool HasNegInfFloat {
csharptestc671a4b2011-06-08 11:51:24 -050014361 get { return result.hasNegInfFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014362 }
14363 public float NegInfFloat {
14364 get { return result.NegInfFloat; }
14365 set { SetNegInfFloat(value); }
14366 }
14367 public Builder SetNegInfFloat(float value) {
14368 result.hasNegInfFloat = true;
14369 result.negInfFloat_ = value;
14370 return this;
14371 }
14372 public Builder ClearNegInfFloat() {
14373 result.hasNegInfFloat = false;
14374 result.negInfFloat_ = float.NegativeInfinity;
14375 return this;
14376 }
14377
14378 public bool HasNanFloat {
csharptestc671a4b2011-06-08 11:51:24 -050014379 get { return result.hasNanFloat; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014380 }
14381 public float NanFloat {
14382 get { return result.NanFloat; }
14383 set { SetNanFloat(value); }
14384 }
14385 public Builder SetNanFloat(float value) {
14386 result.hasNanFloat = true;
14387 result.nanFloat_ = value;
14388 return this;
14389 }
14390 public Builder ClearNanFloat() {
14391 result.hasNanFloat = false;
14392 result.nanFloat_ = float.NaN;
14393 return this;
14394 }
14395 }
14396 static TestExtremeDefaultValues() {
14397 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
14398 }
14399 }
14400
csharptest445bdce2011-05-20 15:50:54 -050014401 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
14402 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
14403 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010014404 public sealed partial class OneString : pb::GeneratedMessage<OneString, OneString.Builder> {
14405 private static readonly OneString defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050014406 private static readonly string[] _oneStringFieldNames = new string[] { "data" };
14407 private static readonly uint[] _oneStringFieldTags = new uint[] { 10 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010014408 public static OneString DefaultInstance {
14409 get { return defaultInstance; }
14410 }
14411
14412 public override OneString DefaultInstanceForType {
14413 get { return defaultInstance; }
14414 }
14415
14416 protected override OneString ThisMessage {
14417 get { return this; }
14418 }
14419
14420 public static pbd::MessageDescriptor Descriptor {
14421 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OneString__Descriptor; }
14422 }
14423
14424 protected override pb::FieldAccess.FieldAccessorTable<OneString, OneString.Builder> InternalFieldAccessors {
14425 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OneString__FieldAccessorTable; }
14426 }
14427
14428 public const int DataFieldNumber = 1;
14429 private bool hasData;
14430 private string data_ = "";
14431 public bool HasData {
14432 get { return hasData; }
14433 }
14434 public string Data {
14435 get { return data_; }
14436 }
14437
14438 public override bool IsInitialized {
14439 get {
14440 return true;
14441 }
14442 }
14443
csharptestffafdaa2011-06-03 12:58:14 -050014444 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014445 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050014446 string[] field_names = _oneStringFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050014447 if (hasData) {
csharptest920b09a2011-06-08 20:13:29 -050014448 output.WriteString(1, field_names[0], Data);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014449 }
14450 UnknownFields.WriteTo(output);
14451 }
14452
14453 private int memoizedSerializedSize = -1;
14454 public override int SerializedSize {
14455 get {
14456 int size = memoizedSerializedSize;
14457 if (size != -1) return size;
14458
14459 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050014460 if (hasData) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014461 size += pb::CodedOutputStream.ComputeStringSize(1, Data);
14462 }
14463 size += UnknownFields.SerializedSize;
14464 memoizedSerializedSize = size;
14465 return size;
14466 }
14467 }
14468
14469 public static OneString ParseFrom(pb::ByteString data) {
14470 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
14471 }
14472 public static OneString ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
14473 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
14474 }
14475 public static OneString ParseFrom(byte[] data) {
14476 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
14477 }
14478 public static OneString ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
14479 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
14480 }
14481 public static OneString ParseFrom(global::System.IO.Stream input) {
14482 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
14483 }
14484 public static OneString ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
14485 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
14486 }
14487 public static OneString ParseDelimitedFrom(global::System.IO.Stream input) {
14488 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
14489 }
14490 public static OneString ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
14491 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
14492 }
csharptest17699c22011-06-03 21:57:15 -050014493 public static OneString ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014494 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
14495 }
csharptest17699c22011-06-03 21:57:15 -050014496 public static OneString ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014497 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
14498 }
14499 public static Builder CreateBuilder() { return new Builder(); }
14500 public override Builder ToBuilder() { return CreateBuilder(this); }
14501 public override Builder CreateBuilderForType() { return new Builder(); }
14502 public static Builder CreateBuilder(OneString prototype) {
14503 return (Builder) new Builder().MergeFrom(prototype);
14504 }
14505
csharptest445bdce2011-05-20 15:50:54 -050014506 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
14507 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
14508 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010014509 public sealed partial class Builder : pb::GeneratedBuilder<OneString, Builder> {
14510 protected override Builder ThisBuilder {
14511 get { return this; }
14512 }
14513 public Builder() {}
14514
14515 OneString result = new OneString();
14516
14517 protected override OneString MessageBeingBuilt {
14518 get { return result; }
14519 }
14520
14521 public override Builder Clear() {
14522 result = new OneString();
14523 return this;
14524 }
14525
14526 public override Builder Clone() {
14527 return new Builder().MergeFrom(result);
14528 }
14529
14530 public override pbd::MessageDescriptor DescriptorForType {
14531 get { return global::Google.ProtocolBuffers.TestProtos.OneString.Descriptor; }
14532 }
14533
14534 public override OneString DefaultInstanceForType {
14535 get { return global::Google.ProtocolBuffers.TestProtos.OneString.DefaultInstance; }
14536 }
14537
14538 public override OneString BuildPartial() {
14539 if (result == null) {
14540 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
14541 }
14542 OneString returnMe = result;
14543 result = null;
14544 return returnMe;
14545 }
14546
14547 public override Builder MergeFrom(pb::IMessage other) {
14548 if (other is OneString) {
14549 return MergeFrom((OneString) other);
14550 } else {
14551 base.MergeFrom(other);
14552 return this;
14553 }
14554 }
14555
14556 public override Builder MergeFrom(OneString other) {
14557 if (other == global::Google.ProtocolBuffers.TestProtos.OneString.DefaultInstance) return this;
14558 if (other.HasData) {
14559 Data = other.Data;
14560 }
14561 this.MergeUnknownFields(other.UnknownFields);
14562 return this;
14563 }
14564
csharptest17699c22011-06-03 21:57:15 -050014565 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014566 return MergeFrom(input, pb::ExtensionRegistry.Empty);
14567 }
14568
csharptest17699c22011-06-03 21:57:15 -050014569 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014570 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050014571 uint tag;
14572 string field_name;
14573 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050014574 if(tag == 0 && field_name != null) {
14575 int field_ordinal = global::System.Array.BinarySearch(_oneStringFieldNames, field_name, global::System.StringComparer.Ordinal);
14576 if(field_ordinal >= 0)
14577 tag = _oneStringFieldTags[field_ordinal];
14578 else {
14579 if (unknownFields == null) {
14580 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
14581 }
14582 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
14583 continue;
14584 }
14585 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014586 switch (tag) {
14587 case 0: {
csharptest99284412011-06-03 14:51:06 -050014588 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010014589 }
14590 default: {
14591 if (pb::WireFormat.IsEndGroupTag(tag)) {
14592 if (unknownFields != null) {
14593 this.UnknownFields = unknownFields.Build();
14594 }
14595 return this;
14596 }
14597 if (unknownFields == null) {
14598 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
14599 }
csharptestd2af9e92011-06-03 21:35:02 -050014600 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014601 break;
14602 }
14603 case 10: {
csharptest920b09a2011-06-08 20:13:29 -050014604 result.hasData = input.ReadString(ref result.data_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014605 break;
14606 }
14607 }
14608 }
csharptest123e5342011-06-03 14:15:21 -050014609
14610 if (unknownFields != null) {
14611 this.UnknownFields = unknownFields.Build();
14612 }
14613 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010014614 }
14615
14616
14617 public bool HasData {
csharptestc671a4b2011-06-08 11:51:24 -050014618 get { return result.hasData; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014619 }
14620 public string Data {
14621 get { return result.Data; }
14622 set { SetData(value); }
14623 }
14624 public Builder SetData(string value) {
14625 pb::ThrowHelper.ThrowIfNull(value, "value");
14626 result.hasData = true;
14627 result.data_ = value;
14628 return this;
14629 }
14630 public Builder ClearData() {
14631 result.hasData = false;
14632 result.data_ = "";
14633 return this;
14634 }
14635 }
14636 static OneString() {
14637 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
14638 }
14639 }
14640
csharptest445bdce2011-05-20 15:50:54 -050014641 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
14642 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
14643 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010014644 public sealed partial class OneBytes : pb::GeneratedMessage<OneBytes, OneBytes.Builder> {
14645 private static readonly OneBytes defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050014646 private static readonly string[] _oneBytesFieldNames = new string[] { "data" };
14647 private static readonly uint[] _oneBytesFieldTags = new uint[] { 10 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010014648 public static OneBytes DefaultInstance {
14649 get { return defaultInstance; }
14650 }
14651
14652 public override OneBytes DefaultInstanceForType {
14653 get { return defaultInstance; }
14654 }
14655
14656 protected override OneBytes ThisMessage {
14657 get { return this; }
14658 }
14659
14660 public static pbd::MessageDescriptor Descriptor {
14661 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OneBytes__Descriptor; }
14662 }
14663
14664 protected override pb::FieldAccess.FieldAccessorTable<OneBytes, OneBytes.Builder> InternalFieldAccessors {
14665 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_OneBytes__FieldAccessorTable; }
14666 }
14667
14668 public const int DataFieldNumber = 1;
14669 private bool hasData;
14670 private pb::ByteString data_ = pb::ByteString.Empty;
14671 public bool HasData {
14672 get { return hasData; }
14673 }
14674 public pb::ByteString Data {
14675 get { return data_; }
14676 }
14677
14678 public override bool IsInitialized {
14679 get {
14680 return true;
14681 }
14682 }
14683
csharptestffafdaa2011-06-03 12:58:14 -050014684 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014685 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050014686 string[] field_names = _oneBytesFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050014687 if (hasData) {
csharptest920b09a2011-06-08 20:13:29 -050014688 output.WriteBytes(1, field_names[0], Data);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014689 }
14690 UnknownFields.WriteTo(output);
14691 }
14692
14693 private int memoizedSerializedSize = -1;
14694 public override int SerializedSize {
14695 get {
14696 int size = memoizedSerializedSize;
14697 if (size != -1) return size;
14698
14699 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050014700 if (hasData) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014701 size += pb::CodedOutputStream.ComputeBytesSize(1, Data);
14702 }
14703 size += UnknownFields.SerializedSize;
14704 memoizedSerializedSize = size;
14705 return size;
14706 }
14707 }
14708
14709 public static OneBytes ParseFrom(pb::ByteString data) {
14710 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
14711 }
14712 public static OneBytes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
14713 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
14714 }
14715 public static OneBytes ParseFrom(byte[] data) {
14716 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
14717 }
14718 public static OneBytes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
14719 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
14720 }
14721 public static OneBytes ParseFrom(global::System.IO.Stream input) {
14722 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
14723 }
14724 public static OneBytes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
14725 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
14726 }
14727 public static OneBytes ParseDelimitedFrom(global::System.IO.Stream input) {
14728 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
14729 }
14730 public static OneBytes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
14731 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
14732 }
csharptest17699c22011-06-03 21:57:15 -050014733 public static OneBytes ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014734 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
14735 }
csharptest17699c22011-06-03 21:57:15 -050014736 public static OneBytes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014737 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
14738 }
14739 public static Builder CreateBuilder() { return new Builder(); }
14740 public override Builder ToBuilder() { return CreateBuilder(this); }
14741 public override Builder CreateBuilderForType() { return new Builder(); }
14742 public static Builder CreateBuilder(OneBytes prototype) {
14743 return (Builder) new Builder().MergeFrom(prototype);
14744 }
14745
csharptest445bdce2011-05-20 15:50:54 -050014746 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
14747 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
14748 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010014749 public sealed partial class Builder : pb::GeneratedBuilder<OneBytes, Builder> {
14750 protected override Builder ThisBuilder {
14751 get { return this; }
14752 }
14753 public Builder() {}
14754
14755 OneBytes result = new OneBytes();
14756
14757 protected override OneBytes MessageBeingBuilt {
14758 get { return result; }
14759 }
14760
14761 public override Builder Clear() {
14762 result = new OneBytes();
14763 return this;
14764 }
14765
14766 public override Builder Clone() {
14767 return new Builder().MergeFrom(result);
14768 }
14769
14770 public override pbd::MessageDescriptor DescriptorForType {
14771 get { return global::Google.ProtocolBuffers.TestProtos.OneBytes.Descriptor; }
14772 }
14773
14774 public override OneBytes DefaultInstanceForType {
14775 get { return global::Google.ProtocolBuffers.TestProtos.OneBytes.DefaultInstance; }
14776 }
14777
14778 public override OneBytes BuildPartial() {
14779 if (result == null) {
14780 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
14781 }
14782 OneBytes returnMe = result;
14783 result = null;
14784 return returnMe;
14785 }
14786
14787 public override Builder MergeFrom(pb::IMessage other) {
14788 if (other is OneBytes) {
14789 return MergeFrom((OneBytes) other);
14790 } else {
14791 base.MergeFrom(other);
14792 return this;
14793 }
14794 }
14795
14796 public override Builder MergeFrom(OneBytes other) {
14797 if (other == global::Google.ProtocolBuffers.TestProtos.OneBytes.DefaultInstance) return this;
14798 if (other.HasData) {
14799 Data = other.Data;
14800 }
14801 this.MergeUnknownFields(other.UnknownFields);
14802 return this;
14803 }
14804
csharptest17699c22011-06-03 21:57:15 -050014805 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014806 return MergeFrom(input, pb::ExtensionRegistry.Empty);
14807 }
14808
csharptest17699c22011-06-03 21:57:15 -050014809 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010014810 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050014811 uint tag;
14812 string field_name;
14813 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050014814 if(tag == 0 && field_name != null) {
14815 int field_ordinal = global::System.Array.BinarySearch(_oneBytesFieldNames, field_name, global::System.StringComparer.Ordinal);
14816 if(field_ordinal >= 0)
14817 tag = _oneBytesFieldTags[field_ordinal];
14818 else {
14819 if (unknownFields == null) {
14820 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
14821 }
14822 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
14823 continue;
14824 }
14825 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014826 switch (tag) {
14827 case 0: {
csharptest99284412011-06-03 14:51:06 -050014828 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010014829 }
14830 default: {
14831 if (pb::WireFormat.IsEndGroupTag(tag)) {
14832 if (unknownFields != null) {
14833 this.UnknownFields = unknownFields.Build();
14834 }
14835 return this;
14836 }
14837 if (unknownFields == null) {
14838 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
14839 }
csharptestd2af9e92011-06-03 21:35:02 -050014840 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014841 break;
14842 }
14843 case 10: {
csharptest920b09a2011-06-08 20:13:29 -050014844 result.hasData = input.ReadBytes(ref result.data_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010014845 break;
14846 }
14847 }
14848 }
csharptest123e5342011-06-03 14:15:21 -050014849
14850 if (unknownFields != null) {
14851 this.UnknownFields = unknownFields.Build();
14852 }
14853 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010014854 }
14855
14856
14857 public bool HasData {
csharptestc671a4b2011-06-08 11:51:24 -050014858 get { return result.hasData; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010014859 }
14860 public pb::ByteString Data {
14861 get { return result.Data; }
14862 set { SetData(value); }
14863 }
14864 public Builder SetData(pb::ByteString value) {
14865 pb::ThrowHelper.ThrowIfNull(value, "value");
14866 result.hasData = true;
14867 result.data_ = value;
14868 return this;
14869 }
14870 public Builder ClearData() {
14871 result.hasData = false;
14872 result.data_ = pb::ByteString.Empty;
14873 return this;
14874 }
14875 }
14876 static OneBytes() {
14877 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
14878 }
14879 }
14880
csharptest445bdce2011-05-20 15:50:54 -050014881 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
14882 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
14883 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010014884 public sealed partial class TestPackedTypes : pb::GeneratedMessage<TestPackedTypes, TestPackedTypes.Builder> {
14885 private static readonly TestPackedTypes defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050014886 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" };
14887 private static readonly uint[] _testPackedTypesFieldTags = new uint[] { 818, 810, 826, 770, 778, 802, 722, 730, 786, 794, 754, 762, 738, 746 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010014888 public static TestPackedTypes DefaultInstance {
14889 get { return defaultInstance; }
14890 }
14891
14892 public override TestPackedTypes DefaultInstanceForType {
14893 get { return defaultInstance; }
14894 }
14895
14896 protected override TestPackedTypes ThisMessage {
14897 get { return this; }
14898 }
14899
14900 public static pbd::MessageDescriptor Descriptor {
14901 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestPackedTypes__Descriptor; }
14902 }
14903
14904 protected override pb::FieldAccess.FieldAccessorTable<TestPackedTypes, TestPackedTypes.Builder> InternalFieldAccessors {
14905 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestPackedTypes__FieldAccessorTable; }
14906 }
14907
14908 public const int PackedInt32FieldNumber = 90;
14909 private int packedInt32MemoizedSerializedSize;
14910 private pbc::PopsicleList<int> packedInt32_ = new pbc::PopsicleList<int>();
14911 public scg::IList<int> PackedInt32List {
14912 get { return pbc::Lists.AsReadOnly(packedInt32_); }
14913 }
14914 public int PackedInt32Count {
14915 get { return packedInt32_.Count; }
14916 }
14917 public int GetPackedInt32(int index) {
14918 return packedInt32_[index];
14919 }
14920
14921 public const int PackedInt64FieldNumber = 91;
14922 private int packedInt64MemoizedSerializedSize;
14923 private pbc::PopsicleList<long> packedInt64_ = new pbc::PopsicleList<long>();
14924 public scg::IList<long> PackedInt64List {
14925 get { return pbc::Lists.AsReadOnly(packedInt64_); }
14926 }
14927 public int PackedInt64Count {
14928 get { return packedInt64_.Count; }
14929 }
14930 public long GetPackedInt64(int index) {
14931 return packedInt64_[index];
14932 }
14933
14934 public const int PackedUint32FieldNumber = 92;
14935 private int packedUint32MemoizedSerializedSize;
14936 private pbc::PopsicleList<uint> packedUint32_ = new pbc::PopsicleList<uint>();
14937 [global::System.CLSCompliant(false)]
14938 public scg::IList<uint> PackedUint32List {
14939 get { return pbc::Lists.AsReadOnly(packedUint32_); }
14940 }
14941 public int PackedUint32Count {
14942 get { return packedUint32_.Count; }
14943 }
14944 [global::System.CLSCompliant(false)]
14945 public uint GetPackedUint32(int index) {
14946 return packedUint32_[index];
14947 }
14948
14949 public const int PackedUint64FieldNumber = 93;
14950 private int packedUint64MemoizedSerializedSize;
14951 private pbc::PopsicleList<ulong> packedUint64_ = new pbc::PopsicleList<ulong>();
14952 [global::System.CLSCompliant(false)]
14953 public scg::IList<ulong> PackedUint64List {
14954 get { return pbc::Lists.AsReadOnly(packedUint64_); }
14955 }
14956 public int PackedUint64Count {
14957 get { return packedUint64_.Count; }
14958 }
14959 [global::System.CLSCompliant(false)]
14960 public ulong GetPackedUint64(int index) {
14961 return packedUint64_[index];
14962 }
14963
14964 public const int PackedSint32FieldNumber = 94;
14965 private int packedSint32MemoizedSerializedSize;
14966 private pbc::PopsicleList<int> packedSint32_ = new pbc::PopsicleList<int>();
14967 public scg::IList<int> PackedSint32List {
14968 get { return pbc::Lists.AsReadOnly(packedSint32_); }
14969 }
14970 public int PackedSint32Count {
14971 get { return packedSint32_.Count; }
14972 }
14973 public int GetPackedSint32(int index) {
14974 return packedSint32_[index];
14975 }
14976
14977 public const int PackedSint64FieldNumber = 95;
14978 private int packedSint64MemoizedSerializedSize;
14979 private pbc::PopsicleList<long> packedSint64_ = new pbc::PopsicleList<long>();
14980 public scg::IList<long> PackedSint64List {
14981 get { return pbc::Lists.AsReadOnly(packedSint64_); }
14982 }
14983 public int PackedSint64Count {
14984 get { return packedSint64_.Count; }
14985 }
14986 public long GetPackedSint64(int index) {
14987 return packedSint64_[index];
14988 }
14989
14990 public const int PackedFixed32FieldNumber = 96;
14991 private int packedFixed32MemoizedSerializedSize;
14992 private pbc::PopsicleList<uint> packedFixed32_ = new pbc::PopsicleList<uint>();
14993 [global::System.CLSCompliant(false)]
14994 public scg::IList<uint> PackedFixed32List {
14995 get { return pbc::Lists.AsReadOnly(packedFixed32_); }
14996 }
14997 public int PackedFixed32Count {
14998 get { return packedFixed32_.Count; }
14999 }
15000 [global::System.CLSCompliant(false)]
15001 public uint GetPackedFixed32(int index) {
15002 return packedFixed32_[index];
15003 }
15004
15005 public const int PackedFixed64FieldNumber = 97;
15006 private int packedFixed64MemoizedSerializedSize;
15007 private pbc::PopsicleList<ulong> packedFixed64_ = new pbc::PopsicleList<ulong>();
15008 [global::System.CLSCompliant(false)]
15009 public scg::IList<ulong> PackedFixed64List {
15010 get { return pbc::Lists.AsReadOnly(packedFixed64_); }
15011 }
15012 public int PackedFixed64Count {
15013 get { return packedFixed64_.Count; }
15014 }
15015 [global::System.CLSCompliant(false)]
15016 public ulong GetPackedFixed64(int index) {
15017 return packedFixed64_[index];
15018 }
15019
15020 public const int PackedSfixed32FieldNumber = 98;
15021 private int packedSfixed32MemoizedSerializedSize;
15022 private pbc::PopsicleList<int> packedSfixed32_ = new pbc::PopsicleList<int>();
15023 public scg::IList<int> PackedSfixed32List {
15024 get { return pbc::Lists.AsReadOnly(packedSfixed32_); }
15025 }
15026 public int PackedSfixed32Count {
15027 get { return packedSfixed32_.Count; }
15028 }
15029 public int GetPackedSfixed32(int index) {
15030 return packedSfixed32_[index];
15031 }
15032
15033 public const int PackedSfixed64FieldNumber = 99;
15034 private int packedSfixed64MemoizedSerializedSize;
15035 private pbc::PopsicleList<long> packedSfixed64_ = new pbc::PopsicleList<long>();
15036 public scg::IList<long> PackedSfixed64List {
15037 get { return pbc::Lists.AsReadOnly(packedSfixed64_); }
15038 }
15039 public int PackedSfixed64Count {
15040 get { return packedSfixed64_.Count; }
15041 }
15042 public long GetPackedSfixed64(int index) {
15043 return packedSfixed64_[index];
15044 }
15045
15046 public const int PackedFloatFieldNumber = 100;
15047 private int packedFloatMemoizedSerializedSize;
15048 private pbc::PopsicleList<float> packedFloat_ = new pbc::PopsicleList<float>();
15049 public scg::IList<float> PackedFloatList {
15050 get { return pbc::Lists.AsReadOnly(packedFloat_); }
15051 }
15052 public int PackedFloatCount {
15053 get { return packedFloat_.Count; }
15054 }
15055 public float GetPackedFloat(int index) {
15056 return packedFloat_[index];
15057 }
15058
15059 public const int PackedDoubleFieldNumber = 101;
15060 private int packedDoubleMemoizedSerializedSize;
15061 private pbc::PopsicleList<double> packedDouble_ = new pbc::PopsicleList<double>();
15062 public scg::IList<double> PackedDoubleList {
15063 get { return pbc::Lists.AsReadOnly(packedDouble_); }
15064 }
15065 public int PackedDoubleCount {
15066 get { return packedDouble_.Count; }
15067 }
15068 public double GetPackedDouble(int index) {
15069 return packedDouble_[index];
15070 }
15071
15072 public const int PackedBoolFieldNumber = 102;
15073 private int packedBoolMemoizedSerializedSize;
15074 private pbc::PopsicleList<bool> packedBool_ = new pbc::PopsicleList<bool>();
15075 public scg::IList<bool> PackedBoolList {
15076 get { return pbc::Lists.AsReadOnly(packedBool_); }
15077 }
15078 public int PackedBoolCount {
15079 get { return packedBool_.Count; }
15080 }
15081 public bool GetPackedBool(int index) {
15082 return packedBool_[index];
15083 }
15084
15085 public const int PackedEnumFieldNumber = 103;
15086 private int packedEnumMemoizedSerializedSize;
15087 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> packedEnum_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>();
15088 public scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> PackedEnumList {
15089 get { return pbc::Lists.AsReadOnly(packedEnum_); }
15090 }
15091 public int PackedEnumCount {
15092 get { return packedEnum_.Count; }
15093 }
15094 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetPackedEnum(int index) {
15095 return packedEnum_[index];
15096 }
15097
15098 public override bool IsInitialized {
15099 get {
15100 return true;
15101 }
15102 }
15103
csharptestffafdaa2011-06-03 12:58:14 -050015104 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010015105 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050015106 string[] field_names = _testPackedTypesFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +010015107 if (packedInt32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015108 output.WritePackedArray(pbd::FieldType.Int32, 90, field_names[6], packedInt32MemoizedSerializedSize, packedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015109 }
15110 if (packedInt64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015111 output.WritePackedArray(pbd::FieldType.Int64, 91, field_names[7], packedInt64MemoizedSerializedSize, packedInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015112 }
15113 if (packedUint32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015114 output.WritePackedArray(pbd::FieldType.UInt32, 92, field_names[12], packedUint32MemoizedSerializedSize, packedUint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015115 }
15116 if (packedUint64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015117 output.WritePackedArray(pbd::FieldType.UInt64, 93, field_names[13], packedUint64MemoizedSerializedSize, packedUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015118 }
15119 if (packedSint32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015120 output.WritePackedArray(pbd::FieldType.SInt32, 94, field_names[10], packedSint32MemoizedSerializedSize, packedSint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015121 }
15122 if (packedSint64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015123 output.WritePackedArray(pbd::FieldType.SInt64, 95, field_names[11], packedSint64MemoizedSerializedSize, packedSint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015124 }
15125 if (packedFixed32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015126 output.WritePackedArray(pbd::FieldType.Fixed32, 96, field_names[3], packedFixed32MemoizedSerializedSize, packedFixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015127 }
15128 if (packedFixed64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015129 output.WritePackedArray(pbd::FieldType.Fixed64, 97, field_names[4], packedFixed64MemoizedSerializedSize, packedFixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015130 }
15131 if (packedSfixed32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015132 output.WritePackedArray(pbd::FieldType.SFixed32, 98, field_names[8], packedSfixed32MemoizedSerializedSize, packedSfixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015133 }
15134 if (packedSfixed64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015135 output.WritePackedArray(pbd::FieldType.SFixed64, 99, field_names[9], packedSfixed64MemoizedSerializedSize, packedSfixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015136 }
15137 if (packedFloat_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015138 output.WritePackedArray(pbd::FieldType.Float, 100, field_names[5], packedFloatMemoizedSerializedSize, packedFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015139 }
15140 if (packedDouble_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015141 output.WritePackedArray(pbd::FieldType.Double, 101, field_names[1], packedDoubleMemoizedSerializedSize, packedDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015142 }
15143 if (packedBool_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015144 output.WritePackedArray(pbd::FieldType.Bool, 102, field_names[0], packedBoolMemoizedSerializedSize, packedBool_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015145 }
15146 if (packedEnum_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050015147 output.WritePackedArray(pbd::FieldType.Enum, 103, field_names[2], packedEnumMemoizedSerializedSize, packedEnum_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015148 }
15149 UnknownFields.WriteTo(output);
15150 }
15151
15152 private int memoizedSerializedSize = -1;
15153 public override int SerializedSize {
15154 get {
15155 int size = memoizedSerializedSize;
15156 if (size != -1) return size;
15157
15158 size = 0;
15159 {
15160 int dataSize = 0;
15161 foreach (int element in PackedInt32List) {
15162 dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element);
15163 }
15164 size += dataSize;
15165 if (packedInt32_.Count != 0) {
15166 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15167 }
15168 packedInt32MemoizedSerializedSize = dataSize;
15169 }
15170 {
15171 int dataSize = 0;
15172 foreach (long element in PackedInt64List) {
15173 dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element);
15174 }
15175 size += dataSize;
15176 if (packedInt64_.Count != 0) {
15177 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15178 }
15179 packedInt64MemoizedSerializedSize = dataSize;
15180 }
15181 {
15182 int dataSize = 0;
15183 foreach (uint element in PackedUint32List) {
15184 dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element);
15185 }
15186 size += dataSize;
15187 if (packedUint32_.Count != 0) {
15188 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15189 }
15190 packedUint32MemoizedSerializedSize = dataSize;
15191 }
15192 {
15193 int dataSize = 0;
15194 foreach (ulong element in PackedUint64List) {
15195 dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element);
15196 }
15197 size += dataSize;
15198 if (packedUint64_.Count != 0) {
15199 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15200 }
15201 packedUint64MemoizedSerializedSize = dataSize;
15202 }
15203 {
15204 int dataSize = 0;
15205 foreach (int element in PackedSint32List) {
15206 dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element);
15207 }
15208 size += dataSize;
15209 if (packedSint32_.Count != 0) {
15210 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15211 }
15212 packedSint32MemoizedSerializedSize = dataSize;
15213 }
15214 {
15215 int dataSize = 0;
15216 foreach (long element in PackedSint64List) {
15217 dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element);
15218 }
15219 size += dataSize;
15220 if (packedSint64_.Count != 0) {
15221 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15222 }
15223 packedSint64MemoizedSerializedSize = dataSize;
15224 }
15225 {
15226 int dataSize = 0;
15227 dataSize = 4 * packedFixed32_.Count;
15228 size += dataSize;
15229 if (packedFixed32_.Count != 0) {
15230 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15231 }
15232 packedFixed32MemoizedSerializedSize = dataSize;
15233 }
15234 {
15235 int dataSize = 0;
15236 dataSize = 8 * packedFixed64_.Count;
15237 size += dataSize;
15238 if (packedFixed64_.Count != 0) {
15239 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15240 }
15241 packedFixed64MemoizedSerializedSize = dataSize;
15242 }
15243 {
15244 int dataSize = 0;
15245 dataSize = 4 * packedSfixed32_.Count;
15246 size += dataSize;
15247 if (packedSfixed32_.Count != 0) {
15248 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15249 }
15250 packedSfixed32MemoizedSerializedSize = dataSize;
15251 }
15252 {
15253 int dataSize = 0;
15254 dataSize = 8 * packedSfixed64_.Count;
15255 size += dataSize;
15256 if (packedSfixed64_.Count != 0) {
15257 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15258 }
15259 packedSfixed64MemoizedSerializedSize = dataSize;
15260 }
15261 {
15262 int dataSize = 0;
15263 dataSize = 4 * packedFloat_.Count;
15264 size += dataSize;
15265 if (packedFloat_.Count != 0) {
15266 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15267 }
15268 packedFloatMemoizedSerializedSize = dataSize;
15269 }
15270 {
15271 int dataSize = 0;
15272 dataSize = 8 * packedDouble_.Count;
15273 size += dataSize;
15274 if (packedDouble_.Count != 0) {
15275 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15276 }
15277 packedDoubleMemoizedSerializedSize = dataSize;
15278 }
15279 {
15280 int dataSize = 0;
15281 dataSize = 1 * packedBool_.Count;
15282 size += dataSize;
15283 if (packedBool_.Count != 0) {
15284 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
15285 }
15286 packedBoolMemoizedSerializedSize = dataSize;
15287 }
15288 {
15289 int dataSize = 0;
15290 if (packedEnum_.Count > 0) {
15291 foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in packedEnum_) {
15292 dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element);
15293 }
15294 size += dataSize;
15295 size += 2;
15296 size += pb::CodedOutputStream.ComputeRawVarint32Size((uint) dataSize);
15297 }
15298 packedEnumMemoizedSerializedSize = dataSize;
15299 }
15300 size += UnknownFields.SerializedSize;
15301 memoizedSerializedSize = size;
15302 return size;
15303 }
15304 }
15305
15306 public static TestPackedTypes ParseFrom(pb::ByteString data) {
15307 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
15308 }
15309 public static TestPackedTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
15310 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
15311 }
15312 public static TestPackedTypes ParseFrom(byte[] data) {
15313 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
15314 }
15315 public static TestPackedTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
15316 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
15317 }
15318 public static TestPackedTypes ParseFrom(global::System.IO.Stream input) {
15319 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
15320 }
15321 public static TestPackedTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
15322 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
15323 }
15324 public static TestPackedTypes ParseDelimitedFrom(global::System.IO.Stream input) {
15325 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
15326 }
15327 public static TestPackedTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
15328 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
15329 }
csharptest17699c22011-06-03 21:57:15 -050015330 public static TestPackedTypes ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010015331 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
15332 }
csharptest17699c22011-06-03 21:57:15 -050015333 public static TestPackedTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010015334 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
15335 }
15336 public static Builder CreateBuilder() { return new Builder(); }
15337 public override Builder ToBuilder() { return CreateBuilder(this); }
15338 public override Builder CreateBuilderForType() { return new Builder(); }
15339 public static Builder CreateBuilder(TestPackedTypes prototype) {
15340 return (Builder) new Builder().MergeFrom(prototype);
15341 }
15342
csharptest445bdce2011-05-20 15:50:54 -050015343 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
15344 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
15345 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010015346 public sealed partial class Builder : pb::GeneratedBuilder<TestPackedTypes, Builder> {
15347 protected override Builder ThisBuilder {
15348 get { return this; }
15349 }
15350 public Builder() {}
15351
15352 TestPackedTypes result = new TestPackedTypes();
15353
15354 protected override TestPackedTypes MessageBeingBuilt {
15355 get { return result; }
15356 }
15357
15358 public override Builder Clear() {
15359 result = new TestPackedTypes();
15360 return this;
15361 }
15362
15363 public override Builder Clone() {
15364 return new Builder().MergeFrom(result);
15365 }
15366
15367 public override pbd::MessageDescriptor DescriptorForType {
15368 get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.Descriptor; }
15369 }
15370
15371 public override TestPackedTypes DefaultInstanceForType {
15372 get { return global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.DefaultInstance; }
15373 }
15374
15375 public override TestPackedTypes BuildPartial() {
15376 if (result == null) {
15377 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
15378 }
15379 result.packedInt32_.MakeReadOnly();
15380 result.packedInt64_.MakeReadOnly();
15381 result.packedUint32_.MakeReadOnly();
15382 result.packedUint64_.MakeReadOnly();
15383 result.packedSint32_.MakeReadOnly();
15384 result.packedSint64_.MakeReadOnly();
15385 result.packedFixed32_.MakeReadOnly();
15386 result.packedFixed64_.MakeReadOnly();
15387 result.packedSfixed32_.MakeReadOnly();
15388 result.packedSfixed64_.MakeReadOnly();
15389 result.packedFloat_.MakeReadOnly();
15390 result.packedDouble_.MakeReadOnly();
15391 result.packedBool_.MakeReadOnly();
15392 result.packedEnum_.MakeReadOnly();
15393 TestPackedTypes returnMe = result;
15394 result = null;
15395 return returnMe;
15396 }
15397
15398 public override Builder MergeFrom(pb::IMessage other) {
15399 if (other is TestPackedTypes) {
15400 return MergeFrom((TestPackedTypes) other);
15401 } else {
15402 base.MergeFrom(other);
15403 return this;
15404 }
15405 }
15406
15407 public override Builder MergeFrom(TestPackedTypes other) {
15408 if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedTypes.DefaultInstance) return this;
15409 if (other.packedInt32_.Count != 0) {
15410 base.AddRange(other.packedInt32_, result.packedInt32_);
15411 }
15412 if (other.packedInt64_.Count != 0) {
15413 base.AddRange(other.packedInt64_, result.packedInt64_);
15414 }
15415 if (other.packedUint32_.Count != 0) {
15416 base.AddRange(other.packedUint32_, result.packedUint32_);
15417 }
15418 if (other.packedUint64_.Count != 0) {
15419 base.AddRange(other.packedUint64_, result.packedUint64_);
15420 }
15421 if (other.packedSint32_.Count != 0) {
15422 base.AddRange(other.packedSint32_, result.packedSint32_);
15423 }
15424 if (other.packedSint64_.Count != 0) {
15425 base.AddRange(other.packedSint64_, result.packedSint64_);
15426 }
15427 if (other.packedFixed32_.Count != 0) {
15428 base.AddRange(other.packedFixed32_, result.packedFixed32_);
15429 }
15430 if (other.packedFixed64_.Count != 0) {
15431 base.AddRange(other.packedFixed64_, result.packedFixed64_);
15432 }
15433 if (other.packedSfixed32_.Count != 0) {
15434 base.AddRange(other.packedSfixed32_, result.packedSfixed32_);
15435 }
15436 if (other.packedSfixed64_.Count != 0) {
15437 base.AddRange(other.packedSfixed64_, result.packedSfixed64_);
15438 }
15439 if (other.packedFloat_.Count != 0) {
15440 base.AddRange(other.packedFloat_, result.packedFloat_);
15441 }
15442 if (other.packedDouble_.Count != 0) {
15443 base.AddRange(other.packedDouble_, result.packedDouble_);
15444 }
15445 if (other.packedBool_.Count != 0) {
15446 base.AddRange(other.packedBool_, result.packedBool_);
15447 }
15448 if (other.packedEnum_.Count != 0) {
15449 base.AddRange(other.packedEnum_, result.packedEnum_);
15450 }
15451 this.MergeUnknownFields(other.UnknownFields);
15452 return this;
15453 }
15454
csharptest17699c22011-06-03 21:57:15 -050015455 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010015456 return MergeFrom(input, pb::ExtensionRegistry.Empty);
15457 }
15458
csharptest17699c22011-06-03 21:57:15 -050015459 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010015460 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050015461 uint tag;
15462 string field_name;
15463 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050015464 if(tag == 0 && field_name != null) {
15465 int field_ordinal = global::System.Array.BinarySearch(_testPackedTypesFieldNames, field_name, global::System.StringComparer.Ordinal);
15466 if(field_ordinal >= 0)
15467 tag = _testPackedTypesFieldTags[field_ordinal];
15468 else {
15469 if (unknownFields == null) {
15470 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
15471 }
15472 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
15473 continue;
15474 }
15475 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010015476 switch (tag) {
15477 case 0: {
csharptest99284412011-06-03 14:51:06 -050015478 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010015479 }
15480 default: {
15481 if (pb::WireFormat.IsEndGroupTag(tag)) {
15482 if (unknownFields != null) {
15483 this.UnknownFields = unknownFields.Build();
15484 }
15485 return this;
15486 }
15487 if (unknownFields == null) {
15488 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
15489 }
csharptestd2af9e92011-06-03 21:35:02 -050015490 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015491 break;
15492 }
csharptest6da31702011-06-04 12:52:57 -050015493 case 722:
15494 case 720: {
csharptestd2af9e92011-06-03 21:35:02 -050015495 input.ReadPrimitiveArray(pbd::FieldType.Int32, tag, field_name, result.packedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015496 break;
15497 }
csharptest6da31702011-06-04 12:52:57 -050015498 case 730:
15499 case 728: {
csharptestd2af9e92011-06-03 21:35:02 -050015500 input.ReadPrimitiveArray(pbd::FieldType.Int64, tag, field_name, result.packedInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015501 break;
15502 }
csharptest6da31702011-06-04 12:52:57 -050015503 case 738:
15504 case 736: {
csharptestd2af9e92011-06-03 21:35:02 -050015505 input.ReadPrimitiveArray(pbd::FieldType.UInt32, tag, field_name, result.packedUint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015506 break;
15507 }
csharptest6da31702011-06-04 12:52:57 -050015508 case 746:
15509 case 744: {
csharptestd2af9e92011-06-03 21:35:02 -050015510 input.ReadPrimitiveArray(pbd::FieldType.UInt64, tag, field_name, result.packedUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015511 break;
15512 }
csharptest6da31702011-06-04 12:52:57 -050015513 case 754:
15514 case 752: {
csharptestd2af9e92011-06-03 21:35:02 -050015515 input.ReadPrimitiveArray(pbd::FieldType.SInt32, tag, field_name, result.packedSint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015516 break;
15517 }
csharptest6da31702011-06-04 12:52:57 -050015518 case 762:
15519 case 760: {
csharptestd2af9e92011-06-03 21:35:02 -050015520 input.ReadPrimitiveArray(pbd::FieldType.SInt64, tag, field_name, result.packedSint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015521 break;
15522 }
csharptest6da31702011-06-04 12:52:57 -050015523 case 770:
15524 case 773: {
csharptestd2af9e92011-06-03 21:35:02 -050015525 input.ReadPrimitiveArray(pbd::FieldType.Fixed32, tag, field_name, result.packedFixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015526 break;
15527 }
csharptest6da31702011-06-04 12:52:57 -050015528 case 778:
15529 case 777: {
csharptestd2af9e92011-06-03 21:35:02 -050015530 input.ReadPrimitiveArray(pbd::FieldType.Fixed64, tag, field_name, result.packedFixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015531 break;
15532 }
csharptest6da31702011-06-04 12:52:57 -050015533 case 786:
15534 case 789: {
csharptestd2af9e92011-06-03 21:35:02 -050015535 input.ReadPrimitiveArray(pbd::FieldType.SFixed32, tag, field_name, result.packedSfixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015536 break;
15537 }
csharptest6da31702011-06-04 12:52:57 -050015538 case 794:
15539 case 793: {
csharptestd2af9e92011-06-03 21:35:02 -050015540 input.ReadPrimitiveArray(pbd::FieldType.SFixed64, tag, field_name, result.packedSfixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015541 break;
15542 }
csharptest6da31702011-06-04 12:52:57 -050015543 case 802:
15544 case 805: {
csharptestd2af9e92011-06-03 21:35:02 -050015545 input.ReadPrimitiveArray(pbd::FieldType.Float, tag, field_name, result.packedFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015546 break;
15547 }
csharptest6da31702011-06-04 12:52:57 -050015548 case 810:
15549 case 809: {
csharptestd2af9e92011-06-03 21:35:02 -050015550 input.ReadPrimitiveArray(pbd::FieldType.Double, tag, field_name, result.packedDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015551 break;
15552 }
csharptest6da31702011-06-04 12:52:57 -050015553 case 818:
15554 case 816: {
csharptestd2af9e92011-06-03 21:35:02 -050015555 input.ReadPrimitiveArray(pbd::FieldType.Bool, tag, field_name, result.packedBool_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015556 break;
15557 }
csharptest6da31702011-06-04 12:52:57 -050015558 case 826:
15559 case 824: {
csharptestd2af9e92011-06-03 21:35:02 -050015560 scg::ICollection<object> unknownItems;
15561 input.ReadEnumArray<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>(tag, field_name, result.packedEnum_, out unknownItems);
15562 if (unknownItems != null) {
15563 if (unknownFields == null) {
15564 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015565 }
csharptestd2af9e92011-06-03 21:35:02 -050015566 foreach (object rawValue in unknownItems)
15567 if (rawValue is int)
15568 unknownFields.MergeVarintField(103, (ulong)(int)rawValue);
Jon Skeet82bb0f12011-04-03 20:17:12 +010015569 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010015570 break;
15571 }
15572 }
15573 }
csharptest123e5342011-06-03 14:15:21 -050015574
15575 if (unknownFields != null) {
15576 this.UnknownFields = unknownFields.Build();
15577 }
15578 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010015579 }
15580
15581
15582 public pbc::IPopsicleList<int> PackedInt32List {
15583 get { return result.packedInt32_; }
15584 }
15585 public int PackedInt32Count {
15586 get { return result.PackedInt32Count; }
15587 }
15588 public int GetPackedInt32(int index) {
15589 return result.GetPackedInt32(index);
15590 }
15591 public Builder SetPackedInt32(int index, int value) {
15592 result.packedInt32_[index] = value;
15593 return this;
15594 }
15595 public Builder AddPackedInt32(int value) {
15596 result.packedInt32_.Add(value);
15597 return this;
15598 }
15599 public Builder AddRangePackedInt32(scg::IEnumerable<int> values) {
15600 base.AddRange(values, result.packedInt32_);
15601 return this;
15602 }
15603 public Builder ClearPackedInt32() {
15604 result.packedInt32_.Clear();
15605 return this;
15606 }
15607
15608 public pbc::IPopsicleList<long> PackedInt64List {
15609 get { return result.packedInt64_; }
15610 }
15611 public int PackedInt64Count {
15612 get { return result.PackedInt64Count; }
15613 }
15614 public long GetPackedInt64(int index) {
15615 return result.GetPackedInt64(index);
15616 }
15617 public Builder SetPackedInt64(int index, long value) {
15618 result.packedInt64_[index] = value;
15619 return this;
15620 }
15621 public Builder AddPackedInt64(long value) {
15622 result.packedInt64_.Add(value);
15623 return this;
15624 }
15625 public Builder AddRangePackedInt64(scg::IEnumerable<long> values) {
15626 base.AddRange(values, result.packedInt64_);
15627 return this;
15628 }
15629 public Builder ClearPackedInt64() {
15630 result.packedInt64_.Clear();
15631 return this;
15632 }
15633
15634 [global::System.CLSCompliant(false)]
15635 public pbc::IPopsicleList<uint> PackedUint32List {
15636 get { return result.packedUint32_; }
15637 }
15638 public int PackedUint32Count {
15639 get { return result.PackedUint32Count; }
15640 }
15641 [global::System.CLSCompliant(false)]
15642 public uint GetPackedUint32(int index) {
15643 return result.GetPackedUint32(index);
15644 }
15645 [global::System.CLSCompliant(false)]
15646 public Builder SetPackedUint32(int index, uint value) {
15647 result.packedUint32_[index] = value;
15648 return this;
15649 }
15650 [global::System.CLSCompliant(false)]
15651 public Builder AddPackedUint32(uint value) {
15652 result.packedUint32_.Add(value);
15653 return this;
15654 }
15655 [global::System.CLSCompliant(false)]
15656 public Builder AddRangePackedUint32(scg::IEnumerable<uint> values) {
15657 base.AddRange(values, result.packedUint32_);
15658 return this;
15659 }
15660 public Builder ClearPackedUint32() {
15661 result.packedUint32_.Clear();
15662 return this;
15663 }
15664
15665 [global::System.CLSCompliant(false)]
15666 public pbc::IPopsicleList<ulong> PackedUint64List {
15667 get { return result.packedUint64_; }
15668 }
15669 public int PackedUint64Count {
15670 get { return result.PackedUint64Count; }
15671 }
15672 [global::System.CLSCompliant(false)]
15673 public ulong GetPackedUint64(int index) {
15674 return result.GetPackedUint64(index);
15675 }
15676 [global::System.CLSCompliant(false)]
15677 public Builder SetPackedUint64(int index, ulong value) {
15678 result.packedUint64_[index] = value;
15679 return this;
15680 }
15681 [global::System.CLSCompliant(false)]
15682 public Builder AddPackedUint64(ulong value) {
15683 result.packedUint64_.Add(value);
15684 return this;
15685 }
15686 [global::System.CLSCompliant(false)]
15687 public Builder AddRangePackedUint64(scg::IEnumerable<ulong> values) {
15688 base.AddRange(values, result.packedUint64_);
15689 return this;
15690 }
15691 public Builder ClearPackedUint64() {
15692 result.packedUint64_.Clear();
15693 return this;
15694 }
15695
15696 public pbc::IPopsicleList<int> PackedSint32List {
15697 get { return result.packedSint32_; }
15698 }
15699 public int PackedSint32Count {
15700 get { return result.PackedSint32Count; }
15701 }
15702 public int GetPackedSint32(int index) {
15703 return result.GetPackedSint32(index);
15704 }
15705 public Builder SetPackedSint32(int index, int value) {
15706 result.packedSint32_[index] = value;
15707 return this;
15708 }
15709 public Builder AddPackedSint32(int value) {
15710 result.packedSint32_.Add(value);
15711 return this;
15712 }
15713 public Builder AddRangePackedSint32(scg::IEnumerable<int> values) {
15714 base.AddRange(values, result.packedSint32_);
15715 return this;
15716 }
15717 public Builder ClearPackedSint32() {
15718 result.packedSint32_.Clear();
15719 return this;
15720 }
15721
15722 public pbc::IPopsicleList<long> PackedSint64List {
15723 get { return result.packedSint64_; }
15724 }
15725 public int PackedSint64Count {
15726 get { return result.PackedSint64Count; }
15727 }
15728 public long GetPackedSint64(int index) {
15729 return result.GetPackedSint64(index);
15730 }
15731 public Builder SetPackedSint64(int index, long value) {
15732 result.packedSint64_[index] = value;
15733 return this;
15734 }
15735 public Builder AddPackedSint64(long value) {
15736 result.packedSint64_.Add(value);
15737 return this;
15738 }
15739 public Builder AddRangePackedSint64(scg::IEnumerable<long> values) {
15740 base.AddRange(values, result.packedSint64_);
15741 return this;
15742 }
15743 public Builder ClearPackedSint64() {
15744 result.packedSint64_.Clear();
15745 return this;
15746 }
15747
15748 [global::System.CLSCompliant(false)]
15749 public pbc::IPopsicleList<uint> PackedFixed32List {
15750 get { return result.packedFixed32_; }
15751 }
15752 public int PackedFixed32Count {
15753 get { return result.PackedFixed32Count; }
15754 }
15755 [global::System.CLSCompliant(false)]
15756 public uint GetPackedFixed32(int index) {
15757 return result.GetPackedFixed32(index);
15758 }
15759 [global::System.CLSCompliant(false)]
15760 public Builder SetPackedFixed32(int index, uint value) {
15761 result.packedFixed32_[index] = value;
15762 return this;
15763 }
15764 [global::System.CLSCompliant(false)]
15765 public Builder AddPackedFixed32(uint value) {
15766 result.packedFixed32_.Add(value);
15767 return this;
15768 }
15769 [global::System.CLSCompliant(false)]
15770 public Builder AddRangePackedFixed32(scg::IEnumerable<uint> values) {
15771 base.AddRange(values, result.packedFixed32_);
15772 return this;
15773 }
15774 public Builder ClearPackedFixed32() {
15775 result.packedFixed32_.Clear();
15776 return this;
15777 }
15778
15779 [global::System.CLSCompliant(false)]
15780 public pbc::IPopsicleList<ulong> PackedFixed64List {
15781 get { return result.packedFixed64_; }
15782 }
15783 public int PackedFixed64Count {
15784 get { return result.PackedFixed64Count; }
15785 }
15786 [global::System.CLSCompliant(false)]
15787 public ulong GetPackedFixed64(int index) {
15788 return result.GetPackedFixed64(index);
15789 }
15790 [global::System.CLSCompliant(false)]
15791 public Builder SetPackedFixed64(int index, ulong value) {
15792 result.packedFixed64_[index] = value;
15793 return this;
15794 }
15795 [global::System.CLSCompliant(false)]
15796 public Builder AddPackedFixed64(ulong value) {
15797 result.packedFixed64_.Add(value);
15798 return this;
15799 }
15800 [global::System.CLSCompliant(false)]
15801 public Builder AddRangePackedFixed64(scg::IEnumerable<ulong> values) {
15802 base.AddRange(values, result.packedFixed64_);
15803 return this;
15804 }
15805 public Builder ClearPackedFixed64() {
15806 result.packedFixed64_.Clear();
15807 return this;
15808 }
15809
15810 public pbc::IPopsicleList<int> PackedSfixed32List {
15811 get { return result.packedSfixed32_; }
15812 }
15813 public int PackedSfixed32Count {
15814 get { return result.PackedSfixed32Count; }
15815 }
15816 public int GetPackedSfixed32(int index) {
15817 return result.GetPackedSfixed32(index);
15818 }
15819 public Builder SetPackedSfixed32(int index, int value) {
15820 result.packedSfixed32_[index] = value;
15821 return this;
15822 }
15823 public Builder AddPackedSfixed32(int value) {
15824 result.packedSfixed32_.Add(value);
15825 return this;
15826 }
15827 public Builder AddRangePackedSfixed32(scg::IEnumerable<int> values) {
15828 base.AddRange(values, result.packedSfixed32_);
15829 return this;
15830 }
15831 public Builder ClearPackedSfixed32() {
15832 result.packedSfixed32_.Clear();
15833 return this;
15834 }
15835
15836 public pbc::IPopsicleList<long> PackedSfixed64List {
15837 get { return result.packedSfixed64_; }
15838 }
15839 public int PackedSfixed64Count {
15840 get { return result.PackedSfixed64Count; }
15841 }
15842 public long GetPackedSfixed64(int index) {
15843 return result.GetPackedSfixed64(index);
15844 }
15845 public Builder SetPackedSfixed64(int index, long value) {
15846 result.packedSfixed64_[index] = value;
15847 return this;
15848 }
15849 public Builder AddPackedSfixed64(long value) {
15850 result.packedSfixed64_.Add(value);
15851 return this;
15852 }
15853 public Builder AddRangePackedSfixed64(scg::IEnumerable<long> values) {
15854 base.AddRange(values, result.packedSfixed64_);
15855 return this;
15856 }
15857 public Builder ClearPackedSfixed64() {
15858 result.packedSfixed64_.Clear();
15859 return this;
15860 }
15861
15862 public pbc::IPopsicleList<float> PackedFloatList {
15863 get { return result.packedFloat_; }
15864 }
15865 public int PackedFloatCount {
15866 get { return result.PackedFloatCount; }
15867 }
15868 public float GetPackedFloat(int index) {
15869 return result.GetPackedFloat(index);
15870 }
15871 public Builder SetPackedFloat(int index, float value) {
15872 result.packedFloat_[index] = value;
15873 return this;
15874 }
15875 public Builder AddPackedFloat(float value) {
15876 result.packedFloat_.Add(value);
15877 return this;
15878 }
15879 public Builder AddRangePackedFloat(scg::IEnumerable<float> values) {
15880 base.AddRange(values, result.packedFloat_);
15881 return this;
15882 }
15883 public Builder ClearPackedFloat() {
15884 result.packedFloat_.Clear();
15885 return this;
15886 }
15887
15888 public pbc::IPopsicleList<double> PackedDoubleList {
15889 get { return result.packedDouble_; }
15890 }
15891 public int PackedDoubleCount {
15892 get { return result.PackedDoubleCount; }
15893 }
15894 public double GetPackedDouble(int index) {
15895 return result.GetPackedDouble(index);
15896 }
15897 public Builder SetPackedDouble(int index, double value) {
15898 result.packedDouble_[index] = value;
15899 return this;
15900 }
15901 public Builder AddPackedDouble(double value) {
15902 result.packedDouble_.Add(value);
15903 return this;
15904 }
15905 public Builder AddRangePackedDouble(scg::IEnumerable<double> values) {
15906 base.AddRange(values, result.packedDouble_);
15907 return this;
15908 }
15909 public Builder ClearPackedDouble() {
15910 result.packedDouble_.Clear();
15911 return this;
15912 }
15913
15914 public pbc::IPopsicleList<bool> PackedBoolList {
15915 get { return result.packedBool_; }
15916 }
15917 public int PackedBoolCount {
15918 get { return result.PackedBoolCount; }
15919 }
15920 public bool GetPackedBool(int index) {
15921 return result.GetPackedBool(index);
15922 }
15923 public Builder SetPackedBool(int index, bool value) {
15924 result.packedBool_[index] = value;
15925 return this;
15926 }
15927 public Builder AddPackedBool(bool value) {
15928 result.packedBool_.Add(value);
15929 return this;
15930 }
15931 public Builder AddRangePackedBool(scg::IEnumerable<bool> values) {
15932 base.AddRange(values, result.packedBool_);
15933 return this;
15934 }
15935 public Builder ClearPackedBool() {
15936 result.packedBool_.Clear();
15937 return this;
15938 }
15939
15940 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> PackedEnumList {
15941 get { return result.packedEnum_; }
15942 }
15943 public int PackedEnumCount {
15944 get { return result.PackedEnumCount; }
15945 }
15946 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetPackedEnum(int index) {
15947 return result.GetPackedEnum(index);
15948 }
15949 public Builder SetPackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
15950 result.packedEnum_[index] = value;
15951 return this;
15952 }
15953 public Builder AddPackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
15954 result.packedEnum_.Add(value);
15955 return this;
15956 }
15957 public Builder AddRangePackedEnum(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> values) {
15958 base.AddRange(values, result.packedEnum_);
15959 return this;
15960 }
15961 public Builder ClearPackedEnum() {
15962 result.packedEnum_.Clear();
15963 return this;
15964 }
15965 }
15966 static TestPackedTypes() {
15967 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
15968 }
15969 }
15970
csharptest445bdce2011-05-20 15:50:54 -050015971 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
15972 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
15973 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010015974 public sealed partial class TestUnpackedTypes : pb::GeneratedMessage<TestUnpackedTypes, TestUnpackedTypes.Builder> {
15975 private static readonly TestUnpackedTypes defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050015976 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" };
15977 private static readonly uint[] _testUnpackedTypesFieldTags = new uint[] { 816, 809, 824, 773, 777, 805, 720, 728, 789, 793, 752, 760, 736, 744 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010015978 public static TestUnpackedTypes DefaultInstance {
15979 get { return defaultInstance; }
15980 }
15981
15982 public override TestUnpackedTypes DefaultInstanceForType {
15983 get { return defaultInstance; }
15984 }
15985
15986 protected override TestUnpackedTypes ThisMessage {
15987 get { return this; }
15988 }
15989
15990 public static pbd::MessageDescriptor Descriptor {
15991 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestUnpackedTypes__Descriptor; }
15992 }
15993
15994 protected override pb::FieldAccess.FieldAccessorTable<TestUnpackedTypes, TestUnpackedTypes.Builder> InternalFieldAccessors {
15995 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestUnpackedTypes__FieldAccessorTable; }
15996 }
15997
15998 public const int UnpackedInt32FieldNumber = 90;
15999 private pbc::PopsicleList<int> unpackedInt32_ = new pbc::PopsicleList<int>();
16000 public scg::IList<int> UnpackedInt32List {
16001 get { return pbc::Lists.AsReadOnly(unpackedInt32_); }
16002 }
16003 public int UnpackedInt32Count {
16004 get { return unpackedInt32_.Count; }
16005 }
16006 public int GetUnpackedInt32(int index) {
16007 return unpackedInt32_[index];
16008 }
16009
16010 public const int UnpackedInt64FieldNumber = 91;
16011 private pbc::PopsicleList<long> unpackedInt64_ = new pbc::PopsicleList<long>();
16012 public scg::IList<long> UnpackedInt64List {
16013 get { return pbc::Lists.AsReadOnly(unpackedInt64_); }
16014 }
16015 public int UnpackedInt64Count {
16016 get { return unpackedInt64_.Count; }
16017 }
16018 public long GetUnpackedInt64(int index) {
16019 return unpackedInt64_[index];
16020 }
16021
16022 public const int UnpackedUint32FieldNumber = 92;
16023 private pbc::PopsicleList<uint> unpackedUint32_ = new pbc::PopsicleList<uint>();
16024 [global::System.CLSCompliant(false)]
16025 public scg::IList<uint> UnpackedUint32List {
16026 get { return pbc::Lists.AsReadOnly(unpackedUint32_); }
16027 }
16028 public int UnpackedUint32Count {
16029 get { return unpackedUint32_.Count; }
16030 }
16031 [global::System.CLSCompliant(false)]
16032 public uint GetUnpackedUint32(int index) {
16033 return unpackedUint32_[index];
16034 }
16035
16036 public const int UnpackedUint64FieldNumber = 93;
16037 private pbc::PopsicleList<ulong> unpackedUint64_ = new pbc::PopsicleList<ulong>();
16038 [global::System.CLSCompliant(false)]
16039 public scg::IList<ulong> UnpackedUint64List {
16040 get { return pbc::Lists.AsReadOnly(unpackedUint64_); }
16041 }
16042 public int UnpackedUint64Count {
16043 get { return unpackedUint64_.Count; }
16044 }
16045 [global::System.CLSCompliant(false)]
16046 public ulong GetUnpackedUint64(int index) {
16047 return unpackedUint64_[index];
16048 }
16049
16050 public const int UnpackedSint32FieldNumber = 94;
16051 private pbc::PopsicleList<int> unpackedSint32_ = new pbc::PopsicleList<int>();
16052 public scg::IList<int> UnpackedSint32List {
16053 get { return pbc::Lists.AsReadOnly(unpackedSint32_); }
16054 }
16055 public int UnpackedSint32Count {
16056 get { return unpackedSint32_.Count; }
16057 }
16058 public int GetUnpackedSint32(int index) {
16059 return unpackedSint32_[index];
16060 }
16061
16062 public const int UnpackedSint64FieldNumber = 95;
16063 private pbc::PopsicleList<long> unpackedSint64_ = new pbc::PopsicleList<long>();
16064 public scg::IList<long> UnpackedSint64List {
16065 get { return pbc::Lists.AsReadOnly(unpackedSint64_); }
16066 }
16067 public int UnpackedSint64Count {
16068 get { return unpackedSint64_.Count; }
16069 }
16070 public long GetUnpackedSint64(int index) {
16071 return unpackedSint64_[index];
16072 }
16073
16074 public const int UnpackedFixed32FieldNumber = 96;
16075 private pbc::PopsicleList<uint> unpackedFixed32_ = new pbc::PopsicleList<uint>();
16076 [global::System.CLSCompliant(false)]
16077 public scg::IList<uint> UnpackedFixed32List {
16078 get { return pbc::Lists.AsReadOnly(unpackedFixed32_); }
16079 }
16080 public int UnpackedFixed32Count {
16081 get { return unpackedFixed32_.Count; }
16082 }
16083 [global::System.CLSCompliant(false)]
16084 public uint GetUnpackedFixed32(int index) {
16085 return unpackedFixed32_[index];
16086 }
16087
16088 public const int UnpackedFixed64FieldNumber = 97;
16089 private pbc::PopsicleList<ulong> unpackedFixed64_ = new pbc::PopsicleList<ulong>();
16090 [global::System.CLSCompliant(false)]
16091 public scg::IList<ulong> UnpackedFixed64List {
16092 get { return pbc::Lists.AsReadOnly(unpackedFixed64_); }
16093 }
16094 public int UnpackedFixed64Count {
16095 get { return unpackedFixed64_.Count; }
16096 }
16097 [global::System.CLSCompliant(false)]
16098 public ulong GetUnpackedFixed64(int index) {
16099 return unpackedFixed64_[index];
16100 }
16101
16102 public const int UnpackedSfixed32FieldNumber = 98;
16103 private pbc::PopsicleList<int> unpackedSfixed32_ = new pbc::PopsicleList<int>();
16104 public scg::IList<int> UnpackedSfixed32List {
16105 get { return pbc::Lists.AsReadOnly(unpackedSfixed32_); }
16106 }
16107 public int UnpackedSfixed32Count {
16108 get { return unpackedSfixed32_.Count; }
16109 }
16110 public int GetUnpackedSfixed32(int index) {
16111 return unpackedSfixed32_[index];
16112 }
16113
16114 public const int UnpackedSfixed64FieldNumber = 99;
16115 private pbc::PopsicleList<long> unpackedSfixed64_ = new pbc::PopsicleList<long>();
16116 public scg::IList<long> UnpackedSfixed64List {
16117 get { return pbc::Lists.AsReadOnly(unpackedSfixed64_); }
16118 }
16119 public int UnpackedSfixed64Count {
16120 get { return unpackedSfixed64_.Count; }
16121 }
16122 public long GetUnpackedSfixed64(int index) {
16123 return unpackedSfixed64_[index];
16124 }
16125
16126 public const int UnpackedFloatFieldNumber = 100;
16127 private pbc::PopsicleList<float> unpackedFloat_ = new pbc::PopsicleList<float>();
16128 public scg::IList<float> UnpackedFloatList {
16129 get { return pbc::Lists.AsReadOnly(unpackedFloat_); }
16130 }
16131 public int UnpackedFloatCount {
16132 get { return unpackedFloat_.Count; }
16133 }
16134 public float GetUnpackedFloat(int index) {
16135 return unpackedFloat_[index];
16136 }
16137
16138 public const int UnpackedDoubleFieldNumber = 101;
16139 private pbc::PopsicleList<double> unpackedDouble_ = new pbc::PopsicleList<double>();
16140 public scg::IList<double> UnpackedDoubleList {
16141 get { return pbc::Lists.AsReadOnly(unpackedDouble_); }
16142 }
16143 public int UnpackedDoubleCount {
16144 get { return unpackedDouble_.Count; }
16145 }
16146 public double GetUnpackedDouble(int index) {
16147 return unpackedDouble_[index];
16148 }
16149
16150 public const int UnpackedBoolFieldNumber = 102;
16151 private pbc::PopsicleList<bool> unpackedBool_ = new pbc::PopsicleList<bool>();
16152 public scg::IList<bool> UnpackedBoolList {
16153 get { return pbc::Lists.AsReadOnly(unpackedBool_); }
16154 }
16155 public int UnpackedBoolCount {
16156 get { return unpackedBool_.Count; }
16157 }
16158 public bool GetUnpackedBool(int index) {
16159 return unpackedBool_[index];
16160 }
16161
16162 public const int UnpackedEnumFieldNumber = 103;
16163 private pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> unpackedEnum_ = new pbc::PopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>();
16164 public scg::IList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> UnpackedEnumList {
16165 get { return pbc::Lists.AsReadOnly(unpackedEnum_); }
16166 }
16167 public int UnpackedEnumCount {
16168 get { return unpackedEnum_.Count; }
16169 }
16170 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetUnpackedEnum(int index) {
16171 return unpackedEnum_[index];
16172 }
16173
16174 public override bool IsInitialized {
16175 get {
16176 return true;
16177 }
16178 }
16179
csharptestffafdaa2011-06-03 12:58:14 -050016180 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010016181 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050016182 string[] field_names = _testUnpackedTypesFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +010016183 if (unpackedInt32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016184 output.WriteArray(pbd::FieldType.Int32, 90, field_names[6], unpackedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016185 }
16186 if (unpackedInt64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016187 output.WriteArray(pbd::FieldType.Int64, 91, field_names[7], unpackedInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016188 }
16189 if (unpackedUint32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016190 output.WriteArray(pbd::FieldType.UInt32, 92, field_names[12], unpackedUint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016191 }
16192 if (unpackedUint64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016193 output.WriteArray(pbd::FieldType.UInt64, 93, field_names[13], unpackedUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016194 }
16195 if (unpackedSint32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016196 output.WriteArray(pbd::FieldType.SInt32, 94, field_names[10], unpackedSint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016197 }
16198 if (unpackedSint64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016199 output.WriteArray(pbd::FieldType.SInt64, 95, field_names[11], unpackedSint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016200 }
16201 if (unpackedFixed32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016202 output.WriteArray(pbd::FieldType.Fixed32, 96, field_names[3], unpackedFixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016203 }
16204 if (unpackedFixed64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016205 output.WriteArray(pbd::FieldType.Fixed64, 97, field_names[4], unpackedFixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016206 }
16207 if (unpackedSfixed32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016208 output.WriteArray(pbd::FieldType.SFixed32, 98, field_names[8], unpackedSfixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016209 }
16210 if (unpackedSfixed64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016211 output.WriteArray(pbd::FieldType.SFixed64, 99, field_names[9], unpackedSfixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016212 }
16213 if (unpackedFloat_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016214 output.WriteArray(pbd::FieldType.Float, 100, field_names[5], unpackedFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016215 }
16216 if (unpackedDouble_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016217 output.WriteArray(pbd::FieldType.Double, 101, field_names[1], unpackedDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016218 }
16219 if (unpackedBool_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016220 output.WriteArray(pbd::FieldType.Bool, 102, field_names[0], unpackedBool_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016221 }
16222 if (unpackedEnum_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050016223 output.WriteArray(pbd::FieldType.Enum, 103, field_names[2], unpackedEnum_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016224 }
16225 UnknownFields.WriteTo(output);
16226 }
16227
16228 private int memoizedSerializedSize = -1;
16229 public override int SerializedSize {
16230 get {
16231 int size = memoizedSerializedSize;
16232 if (size != -1) return size;
16233
16234 size = 0;
16235 {
16236 int dataSize = 0;
16237 foreach (int element in UnpackedInt32List) {
16238 dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element);
16239 }
16240 size += dataSize;
16241 size += 2 * unpackedInt32_.Count;
16242 }
16243 {
16244 int dataSize = 0;
16245 foreach (long element in UnpackedInt64List) {
16246 dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element);
16247 }
16248 size += dataSize;
16249 size += 2 * unpackedInt64_.Count;
16250 }
16251 {
16252 int dataSize = 0;
16253 foreach (uint element in UnpackedUint32List) {
16254 dataSize += pb::CodedOutputStream.ComputeUInt32SizeNoTag(element);
16255 }
16256 size += dataSize;
16257 size += 2 * unpackedUint32_.Count;
16258 }
16259 {
16260 int dataSize = 0;
16261 foreach (ulong element in UnpackedUint64List) {
16262 dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element);
16263 }
16264 size += dataSize;
16265 size += 2 * unpackedUint64_.Count;
16266 }
16267 {
16268 int dataSize = 0;
16269 foreach (int element in UnpackedSint32List) {
16270 dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element);
16271 }
16272 size += dataSize;
16273 size += 2 * unpackedSint32_.Count;
16274 }
16275 {
16276 int dataSize = 0;
16277 foreach (long element in UnpackedSint64List) {
16278 dataSize += pb::CodedOutputStream.ComputeSInt64SizeNoTag(element);
16279 }
16280 size += dataSize;
16281 size += 2 * unpackedSint64_.Count;
16282 }
16283 {
16284 int dataSize = 0;
16285 dataSize = 4 * unpackedFixed32_.Count;
16286 size += dataSize;
16287 size += 2 * unpackedFixed32_.Count;
16288 }
16289 {
16290 int dataSize = 0;
16291 dataSize = 8 * unpackedFixed64_.Count;
16292 size += dataSize;
16293 size += 2 * unpackedFixed64_.Count;
16294 }
16295 {
16296 int dataSize = 0;
16297 dataSize = 4 * unpackedSfixed32_.Count;
16298 size += dataSize;
16299 size += 2 * unpackedSfixed32_.Count;
16300 }
16301 {
16302 int dataSize = 0;
16303 dataSize = 8 * unpackedSfixed64_.Count;
16304 size += dataSize;
16305 size += 2 * unpackedSfixed64_.Count;
16306 }
16307 {
16308 int dataSize = 0;
16309 dataSize = 4 * unpackedFloat_.Count;
16310 size += dataSize;
16311 size += 2 * unpackedFloat_.Count;
16312 }
16313 {
16314 int dataSize = 0;
16315 dataSize = 8 * unpackedDouble_.Count;
16316 size += dataSize;
16317 size += 2 * unpackedDouble_.Count;
16318 }
16319 {
16320 int dataSize = 0;
16321 dataSize = 1 * unpackedBool_.Count;
16322 size += dataSize;
16323 size += 2 * unpackedBool_.Count;
16324 }
16325 {
16326 int dataSize = 0;
16327 if (unpackedEnum_.Count > 0) {
16328 foreach (global::Google.ProtocolBuffers.TestProtos.ForeignEnum element in unpackedEnum_) {
16329 dataSize += pb::CodedOutputStream.ComputeEnumSizeNoTag((int) element);
16330 }
16331 size += dataSize;
16332 size += 2 * unpackedEnum_.Count;
16333 }
16334 }
16335 size += UnknownFields.SerializedSize;
16336 memoizedSerializedSize = size;
16337 return size;
16338 }
16339 }
16340
16341 public static TestUnpackedTypes ParseFrom(pb::ByteString data) {
16342 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
16343 }
16344 public static TestUnpackedTypes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
16345 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
16346 }
16347 public static TestUnpackedTypes ParseFrom(byte[] data) {
16348 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
16349 }
16350 public static TestUnpackedTypes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
16351 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
16352 }
16353 public static TestUnpackedTypes ParseFrom(global::System.IO.Stream input) {
16354 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
16355 }
16356 public static TestUnpackedTypes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
16357 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
16358 }
16359 public static TestUnpackedTypes ParseDelimitedFrom(global::System.IO.Stream input) {
16360 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
16361 }
16362 public static TestUnpackedTypes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
16363 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
16364 }
csharptest17699c22011-06-03 21:57:15 -050016365 public static TestUnpackedTypes ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010016366 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
16367 }
csharptest17699c22011-06-03 21:57:15 -050016368 public static TestUnpackedTypes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010016369 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
16370 }
16371 public static Builder CreateBuilder() { return new Builder(); }
16372 public override Builder ToBuilder() { return CreateBuilder(this); }
16373 public override Builder CreateBuilderForType() { return new Builder(); }
16374 public static Builder CreateBuilder(TestUnpackedTypes prototype) {
16375 return (Builder) new Builder().MergeFrom(prototype);
16376 }
16377
csharptest445bdce2011-05-20 15:50:54 -050016378 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
16379 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
16380 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010016381 public sealed partial class Builder : pb::GeneratedBuilder<TestUnpackedTypes, Builder> {
16382 protected override Builder ThisBuilder {
16383 get { return this; }
16384 }
16385 public Builder() {}
16386
16387 TestUnpackedTypes result = new TestUnpackedTypes();
16388
16389 protected override TestUnpackedTypes MessageBeingBuilt {
16390 get { return result; }
16391 }
16392
16393 public override Builder Clear() {
16394 result = new TestUnpackedTypes();
16395 return this;
16396 }
16397
16398 public override Builder Clone() {
16399 return new Builder().MergeFrom(result);
16400 }
16401
16402 public override pbd::MessageDescriptor DescriptorForType {
16403 get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.Descriptor; }
16404 }
16405
16406 public override TestUnpackedTypes DefaultInstanceForType {
16407 get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.DefaultInstance; }
16408 }
16409
16410 public override TestUnpackedTypes BuildPartial() {
16411 if (result == null) {
16412 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
16413 }
16414 result.unpackedInt32_.MakeReadOnly();
16415 result.unpackedInt64_.MakeReadOnly();
16416 result.unpackedUint32_.MakeReadOnly();
16417 result.unpackedUint64_.MakeReadOnly();
16418 result.unpackedSint32_.MakeReadOnly();
16419 result.unpackedSint64_.MakeReadOnly();
16420 result.unpackedFixed32_.MakeReadOnly();
16421 result.unpackedFixed64_.MakeReadOnly();
16422 result.unpackedSfixed32_.MakeReadOnly();
16423 result.unpackedSfixed64_.MakeReadOnly();
16424 result.unpackedFloat_.MakeReadOnly();
16425 result.unpackedDouble_.MakeReadOnly();
16426 result.unpackedBool_.MakeReadOnly();
16427 result.unpackedEnum_.MakeReadOnly();
16428 TestUnpackedTypes returnMe = result;
16429 result = null;
16430 return returnMe;
16431 }
16432
16433 public override Builder MergeFrom(pb::IMessage other) {
16434 if (other is TestUnpackedTypes) {
16435 return MergeFrom((TestUnpackedTypes) other);
16436 } else {
16437 base.MergeFrom(other);
16438 return this;
16439 }
16440 }
16441
16442 public override Builder MergeFrom(TestUnpackedTypes other) {
16443 if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedTypes.DefaultInstance) return this;
16444 if (other.unpackedInt32_.Count != 0) {
16445 base.AddRange(other.unpackedInt32_, result.unpackedInt32_);
16446 }
16447 if (other.unpackedInt64_.Count != 0) {
16448 base.AddRange(other.unpackedInt64_, result.unpackedInt64_);
16449 }
16450 if (other.unpackedUint32_.Count != 0) {
16451 base.AddRange(other.unpackedUint32_, result.unpackedUint32_);
16452 }
16453 if (other.unpackedUint64_.Count != 0) {
16454 base.AddRange(other.unpackedUint64_, result.unpackedUint64_);
16455 }
16456 if (other.unpackedSint32_.Count != 0) {
16457 base.AddRange(other.unpackedSint32_, result.unpackedSint32_);
16458 }
16459 if (other.unpackedSint64_.Count != 0) {
16460 base.AddRange(other.unpackedSint64_, result.unpackedSint64_);
16461 }
16462 if (other.unpackedFixed32_.Count != 0) {
16463 base.AddRange(other.unpackedFixed32_, result.unpackedFixed32_);
16464 }
16465 if (other.unpackedFixed64_.Count != 0) {
16466 base.AddRange(other.unpackedFixed64_, result.unpackedFixed64_);
16467 }
16468 if (other.unpackedSfixed32_.Count != 0) {
16469 base.AddRange(other.unpackedSfixed32_, result.unpackedSfixed32_);
16470 }
16471 if (other.unpackedSfixed64_.Count != 0) {
16472 base.AddRange(other.unpackedSfixed64_, result.unpackedSfixed64_);
16473 }
16474 if (other.unpackedFloat_.Count != 0) {
16475 base.AddRange(other.unpackedFloat_, result.unpackedFloat_);
16476 }
16477 if (other.unpackedDouble_.Count != 0) {
16478 base.AddRange(other.unpackedDouble_, result.unpackedDouble_);
16479 }
16480 if (other.unpackedBool_.Count != 0) {
16481 base.AddRange(other.unpackedBool_, result.unpackedBool_);
16482 }
16483 if (other.unpackedEnum_.Count != 0) {
16484 base.AddRange(other.unpackedEnum_, result.unpackedEnum_);
16485 }
16486 this.MergeUnknownFields(other.UnknownFields);
16487 return this;
16488 }
16489
csharptest17699c22011-06-03 21:57:15 -050016490 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010016491 return MergeFrom(input, pb::ExtensionRegistry.Empty);
16492 }
16493
csharptest17699c22011-06-03 21:57:15 -050016494 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010016495 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050016496 uint tag;
16497 string field_name;
16498 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050016499 if(tag == 0 && field_name != null) {
16500 int field_ordinal = global::System.Array.BinarySearch(_testUnpackedTypesFieldNames, field_name, global::System.StringComparer.Ordinal);
16501 if(field_ordinal >= 0)
16502 tag = _testUnpackedTypesFieldTags[field_ordinal];
16503 else {
16504 if (unknownFields == null) {
16505 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
16506 }
16507 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
16508 continue;
16509 }
16510 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010016511 switch (tag) {
16512 case 0: {
csharptest99284412011-06-03 14:51:06 -050016513 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010016514 }
16515 default: {
16516 if (pb::WireFormat.IsEndGroupTag(tag)) {
16517 if (unknownFields != null) {
16518 this.UnknownFields = unknownFields.Build();
16519 }
16520 return this;
16521 }
16522 if (unknownFields == null) {
16523 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
16524 }
csharptestd2af9e92011-06-03 21:35:02 -050016525 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016526 break;
16527 }
csharptest6da31702011-06-04 12:52:57 -050016528 case 722:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016529 case 720: {
csharptestd2af9e92011-06-03 21:35:02 -050016530 input.ReadPrimitiveArray(pbd::FieldType.Int32, tag, field_name, result.unpackedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016531 break;
16532 }
csharptest6da31702011-06-04 12:52:57 -050016533 case 730:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016534 case 728: {
csharptestd2af9e92011-06-03 21:35:02 -050016535 input.ReadPrimitiveArray(pbd::FieldType.Int64, tag, field_name, result.unpackedInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016536 break;
16537 }
csharptest6da31702011-06-04 12:52:57 -050016538 case 738:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016539 case 736: {
csharptestd2af9e92011-06-03 21:35:02 -050016540 input.ReadPrimitiveArray(pbd::FieldType.UInt32, tag, field_name, result.unpackedUint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016541 break;
16542 }
csharptest6da31702011-06-04 12:52:57 -050016543 case 746:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016544 case 744: {
csharptestd2af9e92011-06-03 21:35:02 -050016545 input.ReadPrimitiveArray(pbd::FieldType.UInt64, tag, field_name, result.unpackedUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016546 break;
16547 }
csharptest6da31702011-06-04 12:52:57 -050016548 case 754:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016549 case 752: {
csharptestd2af9e92011-06-03 21:35:02 -050016550 input.ReadPrimitiveArray(pbd::FieldType.SInt32, tag, field_name, result.unpackedSint32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016551 break;
16552 }
csharptest6da31702011-06-04 12:52:57 -050016553 case 762:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016554 case 760: {
csharptestd2af9e92011-06-03 21:35:02 -050016555 input.ReadPrimitiveArray(pbd::FieldType.SInt64, tag, field_name, result.unpackedSint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016556 break;
16557 }
csharptest6da31702011-06-04 12:52:57 -050016558 case 770:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016559 case 773: {
csharptestd2af9e92011-06-03 21:35:02 -050016560 input.ReadPrimitiveArray(pbd::FieldType.Fixed32, tag, field_name, result.unpackedFixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016561 break;
16562 }
csharptest6da31702011-06-04 12:52:57 -050016563 case 778:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016564 case 777: {
csharptestd2af9e92011-06-03 21:35:02 -050016565 input.ReadPrimitiveArray(pbd::FieldType.Fixed64, tag, field_name, result.unpackedFixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016566 break;
16567 }
csharptest6da31702011-06-04 12:52:57 -050016568 case 786:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016569 case 789: {
csharptestd2af9e92011-06-03 21:35:02 -050016570 input.ReadPrimitiveArray(pbd::FieldType.SFixed32, tag, field_name, result.unpackedSfixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016571 break;
16572 }
csharptest6da31702011-06-04 12:52:57 -050016573 case 794:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016574 case 793: {
csharptestd2af9e92011-06-03 21:35:02 -050016575 input.ReadPrimitiveArray(pbd::FieldType.SFixed64, tag, field_name, result.unpackedSfixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016576 break;
16577 }
csharptest6da31702011-06-04 12:52:57 -050016578 case 802:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016579 case 805: {
csharptestd2af9e92011-06-03 21:35:02 -050016580 input.ReadPrimitiveArray(pbd::FieldType.Float, tag, field_name, result.unpackedFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016581 break;
16582 }
csharptest6da31702011-06-04 12:52:57 -050016583 case 810:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016584 case 809: {
csharptestd2af9e92011-06-03 21:35:02 -050016585 input.ReadPrimitiveArray(pbd::FieldType.Double, tag, field_name, result.unpackedDouble_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016586 break;
16587 }
csharptest6da31702011-06-04 12:52:57 -050016588 case 818:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016589 case 816: {
csharptestd2af9e92011-06-03 21:35:02 -050016590 input.ReadPrimitiveArray(pbd::FieldType.Bool, tag, field_name, result.unpackedBool_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016591 break;
16592 }
csharptest6da31702011-06-04 12:52:57 -050016593 case 826:
Jon Skeet82bb0f12011-04-03 20:17:12 +010016594 case 824: {
csharptestd2af9e92011-06-03 21:35:02 -050016595 scg::ICollection<object> unknownItems;
16596 input.ReadEnumArray<global::Google.ProtocolBuffers.TestProtos.ForeignEnum>(tag, field_name, result.unpackedEnum_, out unknownItems);
16597 if (unknownItems != null) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010016598 if (unknownFields == null) {
16599 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
16600 }
csharptestd2af9e92011-06-03 21:35:02 -050016601 foreach (object rawValue in unknownItems)
16602 if (rawValue is int)
16603 unknownFields.MergeVarintField(103, (ulong)(int)rawValue);
Jon Skeet82bb0f12011-04-03 20:17:12 +010016604 }
16605 break;
16606 }
16607 }
16608 }
csharptest123e5342011-06-03 14:15:21 -050016609
16610 if (unknownFields != null) {
16611 this.UnknownFields = unknownFields.Build();
16612 }
16613 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010016614 }
16615
16616
16617 public pbc::IPopsicleList<int> UnpackedInt32List {
16618 get { return result.unpackedInt32_; }
16619 }
16620 public int UnpackedInt32Count {
16621 get { return result.UnpackedInt32Count; }
16622 }
16623 public int GetUnpackedInt32(int index) {
16624 return result.GetUnpackedInt32(index);
16625 }
16626 public Builder SetUnpackedInt32(int index, int value) {
16627 result.unpackedInt32_[index] = value;
16628 return this;
16629 }
16630 public Builder AddUnpackedInt32(int value) {
16631 result.unpackedInt32_.Add(value);
16632 return this;
16633 }
16634 public Builder AddRangeUnpackedInt32(scg::IEnumerable<int> values) {
16635 base.AddRange(values, result.unpackedInt32_);
16636 return this;
16637 }
16638 public Builder ClearUnpackedInt32() {
16639 result.unpackedInt32_.Clear();
16640 return this;
16641 }
16642
16643 public pbc::IPopsicleList<long> UnpackedInt64List {
16644 get { return result.unpackedInt64_; }
16645 }
16646 public int UnpackedInt64Count {
16647 get { return result.UnpackedInt64Count; }
16648 }
16649 public long GetUnpackedInt64(int index) {
16650 return result.GetUnpackedInt64(index);
16651 }
16652 public Builder SetUnpackedInt64(int index, long value) {
16653 result.unpackedInt64_[index] = value;
16654 return this;
16655 }
16656 public Builder AddUnpackedInt64(long value) {
16657 result.unpackedInt64_.Add(value);
16658 return this;
16659 }
16660 public Builder AddRangeUnpackedInt64(scg::IEnumerable<long> values) {
16661 base.AddRange(values, result.unpackedInt64_);
16662 return this;
16663 }
16664 public Builder ClearUnpackedInt64() {
16665 result.unpackedInt64_.Clear();
16666 return this;
16667 }
16668
16669 [global::System.CLSCompliant(false)]
16670 public pbc::IPopsicleList<uint> UnpackedUint32List {
16671 get { return result.unpackedUint32_; }
16672 }
16673 public int UnpackedUint32Count {
16674 get { return result.UnpackedUint32Count; }
16675 }
16676 [global::System.CLSCompliant(false)]
16677 public uint GetUnpackedUint32(int index) {
16678 return result.GetUnpackedUint32(index);
16679 }
16680 [global::System.CLSCompliant(false)]
16681 public Builder SetUnpackedUint32(int index, uint value) {
16682 result.unpackedUint32_[index] = value;
16683 return this;
16684 }
16685 [global::System.CLSCompliant(false)]
16686 public Builder AddUnpackedUint32(uint value) {
16687 result.unpackedUint32_.Add(value);
16688 return this;
16689 }
16690 [global::System.CLSCompliant(false)]
16691 public Builder AddRangeUnpackedUint32(scg::IEnumerable<uint> values) {
16692 base.AddRange(values, result.unpackedUint32_);
16693 return this;
16694 }
16695 public Builder ClearUnpackedUint32() {
16696 result.unpackedUint32_.Clear();
16697 return this;
16698 }
16699
16700 [global::System.CLSCompliant(false)]
16701 public pbc::IPopsicleList<ulong> UnpackedUint64List {
16702 get { return result.unpackedUint64_; }
16703 }
16704 public int UnpackedUint64Count {
16705 get { return result.UnpackedUint64Count; }
16706 }
16707 [global::System.CLSCompliant(false)]
16708 public ulong GetUnpackedUint64(int index) {
16709 return result.GetUnpackedUint64(index);
16710 }
16711 [global::System.CLSCompliant(false)]
16712 public Builder SetUnpackedUint64(int index, ulong value) {
16713 result.unpackedUint64_[index] = value;
16714 return this;
16715 }
16716 [global::System.CLSCompliant(false)]
16717 public Builder AddUnpackedUint64(ulong value) {
16718 result.unpackedUint64_.Add(value);
16719 return this;
16720 }
16721 [global::System.CLSCompliant(false)]
16722 public Builder AddRangeUnpackedUint64(scg::IEnumerable<ulong> values) {
16723 base.AddRange(values, result.unpackedUint64_);
16724 return this;
16725 }
16726 public Builder ClearUnpackedUint64() {
16727 result.unpackedUint64_.Clear();
16728 return this;
16729 }
16730
16731 public pbc::IPopsicleList<int> UnpackedSint32List {
16732 get { return result.unpackedSint32_; }
16733 }
16734 public int UnpackedSint32Count {
16735 get { return result.UnpackedSint32Count; }
16736 }
16737 public int GetUnpackedSint32(int index) {
16738 return result.GetUnpackedSint32(index);
16739 }
16740 public Builder SetUnpackedSint32(int index, int value) {
16741 result.unpackedSint32_[index] = value;
16742 return this;
16743 }
16744 public Builder AddUnpackedSint32(int value) {
16745 result.unpackedSint32_.Add(value);
16746 return this;
16747 }
16748 public Builder AddRangeUnpackedSint32(scg::IEnumerable<int> values) {
16749 base.AddRange(values, result.unpackedSint32_);
16750 return this;
16751 }
16752 public Builder ClearUnpackedSint32() {
16753 result.unpackedSint32_.Clear();
16754 return this;
16755 }
16756
16757 public pbc::IPopsicleList<long> UnpackedSint64List {
16758 get { return result.unpackedSint64_; }
16759 }
16760 public int UnpackedSint64Count {
16761 get { return result.UnpackedSint64Count; }
16762 }
16763 public long GetUnpackedSint64(int index) {
16764 return result.GetUnpackedSint64(index);
16765 }
16766 public Builder SetUnpackedSint64(int index, long value) {
16767 result.unpackedSint64_[index] = value;
16768 return this;
16769 }
16770 public Builder AddUnpackedSint64(long value) {
16771 result.unpackedSint64_.Add(value);
16772 return this;
16773 }
16774 public Builder AddRangeUnpackedSint64(scg::IEnumerable<long> values) {
16775 base.AddRange(values, result.unpackedSint64_);
16776 return this;
16777 }
16778 public Builder ClearUnpackedSint64() {
16779 result.unpackedSint64_.Clear();
16780 return this;
16781 }
16782
16783 [global::System.CLSCompliant(false)]
16784 public pbc::IPopsicleList<uint> UnpackedFixed32List {
16785 get { return result.unpackedFixed32_; }
16786 }
16787 public int UnpackedFixed32Count {
16788 get { return result.UnpackedFixed32Count; }
16789 }
16790 [global::System.CLSCompliant(false)]
16791 public uint GetUnpackedFixed32(int index) {
16792 return result.GetUnpackedFixed32(index);
16793 }
16794 [global::System.CLSCompliant(false)]
16795 public Builder SetUnpackedFixed32(int index, uint value) {
16796 result.unpackedFixed32_[index] = value;
16797 return this;
16798 }
16799 [global::System.CLSCompliant(false)]
16800 public Builder AddUnpackedFixed32(uint value) {
16801 result.unpackedFixed32_.Add(value);
16802 return this;
16803 }
16804 [global::System.CLSCompliant(false)]
16805 public Builder AddRangeUnpackedFixed32(scg::IEnumerable<uint> values) {
16806 base.AddRange(values, result.unpackedFixed32_);
16807 return this;
16808 }
16809 public Builder ClearUnpackedFixed32() {
16810 result.unpackedFixed32_.Clear();
16811 return this;
16812 }
16813
16814 [global::System.CLSCompliant(false)]
16815 public pbc::IPopsicleList<ulong> UnpackedFixed64List {
16816 get { return result.unpackedFixed64_; }
16817 }
16818 public int UnpackedFixed64Count {
16819 get { return result.UnpackedFixed64Count; }
16820 }
16821 [global::System.CLSCompliant(false)]
16822 public ulong GetUnpackedFixed64(int index) {
16823 return result.GetUnpackedFixed64(index);
16824 }
16825 [global::System.CLSCompliant(false)]
16826 public Builder SetUnpackedFixed64(int index, ulong value) {
16827 result.unpackedFixed64_[index] = value;
16828 return this;
16829 }
16830 [global::System.CLSCompliant(false)]
16831 public Builder AddUnpackedFixed64(ulong value) {
16832 result.unpackedFixed64_.Add(value);
16833 return this;
16834 }
16835 [global::System.CLSCompliant(false)]
16836 public Builder AddRangeUnpackedFixed64(scg::IEnumerable<ulong> values) {
16837 base.AddRange(values, result.unpackedFixed64_);
16838 return this;
16839 }
16840 public Builder ClearUnpackedFixed64() {
16841 result.unpackedFixed64_.Clear();
16842 return this;
16843 }
16844
16845 public pbc::IPopsicleList<int> UnpackedSfixed32List {
16846 get { return result.unpackedSfixed32_; }
16847 }
16848 public int UnpackedSfixed32Count {
16849 get { return result.UnpackedSfixed32Count; }
16850 }
16851 public int GetUnpackedSfixed32(int index) {
16852 return result.GetUnpackedSfixed32(index);
16853 }
16854 public Builder SetUnpackedSfixed32(int index, int value) {
16855 result.unpackedSfixed32_[index] = value;
16856 return this;
16857 }
16858 public Builder AddUnpackedSfixed32(int value) {
16859 result.unpackedSfixed32_.Add(value);
16860 return this;
16861 }
16862 public Builder AddRangeUnpackedSfixed32(scg::IEnumerable<int> values) {
16863 base.AddRange(values, result.unpackedSfixed32_);
16864 return this;
16865 }
16866 public Builder ClearUnpackedSfixed32() {
16867 result.unpackedSfixed32_.Clear();
16868 return this;
16869 }
16870
16871 public pbc::IPopsicleList<long> UnpackedSfixed64List {
16872 get { return result.unpackedSfixed64_; }
16873 }
16874 public int UnpackedSfixed64Count {
16875 get { return result.UnpackedSfixed64Count; }
16876 }
16877 public long GetUnpackedSfixed64(int index) {
16878 return result.GetUnpackedSfixed64(index);
16879 }
16880 public Builder SetUnpackedSfixed64(int index, long value) {
16881 result.unpackedSfixed64_[index] = value;
16882 return this;
16883 }
16884 public Builder AddUnpackedSfixed64(long value) {
16885 result.unpackedSfixed64_.Add(value);
16886 return this;
16887 }
16888 public Builder AddRangeUnpackedSfixed64(scg::IEnumerable<long> values) {
16889 base.AddRange(values, result.unpackedSfixed64_);
16890 return this;
16891 }
16892 public Builder ClearUnpackedSfixed64() {
16893 result.unpackedSfixed64_.Clear();
16894 return this;
16895 }
16896
16897 public pbc::IPopsicleList<float> UnpackedFloatList {
16898 get { return result.unpackedFloat_; }
16899 }
16900 public int UnpackedFloatCount {
16901 get { return result.UnpackedFloatCount; }
16902 }
16903 public float GetUnpackedFloat(int index) {
16904 return result.GetUnpackedFloat(index);
16905 }
16906 public Builder SetUnpackedFloat(int index, float value) {
16907 result.unpackedFloat_[index] = value;
16908 return this;
16909 }
16910 public Builder AddUnpackedFloat(float value) {
16911 result.unpackedFloat_.Add(value);
16912 return this;
16913 }
16914 public Builder AddRangeUnpackedFloat(scg::IEnumerable<float> values) {
16915 base.AddRange(values, result.unpackedFloat_);
16916 return this;
16917 }
16918 public Builder ClearUnpackedFloat() {
16919 result.unpackedFloat_.Clear();
16920 return this;
16921 }
16922
16923 public pbc::IPopsicleList<double> UnpackedDoubleList {
16924 get { return result.unpackedDouble_; }
16925 }
16926 public int UnpackedDoubleCount {
16927 get { return result.UnpackedDoubleCount; }
16928 }
16929 public double GetUnpackedDouble(int index) {
16930 return result.GetUnpackedDouble(index);
16931 }
16932 public Builder SetUnpackedDouble(int index, double value) {
16933 result.unpackedDouble_[index] = value;
16934 return this;
16935 }
16936 public Builder AddUnpackedDouble(double value) {
16937 result.unpackedDouble_.Add(value);
16938 return this;
16939 }
16940 public Builder AddRangeUnpackedDouble(scg::IEnumerable<double> values) {
16941 base.AddRange(values, result.unpackedDouble_);
16942 return this;
16943 }
16944 public Builder ClearUnpackedDouble() {
16945 result.unpackedDouble_.Clear();
16946 return this;
16947 }
16948
16949 public pbc::IPopsicleList<bool> UnpackedBoolList {
16950 get { return result.unpackedBool_; }
16951 }
16952 public int UnpackedBoolCount {
16953 get { return result.UnpackedBoolCount; }
16954 }
16955 public bool GetUnpackedBool(int index) {
16956 return result.GetUnpackedBool(index);
16957 }
16958 public Builder SetUnpackedBool(int index, bool value) {
16959 result.unpackedBool_[index] = value;
16960 return this;
16961 }
16962 public Builder AddUnpackedBool(bool value) {
16963 result.unpackedBool_.Add(value);
16964 return this;
16965 }
16966 public Builder AddRangeUnpackedBool(scg::IEnumerable<bool> values) {
16967 base.AddRange(values, result.unpackedBool_);
16968 return this;
16969 }
16970 public Builder ClearUnpackedBool() {
16971 result.unpackedBool_.Clear();
16972 return this;
16973 }
16974
16975 public pbc::IPopsicleList<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> UnpackedEnumList {
16976 get { return result.unpackedEnum_; }
16977 }
16978 public int UnpackedEnumCount {
16979 get { return result.UnpackedEnumCount; }
16980 }
16981 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum GetUnpackedEnum(int index) {
16982 return result.GetUnpackedEnum(index);
16983 }
16984 public Builder SetUnpackedEnum(int index, global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
16985 result.unpackedEnum_[index] = value;
16986 return this;
16987 }
16988 public Builder AddUnpackedEnum(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
16989 result.unpackedEnum_.Add(value);
16990 return this;
16991 }
16992 public Builder AddRangeUnpackedEnum(scg::IEnumerable<global::Google.ProtocolBuffers.TestProtos.ForeignEnum> values) {
16993 base.AddRange(values, result.unpackedEnum_);
16994 return this;
16995 }
16996 public Builder ClearUnpackedEnum() {
16997 result.unpackedEnum_.Clear();
16998 return this;
16999 }
17000 }
17001 static TestUnpackedTypes() {
17002 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
17003 }
17004 }
17005
csharptest445bdce2011-05-20 15:50:54 -050017006 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
17007 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
17008 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010017009 public sealed partial class TestPackedExtensions : pb::ExtendableMessage<TestPackedExtensions, TestPackedExtensions.Builder> {
17010 private static readonly TestPackedExtensions defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050017011 private static readonly string[] _testPackedExtensionsFieldNames = new string[] { };
17012 private static readonly uint[] _testPackedExtensionsFieldTags = new uint[] { };
Jon Skeet82bb0f12011-04-03 20:17:12 +010017013 public static TestPackedExtensions DefaultInstance {
17014 get { return defaultInstance; }
17015 }
17016
17017 public override TestPackedExtensions DefaultInstanceForType {
17018 get { return defaultInstance; }
17019 }
17020
17021 protected override TestPackedExtensions ThisMessage {
17022 get { return this; }
17023 }
17024
17025 public static pbd::MessageDescriptor Descriptor {
17026 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestPackedExtensions__Descriptor; }
17027 }
17028
17029 protected override pb::FieldAccess.FieldAccessorTable<TestPackedExtensions, TestPackedExtensions.Builder> InternalFieldAccessors {
17030 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestPackedExtensions__FieldAccessorTable; }
17031 }
17032
17033 public override bool IsInitialized {
17034 get {
17035 if (!ExtensionsAreInitialized) return false;
17036 return true;
17037 }
17038 }
17039
csharptestffafdaa2011-06-03 12:58:14 -050017040 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017041 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050017042 string[] field_names = _testPackedExtensionsFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +010017043 pb::ExtendableMessage<TestPackedExtensions, TestPackedExtensions.Builder>.ExtensionWriter extensionWriter = CreateExtensionWriter(this);
17044 extensionWriter.WriteUntil(536870912, output);
17045 UnknownFields.WriteTo(output);
17046 }
17047
17048 private int memoizedSerializedSize = -1;
17049 public override int SerializedSize {
17050 get {
17051 int size = memoizedSerializedSize;
17052 if (size != -1) return size;
17053
17054 size = 0;
17055 size += ExtensionsSerializedSize;
17056 size += UnknownFields.SerializedSize;
17057 memoizedSerializedSize = size;
17058 return size;
17059 }
17060 }
17061
17062 public static TestPackedExtensions ParseFrom(pb::ByteString data) {
17063 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
17064 }
17065 public static TestPackedExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
17066 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
17067 }
17068 public static TestPackedExtensions ParseFrom(byte[] data) {
17069 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
17070 }
17071 public static TestPackedExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
17072 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
17073 }
17074 public static TestPackedExtensions ParseFrom(global::System.IO.Stream input) {
17075 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
17076 }
17077 public static TestPackedExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
17078 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
17079 }
17080 public static TestPackedExtensions ParseDelimitedFrom(global::System.IO.Stream input) {
17081 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
17082 }
17083 public static TestPackedExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
17084 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
17085 }
csharptest17699c22011-06-03 21:57:15 -050017086 public static TestPackedExtensions ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017087 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
17088 }
csharptest17699c22011-06-03 21:57:15 -050017089 public static TestPackedExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017090 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
17091 }
17092 public static Builder CreateBuilder() { return new Builder(); }
17093 public override Builder ToBuilder() { return CreateBuilder(this); }
17094 public override Builder CreateBuilderForType() { return new Builder(); }
17095 public static Builder CreateBuilder(TestPackedExtensions prototype) {
17096 return (Builder) new Builder().MergeFrom(prototype);
17097 }
17098
csharptest445bdce2011-05-20 15:50:54 -050017099 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
17100 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
17101 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010017102 public sealed partial class Builder : pb::ExtendableBuilder<TestPackedExtensions, Builder> {
17103 protected override Builder ThisBuilder {
17104 get { return this; }
17105 }
17106 public Builder() {}
17107
17108 TestPackedExtensions result = new TestPackedExtensions();
17109
17110 protected override TestPackedExtensions MessageBeingBuilt {
17111 get { return result; }
17112 }
17113
17114 public override Builder Clear() {
17115 result = new TestPackedExtensions();
17116 return this;
17117 }
17118
17119 public override Builder Clone() {
17120 return new Builder().MergeFrom(result);
17121 }
17122
17123 public override pbd::MessageDescriptor DescriptorForType {
17124 get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.Descriptor; }
17125 }
17126
17127 public override TestPackedExtensions DefaultInstanceForType {
17128 get { return global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.DefaultInstance; }
17129 }
17130
17131 public override TestPackedExtensions BuildPartial() {
17132 if (result == null) {
17133 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
17134 }
17135 TestPackedExtensions returnMe = result;
17136 result = null;
17137 return returnMe;
17138 }
17139
17140 public override Builder MergeFrom(pb::IMessage other) {
17141 if (other is TestPackedExtensions) {
17142 return MergeFrom((TestPackedExtensions) other);
17143 } else {
17144 base.MergeFrom(other);
17145 return this;
17146 }
17147 }
17148
17149 public override Builder MergeFrom(TestPackedExtensions other) {
17150 if (other == global::Google.ProtocolBuffers.TestProtos.TestPackedExtensions.DefaultInstance) return this;
17151 this.MergeExtensionFields(other);
17152 this.MergeUnknownFields(other.UnknownFields);
17153 return this;
17154 }
17155
csharptest17699c22011-06-03 21:57:15 -050017156 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017157 return MergeFrom(input, pb::ExtensionRegistry.Empty);
17158 }
17159
csharptest17699c22011-06-03 21:57:15 -050017160 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017161 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050017162 uint tag;
17163 string field_name;
17164 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050017165 if(tag == 0 && field_name != null) {
17166 int field_ordinal = global::System.Array.BinarySearch(_testPackedExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal);
17167 if(field_ordinal >= 0)
17168 tag = _testPackedExtensionsFieldTags[field_ordinal];
17169 else {
17170 if (unknownFields == null) {
17171 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
17172 }
17173 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
17174 continue;
17175 }
17176 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010017177 switch (tag) {
17178 case 0: {
csharptest99284412011-06-03 14:51:06 -050017179 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010017180 }
17181 default: {
17182 if (pb::WireFormat.IsEndGroupTag(tag)) {
17183 if (unknownFields != null) {
17184 this.UnknownFields = unknownFields.Build();
17185 }
17186 return this;
17187 }
17188 if (unknownFields == null) {
17189 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
17190 }
csharptestd2af9e92011-06-03 21:35:02 -050017191 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017192 break;
17193 }
17194 }
17195 }
csharptest123e5342011-06-03 14:15:21 -050017196
17197 if (unknownFields != null) {
17198 this.UnknownFields = unknownFields.Build();
17199 }
17200 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010017201 }
17202
17203 }
17204 static TestPackedExtensions() {
17205 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
17206 }
17207 }
17208
csharptest445bdce2011-05-20 15:50:54 -050017209 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
17210 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
17211 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
csharptest6da31702011-06-04 12:52:57 -050017212 public sealed partial class TestUnpackedExtensions : pb::ExtendableMessage<TestUnpackedExtensions, TestUnpackedExtensions.Builder> {
17213 private static readonly TestUnpackedExtensions defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050017214 private static readonly string[] _testUnpackedExtensionsFieldNames = new string[] { };
17215 private static readonly uint[] _testUnpackedExtensionsFieldTags = new uint[] { };
csharptest6da31702011-06-04 12:52:57 -050017216 public static TestUnpackedExtensions DefaultInstance {
17217 get { return defaultInstance; }
17218 }
17219
17220 public override TestUnpackedExtensions DefaultInstanceForType {
17221 get { return defaultInstance; }
17222 }
17223
17224 protected override TestUnpackedExtensions ThisMessage {
17225 get { return this; }
17226 }
17227
17228 public static pbd::MessageDescriptor Descriptor {
17229 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestUnpackedExtensions__Descriptor; }
17230 }
17231
17232 protected override pb::FieldAccess.FieldAccessorTable<TestUnpackedExtensions, TestUnpackedExtensions.Builder> InternalFieldAccessors {
17233 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestUnpackedExtensions__FieldAccessorTable; }
17234 }
17235
17236 public override bool IsInitialized {
17237 get {
17238 if (!ExtensionsAreInitialized) return false;
17239 return true;
17240 }
17241 }
17242
17243 public override void WriteTo(pb::ICodedOutputStream output) {
17244 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050017245 string[] field_names = _testUnpackedExtensionsFieldNames;
csharptest6da31702011-06-04 12:52:57 -050017246 pb::ExtendableMessage<TestUnpackedExtensions, TestUnpackedExtensions.Builder>.ExtensionWriter extensionWriter = CreateExtensionWriter(this);
17247 extensionWriter.WriteUntil(536870912, output);
17248 UnknownFields.WriteTo(output);
17249 }
17250
17251 private int memoizedSerializedSize = -1;
17252 public override int SerializedSize {
17253 get {
17254 int size = memoizedSerializedSize;
17255 if (size != -1) return size;
17256
17257 size = 0;
17258 size += ExtensionsSerializedSize;
17259 size += UnknownFields.SerializedSize;
17260 memoizedSerializedSize = size;
17261 return size;
17262 }
17263 }
17264
17265 public static TestUnpackedExtensions ParseFrom(pb::ByteString data) {
17266 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
17267 }
17268 public static TestUnpackedExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
17269 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
17270 }
17271 public static TestUnpackedExtensions ParseFrom(byte[] data) {
17272 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
17273 }
17274 public static TestUnpackedExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
17275 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
17276 }
17277 public static TestUnpackedExtensions ParseFrom(global::System.IO.Stream input) {
17278 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
17279 }
17280 public static TestUnpackedExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
17281 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
17282 }
17283 public static TestUnpackedExtensions ParseDelimitedFrom(global::System.IO.Stream input) {
17284 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
17285 }
17286 public static TestUnpackedExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
17287 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
17288 }
17289 public static TestUnpackedExtensions ParseFrom(pb::ICodedInputStream input) {
17290 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
17291 }
17292 public static TestUnpackedExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
17293 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
17294 }
17295 public static Builder CreateBuilder() { return new Builder(); }
17296 public override Builder ToBuilder() { return CreateBuilder(this); }
17297 public override Builder CreateBuilderForType() { return new Builder(); }
17298 public static Builder CreateBuilder(TestUnpackedExtensions prototype) {
17299 return (Builder) new Builder().MergeFrom(prototype);
17300 }
17301
17302 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
17303 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
17304 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
17305 public sealed partial class Builder : pb::ExtendableBuilder<TestUnpackedExtensions, Builder> {
17306 protected override Builder ThisBuilder {
17307 get { return this; }
17308 }
17309 public Builder() {}
17310
17311 TestUnpackedExtensions result = new TestUnpackedExtensions();
17312
17313 protected override TestUnpackedExtensions MessageBeingBuilt {
17314 get { return result; }
17315 }
17316
17317 public override Builder Clear() {
17318 result = new TestUnpackedExtensions();
17319 return this;
17320 }
17321
17322 public override Builder Clone() {
17323 return new Builder().MergeFrom(result);
17324 }
17325
17326 public override pbd::MessageDescriptor DescriptorForType {
17327 get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.Descriptor; }
17328 }
17329
17330 public override TestUnpackedExtensions DefaultInstanceForType {
17331 get { return global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.DefaultInstance; }
17332 }
17333
17334 public override TestUnpackedExtensions BuildPartial() {
17335 if (result == null) {
17336 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
17337 }
17338 TestUnpackedExtensions returnMe = result;
17339 result = null;
17340 return returnMe;
17341 }
17342
17343 public override Builder MergeFrom(pb::IMessage other) {
17344 if (other is TestUnpackedExtensions) {
17345 return MergeFrom((TestUnpackedExtensions) other);
17346 } else {
17347 base.MergeFrom(other);
17348 return this;
17349 }
17350 }
17351
17352 public override Builder MergeFrom(TestUnpackedExtensions other) {
17353 if (other == global::Google.ProtocolBuffers.TestProtos.TestUnpackedExtensions.DefaultInstance) return this;
17354 this.MergeExtensionFields(other);
17355 this.MergeUnknownFields(other.UnknownFields);
17356 return this;
17357 }
17358
17359 public override Builder MergeFrom(pb::ICodedInputStream input) {
17360 return MergeFrom(input, pb::ExtensionRegistry.Empty);
17361 }
17362
17363 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
17364 pb::UnknownFieldSet.Builder unknownFields = null;
17365 uint tag;
17366 string field_name;
17367 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050017368 if(tag == 0 && field_name != null) {
17369 int field_ordinal = global::System.Array.BinarySearch(_testUnpackedExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal);
17370 if(field_ordinal >= 0)
17371 tag = _testUnpackedExtensionsFieldTags[field_ordinal];
17372 else {
17373 if (unknownFields == null) {
17374 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
17375 }
17376 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
17377 continue;
17378 }
17379 }
csharptest6da31702011-06-04 12:52:57 -050017380 switch (tag) {
17381 case 0: {
17382 throw pb::InvalidProtocolBufferException.InvalidTag();
17383 }
17384 default: {
17385 if (pb::WireFormat.IsEndGroupTag(tag)) {
17386 if (unknownFields != null) {
17387 this.UnknownFields = unknownFields.Build();
17388 }
17389 return this;
17390 }
17391 if (unknownFields == null) {
17392 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
17393 }
17394 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
17395 break;
17396 }
17397 }
17398 }
17399
17400 if (unknownFields != null) {
17401 this.UnknownFields = unknownFields.Build();
17402 }
17403 return this;
17404 }
17405
17406 }
17407 static TestUnpackedExtensions() {
17408 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
17409 }
17410 }
17411
17412 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
17413 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
17414 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010017415 public sealed partial class TestDynamicExtensions : pb::GeneratedMessage<TestDynamicExtensions, TestDynamicExtensions.Builder> {
17416 private static readonly TestDynamicExtensions defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050017417 private static readonly string[] _testDynamicExtensionsFieldNames = new string[] { "dynamic_enum_extension", "dynamic_message_extension", "enum_extension", "message_extension", "packed_extension", "repeated_extension", "scalar_extension" };
17418 private static readonly uint[] _testDynamicExtensionsFieldTags = new uint[] { 16016, 16034, 16008, 16026, 16050, 16042, 16005 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010017419 public static TestDynamicExtensions DefaultInstance {
17420 get { return defaultInstance; }
17421 }
17422
17423 public override TestDynamicExtensions DefaultInstanceForType {
17424 get { return defaultInstance; }
17425 }
17426
17427 protected override TestDynamicExtensions ThisMessage {
17428 get { return this; }
17429 }
17430
17431 public static pbd::MessageDescriptor Descriptor {
17432 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDynamicExtensions__Descriptor; }
17433 }
17434
17435 protected override pb::FieldAccess.FieldAccessorTable<TestDynamicExtensions, TestDynamicExtensions.Builder> InternalFieldAccessors {
17436 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDynamicExtensions__FieldAccessorTable; }
17437 }
17438
17439 #region Nested types
csharptest445bdce2011-05-20 15:50:54 -050017440 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
17441 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
17442 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010017443 public static class Types {
csharptest445bdce2011-05-20 15:50:54 -050017444 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
17445 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010017446 public enum DynamicEnumType {
17447 DYNAMIC_FOO = 2200,
17448 DYNAMIC_BAR = 2201,
17449 DYNAMIC_BAZ = 2202,
17450 }
17451
csharptest445bdce2011-05-20 15:50:54 -050017452 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
17453 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
17454 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010017455 public sealed partial class DynamicMessageType : pb::GeneratedMessage<DynamicMessageType, DynamicMessageType.Builder> {
17456 private static readonly DynamicMessageType defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050017457 private static readonly string[] _dynamicMessageTypeFieldNames = new string[] { "dynamic_field" };
17458 private static readonly uint[] _dynamicMessageTypeFieldTags = new uint[] { 16800 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010017459 public static DynamicMessageType DefaultInstance {
17460 get { return defaultInstance; }
17461 }
17462
17463 public override DynamicMessageType DefaultInstanceForType {
17464 get { return defaultInstance; }
17465 }
17466
17467 protected override DynamicMessageType ThisMessage {
17468 get { return this; }
17469 }
17470
17471 public static pbd::MessageDescriptor Descriptor {
17472 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__Descriptor; }
17473 }
17474
17475 protected override pb::FieldAccess.FieldAccessorTable<DynamicMessageType, DynamicMessageType.Builder> InternalFieldAccessors {
17476 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestDynamicExtensions_DynamicMessageType__FieldAccessorTable; }
17477 }
17478
17479 public const int DynamicFieldFieldNumber = 2100;
17480 private bool hasDynamicField;
csharptestced18e12011-06-09 19:47:56 -050017481 private int dynamicField_;
Jon Skeet82bb0f12011-04-03 20:17:12 +010017482 public bool HasDynamicField {
17483 get { return hasDynamicField; }
17484 }
17485 public int DynamicField {
17486 get { return dynamicField_; }
17487 }
17488
17489 public override bool IsInitialized {
17490 get {
17491 return true;
17492 }
17493 }
17494
csharptestffafdaa2011-06-03 12:58:14 -050017495 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017496 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050017497 string[] field_names = _dynamicMessageTypeFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050017498 if (hasDynamicField) {
csharptest920b09a2011-06-08 20:13:29 -050017499 output.WriteInt32(2100, field_names[0], DynamicField);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017500 }
17501 UnknownFields.WriteTo(output);
17502 }
17503
17504 private int memoizedSerializedSize = -1;
17505 public override int SerializedSize {
17506 get {
17507 int size = memoizedSerializedSize;
17508 if (size != -1) return size;
17509
17510 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050017511 if (hasDynamicField) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017512 size += pb::CodedOutputStream.ComputeInt32Size(2100, DynamicField);
17513 }
17514 size += UnknownFields.SerializedSize;
17515 memoizedSerializedSize = size;
17516 return size;
17517 }
17518 }
17519
17520 public static DynamicMessageType ParseFrom(pb::ByteString data) {
17521 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
17522 }
17523 public static DynamicMessageType ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
17524 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
17525 }
17526 public static DynamicMessageType ParseFrom(byte[] data) {
17527 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
17528 }
17529 public static DynamicMessageType ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
17530 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
17531 }
17532 public static DynamicMessageType ParseFrom(global::System.IO.Stream input) {
17533 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
17534 }
17535 public static DynamicMessageType ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
17536 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
17537 }
17538 public static DynamicMessageType ParseDelimitedFrom(global::System.IO.Stream input) {
17539 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
17540 }
17541 public static DynamicMessageType ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
17542 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
17543 }
csharptest17699c22011-06-03 21:57:15 -050017544 public static DynamicMessageType ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017545 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
17546 }
csharptest17699c22011-06-03 21:57:15 -050017547 public static DynamicMessageType ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017548 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
17549 }
17550 public static Builder CreateBuilder() { return new Builder(); }
17551 public override Builder ToBuilder() { return CreateBuilder(this); }
17552 public override Builder CreateBuilderForType() { return new Builder(); }
17553 public static Builder CreateBuilder(DynamicMessageType prototype) {
17554 return (Builder) new Builder().MergeFrom(prototype);
17555 }
17556
csharptest445bdce2011-05-20 15:50:54 -050017557 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
17558 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
17559 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010017560 public sealed partial class Builder : pb::GeneratedBuilder<DynamicMessageType, Builder> {
17561 protected override Builder ThisBuilder {
17562 get { return this; }
17563 }
17564 public Builder() {}
17565
17566 DynamicMessageType result = new DynamicMessageType();
17567
17568 protected override DynamicMessageType MessageBeingBuilt {
17569 get { return result; }
17570 }
17571
17572 public override Builder Clear() {
17573 result = new DynamicMessageType();
17574 return this;
17575 }
17576
17577 public override Builder Clone() {
17578 return new Builder().MergeFrom(result);
17579 }
17580
17581 public override pbd::MessageDescriptor DescriptorForType {
17582 get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Descriptor; }
17583 }
17584
17585 public override DynamicMessageType DefaultInstanceForType {
17586 get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance; }
17587 }
17588
17589 public override DynamicMessageType BuildPartial() {
17590 if (result == null) {
17591 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
17592 }
17593 DynamicMessageType returnMe = result;
17594 result = null;
17595 return returnMe;
17596 }
17597
17598 public override Builder MergeFrom(pb::IMessage other) {
17599 if (other is DynamicMessageType) {
17600 return MergeFrom((DynamicMessageType) other);
17601 } else {
17602 base.MergeFrom(other);
17603 return this;
17604 }
17605 }
17606
17607 public override Builder MergeFrom(DynamicMessageType other) {
17608 if (other == global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance) return this;
17609 if (other.HasDynamicField) {
17610 DynamicField = other.DynamicField;
17611 }
17612 this.MergeUnknownFields(other.UnknownFields);
17613 return this;
17614 }
17615
csharptest17699c22011-06-03 21:57:15 -050017616 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017617 return MergeFrom(input, pb::ExtensionRegistry.Empty);
17618 }
17619
csharptest17699c22011-06-03 21:57:15 -050017620 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017621 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050017622 uint tag;
17623 string field_name;
17624 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050017625 if(tag == 0 && field_name != null) {
17626 int field_ordinal = global::System.Array.BinarySearch(_dynamicMessageTypeFieldNames, field_name, global::System.StringComparer.Ordinal);
17627 if(field_ordinal >= 0)
17628 tag = _dynamicMessageTypeFieldTags[field_ordinal];
17629 else {
17630 if (unknownFields == null) {
17631 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
17632 }
17633 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
17634 continue;
17635 }
17636 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010017637 switch (tag) {
17638 case 0: {
csharptest99284412011-06-03 14:51:06 -050017639 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010017640 }
17641 default: {
17642 if (pb::WireFormat.IsEndGroupTag(tag)) {
17643 if (unknownFields != null) {
17644 this.UnknownFields = unknownFields.Build();
17645 }
17646 return this;
17647 }
17648 if (unknownFields == null) {
17649 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
17650 }
csharptestd2af9e92011-06-03 21:35:02 -050017651 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017652 break;
17653 }
17654 case 16800: {
csharptest920b09a2011-06-08 20:13:29 -050017655 result.hasDynamicField = input.ReadInt32(ref result.dynamicField_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017656 break;
17657 }
17658 }
17659 }
csharptest123e5342011-06-03 14:15:21 -050017660
17661 if (unknownFields != null) {
17662 this.UnknownFields = unknownFields.Build();
17663 }
17664 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010017665 }
17666
17667
17668 public bool HasDynamicField {
csharptestc671a4b2011-06-08 11:51:24 -050017669 get { return result.hasDynamicField; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010017670 }
17671 public int DynamicField {
17672 get { return result.DynamicField; }
17673 set { SetDynamicField(value); }
17674 }
17675 public Builder SetDynamicField(int value) {
17676 result.hasDynamicField = true;
17677 result.dynamicField_ = value;
17678 return this;
17679 }
17680 public Builder ClearDynamicField() {
17681 result.hasDynamicField = false;
17682 result.dynamicField_ = 0;
17683 return this;
17684 }
17685 }
17686 static DynamicMessageType() {
17687 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
17688 }
17689 }
17690
17691 }
17692 #endregion
17693
17694 public const int ScalarExtensionFieldNumber = 2000;
17695 private bool hasScalarExtension;
csharptestced18e12011-06-09 19:47:56 -050017696 private uint scalarExtension_;
Jon Skeet82bb0f12011-04-03 20:17:12 +010017697 public bool HasScalarExtension {
17698 get { return hasScalarExtension; }
17699 }
17700 [global::System.CLSCompliant(false)]
17701 public uint ScalarExtension {
17702 get { return scalarExtension_; }
17703 }
17704
17705 public const int EnumExtensionFieldNumber = 2001;
17706 private bool hasEnumExtension;
17707 private global::Google.ProtocolBuffers.TestProtos.ForeignEnum enumExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO;
17708 public bool HasEnumExtension {
17709 get { return hasEnumExtension; }
17710 }
17711 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumExtension {
17712 get { return enumExtension_; }
17713 }
17714
17715 public const int DynamicEnumExtensionFieldNumber = 2002;
17716 private bool hasDynamicEnumExtension;
17717 private global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType dynamicEnumExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType.DYNAMIC_FOO;
17718 public bool HasDynamicEnumExtension {
17719 get { return hasDynamicEnumExtension; }
17720 }
17721 public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType DynamicEnumExtension {
17722 get { return dynamicEnumExtension_; }
17723 }
17724
17725 public const int MessageExtensionFieldNumber = 2003;
17726 private bool hasMessageExtension;
17727 private global::Google.ProtocolBuffers.TestProtos.ForeignMessage messageExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance;
17728 public bool HasMessageExtension {
17729 get { return hasMessageExtension; }
17730 }
17731 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageExtension {
17732 get { return messageExtension_; }
17733 }
17734
17735 public const int DynamicMessageExtensionFieldNumber = 2004;
17736 private bool hasDynamicMessageExtension;
17737 private global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType dynamicMessageExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance;
17738 public bool HasDynamicMessageExtension {
17739 get { return hasDynamicMessageExtension; }
17740 }
17741 public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType DynamicMessageExtension {
17742 get { return dynamicMessageExtension_; }
17743 }
17744
17745 public const int RepeatedExtensionFieldNumber = 2005;
17746 private pbc::PopsicleList<string> repeatedExtension_ = new pbc::PopsicleList<string>();
17747 public scg::IList<string> RepeatedExtensionList {
17748 get { return pbc::Lists.AsReadOnly(repeatedExtension_); }
17749 }
17750 public int RepeatedExtensionCount {
17751 get { return repeatedExtension_.Count; }
17752 }
17753 public string GetRepeatedExtension(int index) {
17754 return repeatedExtension_[index];
17755 }
17756
17757 public const int PackedExtensionFieldNumber = 2006;
17758 private int packedExtensionMemoizedSerializedSize;
17759 private pbc::PopsicleList<int> packedExtension_ = new pbc::PopsicleList<int>();
17760 public scg::IList<int> PackedExtensionList {
17761 get { return pbc::Lists.AsReadOnly(packedExtension_); }
17762 }
17763 public int PackedExtensionCount {
17764 get { return packedExtension_.Count; }
17765 }
17766 public int GetPackedExtension(int index) {
17767 return packedExtension_[index];
17768 }
17769
17770 public override bool IsInitialized {
17771 get {
17772 return true;
17773 }
17774 }
17775
csharptestffafdaa2011-06-03 12:58:14 -050017776 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017777 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050017778 string[] field_names = _testDynamicExtensionsFieldNames;
csharptestc671a4b2011-06-08 11:51:24 -050017779 if (hasScalarExtension) {
csharptest920b09a2011-06-08 20:13:29 -050017780 output.WriteFixed32(2000, field_names[6], ScalarExtension);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017781 }
csharptestc671a4b2011-06-08 11:51:24 -050017782 if (hasEnumExtension) {
csharptestced18e12011-06-09 19:47:56 -050017783 output.WriteEnum(2001, field_names[2], (int) EnumExtension, EnumExtension);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017784 }
csharptestc671a4b2011-06-08 11:51:24 -050017785 if (hasDynamicEnumExtension) {
csharptestced18e12011-06-09 19:47:56 -050017786 output.WriteEnum(2002, field_names[0], (int) DynamicEnumExtension, DynamicEnumExtension);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017787 }
csharptestc671a4b2011-06-08 11:51:24 -050017788 if (hasMessageExtension) {
csharptest920b09a2011-06-08 20:13:29 -050017789 output.WriteMessage(2003, field_names[3], MessageExtension);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017790 }
csharptestc671a4b2011-06-08 11:51:24 -050017791 if (hasDynamicMessageExtension) {
csharptest920b09a2011-06-08 20:13:29 -050017792 output.WriteMessage(2004, field_names[1], DynamicMessageExtension);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017793 }
17794 if (repeatedExtension_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050017795 output.WriteArray(pbd::FieldType.String, 2005, field_names[5], repeatedExtension_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017796 }
17797 if (packedExtension_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050017798 output.WritePackedArray(pbd::FieldType.SInt32, 2006, field_names[4], packedExtensionMemoizedSerializedSize, packedExtension_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010017799 }
17800 UnknownFields.WriteTo(output);
17801 }
17802
17803 private int memoizedSerializedSize = -1;
17804 public override int SerializedSize {
17805 get {
17806 int size = memoizedSerializedSize;
17807 if (size != -1) return size;
17808
17809 size = 0;
csharptestc671a4b2011-06-08 11:51:24 -050017810 if (hasScalarExtension) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017811 size += pb::CodedOutputStream.ComputeFixed32Size(2000, ScalarExtension);
17812 }
csharptestc671a4b2011-06-08 11:51:24 -050017813 if (hasEnumExtension) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017814 size += pb::CodedOutputStream.ComputeEnumSize(2001, (int) EnumExtension);
17815 }
csharptestc671a4b2011-06-08 11:51:24 -050017816 if (hasDynamicEnumExtension) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017817 size += pb::CodedOutputStream.ComputeEnumSize(2002, (int) DynamicEnumExtension);
17818 }
csharptestc671a4b2011-06-08 11:51:24 -050017819 if (hasMessageExtension) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017820 size += pb::CodedOutputStream.ComputeMessageSize(2003, MessageExtension);
17821 }
csharptestc671a4b2011-06-08 11:51:24 -050017822 if (hasDynamicMessageExtension) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017823 size += pb::CodedOutputStream.ComputeMessageSize(2004, DynamicMessageExtension);
17824 }
17825 {
17826 int dataSize = 0;
17827 foreach (string element in RepeatedExtensionList) {
17828 dataSize += pb::CodedOutputStream.ComputeStringSizeNoTag(element);
17829 }
17830 size += dataSize;
17831 size += 2 * repeatedExtension_.Count;
17832 }
17833 {
17834 int dataSize = 0;
17835 foreach (int element in PackedExtensionList) {
17836 dataSize += pb::CodedOutputStream.ComputeSInt32SizeNoTag(element);
17837 }
17838 size += dataSize;
17839 if (packedExtension_.Count != 0) {
17840 size += 2 + pb::CodedOutputStream.ComputeInt32SizeNoTag(dataSize);
17841 }
17842 packedExtensionMemoizedSerializedSize = dataSize;
17843 }
17844 size += UnknownFields.SerializedSize;
17845 memoizedSerializedSize = size;
17846 return size;
17847 }
17848 }
17849
17850 public static TestDynamicExtensions ParseFrom(pb::ByteString data) {
17851 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
17852 }
17853 public static TestDynamicExtensions ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
17854 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
17855 }
17856 public static TestDynamicExtensions ParseFrom(byte[] data) {
17857 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
17858 }
17859 public static TestDynamicExtensions ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
17860 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
17861 }
17862 public static TestDynamicExtensions ParseFrom(global::System.IO.Stream input) {
17863 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
17864 }
17865 public static TestDynamicExtensions ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
17866 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
17867 }
17868 public static TestDynamicExtensions ParseDelimitedFrom(global::System.IO.Stream input) {
17869 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
17870 }
17871 public static TestDynamicExtensions ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
17872 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
17873 }
csharptest17699c22011-06-03 21:57:15 -050017874 public static TestDynamicExtensions ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017875 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
17876 }
csharptest17699c22011-06-03 21:57:15 -050017877 public static TestDynamicExtensions ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017878 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
17879 }
17880 public static Builder CreateBuilder() { return new Builder(); }
17881 public override Builder ToBuilder() { return CreateBuilder(this); }
17882 public override Builder CreateBuilderForType() { return new Builder(); }
17883 public static Builder CreateBuilder(TestDynamicExtensions prototype) {
17884 return (Builder) new Builder().MergeFrom(prototype);
17885 }
17886
csharptest445bdce2011-05-20 15:50:54 -050017887 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
17888 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
17889 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010017890 public sealed partial class Builder : pb::GeneratedBuilder<TestDynamicExtensions, Builder> {
17891 protected override Builder ThisBuilder {
17892 get { return this; }
17893 }
17894 public Builder() {}
17895
17896 TestDynamicExtensions result = new TestDynamicExtensions();
17897
17898 protected override TestDynamicExtensions MessageBeingBuilt {
17899 get { return result; }
17900 }
17901
17902 public override Builder Clear() {
17903 result = new TestDynamicExtensions();
17904 return this;
17905 }
17906
17907 public override Builder Clone() {
17908 return new Builder().MergeFrom(result);
17909 }
17910
17911 public override pbd::MessageDescriptor DescriptorForType {
17912 get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Descriptor; }
17913 }
17914
17915 public override TestDynamicExtensions DefaultInstanceForType {
17916 get { return global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.DefaultInstance; }
17917 }
17918
17919 public override TestDynamicExtensions BuildPartial() {
17920 if (result == null) {
17921 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
17922 }
17923 result.repeatedExtension_.MakeReadOnly();
17924 result.packedExtension_.MakeReadOnly();
17925 TestDynamicExtensions returnMe = result;
17926 result = null;
17927 return returnMe;
17928 }
17929
17930 public override Builder MergeFrom(pb::IMessage other) {
17931 if (other is TestDynamicExtensions) {
17932 return MergeFrom((TestDynamicExtensions) other);
17933 } else {
17934 base.MergeFrom(other);
17935 return this;
17936 }
17937 }
17938
17939 public override Builder MergeFrom(TestDynamicExtensions other) {
17940 if (other == global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.DefaultInstance) return this;
17941 if (other.HasScalarExtension) {
17942 ScalarExtension = other.ScalarExtension;
17943 }
17944 if (other.HasEnumExtension) {
17945 EnumExtension = other.EnumExtension;
17946 }
17947 if (other.HasDynamicEnumExtension) {
17948 DynamicEnumExtension = other.DynamicEnumExtension;
17949 }
17950 if (other.HasMessageExtension) {
17951 MergeMessageExtension(other.MessageExtension);
17952 }
17953 if (other.HasDynamicMessageExtension) {
17954 MergeDynamicMessageExtension(other.DynamicMessageExtension);
17955 }
17956 if (other.repeatedExtension_.Count != 0) {
17957 base.AddRange(other.repeatedExtension_, result.repeatedExtension_);
17958 }
17959 if (other.packedExtension_.Count != 0) {
17960 base.AddRange(other.packedExtension_, result.packedExtension_);
17961 }
17962 this.MergeUnknownFields(other.UnknownFields);
17963 return this;
17964 }
17965
csharptest17699c22011-06-03 21:57:15 -050017966 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017967 return MergeFrom(input, pb::ExtensionRegistry.Empty);
17968 }
17969
csharptest17699c22011-06-03 21:57:15 -050017970 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010017971 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050017972 uint tag;
17973 string field_name;
17974 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050017975 if(tag == 0 && field_name != null) {
17976 int field_ordinal = global::System.Array.BinarySearch(_testDynamicExtensionsFieldNames, field_name, global::System.StringComparer.Ordinal);
17977 if(field_ordinal >= 0)
17978 tag = _testDynamicExtensionsFieldTags[field_ordinal];
17979 else {
17980 if (unknownFields == null) {
17981 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
17982 }
17983 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
17984 continue;
17985 }
17986 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010017987 switch (tag) {
17988 case 0: {
csharptest99284412011-06-03 14:51:06 -050017989 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010017990 }
17991 default: {
17992 if (pb::WireFormat.IsEndGroupTag(tag)) {
17993 if (unknownFields != null) {
17994 this.UnknownFields = unknownFields.Build();
17995 }
17996 return this;
17997 }
17998 if (unknownFields == null) {
17999 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
18000 }
csharptestd2af9e92011-06-03 21:35:02 -050018001 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018002 break;
18003 }
18004 case 16005: {
csharptest920b09a2011-06-08 20:13:29 -050018005 result.hasScalarExtension = input.ReadFixed32(ref result.scalarExtension_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018006 break;
18007 }
18008 case 16008: {
csharptestd2af9e92011-06-03 21:35:02 -050018009 object unknown;
18010 if(input.ReadEnum(ref result.enumExtension_, out unknown)) {
18011 result.hasEnumExtension = true;
18012 } else if(unknown is int) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018013 if (unknownFields == null) {
18014 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
18015 }
csharptestd2af9e92011-06-03 21:35:02 -050018016 unknownFields.MergeVarintField(2001, (ulong)(int)unknown);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018017 }
18018 break;
18019 }
18020 case 16016: {
csharptestd2af9e92011-06-03 21:35:02 -050018021 object unknown;
18022 if(input.ReadEnum(ref result.dynamicEnumExtension_, out unknown)) {
18023 result.hasDynamicEnumExtension = true;
18024 } else if(unknown is int) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018025 if (unknownFields == null) {
18026 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
18027 }
csharptestd2af9e92011-06-03 21:35:02 -050018028 unknownFields.MergeVarintField(2002, (ulong)(int)unknown);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018029 }
18030 break;
18031 }
18032 case 16026: {
18033 global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -050018034 if (result.hasMessageExtension) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018035 subBuilder.MergeFrom(MessageExtension);
18036 }
18037 input.ReadMessage(subBuilder, extensionRegistry);
18038 MessageExtension = subBuilder.BuildPartial();
18039 break;
18040 }
18041 case 16034: {
18042 global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder subBuilder = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.CreateBuilder();
csharptestc671a4b2011-06-08 11:51:24 -050018043 if (result.hasDynamicMessageExtension) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018044 subBuilder.MergeFrom(DynamicMessageExtension);
18045 }
18046 input.ReadMessage(subBuilder, extensionRegistry);
18047 DynamicMessageExtension = subBuilder.BuildPartial();
18048 break;
18049 }
18050 case 16042: {
csharptestd2af9e92011-06-03 21:35:02 -050018051 input.ReadPrimitiveArray(pbd::FieldType.String, tag, field_name, result.repeatedExtension_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018052 break;
18053 }
csharptest6da31702011-06-04 12:52:57 -050018054 case 16050:
18055 case 16048: {
csharptestd2af9e92011-06-03 21:35:02 -050018056 input.ReadPrimitiveArray(pbd::FieldType.SInt32, tag, field_name, result.packedExtension_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018057 break;
18058 }
18059 }
18060 }
csharptest123e5342011-06-03 14:15:21 -050018061
18062 if (unknownFields != null) {
18063 this.UnknownFields = unknownFields.Build();
18064 }
18065 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010018066 }
18067
18068
18069 public bool HasScalarExtension {
csharptestc671a4b2011-06-08 11:51:24 -050018070 get { return result.hasScalarExtension; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010018071 }
18072 [global::System.CLSCompliant(false)]
18073 public uint ScalarExtension {
18074 get { return result.ScalarExtension; }
18075 set { SetScalarExtension(value); }
18076 }
18077 [global::System.CLSCompliant(false)]
18078 public Builder SetScalarExtension(uint value) {
18079 result.hasScalarExtension = true;
18080 result.scalarExtension_ = value;
18081 return this;
18082 }
18083 public Builder ClearScalarExtension() {
18084 result.hasScalarExtension = false;
18085 result.scalarExtension_ = 0;
18086 return this;
18087 }
18088
18089 public bool HasEnumExtension {
csharptestc671a4b2011-06-08 11:51:24 -050018090 get { return result.hasEnumExtension; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010018091 }
18092 public global::Google.ProtocolBuffers.TestProtos.ForeignEnum EnumExtension {
18093 get { return result.EnumExtension; }
18094 set { SetEnumExtension(value); }
18095 }
18096 public Builder SetEnumExtension(global::Google.ProtocolBuffers.TestProtos.ForeignEnum value) {
18097 result.hasEnumExtension = true;
18098 result.enumExtension_ = value;
18099 return this;
18100 }
18101 public Builder ClearEnumExtension() {
18102 result.hasEnumExtension = false;
18103 result.enumExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignEnum.FOREIGN_FOO;
18104 return this;
18105 }
18106
18107 public bool HasDynamicEnumExtension {
csharptestc671a4b2011-06-08 11:51:24 -050018108 get { return result.hasDynamicEnumExtension; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010018109 }
18110 public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType DynamicEnumExtension {
18111 get { return result.DynamicEnumExtension; }
18112 set { SetDynamicEnumExtension(value); }
18113 }
18114 public Builder SetDynamicEnumExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType value) {
18115 result.hasDynamicEnumExtension = true;
18116 result.dynamicEnumExtension_ = value;
18117 return this;
18118 }
18119 public Builder ClearDynamicEnumExtension() {
18120 result.hasDynamicEnumExtension = false;
18121 result.dynamicEnumExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicEnumType.DYNAMIC_FOO;
18122 return this;
18123 }
18124
18125 public bool HasMessageExtension {
csharptestc671a4b2011-06-08 11:51:24 -050018126 get { return result.hasMessageExtension; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010018127 }
18128 public global::Google.ProtocolBuffers.TestProtos.ForeignMessage MessageExtension {
18129 get { return result.MessageExtension; }
18130 set { SetMessageExtension(value); }
18131 }
18132 public Builder SetMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
18133 pb::ThrowHelper.ThrowIfNull(value, "value");
18134 result.hasMessageExtension = true;
18135 result.messageExtension_ = value;
18136 return this;
18137 }
18138 public Builder SetMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage.Builder builderForValue) {
18139 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
18140 result.hasMessageExtension = true;
18141 result.messageExtension_ = builderForValue.Build();
18142 return this;
18143 }
18144 public Builder MergeMessageExtension(global::Google.ProtocolBuffers.TestProtos.ForeignMessage value) {
18145 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -050018146 if (result.hasMessageExtension &&
Jon Skeet82bb0f12011-04-03 20:17:12 +010018147 result.messageExtension_ != global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance) {
18148 result.messageExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.CreateBuilder(result.messageExtension_).MergeFrom(value).BuildPartial();
18149 } else {
18150 result.messageExtension_ = value;
18151 }
18152 result.hasMessageExtension = true;
18153 return this;
18154 }
18155 public Builder ClearMessageExtension() {
18156 result.hasMessageExtension = false;
18157 result.messageExtension_ = global::Google.ProtocolBuffers.TestProtos.ForeignMessage.DefaultInstance;
18158 return this;
18159 }
18160
18161 public bool HasDynamicMessageExtension {
csharptestc671a4b2011-06-08 11:51:24 -050018162 get { return result.hasDynamicMessageExtension; }
Jon Skeet82bb0f12011-04-03 20:17:12 +010018163 }
18164 public global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType DynamicMessageExtension {
18165 get { return result.DynamicMessageExtension; }
18166 set { SetDynamicMessageExtension(value); }
18167 }
18168 public Builder SetDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType value) {
18169 pb::ThrowHelper.ThrowIfNull(value, "value");
18170 result.hasDynamicMessageExtension = true;
18171 result.dynamicMessageExtension_ = value;
18172 return this;
18173 }
18174 public Builder SetDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.Builder builderForValue) {
18175 pb::ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
18176 result.hasDynamicMessageExtension = true;
18177 result.dynamicMessageExtension_ = builderForValue.Build();
18178 return this;
18179 }
18180 public Builder MergeDynamicMessageExtension(global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType value) {
18181 pb::ThrowHelper.ThrowIfNull(value, "value");
csharptestc671a4b2011-06-08 11:51:24 -050018182 if (result.hasDynamicMessageExtension &&
Jon Skeet82bb0f12011-04-03 20:17:12 +010018183 result.dynamicMessageExtension_ != global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance) {
18184 result.dynamicMessageExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.CreateBuilder(result.dynamicMessageExtension_).MergeFrom(value).BuildPartial();
18185 } else {
18186 result.dynamicMessageExtension_ = value;
18187 }
18188 result.hasDynamicMessageExtension = true;
18189 return this;
18190 }
18191 public Builder ClearDynamicMessageExtension() {
18192 result.hasDynamicMessageExtension = false;
18193 result.dynamicMessageExtension_ = global::Google.ProtocolBuffers.TestProtos.TestDynamicExtensions.Types.DynamicMessageType.DefaultInstance;
18194 return this;
18195 }
18196
18197 public pbc::IPopsicleList<string> RepeatedExtensionList {
18198 get { return result.repeatedExtension_; }
18199 }
18200 public int RepeatedExtensionCount {
18201 get { return result.RepeatedExtensionCount; }
18202 }
18203 public string GetRepeatedExtension(int index) {
18204 return result.GetRepeatedExtension(index);
18205 }
18206 public Builder SetRepeatedExtension(int index, string value) {
18207 pb::ThrowHelper.ThrowIfNull(value, "value");
18208 result.repeatedExtension_[index] = value;
18209 return this;
18210 }
18211 public Builder AddRepeatedExtension(string value) {
18212 pb::ThrowHelper.ThrowIfNull(value, "value");
18213 result.repeatedExtension_.Add(value);
18214 return this;
18215 }
18216 public Builder AddRangeRepeatedExtension(scg::IEnumerable<string> values) {
18217 base.AddRange(values, result.repeatedExtension_);
18218 return this;
18219 }
18220 public Builder ClearRepeatedExtension() {
18221 result.repeatedExtension_.Clear();
18222 return this;
18223 }
18224
18225 public pbc::IPopsicleList<int> PackedExtensionList {
18226 get { return result.packedExtension_; }
18227 }
18228 public int PackedExtensionCount {
18229 get { return result.PackedExtensionCount; }
18230 }
18231 public int GetPackedExtension(int index) {
18232 return result.GetPackedExtension(index);
18233 }
18234 public Builder SetPackedExtension(int index, int value) {
18235 result.packedExtension_[index] = value;
18236 return this;
18237 }
18238 public Builder AddPackedExtension(int value) {
18239 result.packedExtension_.Add(value);
18240 return this;
18241 }
18242 public Builder AddRangePackedExtension(scg::IEnumerable<int> values) {
18243 base.AddRange(values, result.packedExtension_);
18244 return this;
18245 }
18246 public Builder ClearPackedExtension() {
18247 result.packedExtension_.Clear();
18248 return this;
18249 }
18250 }
18251 static TestDynamicExtensions() {
18252 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
18253 }
18254 }
18255
csharptest445bdce2011-05-20 15:50:54 -050018256 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
18257 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
18258 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010018259 public sealed partial class TestRepeatedScalarDifferentTagSizes : pb::GeneratedMessage<TestRepeatedScalarDifferentTagSizes, TestRepeatedScalarDifferentTagSizes.Builder> {
18260 private static readonly TestRepeatedScalarDifferentTagSizes defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050018261 private static readonly string[] _testRepeatedScalarDifferentTagSizesFieldNames = new string[] { "repeated_fixed32", "repeated_fixed64", "repeated_float", "repeated_int32", "repeated_int64", "repeated_uint64" };
18262 private static readonly uint[] _testRepeatedScalarDifferentTagSizesFieldTags = new uint[] { 101, 16369, 2097141, 104, 16376, 2097144 };
Jon Skeet82bb0f12011-04-03 20:17:12 +010018263 public static TestRepeatedScalarDifferentTagSizes DefaultInstance {
18264 get { return defaultInstance; }
18265 }
18266
18267 public override TestRepeatedScalarDifferentTagSizes DefaultInstanceForType {
18268 get { return defaultInstance; }
18269 }
18270
18271 protected override TestRepeatedScalarDifferentTagSizes ThisMessage {
18272 get { return this; }
18273 }
18274
18275 public static pbd::MessageDescriptor Descriptor {
18276 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__Descriptor; }
18277 }
18278
18279 protected override pb::FieldAccess.FieldAccessorTable<TestRepeatedScalarDifferentTagSizes, TestRepeatedScalarDifferentTagSizes.Builder> InternalFieldAccessors {
18280 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_TestRepeatedScalarDifferentTagSizes__FieldAccessorTable; }
18281 }
18282
18283 public const int RepeatedFixed32FieldNumber = 12;
18284 private pbc::PopsicleList<uint> repeatedFixed32_ = new pbc::PopsicleList<uint>();
18285 [global::System.CLSCompliant(false)]
18286 public scg::IList<uint> RepeatedFixed32List {
18287 get { return pbc::Lists.AsReadOnly(repeatedFixed32_); }
18288 }
18289 public int RepeatedFixed32Count {
18290 get { return repeatedFixed32_.Count; }
18291 }
18292 [global::System.CLSCompliant(false)]
18293 public uint GetRepeatedFixed32(int index) {
18294 return repeatedFixed32_[index];
18295 }
18296
18297 public const int RepeatedInt32FieldNumber = 13;
18298 private pbc::PopsicleList<int> repeatedInt32_ = new pbc::PopsicleList<int>();
18299 public scg::IList<int> RepeatedInt32List {
18300 get { return pbc::Lists.AsReadOnly(repeatedInt32_); }
18301 }
18302 public int RepeatedInt32Count {
18303 get { return repeatedInt32_.Count; }
18304 }
18305 public int GetRepeatedInt32(int index) {
18306 return repeatedInt32_[index];
18307 }
18308
18309 public const int RepeatedFixed64FieldNumber = 2046;
18310 private pbc::PopsicleList<ulong> repeatedFixed64_ = new pbc::PopsicleList<ulong>();
18311 [global::System.CLSCompliant(false)]
18312 public scg::IList<ulong> RepeatedFixed64List {
18313 get { return pbc::Lists.AsReadOnly(repeatedFixed64_); }
18314 }
18315 public int RepeatedFixed64Count {
18316 get { return repeatedFixed64_.Count; }
18317 }
18318 [global::System.CLSCompliant(false)]
18319 public ulong GetRepeatedFixed64(int index) {
18320 return repeatedFixed64_[index];
18321 }
18322
18323 public const int RepeatedInt64FieldNumber = 2047;
18324 private pbc::PopsicleList<long> repeatedInt64_ = new pbc::PopsicleList<long>();
18325 public scg::IList<long> RepeatedInt64List {
18326 get { return pbc::Lists.AsReadOnly(repeatedInt64_); }
18327 }
18328 public int RepeatedInt64Count {
18329 get { return repeatedInt64_.Count; }
18330 }
18331 public long GetRepeatedInt64(int index) {
18332 return repeatedInt64_[index];
18333 }
18334
18335 public const int RepeatedFloatFieldNumber = 262142;
18336 private pbc::PopsicleList<float> repeatedFloat_ = new pbc::PopsicleList<float>();
18337 public scg::IList<float> RepeatedFloatList {
18338 get { return pbc::Lists.AsReadOnly(repeatedFloat_); }
18339 }
18340 public int RepeatedFloatCount {
18341 get { return repeatedFloat_.Count; }
18342 }
18343 public float GetRepeatedFloat(int index) {
18344 return repeatedFloat_[index];
18345 }
18346
18347 public const int RepeatedUint64FieldNumber = 262143;
18348 private pbc::PopsicleList<ulong> repeatedUint64_ = new pbc::PopsicleList<ulong>();
18349 [global::System.CLSCompliant(false)]
18350 public scg::IList<ulong> RepeatedUint64List {
18351 get { return pbc::Lists.AsReadOnly(repeatedUint64_); }
18352 }
18353 public int RepeatedUint64Count {
18354 get { return repeatedUint64_.Count; }
18355 }
18356 [global::System.CLSCompliant(false)]
18357 public ulong GetRepeatedUint64(int index) {
18358 return repeatedUint64_[index];
18359 }
18360
18361 public override bool IsInitialized {
18362 get {
18363 return true;
18364 }
18365 }
18366
csharptestffafdaa2011-06-03 12:58:14 -050018367 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018368 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050018369 string[] field_names = _testRepeatedScalarDifferentTagSizesFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +010018370 if (repeatedFixed32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050018371 output.WriteArray(pbd::FieldType.Fixed32, 12, field_names[0], repeatedFixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018372 }
18373 if (repeatedInt32_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050018374 output.WriteArray(pbd::FieldType.Int32, 13, field_names[3], repeatedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018375 }
18376 if (repeatedFixed64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050018377 output.WriteArray(pbd::FieldType.Fixed64, 2046, field_names[1], repeatedFixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018378 }
18379 if (repeatedInt64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050018380 output.WriteArray(pbd::FieldType.Int64, 2047, field_names[4], repeatedInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018381 }
18382 if (repeatedFloat_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050018383 output.WriteArray(pbd::FieldType.Float, 262142, field_names[2], repeatedFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018384 }
18385 if (repeatedUint64_.Count > 0) {
csharptest920b09a2011-06-08 20:13:29 -050018386 output.WriteArray(pbd::FieldType.UInt64, 262143, field_names[5], repeatedUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018387 }
18388 UnknownFields.WriteTo(output);
18389 }
18390
18391 private int memoizedSerializedSize = -1;
18392 public override int SerializedSize {
18393 get {
18394 int size = memoizedSerializedSize;
18395 if (size != -1) return size;
18396
18397 size = 0;
18398 {
18399 int dataSize = 0;
18400 dataSize = 4 * repeatedFixed32_.Count;
18401 size += dataSize;
18402 size += 1 * repeatedFixed32_.Count;
18403 }
18404 {
18405 int dataSize = 0;
18406 foreach (int element in RepeatedInt32List) {
18407 dataSize += pb::CodedOutputStream.ComputeInt32SizeNoTag(element);
18408 }
18409 size += dataSize;
18410 size += 1 * repeatedInt32_.Count;
18411 }
18412 {
18413 int dataSize = 0;
18414 dataSize = 8 * repeatedFixed64_.Count;
18415 size += dataSize;
18416 size += 2 * repeatedFixed64_.Count;
18417 }
18418 {
18419 int dataSize = 0;
18420 foreach (long element in RepeatedInt64List) {
18421 dataSize += pb::CodedOutputStream.ComputeInt64SizeNoTag(element);
18422 }
18423 size += dataSize;
18424 size += 2 * repeatedInt64_.Count;
18425 }
18426 {
18427 int dataSize = 0;
18428 dataSize = 4 * repeatedFloat_.Count;
18429 size += dataSize;
18430 size += 3 * repeatedFloat_.Count;
18431 }
18432 {
18433 int dataSize = 0;
18434 foreach (ulong element in RepeatedUint64List) {
18435 dataSize += pb::CodedOutputStream.ComputeUInt64SizeNoTag(element);
18436 }
18437 size += dataSize;
18438 size += 3 * repeatedUint64_.Count;
18439 }
18440 size += UnknownFields.SerializedSize;
18441 memoizedSerializedSize = size;
18442 return size;
18443 }
18444 }
18445
18446 public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ByteString data) {
18447 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
18448 }
18449 public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
18450 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
18451 }
18452 public static TestRepeatedScalarDifferentTagSizes ParseFrom(byte[] data) {
18453 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
18454 }
18455 public static TestRepeatedScalarDifferentTagSizes ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
18456 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
18457 }
18458 public static TestRepeatedScalarDifferentTagSizes ParseFrom(global::System.IO.Stream input) {
18459 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
18460 }
18461 public static TestRepeatedScalarDifferentTagSizes ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
18462 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
18463 }
18464 public static TestRepeatedScalarDifferentTagSizes ParseDelimitedFrom(global::System.IO.Stream input) {
18465 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
18466 }
18467 public static TestRepeatedScalarDifferentTagSizes ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
18468 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
18469 }
csharptest17699c22011-06-03 21:57:15 -050018470 public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018471 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
18472 }
csharptest17699c22011-06-03 21:57:15 -050018473 public static TestRepeatedScalarDifferentTagSizes ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018474 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
18475 }
18476 public static Builder CreateBuilder() { return new Builder(); }
18477 public override Builder ToBuilder() { return CreateBuilder(this); }
18478 public override Builder CreateBuilderForType() { return new Builder(); }
18479 public static Builder CreateBuilder(TestRepeatedScalarDifferentTagSizes prototype) {
18480 return (Builder) new Builder().MergeFrom(prototype);
18481 }
18482
csharptest445bdce2011-05-20 15:50:54 -050018483 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
18484 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
18485 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010018486 public sealed partial class Builder : pb::GeneratedBuilder<TestRepeatedScalarDifferentTagSizes, Builder> {
18487 protected override Builder ThisBuilder {
18488 get { return this; }
18489 }
18490 public Builder() {}
18491
18492 TestRepeatedScalarDifferentTagSizes result = new TestRepeatedScalarDifferentTagSizes();
18493
18494 protected override TestRepeatedScalarDifferentTagSizes MessageBeingBuilt {
18495 get { return result; }
18496 }
18497
18498 public override Builder Clear() {
18499 result = new TestRepeatedScalarDifferentTagSizes();
18500 return this;
18501 }
18502
18503 public override Builder Clone() {
18504 return new Builder().MergeFrom(result);
18505 }
18506
18507 public override pbd::MessageDescriptor DescriptorForType {
18508 get { return global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.Descriptor; }
18509 }
18510
18511 public override TestRepeatedScalarDifferentTagSizes DefaultInstanceForType {
18512 get { return global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.DefaultInstance; }
18513 }
18514
18515 public override TestRepeatedScalarDifferentTagSizes BuildPartial() {
18516 if (result == null) {
18517 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
18518 }
18519 result.repeatedFixed32_.MakeReadOnly();
18520 result.repeatedInt32_.MakeReadOnly();
18521 result.repeatedFixed64_.MakeReadOnly();
18522 result.repeatedInt64_.MakeReadOnly();
18523 result.repeatedFloat_.MakeReadOnly();
18524 result.repeatedUint64_.MakeReadOnly();
18525 TestRepeatedScalarDifferentTagSizes returnMe = result;
18526 result = null;
18527 return returnMe;
18528 }
18529
18530 public override Builder MergeFrom(pb::IMessage other) {
18531 if (other is TestRepeatedScalarDifferentTagSizes) {
18532 return MergeFrom((TestRepeatedScalarDifferentTagSizes) other);
18533 } else {
18534 base.MergeFrom(other);
18535 return this;
18536 }
18537 }
18538
18539 public override Builder MergeFrom(TestRepeatedScalarDifferentTagSizes other) {
18540 if (other == global::Google.ProtocolBuffers.TestProtos.TestRepeatedScalarDifferentTagSizes.DefaultInstance) return this;
18541 if (other.repeatedFixed32_.Count != 0) {
18542 base.AddRange(other.repeatedFixed32_, result.repeatedFixed32_);
18543 }
18544 if (other.repeatedInt32_.Count != 0) {
18545 base.AddRange(other.repeatedInt32_, result.repeatedInt32_);
18546 }
18547 if (other.repeatedFixed64_.Count != 0) {
18548 base.AddRange(other.repeatedFixed64_, result.repeatedFixed64_);
18549 }
18550 if (other.repeatedInt64_.Count != 0) {
18551 base.AddRange(other.repeatedInt64_, result.repeatedInt64_);
18552 }
18553 if (other.repeatedFloat_.Count != 0) {
18554 base.AddRange(other.repeatedFloat_, result.repeatedFloat_);
18555 }
18556 if (other.repeatedUint64_.Count != 0) {
18557 base.AddRange(other.repeatedUint64_, result.repeatedUint64_);
18558 }
18559 this.MergeUnknownFields(other.UnknownFields);
18560 return this;
18561 }
18562
csharptest17699c22011-06-03 21:57:15 -050018563 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018564 return MergeFrom(input, pb::ExtensionRegistry.Empty);
18565 }
18566
csharptest17699c22011-06-03 21:57:15 -050018567 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018568 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050018569 uint tag;
18570 string field_name;
18571 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050018572 if(tag == 0 && field_name != null) {
18573 int field_ordinal = global::System.Array.BinarySearch(_testRepeatedScalarDifferentTagSizesFieldNames, field_name, global::System.StringComparer.Ordinal);
18574 if(field_ordinal >= 0)
18575 tag = _testRepeatedScalarDifferentTagSizesFieldTags[field_ordinal];
18576 else {
18577 if (unknownFields == null) {
18578 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
18579 }
18580 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
18581 continue;
18582 }
18583 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010018584 switch (tag) {
18585 case 0: {
csharptest99284412011-06-03 14:51:06 -050018586 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010018587 }
18588 default: {
18589 if (pb::WireFormat.IsEndGroupTag(tag)) {
18590 if (unknownFields != null) {
18591 this.UnknownFields = unknownFields.Build();
18592 }
18593 return this;
18594 }
18595 if (unknownFields == null) {
18596 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
18597 }
csharptestd2af9e92011-06-03 21:35:02 -050018598 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018599 break;
18600 }
csharptest6da31702011-06-04 12:52:57 -050018601 case 98:
Jon Skeet82bb0f12011-04-03 20:17:12 +010018602 case 101: {
csharptestd2af9e92011-06-03 21:35:02 -050018603 input.ReadPrimitiveArray(pbd::FieldType.Fixed32, tag, field_name, result.repeatedFixed32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018604 break;
18605 }
csharptest6da31702011-06-04 12:52:57 -050018606 case 106:
Jon Skeet82bb0f12011-04-03 20:17:12 +010018607 case 104: {
csharptestd2af9e92011-06-03 21:35:02 -050018608 input.ReadPrimitiveArray(pbd::FieldType.Int32, tag, field_name, result.repeatedInt32_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018609 break;
18610 }
csharptest6da31702011-06-04 12:52:57 -050018611 case 16370:
Jon Skeet82bb0f12011-04-03 20:17:12 +010018612 case 16369: {
csharptestd2af9e92011-06-03 21:35:02 -050018613 input.ReadPrimitiveArray(pbd::FieldType.Fixed64, tag, field_name, result.repeatedFixed64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018614 break;
18615 }
csharptest6da31702011-06-04 12:52:57 -050018616 case 16378:
Jon Skeet82bb0f12011-04-03 20:17:12 +010018617 case 16376: {
csharptestd2af9e92011-06-03 21:35:02 -050018618 input.ReadPrimitiveArray(pbd::FieldType.Int64, tag, field_name, result.repeatedInt64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018619 break;
18620 }
csharptest6da31702011-06-04 12:52:57 -050018621 case 2097138:
Jon Skeet82bb0f12011-04-03 20:17:12 +010018622 case 2097141: {
csharptestd2af9e92011-06-03 21:35:02 -050018623 input.ReadPrimitiveArray(pbd::FieldType.Float, tag, field_name, result.repeatedFloat_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018624 break;
18625 }
csharptest6da31702011-06-04 12:52:57 -050018626 case 2097146:
Jon Skeet82bb0f12011-04-03 20:17:12 +010018627 case 2097144: {
csharptestd2af9e92011-06-03 21:35:02 -050018628 input.ReadPrimitiveArray(pbd::FieldType.UInt64, tag, field_name, result.repeatedUint64_);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018629 break;
18630 }
18631 }
18632 }
csharptest123e5342011-06-03 14:15:21 -050018633
18634 if (unknownFields != null) {
18635 this.UnknownFields = unknownFields.Build();
18636 }
18637 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010018638 }
18639
18640
18641 [global::System.CLSCompliant(false)]
18642 public pbc::IPopsicleList<uint> RepeatedFixed32List {
18643 get { return result.repeatedFixed32_; }
18644 }
18645 public int RepeatedFixed32Count {
18646 get { return result.RepeatedFixed32Count; }
18647 }
18648 [global::System.CLSCompliant(false)]
18649 public uint GetRepeatedFixed32(int index) {
18650 return result.GetRepeatedFixed32(index);
18651 }
18652 [global::System.CLSCompliant(false)]
18653 public Builder SetRepeatedFixed32(int index, uint value) {
18654 result.repeatedFixed32_[index] = value;
18655 return this;
18656 }
18657 [global::System.CLSCompliant(false)]
18658 public Builder AddRepeatedFixed32(uint value) {
18659 result.repeatedFixed32_.Add(value);
18660 return this;
18661 }
18662 [global::System.CLSCompliant(false)]
18663 public Builder AddRangeRepeatedFixed32(scg::IEnumerable<uint> values) {
18664 base.AddRange(values, result.repeatedFixed32_);
18665 return this;
18666 }
18667 public Builder ClearRepeatedFixed32() {
18668 result.repeatedFixed32_.Clear();
18669 return this;
18670 }
18671
18672 public pbc::IPopsicleList<int> RepeatedInt32List {
18673 get { return result.repeatedInt32_; }
18674 }
18675 public int RepeatedInt32Count {
18676 get { return result.RepeatedInt32Count; }
18677 }
18678 public int GetRepeatedInt32(int index) {
18679 return result.GetRepeatedInt32(index);
18680 }
18681 public Builder SetRepeatedInt32(int index, int value) {
18682 result.repeatedInt32_[index] = value;
18683 return this;
18684 }
18685 public Builder AddRepeatedInt32(int value) {
18686 result.repeatedInt32_.Add(value);
18687 return this;
18688 }
18689 public Builder AddRangeRepeatedInt32(scg::IEnumerable<int> values) {
18690 base.AddRange(values, result.repeatedInt32_);
18691 return this;
18692 }
18693 public Builder ClearRepeatedInt32() {
18694 result.repeatedInt32_.Clear();
18695 return this;
18696 }
18697
18698 [global::System.CLSCompliant(false)]
18699 public pbc::IPopsicleList<ulong> RepeatedFixed64List {
18700 get { return result.repeatedFixed64_; }
18701 }
18702 public int RepeatedFixed64Count {
18703 get { return result.RepeatedFixed64Count; }
18704 }
18705 [global::System.CLSCompliant(false)]
18706 public ulong GetRepeatedFixed64(int index) {
18707 return result.GetRepeatedFixed64(index);
18708 }
18709 [global::System.CLSCompliant(false)]
18710 public Builder SetRepeatedFixed64(int index, ulong value) {
18711 result.repeatedFixed64_[index] = value;
18712 return this;
18713 }
18714 [global::System.CLSCompliant(false)]
18715 public Builder AddRepeatedFixed64(ulong value) {
18716 result.repeatedFixed64_.Add(value);
18717 return this;
18718 }
18719 [global::System.CLSCompliant(false)]
18720 public Builder AddRangeRepeatedFixed64(scg::IEnumerable<ulong> values) {
18721 base.AddRange(values, result.repeatedFixed64_);
18722 return this;
18723 }
18724 public Builder ClearRepeatedFixed64() {
18725 result.repeatedFixed64_.Clear();
18726 return this;
18727 }
18728
18729 public pbc::IPopsicleList<long> RepeatedInt64List {
18730 get { return result.repeatedInt64_; }
18731 }
18732 public int RepeatedInt64Count {
18733 get { return result.RepeatedInt64Count; }
18734 }
18735 public long GetRepeatedInt64(int index) {
18736 return result.GetRepeatedInt64(index);
18737 }
18738 public Builder SetRepeatedInt64(int index, long value) {
18739 result.repeatedInt64_[index] = value;
18740 return this;
18741 }
18742 public Builder AddRepeatedInt64(long value) {
18743 result.repeatedInt64_.Add(value);
18744 return this;
18745 }
18746 public Builder AddRangeRepeatedInt64(scg::IEnumerable<long> values) {
18747 base.AddRange(values, result.repeatedInt64_);
18748 return this;
18749 }
18750 public Builder ClearRepeatedInt64() {
18751 result.repeatedInt64_.Clear();
18752 return this;
18753 }
18754
18755 public pbc::IPopsicleList<float> RepeatedFloatList {
18756 get { return result.repeatedFloat_; }
18757 }
18758 public int RepeatedFloatCount {
18759 get { return result.RepeatedFloatCount; }
18760 }
18761 public float GetRepeatedFloat(int index) {
18762 return result.GetRepeatedFloat(index);
18763 }
18764 public Builder SetRepeatedFloat(int index, float value) {
18765 result.repeatedFloat_[index] = value;
18766 return this;
18767 }
18768 public Builder AddRepeatedFloat(float value) {
18769 result.repeatedFloat_.Add(value);
18770 return this;
18771 }
18772 public Builder AddRangeRepeatedFloat(scg::IEnumerable<float> values) {
18773 base.AddRange(values, result.repeatedFloat_);
18774 return this;
18775 }
18776 public Builder ClearRepeatedFloat() {
18777 result.repeatedFloat_.Clear();
18778 return this;
18779 }
18780
18781 [global::System.CLSCompliant(false)]
18782 public pbc::IPopsicleList<ulong> RepeatedUint64List {
18783 get { return result.repeatedUint64_; }
18784 }
18785 public int RepeatedUint64Count {
18786 get { return result.RepeatedUint64Count; }
18787 }
18788 [global::System.CLSCompliant(false)]
18789 public ulong GetRepeatedUint64(int index) {
18790 return result.GetRepeatedUint64(index);
18791 }
18792 [global::System.CLSCompliant(false)]
18793 public Builder SetRepeatedUint64(int index, ulong value) {
18794 result.repeatedUint64_[index] = value;
18795 return this;
18796 }
18797 [global::System.CLSCompliant(false)]
18798 public Builder AddRepeatedUint64(ulong value) {
18799 result.repeatedUint64_.Add(value);
18800 return this;
18801 }
18802 [global::System.CLSCompliant(false)]
18803 public Builder AddRangeRepeatedUint64(scg::IEnumerable<ulong> values) {
18804 base.AddRange(values, result.repeatedUint64_);
18805 return this;
18806 }
18807 public Builder ClearRepeatedUint64() {
18808 result.repeatedUint64_.Clear();
18809 return this;
18810 }
18811 }
18812 static TestRepeatedScalarDifferentTagSizes() {
18813 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
18814 }
18815 }
18816
csharptest445bdce2011-05-20 15:50:54 -050018817 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
18818 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
18819 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010018820 public sealed partial class FooRequest : pb::GeneratedMessage<FooRequest, FooRequest.Builder> {
18821 private static readonly FooRequest defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050018822 private static readonly string[] _fooRequestFieldNames = new string[] { };
18823 private static readonly uint[] _fooRequestFieldTags = new uint[] { };
Jon Skeet82bb0f12011-04-03 20:17:12 +010018824 public static FooRequest DefaultInstance {
18825 get { return defaultInstance; }
18826 }
18827
18828 public override FooRequest DefaultInstanceForType {
18829 get { return defaultInstance; }
18830 }
18831
18832 protected override FooRequest ThisMessage {
18833 get { return this; }
18834 }
18835
18836 public static pbd::MessageDescriptor Descriptor {
18837 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_FooRequest__Descriptor; }
18838 }
18839
18840 protected override pb::FieldAccess.FieldAccessorTable<FooRequest, FooRequest.Builder> InternalFieldAccessors {
18841 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_FooRequest__FieldAccessorTable; }
18842 }
18843
18844 public override bool IsInitialized {
18845 get {
18846 return true;
18847 }
18848 }
18849
csharptestffafdaa2011-06-03 12:58:14 -050018850 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018851 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050018852 string[] field_names = _fooRequestFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +010018853 UnknownFields.WriteTo(output);
18854 }
18855
18856 private int memoizedSerializedSize = -1;
18857 public override int SerializedSize {
18858 get {
18859 int size = memoizedSerializedSize;
18860 if (size != -1) return size;
18861
18862 size = 0;
18863 size += UnknownFields.SerializedSize;
18864 memoizedSerializedSize = size;
18865 return size;
18866 }
18867 }
18868
18869 public static FooRequest ParseFrom(pb::ByteString data) {
18870 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
18871 }
18872 public static FooRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
18873 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
18874 }
18875 public static FooRequest ParseFrom(byte[] data) {
18876 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
18877 }
18878 public static FooRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
18879 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
18880 }
18881 public static FooRequest ParseFrom(global::System.IO.Stream input) {
18882 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
18883 }
18884 public static FooRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
18885 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
18886 }
18887 public static FooRequest ParseDelimitedFrom(global::System.IO.Stream input) {
18888 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
18889 }
18890 public static FooRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
18891 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
18892 }
csharptest17699c22011-06-03 21:57:15 -050018893 public static FooRequest ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018894 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
18895 }
csharptest17699c22011-06-03 21:57:15 -050018896 public static FooRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018897 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
18898 }
18899 public static Builder CreateBuilder() { return new Builder(); }
18900 public override Builder ToBuilder() { return CreateBuilder(this); }
18901 public override Builder CreateBuilderForType() { return new Builder(); }
18902 public static Builder CreateBuilder(FooRequest prototype) {
18903 return (Builder) new Builder().MergeFrom(prototype);
18904 }
18905
csharptest445bdce2011-05-20 15:50:54 -050018906 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
18907 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
18908 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010018909 public sealed partial class Builder : pb::GeneratedBuilder<FooRequest, Builder> {
18910 protected override Builder ThisBuilder {
18911 get { return this; }
18912 }
18913 public Builder() {}
18914
18915 FooRequest result = new FooRequest();
18916
18917 protected override FooRequest MessageBeingBuilt {
18918 get { return result; }
18919 }
18920
18921 public override Builder Clear() {
18922 result = new FooRequest();
18923 return this;
18924 }
18925
18926 public override Builder Clone() {
18927 return new Builder().MergeFrom(result);
18928 }
18929
18930 public override pbd::MessageDescriptor DescriptorForType {
18931 get { return global::Google.ProtocolBuffers.TestProtos.FooRequest.Descriptor; }
18932 }
18933
18934 public override FooRequest DefaultInstanceForType {
18935 get { return global::Google.ProtocolBuffers.TestProtos.FooRequest.DefaultInstance; }
18936 }
18937
18938 public override FooRequest BuildPartial() {
18939 if (result == null) {
18940 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
18941 }
18942 FooRequest returnMe = result;
18943 result = null;
18944 return returnMe;
18945 }
18946
18947 public override Builder MergeFrom(pb::IMessage other) {
18948 if (other is FooRequest) {
18949 return MergeFrom((FooRequest) other);
18950 } else {
18951 base.MergeFrom(other);
18952 return this;
18953 }
18954 }
18955
18956 public override Builder MergeFrom(FooRequest other) {
18957 if (other == global::Google.ProtocolBuffers.TestProtos.FooRequest.DefaultInstance) return this;
18958 this.MergeUnknownFields(other.UnknownFields);
18959 return this;
18960 }
18961
csharptest17699c22011-06-03 21:57:15 -050018962 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018963 return MergeFrom(input, pb::ExtensionRegistry.Empty);
18964 }
18965
csharptest17699c22011-06-03 21:57:15 -050018966 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010018967 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050018968 uint tag;
18969 string field_name;
18970 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050018971 if(tag == 0 && field_name != null) {
18972 int field_ordinal = global::System.Array.BinarySearch(_fooRequestFieldNames, field_name, global::System.StringComparer.Ordinal);
18973 if(field_ordinal >= 0)
18974 tag = _fooRequestFieldTags[field_ordinal];
18975 else {
18976 if (unknownFields == null) {
18977 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
18978 }
18979 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
18980 continue;
18981 }
18982 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010018983 switch (tag) {
18984 case 0: {
csharptest99284412011-06-03 14:51:06 -050018985 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010018986 }
18987 default: {
18988 if (pb::WireFormat.IsEndGroupTag(tag)) {
18989 if (unknownFields != null) {
18990 this.UnknownFields = unknownFields.Build();
18991 }
18992 return this;
18993 }
18994 if (unknownFields == null) {
18995 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
18996 }
csharptestd2af9e92011-06-03 21:35:02 -050018997 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010018998 break;
18999 }
19000 }
19001 }
csharptest123e5342011-06-03 14:15:21 -050019002
19003 if (unknownFields != null) {
19004 this.UnknownFields = unknownFields.Build();
19005 }
19006 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010019007 }
19008
19009 }
19010 static FooRequest() {
19011 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
19012 }
19013 }
19014
csharptest445bdce2011-05-20 15:50:54 -050019015 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
19016 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
19017 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010019018 public sealed partial class FooResponse : pb::GeneratedMessage<FooResponse, FooResponse.Builder> {
19019 private static readonly FooResponse defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050019020 private static readonly string[] _fooResponseFieldNames = new string[] { };
19021 private static readonly uint[] _fooResponseFieldTags = new uint[] { };
Jon Skeet82bb0f12011-04-03 20:17:12 +010019022 public static FooResponse DefaultInstance {
19023 get { return defaultInstance; }
19024 }
19025
19026 public override FooResponse DefaultInstanceForType {
19027 get { return defaultInstance; }
19028 }
19029
19030 protected override FooResponse ThisMessage {
19031 get { return this; }
19032 }
19033
19034 public static pbd::MessageDescriptor Descriptor {
19035 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_FooResponse__Descriptor; }
19036 }
19037
19038 protected override pb::FieldAccess.FieldAccessorTable<FooResponse, FooResponse.Builder> InternalFieldAccessors {
19039 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_FooResponse__FieldAccessorTable; }
19040 }
19041
19042 public override bool IsInitialized {
19043 get {
19044 return true;
19045 }
19046 }
19047
csharptestffafdaa2011-06-03 12:58:14 -050019048 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019049 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050019050 string[] field_names = _fooResponseFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +010019051 UnknownFields.WriteTo(output);
19052 }
19053
19054 private int memoizedSerializedSize = -1;
19055 public override int SerializedSize {
19056 get {
19057 int size = memoizedSerializedSize;
19058 if (size != -1) return size;
19059
19060 size = 0;
19061 size += UnknownFields.SerializedSize;
19062 memoizedSerializedSize = size;
19063 return size;
19064 }
19065 }
19066
19067 public static FooResponse ParseFrom(pb::ByteString data) {
19068 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
19069 }
19070 public static FooResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
19071 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
19072 }
19073 public static FooResponse ParseFrom(byte[] data) {
19074 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
19075 }
19076 public static FooResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
19077 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
19078 }
19079 public static FooResponse ParseFrom(global::System.IO.Stream input) {
19080 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
19081 }
19082 public static FooResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
19083 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
19084 }
19085 public static FooResponse ParseDelimitedFrom(global::System.IO.Stream input) {
19086 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
19087 }
19088 public static FooResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
19089 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
19090 }
csharptest17699c22011-06-03 21:57:15 -050019091 public static FooResponse ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019092 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
19093 }
csharptest17699c22011-06-03 21:57:15 -050019094 public static FooResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019095 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
19096 }
19097 public static Builder CreateBuilder() { return new Builder(); }
19098 public override Builder ToBuilder() { return CreateBuilder(this); }
19099 public override Builder CreateBuilderForType() { return new Builder(); }
19100 public static Builder CreateBuilder(FooResponse prototype) {
19101 return (Builder) new Builder().MergeFrom(prototype);
19102 }
19103
csharptest445bdce2011-05-20 15:50:54 -050019104 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
19105 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
19106 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010019107 public sealed partial class Builder : pb::GeneratedBuilder<FooResponse, Builder> {
19108 protected override Builder ThisBuilder {
19109 get { return this; }
19110 }
19111 public Builder() {}
19112
19113 FooResponse result = new FooResponse();
19114
19115 protected override FooResponse MessageBeingBuilt {
19116 get { return result; }
19117 }
19118
19119 public override Builder Clear() {
19120 result = new FooResponse();
19121 return this;
19122 }
19123
19124 public override Builder Clone() {
19125 return new Builder().MergeFrom(result);
19126 }
19127
19128 public override pbd::MessageDescriptor DescriptorForType {
19129 get { return global::Google.ProtocolBuffers.TestProtos.FooResponse.Descriptor; }
19130 }
19131
19132 public override FooResponse DefaultInstanceForType {
19133 get { return global::Google.ProtocolBuffers.TestProtos.FooResponse.DefaultInstance; }
19134 }
19135
19136 public override FooResponse BuildPartial() {
19137 if (result == null) {
19138 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
19139 }
19140 FooResponse returnMe = result;
19141 result = null;
19142 return returnMe;
19143 }
19144
19145 public override Builder MergeFrom(pb::IMessage other) {
19146 if (other is FooResponse) {
19147 return MergeFrom((FooResponse) other);
19148 } else {
19149 base.MergeFrom(other);
19150 return this;
19151 }
19152 }
19153
19154 public override Builder MergeFrom(FooResponse other) {
19155 if (other == global::Google.ProtocolBuffers.TestProtos.FooResponse.DefaultInstance) return this;
19156 this.MergeUnknownFields(other.UnknownFields);
19157 return this;
19158 }
19159
csharptest17699c22011-06-03 21:57:15 -050019160 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019161 return MergeFrom(input, pb::ExtensionRegistry.Empty);
19162 }
19163
csharptest17699c22011-06-03 21:57:15 -050019164 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019165 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050019166 uint tag;
19167 string field_name;
19168 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050019169 if(tag == 0 && field_name != null) {
19170 int field_ordinal = global::System.Array.BinarySearch(_fooResponseFieldNames, field_name, global::System.StringComparer.Ordinal);
19171 if(field_ordinal >= 0)
19172 tag = _fooResponseFieldTags[field_ordinal];
19173 else {
19174 if (unknownFields == null) {
19175 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
19176 }
19177 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
19178 continue;
19179 }
19180 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010019181 switch (tag) {
19182 case 0: {
csharptest99284412011-06-03 14:51:06 -050019183 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010019184 }
19185 default: {
19186 if (pb::WireFormat.IsEndGroupTag(tag)) {
19187 if (unknownFields != null) {
19188 this.UnknownFields = unknownFields.Build();
19189 }
19190 return this;
19191 }
19192 if (unknownFields == null) {
19193 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
19194 }
csharptestd2af9e92011-06-03 21:35:02 -050019195 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010019196 break;
19197 }
19198 }
19199 }
csharptest123e5342011-06-03 14:15:21 -050019200
19201 if (unknownFields != null) {
19202 this.UnknownFields = unknownFields.Build();
19203 }
19204 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010019205 }
19206
19207 }
19208 static FooResponse() {
19209 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
19210 }
19211 }
19212
csharptest445bdce2011-05-20 15:50:54 -050019213 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
19214 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
19215 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010019216 public sealed partial class BarRequest : pb::GeneratedMessage<BarRequest, BarRequest.Builder> {
19217 private static readonly BarRequest defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050019218 private static readonly string[] _barRequestFieldNames = new string[] { };
19219 private static readonly uint[] _barRequestFieldTags = new uint[] { };
Jon Skeet82bb0f12011-04-03 20:17:12 +010019220 public static BarRequest DefaultInstance {
19221 get { return defaultInstance; }
19222 }
19223
19224 public override BarRequest DefaultInstanceForType {
19225 get { return defaultInstance; }
19226 }
19227
19228 protected override BarRequest ThisMessage {
19229 get { return this; }
19230 }
19231
19232 public static pbd::MessageDescriptor Descriptor {
19233 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_BarRequest__Descriptor; }
19234 }
19235
19236 protected override pb::FieldAccess.FieldAccessorTable<BarRequest, BarRequest.Builder> InternalFieldAccessors {
19237 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_BarRequest__FieldAccessorTable; }
19238 }
19239
19240 public override bool IsInitialized {
19241 get {
19242 return true;
19243 }
19244 }
19245
csharptestffafdaa2011-06-03 12:58:14 -050019246 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019247 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050019248 string[] field_names = _barRequestFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +010019249 UnknownFields.WriteTo(output);
19250 }
19251
19252 private int memoizedSerializedSize = -1;
19253 public override int SerializedSize {
19254 get {
19255 int size = memoizedSerializedSize;
19256 if (size != -1) return size;
19257
19258 size = 0;
19259 size += UnknownFields.SerializedSize;
19260 memoizedSerializedSize = size;
19261 return size;
19262 }
19263 }
19264
19265 public static BarRequest ParseFrom(pb::ByteString data) {
19266 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
19267 }
19268 public static BarRequest ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
19269 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
19270 }
19271 public static BarRequest ParseFrom(byte[] data) {
19272 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
19273 }
19274 public static BarRequest ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
19275 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
19276 }
19277 public static BarRequest ParseFrom(global::System.IO.Stream input) {
19278 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
19279 }
19280 public static BarRequest ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
19281 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
19282 }
19283 public static BarRequest ParseDelimitedFrom(global::System.IO.Stream input) {
19284 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
19285 }
19286 public static BarRequest ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
19287 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
19288 }
csharptest17699c22011-06-03 21:57:15 -050019289 public static BarRequest ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019290 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
19291 }
csharptest17699c22011-06-03 21:57:15 -050019292 public static BarRequest ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019293 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
19294 }
19295 public static Builder CreateBuilder() { return new Builder(); }
19296 public override Builder ToBuilder() { return CreateBuilder(this); }
19297 public override Builder CreateBuilderForType() { return new Builder(); }
19298 public static Builder CreateBuilder(BarRequest prototype) {
19299 return (Builder) new Builder().MergeFrom(prototype);
19300 }
19301
csharptest445bdce2011-05-20 15:50:54 -050019302 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
19303 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
19304 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010019305 public sealed partial class Builder : pb::GeneratedBuilder<BarRequest, Builder> {
19306 protected override Builder ThisBuilder {
19307 get { return this; }
19308 }
19309 public Builder() {}
19310
19311 BarRequest result = new BarRequest();
19312
19313 protected override BarRequest MessageBeingBuilt {
19314 get { return result; }
19315 }
19316
19317 public override Builder Clear() {
19318 result = new BarRequest();
19319 return this;
19320 }
19321
19322 public override Builder Clone() {
19323 return new Builder().MergeFrom(result);
19324 }
19325
19326 public override pbd::MessageDescriptor DescriptorForType {
19327 get { return global::Google.ProtocolBuffers.TestProtos.BarRequest.Descriptor; }
19328 }
19329
19330 public override BarRequest DefaultInstanceForType {
19331 get { return global::Google.ProtocolBuffers.TestProtos.BarRequest.DefaultInstance; }
19332 }
19333
19334 public override BarRequest BuildPartial() {
19335 if (result == null) {
19336 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
19337 }
19338 BarRequest returnMe = result;
19339 result = null;
19340 return returnMe;
19341 }
19342
19343 public override Builder MergeFrom(pb::IMessage other) {
19344 if (other is BarRequest) {
19345 return MergeFrom((BarRequest) other);
19346 } else {
19347 base.MergeFrom(other);
19348 return this;
19349 }
19350 }
19351
19352 public override Builder MergeFrom(BarRequest other) {
19353 if (other == global::Google.ProtocolBuffers.TestProtos.BarRequest.DefaultInstance) return this;
19354 this.MergeUnknownFields(other.UnknownFields);
19355 return this;
19356 }
19357
csharptest17699c22011-06-03 21:57:15 -050019358 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019359 return MergeFrom(input, pb::ExtensionRegistry.Empty);
19360 }
19361
csharptest17699c22011-06-03 21:57:15 -050019362 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019363 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050019364 uint tag;
19365 string field_name;
19366 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050019367 if(tag == 0 && field_name != null) {
19368 int field_ordinal = global::System.Array.BinarySearch(_barRequestFieldNames, field_name, global::System.StringComparer.Ordinal);
19369 if(field_ordinal >= 0)
19370 tag = _barRequestFieldTags[field_ordinal];
19371 else {
19372 if (unknownFields == null) {
19373 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
19374 }
19375 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
19376 continue;
19377 }
19378 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010019379 switch (tag) {
19380 case 0: {
csharptest99284412011-06-03 14:51:06 -050019381 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010019382 }
19383 default: {
19384 if (pb::WireFormat.IsEndGroupTag(tag)) {
19385 if (unknownFields != null) {
19386 this.UnknownFields = unknownFields.Build();
19387 }
19388 return this;
19389 }
19390 if (unknownFields == null) {
19391 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
19392 }
csharptestd2af9e92011-06-03 21:35:02 -050019393 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010019394 break;
19395 }
19396 }
19397 }
csharptest123e5342011-06-03 14:15:21 -050019398
19399 if (unknownFields != null) {
19400 this.UnknownFields = unknownFields.Build();
19401 }
19402 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010019403 }
19404
19405 }
19406 static BarRequest() {
19407 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
19408 }
19409 }
19410
csharptest445bdce2011-05-20 15:50:54 -050019411 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
19412 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
19413 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010019414 public sealed partial class BarResponse : pb::GeneratedMessage<BarResponse, BarResponse.Builder> {
19415 private static readonly BarResponse defaultInstance = new Builder().BuildPartial();
csharptest920b09a2011-06-08 20:13:29 -050019416 private static readonly string[] _barResponseFieldNames = new string[] { };
19417 private static readonly uint[] _barResponseFieldTags = new uint[] { };
Jon Skeet82bb0f12011-04-03 20:17:12 +010019418 public static BarResponse DefaultInstance {
19419 get { return defaultInstance; }
19420 }
19421
19422 public override BarResponse DefaultInstanceForType {
19423 get { return defaultInstance; }
19424 }
19425
19426 protected override BarResponse ThisMessage {
19427 get { return this; }
19428 }
19429
19430 public static pbd::MessageDescriptor Descriptor {
19431 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_BarResponse__Descriptor; }
19432 }
19433
19434 protected override pb::FieldAccess.FieldAccessorTable<BarResponse, BarResponse.Builder> InternalFieldAccessors {
19435 get { return global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.internal__static_protobuf_unittest_BarResponse__FieldAccessorTable; }
19436 }
19437
19438 public override bool IsInitialized {
19439 get {
19440 return true;
19441 }
19442 }
19443
csharptestffafdaa2011-06-03 12:58:14 -050019444 public override void WriteTo(pb::ICodedOutputStream output) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019445 int size = SerializedSize;
csharptest920b09a2011-06-08 20:13:29 -050019446 string[] field_names = _barResponseFieldNames;
Jon Skeet82bb0f12011-04-03 20:17:12 +010019447 UnknownFields.WriteTo(output);
19448 }
19449
19450 private int memoizedSerializedSize = -1;
19451 public override int SerializedSize {
19452 get {
19453 int size = memoizedSerializedSize;
19454 if (size != -1) return size;
19455
19456 size = 0;
19457 size += UnknownFields.SerializedSize;
19458 memoizedSerializedSize = size;
19459 return size;
19460 }
19461 }
19462
19463 public static BarResponse ParseFrom(pb::ByteString data) {
19464 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
19465 }
19466 public static BarResponse ParseFrom(pb::ByteString data, pb::ExtensionRegistry extensionRegistry) {
19467 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
19468 }
19469 public static BarResponse ParseFrom(byte[] data) {
19470 return ((Builder) CreateBuilder().MergeFrom(data)).BuildParsed();
19471 }
19472 public static BarResponse ParseFrom(byte[] data, pb::ExtensionRegistry extensionRegistry) {
19473 return ((Builder) CreateBuilder().MergeFrom(data, extensionRegistry)).BuildParsed();
19474 }
19475 public static BarResponse ParseFrom(global::System.IO.Stream input) {
19476 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
19477 }
19478 public static BarResponse ParseFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
19479 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
19480 }
19481 public static BarResponse ParseDelimitedFrom(global::System.IO.Stream input) {
19482 return CreateBuilder().MergeDelimitedFrom(input).BuildParsed();
19483 }
19484 public static BarResponse ParseDelimitedFrom(global::System.IO.Stream input, pb::ExtensionRegistry extensionRegistry) {
19485 return CreateBuilder().MergeDelimitedFrom(input, extensionRegistry).BuildParsed();
19486 }
csharptest17699c22011-06-03 21:57:15 -050019487 public static BarResponse ParseFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019488 return ((Builder) CreateBuilder().MergeFrom(input)).BuildParsed();
19489 }
csharptest17699c22011-06-03 21:57:15 -050019490 public static BarResponse ParseFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019491 return ((Builder) CreateBuilder().MergeFrom(input, extensionRegistry)).BuildParsed();
19492 }
19493 public static Builder CreateBuilder() { return new Builder(); }
19494 public override Builder ToBuilder() { return CreateBuilder(this); }
19495 public override Builder CreateBuilderForType() { return new Builder(); }
19496 public static Builder CreateBuilder(BarResponse prototype) {
19497 return (Builder) new Builder().MergeFrom(prototype);
19498 }
19499
csharptest445bdce2011-05-20 15:50:54 -050019500 [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
19501 [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
19502 [global::System.CodeDom.Compiler.GeneratedCodeAttribute("ProtoGen", "2.3.0.277")]
Jon Skeet82bb0f12011-04-03 20:17:12 +010019503 public sealed partial class Builder : pb::GeneratedBuilder<BarResponse, Builder> {
19504 protected override Builder ThisBuilder {
19505 get { return this; }
19506 }
19507 public Builder() {}
19508
19509 BarResponse result = new BarResponse();
19510
19511 protected override BarResponse MessageBeingBuilt {
19512 get { return result; }
19513 }
19514
19515 public override Builder Clear() {
19516 result = new BarResponse();
19517 return this;
19518 }
19519
19520 public override Builder Clone() {
19521 return new Builder().MergeFrom(result);
19522 }
19523
19524 public override pbd::MessageDescriptor DescriptorForType {
19525 get { return global::Google.ProtocolBuffers.TestProtos.BarResponse.Descriptor; }
19526 }
19527
19528 public override BarResponse DefaultInstanceForType {
19529 get { return global::Google.ProtocolBuffers.TestProtos.BarResponse.DefaultInstance; }
19530 }
19531
19532 public override BarResponse BuildPartial() {
19533 if (result == null) {
19534 throw new global::System.InvalidOperationException("build() has already been called on this Builder");
19535 }
19536 BarResponse returnMe = result;
19537 result = null;
19538 return returnMe;
19539 }
19540
19541 public override Builder MergeFrom(pb::IMessage other) {
19542 if (other is BarResponse) {
19543 return MergeFrom((BarResponse) other);
19544 } else {
19545 base.MergeFrom(other);
19546 return this;
19547 }
19548 }
19549
19550 public override Builder MergeFrom(BarResponse other) {
19551 if (other == global::Google.ProtocolBuffers.TestProtos.BarResponse.DefaultInstance) return this;
19552 this.MergeUnknownFields(other.UnknownFields);
19553 return this;
19554 }
19555
csharptest17699c22011-06-03 21:57:15 -050019556 public override Builder MergeFrom(pb::ICodedInputStream input) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019557 return MergeFrom(input, pb::ExtensionRegistry.Empty);
19558 }
19559
csharptest17699c22011-06-03 21:57:15 -050019560 public override Builder MergeFrom(pb::ICodedInputStream input, pb::ExtensionRegistry extensionRegistry) {
Jon Skeet82bb0f12011-04-03 20:17:12 +010019561 pb::UnknownFieldSet.Builder unknownFields = null;
csharptest123e5342011-06-03 14:15:21 -050019562 uint tag;
19563 string field_name;
19564 while (input.ReadTag(out tag, out field_name)) {
csharptest920b09a2011-06-08 20:13:29 -050019565 if(tag == 0 && field_name != null) {
19566 int field_ordinal = global::System.Array.BinarySearch(_barResponseFieldNames, field_name, global::System.StringComparer.Ordinal);
19567 if(field_ordinal >= 0)
19568 tag = _barResponseFieldTags[field_ordinal];
19569 else {
19570 if (unknownFields == null) {
19571 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
19572 }
19573 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
19574 continue;
19575 }
19576 }
Jon Skeet82bb0f12011-04-03 20:17:12 +010019577 switch (tag) {
19578 case 0: {
csharptest99284412011-06-03 14:51:06 -050019579 throw pb::InvalidProtocolBufferException.InvalidTag();
Jon Skeet82bb0f12011-04-03 20:17:12 +010019580 }
19581 default: {
19582 if (pb::WireFormat.IsEndGroupTag(tag)) {
19583 if (unknownFields != null) {
19584 this.UnknownFields = unknownFields.Build();
19585 }
19586 return this;
19587 }
19588 if (unknownFields == null) {
19589 unknownFields = pb::UnknownFieldSet.CreateBuilder(this.UnknownFields);
19590 }
csharptestd2af9e92011-06-03 21:35:02 -050019591 ParseUnknownField(input, unknownFields, extensionRegistry, tag, field_name);
Jon Skeet82bb0f12011-04-03 20:17:12 +010019592 break;
19593 }
19594 }
19595 }
csharptest123e5342011-06-03 14:15:21 -050019596
19597 if (unknownFields != null) {
19598 this.UnknownFields = unknownFields.Build();
19599 }
19600 return this;
Jon Skeet82bb0f12011-04-03 20:17:12 +010019601 }
19602
19603 }
19604 static BarResponse() {
19605 object.ReferenceEquals(global::Google.ProtocolBuffers.TestProtos.UnitTestProtoFile.Descriptor, null);
19606 }
19607 }
19608
19609 #endregion
19610
19611 #region Services
csharptestf1816be2011-05-19 12:01:16 -050019612 /*
19613 * Service generation is now disabled by default, use the following option to enable:
19614 * option (google.protobuf.csharp_file_options).service_generator_type = GENERIC;
19615 */
Jon Skeet82bb0f12011-04-03 20:17:12 +010019616 #endregion
19617
19618}