@@ -52,80 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
52
52
return this .unknownFields ;
53
53
}
54
54
55
- private BigQueryConnectionSpec (
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 8 :
74
- {
75
- int rawValue = input .readEnum ();
76
-
77
- connectionType_ = rawValue ;
78
- break ;
79
- }
80
- case 18 :
81
- {
82
- com .google .cloud .datacatalog .v1 .CloudSqlBigQueryConnectionSpec .Builder subBuilder =
83
- null ;
84
- if (connectionSpecCase_ == 2 ) {
85
- subBuilder =
86
- ((com .google .cloud .datacatalog .v1 .CloudSqlBigQueryConnectionSpec )
87
- connectionSpec_ )
88
- .toBuilder ();
89
- }
90
- connectionSpec_ =
91
- input .readMessage (
92
- com .google .cloud .datacatalog .v1 .CloudSqlBigQueryConnectionSpec .parser (),
93
- extensionRegistry );
94
- if (subBuilder != null ) {
95
- subBuilder .mergeFrom (
96
- (com .google .cloud .datacatalog .v1 .CloudSqlBigQueryConnectionSpec )
97
- connectionSpec_ );
98
- connectionSpec_ = subBuilder .buildPartial ();
99
- }
100
- connectionSpecCase_ = 2 ;
101
- break ;
102
- }
103
- case 24 :
104
- {
105
- hasCredential_ = input .readBool ();
106
- break ;
107
- }
108
- default :
109
- {
110
- if (!parseUnknownField (input , unknownFields , extensionRegistry , tag )) {
111
- done = true ;
112
- }
113
- break ;
114
- }
115
- }
116
- }
117
- } catch (com .google .protobuf .InvalidProtocolBufferException e ) {
118
- throw e .setUnfinishedMessage (this );
119
- } catch (com .google .protobuf .UninitializedMessageException e ) {
120
- throw e .asInvalidProtocolBufferException ().setUnfinishedMessage (this );
121
- } catch (java .io .IOException e ) {
122
- throw new com .google .protobuf .InvalidProtocolBufferException (e ).setUnfinishedMessage (this );
123
- } finally {
124
- this .unknownFields = unknownFields .build ();
125
- makeExtensionsImmutable ();
126
- }
127
- }
128
-
129
55
public static final com .google .protobuf .Descriptors .Descriptor getDescriptor () {
130
56
return com .google .cloud .datacatalog .v1 .BigQueryProto
131
57
.internal_static_google_cloud_datacatalog_v1_BigQueryConnectionSpec_descriptor ;
@@ -461,7 +387,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
461
387
if (hasCredential_ != false ) {
462
388
output .writeBool (3 , hasCredential_ );
463
389
}
464
- unknownFields .writeTo (output );
390
+ getUnknownFields () .writeTo (output );
465
391
}
466
392
467
393
@ java .lang .Override
@@ -484,7 +410,7 @@ public int getSerializedSize() {
484
410
if (hasCredential_ != false ) {
485
411
size += com .google .protobuf .CodedOutputStream .computeBoolSize (3 , hasCredential_ );
486
412
}
487
- size += unknownFields .getSerializedSize ();
413
+ size += getUnknownFields () .getSerializedSize ();
488
414
memoizedSize = size ;
489
415
return size ;
490
416
}
@@ -510,7 +436,7 @@ public boolean equals(final java.lang.Object obj) {
510
436
case 0 :
511
437
default :
512
438
}
513
- if (!unknownFields .equals (other .unknownFields )) return false ;
439
+ if (!getUnknownFields () .equals (other .getUnknownFields () )) return false ;
514
440
return true ;
515
441
}
516
442
@@ -533,7 +459,7 @@ public int hashCode() {
533
459
case 0 :
534
460
default :
535
461
}
536
- hash = (29 * hash ) + unknownFields .hashCode ();
462
+ hash = (29 * hash ) + getUnknownFields () .hashCode ();
537
463
memoizedHashCode = hash ;
538
464
return hash ;
539
465
}
@@ -663,24 +589,20 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
663
589
}
664
590
665
591
// Construct using com.google.cloud.datacatalog.v1.BigQueryConnectionSpec.newBuilder()
666
- private Builder () {
667
- maybeForceBuilderInitialization ();
668
- }
592
+ private Builder () {}
669
593
670
594
private Builder (com .google .protobuf .GeneratedMessageV3 .BuilderParent parent ) {
671
595
super (parent );
672
- maybeForceBuilderInitialization ();
673
- }
674
-
675
- private void maybeForceBuilderInitialization () {
676
- if (com .google .protobuf .GeneratedMessageV3 .alwaysUseFieldBuilders ) {}
677
596
}
678
597
679
598
@ java .lang .Override
680
599
public Builder clear () {
681
600
super .clear ();
682
601
connectionType_ = 0 ;
683
602
603
+ if (cloudSqlBuilder_ != null ) {
604
+ cloudSqlBuilder_ .clear ();
605
+ }
684
606
hasCredential_ = false ;
685
607
686
608
connectionSpecCase_ = 0 ;
@@ -789,7 +711,7 @@ public Builder mergeFrom(com.google.cloud.datacatalog.v1.BigQueryConnectionSpec
789
711
break ;
790
712
}
791
713
}
792
- this .mergeUnknownFields (other .unknownFields );
714
+ this .mergeUnknownFields (other .getUnknownFields () );
793
715
onChanged ();
794
716
return this ;
795
717
}
@@ -804,18 +726,49 @@ public Builder mergeFrom(
804
726
com .google .protobuf .CodedInputStream input ,
805
727
com .google .protobuf .ExtensionRegistryLite extensionRegistry )
806
728
throws java .io .IOException {
807
- com .google .cloud .datacatalog .v1 .BigQueryConnectionSpec parsedMessage = null ;
729
+ if (extensionRegistry == null ) {
730
+ throw new java .lang .NullPointerException ();
731
+ }
808
732
try {
809
- parsedMessage = PARSER .parsePartialFrom (input , extensionRegistry );
733
+ boolean done = false ;
734
+ while (!done ) {
735
+ int tag = input .readTag ();
736
+ switch (tag ) {
737
+ case 0 :
738
+ done = true ;
739
+ break ;
740
+ case 8 :
741
+ {
742
+ connectionType_ = input .readEnum ();
743
+
744
+ break ;
745
+ } // case 8
746
+ case 18 :
747
+ {
748
+ input .readMessage (getCloudSqlFieldBuilder ().getBuilder (), extensionRegistry );
749
+ connectionSpecCase_ = 2 ;
750
+ break ;
751
+ } // case 18
752
+ case 24 :
753
+ {
754
+ hasCredential_ = input .readBool ();
755
+
756
+ break ;
757
+ } // case 24
758
+ default :
759
+ {
760
+ if (!super .parseUnknownField (input , extensionRegistry , tag )) {
761
+ done = true ; // was an endgroup tag
762
+ }
763
+ break ;
764
+ } // default:
765
+ } // switch (tag)
766
+ } // while (!done)
810
767
} catch (com .google .protobuf .InvalidProtocolBufferException e ) {
811
- parsedMessage =
812
- (com .google .cloud .datacatalog .v1 .BigQueryConnectionSpec ) e .getUnfinishedMessage ();
813
768
throw e .unwrapIOException ();
814
769
} finally {
815
- if (parsedMessage != null ) {
816
- mergeFrom (parsedMessage );
817
- }
818
- }
770
+ onChanged ();
771
+ } // finally
819
772
return this ;
820
773
}
821
774
@@ -1239,7 +1192,18 @@ public BigQueryConnectionSpec parsePartialFrom(
1239
1192
com .google .protobuf .CodedInputStream input ,
1240
1193
com .google .protobuf .ExtensionRegistryLite extensionRegistry )
1241
1194
throws com .google .protobuf .InvalidProtocolBufferException {
1242
- return new BigQueryConnectionSpec (input , extensionRegistry );
1195
+ Builder builder = newBuilder ();
1196
+ try {
1197
+ builder .mergeFrom (input , extensionRegistry );
1198
+ } catch (com .google .protobuf .InvalidProtocolBufferException e ) {
1199
+ throw e .setUnfinishedMessage (builder .buildPartial ());
1200
+ } catch (com .google .protobuf .UninitializedMessageException e ) {
1201
+ throw e .asInvalidProtocolBufferException ().setUnfinishedMessage (builder .buildPartial ());
1202
+ } catch (java .io .IOException e ) {
1203
+ throw new com .google .protobuf .InvalidProtocolBufferException (e )
1204
+ .setUnfinishedMessage (builder .buildPartial ());
1205
+ }
1206
+ return builder .buildPartial ();
1243
1207
}
1244
1208
};
1245
1209
0 commit comments