@@ -333,11 +333,12 @@ public com.google.protobuf.ByteString getTableBytes() {
333
333
*
334
334
*
335
335
* <pre>
336
- * When true, use the topic's schema as the columns to write to in BigQuery,
337
- * if it exists.
336
+ * Optional. When true, use the topic's schema as the columns to write to in
337
+ * BigQuery, if it exists. `use_topic_schema` and `use_table_schema` cannot be
338
+ * enabled at the same time.
338
339
* </pre>
339
340
*
340
- * <code>bool use_topic_schema = 2;</code>
341
+ * <code>bool use_topic_schema = 2 [(.google.api.field_behavior) = OPTIONAL] ;</code>
341
342
*
342
343
* @return The useTopicSchema.
343
344
*/
@@ -431,6 +432,26 @@ public com.google.pubsub.v1.BigQueryConfig.State getState() {
431
432
return result == null ? com .google .pubsub .v1 .BigQueryConfig .State .UNRECOGNIZED : result ;
432
433
}
433
434
435
+ public static final int USE_TABLE_SCHEMA_FIELD_NUMBER = 6 ;
436
+ private boolean useTableSchema_ = false ;
437
+ /**
438
+ *
439
+ *
440
+ * <pre>
441
+ * Optional. When true, use the BigQuery table's schema as the columns to
442
+ * write to in BigQuery. `use_table_schema` and `use_topic_schema` cannot be
443
+ * enabled at the same time.
444
+ * </pre>
445
+ *
446
+ * <code>bool use_table_schema = 6 [(.google.api.field_behavior) = OPTIONAL];</code>
447
+ *
448
+ * @return The useTableSchema.
449
+ */
450
+ @ java .lang .Override
451
+ public boolean getUseTableSchema () {
452
+ return useTableSchema_ ;
453
+ }
454
+
434
455
private byte memoizedIsInitialized = -1 ;
435
456
436
457
@ java .lang .Override
@@ -460,6 +481,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
460
481
if (state_ != com .google .pubsub .v1 .BigQueryConfig .State .STATE_UNSPECIFIED .getNumber ()) {
461
482
output .writeEnum (5 , state_ );
462
483
}
484
+ if (useTableSchema_ != false ) {
485
+ output .writeBool (6 , useTableSchema_ );
486
+ }
463
487
getUnknownFields ().writeTo (output );
464
488
}
465
489
@@ -484,6 +508,9 @@ public int getSerializedSize() {
484
508
if (state_ != com .google .pubsub .v1 .BigQueryConfig .State .STATE_UNSPECIFIED .getNumber ()) {
485
509
size += com .google .protobuf .CodedOutputStream .computeEnumSize (5 , state_ );
486
510
}
511
+ if (useTableSchema_ != false ) {
512
+ size += com .google .protobuf .CodedOutputStream .computeBoolSize (6 , useTableSchema_ );
513
+ }
487
514
size += getUnknownFields ().getSerializedSize ();
488
515
memoizedSize = size ;
489
516
return size ;
@@ -504,6 +531,7 @@ public boolean equals(final java.lang.Object obj) {
504
531
if (getWriteMetadata () != other .getWriteMetadata ()) return false ;
505
532
if (getDropUnknownFields () != other .getDropUnknownFields ()) return false ;
506
533
if (state_ != other .state_ ) return false ;
534
+ if (getUseTableSchema () != other .getUseTableSchema ()) return false ;
507
535
if (!getUnknownFields ().equals (other .getUnknownFields ())) return false ;
508
536
return true ;
509
537
}
@@ -525,6 +553,8 @@ public int hashCode() {
525
553
hash = (53 * hash ) + com .google .protobuf .Internal .hashBoolean (getDropUnknownFields ());
526
554
hash = (37 * hash ) + STATE_FIELD_NUMBER ;
527
555
hash = (53 * hash ) + state_ ;
556
+ hash = (37 * hash ) + USE_TABLE_SCHEMA_FIELD_NUMBER ;
557
+ hash = (53 * hash ) + com .google .protobuf .Internal .hashBoolean (getUseTableSchema ());
528
558
hash = (29 * hash ) + getUnknownFields ().hashCode ();
529
559
memoizedHashCode = hash ;
530
560
return hash ;
@@ -668,6 +698,7 @@ public Builder clear() {
668
698
writeMetadata_ = false ;
669
699
dropUnknownFields_ = false ;
670
700
state_ = 0 ;
701
+ useTableSchema_ = false ;
671
702
return this ;
672
703
}
673
704
@@ -718,6 +749,9 @@ private void buildPartial0(com.google.pubsub.v1.BigQueryConfig result) {
718
749
if (((from_bitField0_ & 0x00000010 ) != 0 )) {
719
750
result .state_ = state_ ;
720
751
}
752
+ if (((from_bitField0_ & 0x00000020 ) != 0 )) {
753
+ result .useTableSchema_ = useTableSchema_ ;
754
+ }
721
755
}
722
756
723
757
@ java .lang .Override
@@ -782,6 +816,9 @@ public Builder mergeFrom(com.google.pubsub.v1.BigQueryConfig other) {
782
816
if (other .state_ != 0 ) {
783
817
setStateValue (other .getStateValue ());
784
818
}
819
+ if (other .getUseTableSchema () != false ) {
820
+ setUseTableSchema (other .getUseTableSchema ());
821
+ }
785
822
this .mergeUnknownFields (other .getUnknownFields ());
786
823
onChanged ();
787
824
return this ;
@@ -838,6 +875,12 @@ public Builder mergeFrom(
838
875
bitField0_ |= 0x00000010 ;
839
876
break ;
840
877
} // case 40
878
+ case 48 :
879
+ {
880
+ useTableSchema_ = input .readBool ();
881
+ bitField0_ |= 0x00000020 ;
882
+ break ;
883
+ } // case 48
841
884
default :
842
885
{
843
886
if (!super .parseUnknownField (input , extensionRegistry , tag )) {
@@ -973,11 +1016,12 @@ public Builder setTableBytes(com.google.protobuf.ByteString value) {
973
1016
*
974
1017
*
975
1018
* <pre>
976
- * When true, use the topic's schema as the columns to write to in BigQuery,
977
- * if it exists.
1019
+ * Optional. When true, use the topic's schema as the columns to write to in
1020
+ * BigQuery, if it exists. `use_topic_schema` and `use_table_schema` cannot be
1021
+ * enabled at the same time.
978
1022
* </pre>
979
1023
*
980
- * <code>bool use_topic_schema = 2;</code>
1024
+ * <code>bool use_topic_schema = 2 [(.google.api.field_behavior) = OPTIONAL] ;</code>
981
1025
*
982
1026
* @return The useTopicSchema.
983
1027
*/
@@ -989,11 +1033,12 @@ public boolean getUseTopicSchema() {
989
1033
*
990
1034
*
991
1035
* <pre>
992
- * When true, use the topic's schema as the columns to write to in BigQuery,
993
- * if it exists.
1036
+ * Optional. When true, use the topic's schema as the columns to write to in
1037
+ * BigQuery, if it exists. `use_topic_schema` and `use_table_schema` cannot be
1038
+ * enabled at the same time.
994
1039
* </pre>
995
1040
*
996
- * <code>bool use_topic_schema = 2;</code>
1041
+ * <code>bool use_topic_schema = 2 [(.google.api.field_behavior) = OPTIONAL] ;</code>
997
1042
*
998
1043
* @param value The useTopicSchema to set.
999
1044
* @return This builder for chaining.
@@ -1009,11 +1054,12 @@ public Builder setUseTopicSchema(boolean value) {
1009
1054
*
1010
1055
*
1011
1056
* <pre>
1012
- * When true, use the topic's schema as the columns to write to in BigQuery,
1013
- * if it exists.
1057
+ * Optional. When true, use the topic's schema as the columns to write to in
1058
+ * BigQuery, if it exists. `use_topic_schema` and `use_table_schema` cannot be
1059
+ * enabled at the same time.
1014
1060
* </pre>
1015
1061
*
1016
- * <code>bool use_topic_schema = 2;</code>
1062
+ * <code>bool use_topic_schema = 2 [(.google.api.field_behavior) = OPTIONAL] ;</code>
1017
1063
*
1018
1064
* @return This builder for chaining.
1019
1065
*/
@@ -1259,6 +1305,65 @@ public Builder clearState() {
1259
1305
return this ;
1260
1306
}
1261
1307
1308
+ private boolean useTableSchema_ ;
1309
+ /**
1310
+ *
1311
+ *
1312
+ * <pre>
1313
+ * Optional. When true, use the BigQuery table's schema as the columns to
1314
+ * write to in BigQuery. `use_table_schema` and `use_topic_schema` cannot be
1315
+ * enabled at the same time.
1316
+ * </pre>
1317
+ *
1318
+ * <code>bool use_table_schema = 6 [(.google.api.field_behavior) = OPTIONAL];</code>
1319
+ *
1320
+ * @return The useTableSchema.
1321
+ */
1322
+ @ java .lang .Override
1323
+ public boolean getUseTableSchema () {
1324
+ return useTableSchema_ ;
1325
+ }
1326
+ /**
1327
+ *
1328
+ *
1329
+ * <pre>
1330
+ * Optional. When true, use the BigQuery table's schema as the columns to
1331
+ * write to in BigQuery. `use_table_schema` and `use_topic_schema` cannot be
1332
+ * enabled at the same time.
1333
+ * </pre>
1334
+ *
1335
+ * <code>bool use_table_schema = 6 [(.google.api.field_behavior) = OPTIONAL];</code>
1336
+ *
1337
+ * @param value The useTableSchema to set.
1338
+ * @return This builder for chaining.
1339
+ */
1340
+ public Builder setUseTableSchema (boolean value ) {
1341
+
1342
+ useTableSchema_ = value ;
1343
+ bitField0_ |= 0x00000020 ;
1344
+ onChanged ();
1345
+ return this ;
1346
+ }
1347
+ /**
1348
+ *
1349
+ *
1350
+ * <pre>
1351
+ * Optional. When true, use the BigQuery table's schema as the columns to
1352
+ * write to in BigQuery. `use_table_schema` and `use_topic_schema` cannot be
1353
+ * enabled at the same time.
1354
+ * </pre>
1355
+ *
1356
+ * <code>bool use_table_schema = 6 [(.google.api.field_behavior) = OPTIONAL];</code>
1357
+ *
1358
+ * @return This builder for chaining.
1359
+ */
1360
+ public Builder clearUseTableSchema () {
1361
+ bitField0_ = (bitField0_ & ~0x00000020 );
1362
+ useTableSchema_ = false ;
1363
+ onChanged ();
1364
+ return this ;
1365
+ }
1366
+
1262
1367
@ java .lang .Override
1263
1368
public final Builder setUnknownFields (final com .google .protobuf .UnknownFieldSet unknownFields ) {
1264
1369
return super .setUnknownFields (unknownFields );
0 commit comments