@@ -52,69 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
52
52
return this .unknownFields ;
53
53
}
54
54
55
- private ConfigSync (
56
- com .google .protobuf .CodedInputStream input ,
57
- com .google .protobuf .ExtensionRegistryLite extensionRegistry )
58
- throws com .google .protobuf .InvalidProtocolBufferException {
59
- this ();
60
- if (extensionRegistry == null ) {
61
- throw new java .lang .NullPointerException ();
62
- }
63
- com .google .protobuf .UnknownFieldSet .Builder unknownFields =
64
- com .google .protobuf .UnknownFieldSet .newBuilder ();
65
- try {
66
- boolean done = false ;
67
- while (!done ) {
68
- int tag = input .readTag ();
69
- switch (tag ) {
70
- case 0 :
71
- done = true ;
72
- break ;
73
- case 58 :
74
- {
75
- com .google .cloud .gkehub .configmanagement .v1 .GitConfig .Builder subBuilder = null ;
76
- if (git_ != null ) {
77
- subBuilder = git_ .toBuilder ();
78
- }
79
- git_ =
80
- input .readMessage (
81
- com .google .cloud .gkehub .configmanagement .v1 .GitConfig .parser (),
82
- extensionRegistry );
83
- if (subBuilder != null ) {
84
- subBuilder .mergeFrom (git_ );
85
- git_ = subBuilder .buildPartial ();
86
- }
87
-
88
- break ;
89
- }
90
- case 66 :
91
- {
92
- java .lang .String s = input .readStringRequireUtf8 ();
93
-
94
- sourceFormat_ = s ;
95
- break ;
96
- }
97
- default :
98
- {
99
- if (!parseUnknownField (input , unknownFields , extensionRegistry , tag )) {
100
- done = true ;
101
- }
102
- break ;
103
- }
104
- }
105
- }
106
- } catch (com .google .protobuf .InvalidProtocolBufferException e ) {
107
- throw e .setUnfinishedMessage (this );
108
- } catch (com .google .protobuf .UninitializedMessageException e ) {
109
- throw e .asInvalidProtocolBufferException ().setUnfinishedMessage (this );
110
- } catch (java .io .IOException e ) {
111
- throw new com .google .protobuf .InvalidProtocolBufferException (e ).setUnfinishedMessage (this );
112
- } finally {
113
- this .unknownFields = unknownFields .build ();
114
- makeExtensionsImmutable ();
115
- }
116
- }
117
-
118
55
public static final com .google .protobuf .Descriptors .Descriptor getDescriptor () {
119
56
return com .google .cloud .gkehub .configmanagement .v1 .ConfigManagementProto
120
57
.internal_static_google_cloud_gkehub_configmanagement_v1_ConfigSync_descriptor ;
@@ -249,7 +186,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
249
186
if (!com .google .protobuf .GeneratedMessageV3 .isStringEmpty (sourceFormat_ )) {
250
187
com .google .protobuf .GeneratedMessageV3 .writeString (output , 8 , sourceFormat_ );
251
188
}
252
- unknownFields .writeTo (output );
189
+ getUnknownFields () .writeTo (output );
253
190
}
254
191
255
192
@ java .lang .Override
@@ -264,7 +201,7 @@ public int getSerializedSize() {
264
201
if (!com .google .protobuf .GeneratedMessageV3 .isStringEmpty (sourceFormat_ )) {
265
202
size += com .google .protobuf .GeneratedMessageV3 .computeStringSize (8 , sourceFormat_ );
266
203
}
267
- size += unknownFields .getSerializedSize ();
204
+ size += getUnknownFields () .getSerializedSize ();
268
205
memoizedSize = size ;
269
206
return size ;
270
207
}
@@ -285,7 +222,7 @@ public boolean equals(final java.lang.Object obj) {
285
222
if (!getGit ().equals (other .getGit ())) return false ;
286
223
}
287
224
if (!getSourceFormat ().equals (other .getSourceFormat ())) return false ;
288
- if (!unknownFields .equals (other .unknownFields )) return false ;
225
+ if (!getUnknownFields () .equals (other .getUnknownFields () )) return false ;
289
226
return true ;
290
227
}
291
228
@@ -302,7 +239,7 @@ public int hashCode() {
302
239
}
303
240
hash = (37 * hash ) + SOURCE_FORMAT_FIELD_NUMBER ;
304
241
hash = (53 * hash ) + getSourceFormat ().hashCode ();
305
- hash = (29 * hash ) + unknownFields .hashCode ();
242
+ hash = (29 * hash ) + getUnknownFields () .hashCode ();
306
243
memoizedHashCode = hash ;
307
244
return hash ;
308
245
}
@@ -432,17 +369,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
432
369
}
433
370
434
371
// Construct using com.google.cloud.gkehub.configmanagement.v1.ConfigSync.newBuilder()
435
- private Builder () {
436
- maybeForceBuilderInitialization ();
437
- }
372
+ private Builder () {}
438
373
439
374
private Builder (com .google .protobuf .GeneratedMessageV3 .BuilderParent parent ) {
440
375
super (parent );
441
- maybeForceBuilderInitialization ();
442
- }
443
-
444
- private void maybeForceBuilderInitialization () {
445
- if (com .google .protobuf .GeneratedMessageV3 .alwaysUseFieldBuilders ) {}
446
376
}
447
377
448
378
@ java .lang .Override
@@ -546,7 +476,7 @@ public Builder mergeFrom(com.google.cloud.gkehub.configmanagement.v1.ConfigSync
546
476
sourceFormat_ = other .sourceFormat_ ;
547
477
onChanged ();
548
478
}
549
- this .mergeUnknownFields (other .unknownFields );
479
+ this .mergeUnknownFields (other .getUnknownFields () );
550
480
onChanged ();
551
481
return this ;
552
482
}
@@ -561,18 +491,43 @@ public Builder mergeFrom(
561
491
com .google .protobuf .CodedInputStream input ,
562
492
com .google .protobuf .ExtensionRegistryLite extensionRegistry )
563
493
throws java .io .IOException {
564
- com .google .cloud .gkehub .configmanagement .v1 .ConfigSync parsedMessage = null ;
494
+ if (extensionRegistry == null ) {
495
+ throw new java .lang .NullPointerException ();
496
+ }
565
497
try {
566
- parsedMessage = PARSER .parsePartialFrom (input , extensionRegistry );
498
+ boolean done = false ;
499
+ while (!done ) {
500
+ int tag = input .readTag ();
501
+ switch (tag ) {
502
+ case 0 :
503
+ done = true ;
504
+ break ;
505
+ case 58 :
506
+ {
507
+ input .readMessage (getGitFieldBuilder ().getBuilder (), extensionRegistry );
508
+
509
+ break ;
510
+ } // case 58
511
+ case 66 :
512
+ {
513
+ sourceFormat_ = input .readStringRequireUtf8 ();
514
+
515
+ break ;
516
+ } // case 66
517
+ default :
518
+ {
519
+ if (!super .parseUnknownField (input , extensionRegistry , tag )) {
520
+ done = true ; // was an endgroup tag
521
+ }
522
+ break ;
523
+ } // default:
524
+ } // switch (tag)
525
+ } // while (!done)
567
526
} catch (com .google .protobuf .InvalidProtocolBufferException e ) {
568
- parsedMessage =
569
- (com .google .cloud .gkehub .configmanagement .v1 .ConfigSync ) e .getUnfinishedMessage ();
570
527
throw e .unwrapIOException ();
571
528
} finally {
572
- if (parsedMessage != null ) {
573
- mergeFrom (parsedMessage );
574
- }
575
- }
529
+ onChanged ();
530
+ } // finally
576
531
return this ;
577
532
}
578
533
@@ -905,7 +860,18 @@ public ConfigSync parsePartialFrom(
905
860
com .google .protobuf .CodedInputStream input ,
906
861
com .google .protobuf .ExtensionRegistryLite extensionRegistry )
907
862
throws com .google .protobuf .InvalidProtocolBufferException {
908
- return new ConfigSync (input , extensionRegistry );
863
+ Builder builder = newBuilder ();
864
+ try {
865
+ builder .mergeFrom (input , extensionRegistry );
866
+ } catch (com .google .protobuf .InvalidProtocolBufferException e ) {
867
+ throw e .setUnfinishedMessage (builder .buildPartial ());
868
+ } catch (com .google .protobuf .UninitializedMessageException e ) {
869
+ throw e .asInvalidProtocolBufferException ().setUnfinishedMessage (builder .buildPartial ());
870
+ } catch (java .io .IOException e ) {
871
+ throw new com .google .protobuf .InvalidProtocolBufferException (e )
872
+ .setUnfinishedMessage (builder .buildPartial ());
873
+ }
874
+ return builder .buildPartial ();
909
875
}
910
876
};
911
877
0 commit comments