@@ -53,68 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
5353 return this .unknownFields ;
5454 }
5555
56- private CreateOfflineProfileRequest (
57- com .google .protobuf .CodedInputStream input ,
58- com .google .protobuf .ExtensionRegistryLite extensionRegistry )
59- throws com .google .protobuf .InvalidProtocolBufferException {
60- this ();
61- if (extensionRegistry == null ) {
62- throw new java .lang .NullPointerException ();
63- }
64- com .google .protobuf .UnknownFieldSet .Builder unknownFields =
65- com .google .protobuf .UnknownFieldSet .newBuilder ();
66- try {
67- boolean done = false ;
68- while (!done ) {
69- int tag = input .readTag ();
70- switch (tag ) {
71- case 0 :
72- done = true ;
73- break ;
74- case 10 :
75- {
76- java .lang .String s = input .readStringRequireUtf8 ();
77-
78- parent_ = s ;
79- break ;
80- }
81- case 18 :
82- {
83- com .google .devtools .cloudprofiler .v2 .Profile .Builder subBuilder = null ;
84- if (profile_ != null ) {
85- subBuilder = profile_ .toBuilder ();
86- }
87- profile_ =
88- input .readMessage (
89- com .google .devtools .cloudprofiler .v2 .Profile .parser (), extensionRegistry );
90- if (subBuilder != null ) {
91- subBuilder .mergeFrom (profile_ );
92- profile_ = subBuilder .buildPartial ();
93- }
94-
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-
11856 public static final com .google .protobuf .Descriptors .Descriptor getDescriptor () {
11957 return com .google .devtools .cloudprofiler .v2 .ProfilerProto
12058 .internal_static_google_devtools_cloudprofiler_v2_CreateOfflineProfileRequest_descriptor ;
@@ -247,7 +185,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
247185 if (profile_ != null ) {
248186 output .writeMessage (2 , getProfile ());
249187 }
250- unknownFields .writeTo (output );
188+ getUnknownFields () .writeTo (output );
251189 }
252190
253191 @ java .lang .Override
@@ -262,7 +200,7 @@ public int getSerializedSize() {
262200 if (profile_ != null ) {
263201 size += com .google .protobuf .CodedOutputStream .computeMessageSize (2 , getProfile ());
264202 }
265- size += unknownFields .getSerializedSize ();
203+ size += getUnknownFields () .getSerializedSize ();
266204 memoizedSize = size ;
267205 return size ;
268206 }
@@ -283,7 +221,7 @@ public boolean equals(final java.lang.Object obj) {
283221 if (hasProfile ()) {
284222 if (!getProfile ().equals (other .getProfile ())) return false ;
285223 }
286- if (!unknownFields .equals (other .unknownFields )) return false ;
224+ if (!getUnknownFields () .equals (other .getUnknownFields () )) return false ;
287225 return true ;
288226 }
289227
@@ -300,7 +238,7 @@ public int hashCode() {
300238 hash = (37 * hash ) + PROFILE_FIELD_NUMBER ;
301239 hash = (53 * hash ) + getProfile ().hashCode ();
302240 }
303- hash = (29 * hash ) + unknownFields .hashCode ();
241+ hash = (29 * hash ) + getUnknownFields () .hashCode ();
304242 memoizedHashCode = hash ;
305243 return hash ;
306244 }
@@ -431,17 +369,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
431369 }
432370
433371 // Construct using com.google.devtools.cloudprofiler.v2.CreateOfflineProfileRequest.newBuilder()
434- private Builder () {
435- maybeForceBuilderInitialization ();
436- }
372+ private Builder () {}
437373
438374 private Builder (com .google .protobuf .GeneratedMessageV3 .BuilderParent parent ) {
439375 super (parent );
440- maybeForceBuilderInitialization ();
441- }
442-
443- private void maybeForceBuilderInitialization () {
444- if (com .google .protobuf .GeneratedMessageV3 .alwaysUseFieldBuilders ) {}
445376 }
446377
447378 @ java .lang .Override
@@ -548,7 +479,7 @@ public Builder mergeFrom(
548479 if (other .hasProfile ()) {
549480 mergeProfile (other .getProfile ());
550481 }
551- this .mergeUnknownFields (other .unknownFields );
482+ this .mergeUnknownFields (other .getUnknownFields () );
552483 onChanged ();
553484 return this ;
554485 }
@@ -563,19 +494,43 @@ public Builder mergeFrom(
563494 com .google .protobuf .CodedInputStream input ,
564495 com .google .protobuf .ExtensionRegistryLite extensionRegistry )
565496 throws java .io .IOException {
566- com .google .devtools .cloudprofiler .v2 .CreateOfflineProfileRequest parsedMessage = null ;
497+ if (extensionRegistry == null ) {
498+ throw new java .lang .NullPointerException ();
499+ }
567500 try {
568- parsedMessage = PARSER .parsePartialFrom (input , extensionRegistry );
501+ boolean done = false ;
502+ while (!done ) {
503+ int tag = input .readTag ();
504+ switch (tag ) {
505+ case 0 :
506+ done = true ;
507+ break ;
508+ case 10 :
509+ {
510+ parent_ = input .readStringRequireUtf8 ();
511+
512+ break ;
513+ } // case 10
514+ case 18 :
515+ {
516+ input .readMessage (getProfileFieldBuilder ().getBuilder (), extensionRegistry );
517+
518+ break ;
519+ } // case 18
520+ default :
521+ {
522+ if (!super .parseUnknownField (input , extensionRegistry , tag )) {
523+ done = true ; // was an endgroup tag
524+ }
525+ break ;
526+ } // default:
527+ } // switch (tag)
528+ } // while (!done)
569529 } catch (com .google .protobuf .InvalidProtocolBufferException e ) {
570- parsedMessage =
571- (com .google .devtools .cloudprofiler .v2 .CreateOfflineProfileRequest )
572- e .getUnfinishedMessage ();
573530 throw e .unwrapIOException ();
574531 } finally {
575- if (parsedMessage != null ) {
576- mergeFrom (parsedMessage );
577- }
578- }
532+ onChanged ();
533+ } // finally
579534 return this ;
580535 }
581536
@@ -905,7 +860,18 @@ public CreateOfflineProfileRequest parsePartialFrom(
905860 com .google .protobuf .CodedInputStream input ,
906861 com .google .protobuf .ExtensionRegistryLite extensionRegistry )
907862 throws com .google .protobuf .InvalidProtocolBufferException {
908- return new CreateOfflineProfileRequest (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 ();
909875 }
910876 };
911877
0 commit comments