1 /* 2 * Copyright 2020 Google LLC 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * https://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 // Generated by the protocol buffer compiler. DO NOT EDIT! 17 // source: google/cloud/dataproc/v1/jobs.proto 18 19 package com.google.cloud.dataproc.v1; 20 21 /** 22 * 23 * 24 * <pre> 25 * A request to list jobs in a project. 26 * </pre> 27 * 28 * Protobuf type {@code google.cloud.dataproc.v1.ListJobsRequest} 29 */ 30 public final class ListJobsRequest extends com.google.protobuf.GeneratedMessageV3 31 implements 32 // @@protoc_insertion_point(message_implements:google.cloud.dataproc.v1.ListJobsRequest) 33 ListJobsRequestOrBuilder { 34 private static final long serialVersionUID = 0L; 35 // Use ListJobsRequest.newBuilder() to construct. ListJobsRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)36 private ListJobsRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { 37 super(builder); 38 } 39 ListJobsRequest()40 private ListJobsRequest() { 41 projectId_ = ""; 42 region_ = ""; 43 pageToken_ = ""; 44 clusterName_ = ""; 45 jobStateMatcher_ = 0; 46 filter_ = ""; 47 } 48 49 @java.lang.Override 50 @SuppressWarnings({"unused"}) newInstance(UnusedPrivateParameter unused)51 protected java.lang.Object newInstance(UnusedPrivateParameter unused) { 52 return new ListJobsRequest(); 53 } 54 55 @java.lang.Override getUnknownFields()56 public final com.google.protobuf.UnknownFieldSet getUnknownFields() { 57 return this.unknownFields; 58 } 59 getDescriptor()60 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 61 return com.google.cloud.dataproc.v1.JobsProto 62 .internal_static_google_cloud_dataproc_v1_ListJobsRequest_descriptor; 63 } 64 65 @java.lang.Override 66 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()67 internalGetFieldAccessorTable() { 68 return com.google.cloud.dataproc.v1.JobsProto 69 .internal_static_google_cloud_dataproc_v1_ListJobsRequest_fieldAccessorTable 70 .ensureFieldAccessorsInitialized( 71 com.google.cloud.dataproc.v1.ListJobsRequest.class, 72 com.google.cloud.dataproc.v1.ListJobsRequest.Builder.class); 73 } 74 75 /** 76 * 77 * 78 * <pre> 79 * A matcher that specifies categories of job states. 80 * </pre> 81 * 82 * Protobuf enum {@code google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher} 83 */ 84 public enum JobStateMatcher implements com.google.protobuf.ProtocolMessageEnum { 85 /** 86 * 87 * 88 * <pre> 89 * Match all jobs, regardless of state. 90 * </pre> 91 * 92 * <code>ALL = 0;</code> 93 */ 94 ALL(0), 95 /** 96 * 97 * 98 * <pre> 99 * Only match jobs in non-terminal states: PENDING, RUNNING, or 100 * CANCEL_PENDING. 101 * </pre> 102 * 103 * <code>ACTIVE = 1;</code> 104 */ 105 ACTIVE(1), 106 /** 107 * 108 * 109 * <pre> 110 * Only match jobs in terminal states: CANCELLED, DONE, or ERROR. 111 * </pre> 112 * 113 * <code>NON_ACTIVE = 2;</code> 114 */ 115 NON_ACTIVE(2), 116 UNRECOGNIZED(-1), 117 ; 118 119 /** 120 * 121 * 122 * <pre> 123 * Match all jobs, regardless of state. 124 * </pre> 125 * 126 * <code>ALL = 0;</code> 127 */ 128 public static final int ALL_VALUE = 0; 129 /** 130 * 131 * 132 * <pre> 133 * Only match jobs in non-terminal states: PENDING, RUNNING, or 134 * CANCEL_PENDING. 135 * </pre> 136 * 137 * <code>ACTIVE = 1;</code> 138 */ 139 public static final int ACTIVE_VALUE = 1; 140 /** 141 * 142 * 143 * <pre> 144 * Only match jobs in terminal states: CANCELLED, DONE, or ERROR. 145 * </pre> 146 * 147 * <code>NON_ACTIVE = 2;</code> 148 */ 149 public static final int NON_ACTIVE_VALUE = 2; 150 getNumber()151 public final int getNumber() { 152 if (this == UNRECOGNIZED) { 153 throw new java.lang.IllegalArgumentException( 154 "Can't get the number of an unknown enum value."); 155 } 156 return value; 157 } 158 159 /** 160 * @param value The numeric wire value of the corresponding enum entry. 161 * @return The enum associated with the given numeric wire value. 162 * @deprecated Use {@link #forNumber(int)} instead. 163 */ 164 @java.lang.Deprecated valueOf(int value)165 public static JobStateMatcher valueOf(int value) { 166 return forNumber(value); 167 } 168 169 /** 170 * @param value The numeric wire value of the corresponding enum entry. 171 * @return The enum associated with the given numeric wire value. 172 */ forNumber(int value)173 public static JobStateMatcher forNumber(int value) { 174 switch (value) { 175 case 0: 176 return ALL; 177 case 1: 178 return ACTIVE; 179 case 2: 180 return NON_ACTIVE; 181 default: 182 return null; 183 } 184 } 185 internalGetValueMap()186 public static com.google.protobuf.Internal.EnumLiteMap<JobStateMatcher> internalGetValueMap() { 187 return internalValueMap; 188 } 189 190 private static final com.google.protobuf.Internal.EnumLiteMap<JobStateMatcher> 191 internalValueMap = 192 new com.google.protobuf.Internal.EnumLiteMap<JobStateMatcher>() { 193 public JobStateMatcher findValueByNumber(int number) { 194 return JobStateMatcher.forNumber(number); 195 } 196 }; 197 getValueDescriptor()198 public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { 199 if (this == UNRECOGNIZED) { 200 throw new java.lang.IllegalStateException( 201 "Can't get the descriptor of an unrecognized enum value."); 202 } 203 return getDescriptor().getValues().get(ordinal()); 204 } 205 getDescriptorForType()206 public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { 207 return getDescriptor(); 208 } 209 getDescriptor()210 public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { 211 return com.google.cloud.dataproc.v1.ListJobsRequest.getDescriptor().getEnumTypes().get(0); 212 } 213 214 private static final JobStateMatcher[] VALUES = values(); 215 valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc)216 public static JobStateMatcher valueOf( 217 com.google.protobuf.Descriptors.EnumValueDescriptor desc) { 218 if (desc.getType() != getDescriptor()) { 219 throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); 220 } 221 if (desc.getIndex() == -1) { 222 return UNRECOGNIZED; 223 } 224 return VALUES[desc.getIndex()]; 225 } 226 227 private final int value; 228 JobStateMatcher(int value)229 private JobStateMatcher(int value) { 230 this.value = value; 231 } 232 233 // @@protoc_insertion_point(enum_scope:google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher) 234 } 235 236 public static final int PROJECT_ID_FIELD_NUMBER = 1; 237 238 @SuppressWarnings("serial") 239 private volatile java.lang.Object projectId_ = ""; 240 /** 241 * 242 * 243 * <pre> 244 * Required. The ID of the Google Cloud Platform project that the job 245 * belongs to. 246 * </pre> 247 * 248 * <code>string project_id = 1 [(.google.api.field_behavior) = REQUIRED];</code> 249 * 250 * @return The projectId. 251 */ 252 @java.lang.Override getProjectId()253 public java.lang.String getProjectId() { 254 java.lang.Object ref = projectId_; 255 if (ref instanceof java.lang.String) { 256 return (java.lang.String) ref; 257 } else { 258 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 259 java.lang.String s = bs.toStringUtf8(); 260 projectId_ = s; 261 return s; 262 } 263 } 264 /** 265 * 266 * 267 * <pre> 268 * Required. The ID of the Google Cloud Platform project that the job 269 * belongs to. 270 * </pre> 271 * 272 * <code>string project_id = 1 [(.google.api.field_behavior) = REQUIRED];</code> 273 * 274 * @return The bytes for projectId. 275 */ 276 @java.lang.Override getProjectIdBytes()277 public com.google.protobuf.ByteString getProjectIdBytes() { 278 java.lang.Object ref = projectId_; 279 if (ref instanceof java.lang.String) { 280 com.google.protobuf.ByteString b = 281 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 282 projectId_ = b; 283 return b; 284 } else { 285 return (com.google.protobuf.ByteString) ref; 286 } 287 } 288 289 public static final int REGION_FIELD_NUMBER = 6; 290 291 @SuppressWarnings("serial") 292 private volatile java.lang.Object region_ = ""; 293 /** 294 * 295 * 296 * <pre> 297 * Required. The Dataproc region in which to handle the request. 298 * </pre> 299 * 300 * <code>string region = 6 [(.google.api.field_behavior) = REQUIRED];</code> 301 * 302 * @return The region. 303 */ 304 @java.lang.Override getRegion()305 public java.lang.String getRegion() { 306 java.lang.Object ref = region_; 307 if (ref instanceof java.lang.String) { 308 return (java.lang.String) ref; 309 } else { 310 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 311 java.lang.String s = bs.toStringUtf8(); 312 region_ = s; 313 return s; 314 } 315 } 316 /** 317 * 318 * 319 * <pre> 320 * Required. The Dataproc region in which to handle the request. 321 * </pre> 322 * 323 * <code>string region = 6 [(.google.api.field_behavior) = REQUIRED];</code> 324 * 325 * @return The bytes for region. 326 */ 327 @java.lang.Override getRegionBytes()328 public com.google.protobuf.ByteString getRegionBytes() { 329 java.lang.Object ref = region_; 330 if (ref instanceof java.lang.String) { 331 com.google.protobuf.ByteString b = 332 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 333 region_ = b; 334 return b; 335 } else { 336 return (com.google.protobuf.ByteString) ref; 337 } 338 } 339 340 public static final int PAGE_SIZE_FIELD_NUMBER = 2; 341 private int pageSize_ = 0; 342 /** 343 * 344 * 345 * <pre> 346 * Optional. The number of results to return in each response. 347 * </pre> 348 * 349 * <code>int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL];</code> 350 * 351 * @return The pageSize. 352 */ 353 @java.lang.Override getPageSize()354 public int getPageSize() { 355 return pageSize_; 356 } 357 358 public static final int PAGE_TOKEN_FIELD_NUMBER = 3; 359 360 @SuppressWarnings("serial") 361 private volatile java.lang.Object pageToken_ = ""; 362 /** 363 * 364 * 365 * <pre> 366 * Optional. The page token, returned by a previous call, to request the 367 * next page of results. 368 * </pre> 369 * 370 * <code>string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];</code> 371 * 372 * @return The pageToken. 373 */ 374 @java.lang.Override getPageToken()375 public java.lang.String getPageToken() { 376 java.lang.Object ref = pageToken_; 377 if (ref instanceof java.lang.String) { 378 return (java.lang.String) ref; 379 } else { 380 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 381 java.lang.String s = bs.toStringUtf8(); 382 pageToken_ = s; 383 return s; 384 } 385 } 386 /** 387 * 388 * 389 * <pre> 390 * Optional. The page token, returned by a previous call, to request the 391 * next page of results. 392 * </pre> 393 * 394 * <code>string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];</code> 395 * 396 * @return The bytes for pageToken. 397 */ 398 @java.lang.Override getPageTokenBytes()399 public com.google.protobuf.ByteString getPageTokenBytes() { 400 java.lang.Object ref = pageToken_; 401 if (ref instanceof java.lang.String) { 402 com.google.protobuf.ByteString b = 403 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 404 pageToken_ = b; 405 return b; 406 } else { 407 return (com.google.protobuf.ByteString) ref; 408 } 409 } 410 411 public static final int CLUSTER_NAME_FIELD_NUMBER = 4; 412 413 @SuppressWarnings("serial") 414 private volatile java.lang.Object clusterName_ = ""; 415 /** 416 * 417 * 418 * <pre> 419 * Optional. If set, the returned jobs list includes only jobs that were 420 * submitted to the named cluster. 421 * </pre> 422 * 423 * <code>string cluster_name = 4 [(.google.api.field_behavior) = OPTIONAL];</code> 424 * 425 * @return The clusterName. 426 */ 427 @java.lang.Override getClusterName()428 public java.lang.String getClusterName() { 429 java.lang.Object ref = clusterName_; 430 if (ref instanceof java.lang.String) { 431 return (java.lang.String) ref; 432 } else { 433 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 434 java.lang.String s = bs.toStringUtf8(); 435 clusterName_ = s; 436 return s; 437 } 438 } 439 /** 440 * 441 * 442 * <pre> 443 * Optional. If set, the returned jobs list includes only jobs that were 444 * submitted to the named cluster. 445 * </pre> 446 * 447 * <code>string cluster_name = 4 [(.google.api.field_behavior) = OPTIONAL];</code> 448 * 449 * @return The bytes for clusterName. 450 */ 451 @java.lang.Override getClusterNameBytes()452 public com.google.protobuf.ByteString getClusterNameBytes() { 453 java.lang.Object ref = clusterName_; 454 if (ref instanceof java.lang.String) { 455 com.google.protobuf.ByteString b = 456 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 457 clusterName_ = b; 458 return b; 459 } else { 460 return (com.google.protobuf.ByteString) ref; 461 } 462 } 463 464 public static final int JOB_STATE_MATCHER_FIELD_NUMBER = 5; 465 private int jobStateMatcher_ = 0; 466 /** 467 * 468 * 469 * <pre> 470 * Optional. Specifies enumerated categories of jobs to list. 471 * (default = match ALL jobs). 472 * If `filter` is provided, `jobStateMatcher` will be ignored. 473 * </pre> 474 * 475 * <code> 476 * .google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher job_state_matcher = 5 [(.google.api.field_behavior) = OPTIONAL]; 477 * </code> 478 * 479 * @return The enum numeric value on the wire for jobStateMatcher. 480 */ 481 @java.lang.Override getJobStateMatcherValue()482 public int getJobStateMatcherValue() { 483 return jobStateMatcher_; 484 } 485 /** 486 * 487 * 488 * <pre> 489 * Optional. Specifies enumerated categories of jobs to list. 490 * (default = match ALL jobs). 491 * If `filter` is provided, `jobStateMatcher` will be ignored. 492 * </pre> 493 * 494 * <code> 495 * .google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher job_state_matcher = 5 [(.google.api.field_behavior) = OPTIONAL]; 496 * </code> 497 * 498 * @return The jobStateMatcher. 499 */ 500 @java.lang.Override getJobStateMatcher()501 public com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher getJobStateMatcher() { 502 com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher result = 503 com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher.forNumber(jobStateMatcher_); 504 return result == null 505 ? com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher.UNRECOGNIZED 506 : result; 507 } 508 509 public static final int FILTER_FIELD_NUMBER = 7; 510 511 @SuppressWarnings("serial") 512 private volatile java.lang.Object filter_ = ""; 513 /** 514 * 515 * 516 * <pre> 517 * Optional. A filter constraining the jobs to list. Filters are 518 * case-sensitive and have the following syntax: 519 * [field = value] AND [field [= value]] ... 520 * where **field** is `status.state` or `labels.[KEY]`, and `[KEY]` is a label 521 * key. **value** can be `*` to match all values. 522 * `status.state` can be either `ACTIVE` or `NON_ACTIVE`. 523 * Only the logical `AND` operator is supported; space-separated items are 524 * treated as having an implicit `AND` operator. 525 * Example filter: 526 * status.state = ACTIVE AND labels.env = staging AND labels.starred = * 527 * </pre> 528 * 529 * <code>string filter = 7 [(.google.api.field_behavior) = OPTIONAL];</code> 530 * 531 * @return The filter. 532 */ 533 @java.lang.Override getFilter()534 public java.lang.String getFilter() { 535 java.lang.Object ref = filter_; 536 if (ref instanceof java.lang.String) { 537 return (java.lang.String) ref; 538 } else { 539 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 540 java.lang.String s = bs.toStringUtf8(); 541 filter_ = s; 542 return s; 543 } 544 } 545 /** 546 * 547 * 548 * <pre> 549 * Optional. A filter constraining the jobs to list. Filters are 550 * case-sensitive and have the following syntax: 551 * [field = value] AND [field [= value]] ... 552 * where **field** is `status.state` or `labels.[KEY]`, and `[KEY]` is a label 553 * key. **value** can be `*` to match all values. 554 * `status.state` can be either `ACTIVE` or `NON_ACTIVE`. 555 * Only the logical `AND` operator is supported; space-separated items are 556 * treated as having an implicit `AND` operator. 557 * Example filter: 558 * status.state = ACTIVE AND labels.env = staging AND labels.starred = * 559 * </pre> 560 * 561 * <code>string filter = 7 [(.google.api.field_behavior) = OPTIONAL];</code> 562 * 563 * @return The bytes for filter. 564 */ 565 @java.lang.Override getFilterBytes()566 public com.google.protobuf.ByteString getFilterBytes() { 567 java.lang.Object ref = filter_; 568 if (ref instanceof java.lang.String) { 569 com.google.protobuf.ByteString b = 570 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 571 filter_ = b; 572 return b; 573 } else { 574 return (com.google.protobuf.ByteString) ref; 575 } 576 } 577 578 private byte memoizedIsInitialized = -1; 579 580 @java.lang.Override isInitialized()581 public final boolean isInitialized() { 582 byte isInitialized = memoizedIsInitialized; 583 if (isInitialized == 1) return true; 584 if (isInitialized == 0) return false; 585 586 memoizedIsInitialized = 1; 587 return true; 588 } 589 590 @java.lang.Override writeTo(com.google.protobuf.CodedOutputStream output)591 public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { 592 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { 593 com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); 594 } 595 if (pageSize_ != 0) { 596 output.writeInt32(2, pageSize_); 597 } 598 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { 599 com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); 600 } 601 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(clusterName_)) { 602 com.google.protobuf.GeneratedMessageV3.writeString(output, 4, clusterName_); 603 } 604 if (jobStateMatcher_ 605 != com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher.ALL.getNumber()) { 606 output.writeEnum(5, jobStateMatcher_); 607 } 608 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(region_)) { 609 com.google.protobuf.GeneratedMessageV3.writeString(output, 6, region_); 610 } 611 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { 612 com.google.protobuf.GeneratedMessageV3.writeString(output, 7, filter_); 613 } 614 getUnknownFields().writeTo(output); 615 } 616 617 @java.lang.Override getSerializedSize()618 public int getSerializedSize() { 619 int size = memoizedSize; 620 if (size != -1) return size; 621 622 size = 0; 623 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { 624 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); 625 } 626 if (pageSize_ != 0) { 627 size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); 628 } 629 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { 630 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); 631 } 632 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(clusterName_)) { 633 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, clusterName_); 634 } 635 if (jobStateMatcher_ 636 != com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher.ALL.getNumber()) { 637 size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, jobStateMatcher_); 638 } 639 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(region_)) { 640 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, region_); 641 } 642 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { 643 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, filter_); 644 } 645 size += getUnknownFields().getSerializedSize(); 646 memoizedSize = size; 647 return size; 648 } 649 650 @java.lang.Override equals(final java.lang.Object obj)651 public boolean equals(final java.lang.Object obj) { 652 if (obj == this) { 653 return true; 654 } 655 if (!(obj instanceof com.google.cloud.dataproc.v1.ListJobsRequest)) { 656 return super.equals(obj); 657 } 658 com.google.cloud.dataproc.v1.ListJobsRequest other = 659 (com.google.cloud.dataproc.v1.ListJobsRequest) obj; 660 661 if (!getProjectId().equals(other.getProjectId())) return false; 662 if (!getRegion().equals(other.getRegion())) return false; 663 if (getPageSize() != other.getPageSize()) return false; 664 if (!getPageToken().equals(other.getPageToken())) return false; 665 if (!getClusterName().equals(other.getClusterName())) return false; 666 if (jobStateMatcher_ != other.jobStateMatcher_) return false; 667 if (!getFilter().equals(other.getFilter())) return false; 668 if (!getUnknownFields().equals(other.getUnknownFields())) return false; 669 return true; 670 } 671 672 @java.lang.Override hashCode()673 public int hashCode() { 674 if (memoizedHashCode != 0) { 675 return memoizedHashCode; 676 } 677 int hash = 41; 678 hash = (19 * hash) + getDescriptor().hashCode(); 679 hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; 680 hash = (53 * hash) + getProjectId().hashCode(); 681 hash = (37 * hash) + REGION_FIELD_NUMBER; 682 hash = (53 * hash) + getRegion().hashCode(); 683 hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; 684 hash = (53 * hash) + getPageSize(); 685 hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; 686 hash = (53 * hash) + getPageToken().hashCode(); 687 hash = (37 * hash) + CLUSTER_NAME_FIELD_NUMBER; 688 hash = (53 * hash) + getClusterName().hashCode(); 689 hash = (37 * hash) + JOB_STATE_MATCHER_FIELD_NUMBER; 690 hash = (53 * hash) + jobStateMatcher_; 691 hash = (37 * hash) + FILTER_FIELD_NUMBER; 692 hash = (53 * hash) + getFilter().hashCode(); 693 hash = (29 * hash) + getUnknownFields().hashCode(); 694 memoizedHashCode = hash; 695 return hash; 696 } 697 parseFrom(java.nio.ByteBuffer data)698 public static com.google.cloud.dataproc.v1.ListJobsRequest parseFrom(java.nio.ByteBuffer data) 699 throws com.google.protobuf.InvalidProtocolBufferException { 700 return PARSER.parseFrom(data); 701 } 702 parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)703 public static com.google.cloud.dataproc.v1.ListJobsRequest parseFrom( 704 java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 705 throws com.google.protobuf.InvalidProtocolBufferException { 706 return PARSER.parseFrom(data, extensionRegistry); 707 } 708 parseFrom( com.google.protobuf.ByteString data)709 public static com.google.cloud.dataproc.v1.ListJobsRequest parseFrom( 710 com.google.protobuf.ByteString data) 711 throws com.google.protobuf.InvalidProtocolBufferException { 712 return PARSER.parseFrom(data); 713 } 714 parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)715 public static com.google.cloud.dataproc.v1.ListJobsRequest parseFrom( 716 com.google.protobuf.ByteString data, 717 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 718 throws com.google.protobuf.InvalidProtocolBufferException { 719 return PARSER.parseFrom(data, extensionRegistry); 720 } 721 parseFrom(byte[] data)722 public static com.google.cloud.dataproc.v1.ListJobsRequest parseFrom(byte[] data) 723 throws com.google.protobuf.InvalidProtocolBufferException { 724 return PARSER.parseFrom(data); 725 } 726 parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)727 public static com.google.cloud.dataproc.v1.ListJobsRequest parseFrom( 728 byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 729 throws com.google.protobuf.InvalidProtocolBufferException { 730 return PARSER.parseFrom(data, extensionRegistry); 731 } 732 parseFrom(java.io.InputStream input)733 public static com.google.cloud.dataproc.v1.ListJobsRequest parseFrom(java.io.InputStream input) 734 throws java.io.IOException { 735 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 736 } 737 parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)738 public static com.google.cloud.dataproc.v1.ListJobsRequest parseFrom( 739 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 740 throws java.io.IOException { 741 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 742 PARSER, input, extensionRegistry); 743 } 744 parseDelimitedFrom( java.io.InputStream input)745 public static com.google.cloud.dataproc.v1.ListJobsRequest parseDelimitedFrom( 746 java.io.InputStream input) throws java.io.IOException { 747 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); 748 } 749 parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)750 public static com.google.cloud.dataproc.v1.ListJobsRequest parseDelimitedFrom( 751 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 752 throws java.io.IOException { 753 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( 754 PARSER, input, extensionRegistry); 755 } 756 parseFrom( com.google.protobuf.CodedInputStream input)757 public static com.google.cloud.dataproc.v1.ListJobsRequest parseFrom( 758 com.google.protobuf.CodedInputStream input) throws java.io.IOException { 759 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 760 } 761 parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)762 public static com.google.cloud.dataproc.v1.ListJobsRequest parseFrom( 763 com.google.protobuf.CodedInputStream input, 764 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 765 throws java.io.IOException { 766 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 767 PARSER, input, extensionRegistry); 768 } 769 770 @java.lang.Override newBuilderForType()771 public Builder newBuilderForType() { 772 return newBuilder(); 773 } 774 newBuilder()775 public static Builder newBuilder() { 776 return DEFAULT_INSTANCE.toBuilder(); 777 } 778 newBuilder(com.google.cloud.dataproc.v1.ListJobsRequest prototype)779 public static Builder newBuilder(com.google.cloud.dataproc.v1.ListJobsRequest prototype) { 780 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); 781 } 782 783 @java.lang.Override toBuilder()784 public Builder toBuilder() { 785 return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); 786 } 787 788 @java.lang.Override newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)789 protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 790 Builder builder = new Builder(parent); 791 return builder; 792 } 793 /** 794 * 795 * 796 * <pre> 797 * A request to list jobs in a project. 798 * </pre> 799 * 800 * Protobuf type {@code google.cloud.dataproc.v1.ListJobsRequest} 801 */ 802 public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> 803 implements 804 // @@protoc_insertion_point(builder_implements:google.cloud.dataproc.v1.ListJobsRequest) 805 com.google.cloud.dataproc.v1.ListJobsRequestOrBuilder { getDescriptor()806 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 807 return com.google.cloud.dataproc.v1.JobsProto 808 .internal_static_google_cloud_dataproc_v1_ListJobsRequest_descriptor; 809 } 810 811 @java.lang.Override 812 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()813 internalGetFieldAccessorTable() { 814 return com.google.cloud.dataproc.v1.JobsProto 815 .internal_static_google_cloud_dataproc_v1_ListJobsRequest_fieldAccessorTable 816 .ensureFieldAccessorsInitialized( 817 com.google.cloud.dataproc.v1.ListJobsRequest.class, 818 com.google.cloud.dataproc.v1.ListJobsRequest.Builder.class); 819 } 820 821 // Construct using com.google.cloud.dataproc.v1.ListJobsRequest.newBuilder() Builder()822 private Builder() {} 823 Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)824 private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 825 super(parent); 826 } 827 828 @java.lang.Override clear()829 public Builder clear() { 830 super.clear(); 831 bitField0_ = 0; 832 projectId_ = ""; 833 region_ = ""; 834 pageSize_ = 0; 835 pageToken_ = ""; 836 clusterName_ = ""; 837 jobStateMatcher_ = 0; 838 filter_ = ""; 839 return this; 840 } 841 842 @java.lang.Override getDescriptorForType()843 public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { 844 return com.google.cloud.dataproc.v1.JobsProto 845 .internal_static_google_cloud_dataproc_v1_ListJobsRequest_descriptor; 846 } 847 848 @java.lang.Override getDefaultInstanceForType()849 public com.google.cloud.dataproc.v1.ListJobsRequest getDefaultInstanceForType() { 850 return com.google.cloud.dataproc.v1.ListJobsRequest.getDefaultInstance(); 851 } 852 853 @java.lang.Override build()854 public com.google.cloud.dataproc.v1.ListJobsRequest build() { 855 com.google.cloud.dataproc.v1.ListJobsRequest result = buildPartial(); 856 if (!result.isInitialized()) { 857 throw newUninitializedMessageException(result); 858 } 859 return result; 860 } 861 862 @java.lang.Override buildPartial()863 public com.google.cloud.dataproc.v1.ListJobsRequest buildPartial() { 864 com.google.cloud.dataproc.v1.ListJobsRequest result = 865 new com.google.cloud.dataproc.v1.ListJobsRequest(this); 866 if (bitField0_ != 0) { 867 buildPartial0(result); 868 } 869 onBuilt(); 870 return result; 871 } 872 buildPartial0(com.google.cloud.dataproc.v1.ListJobsRequest result)873 private void buildPartial0(com.google.cloud.dataproc.v1.ListJobsRequest result) { 874 int from_bitField0_ = bitField0_; 875 if (((from_bitField0_ & 0x00000001) != 0)) { 876 result.projectId_ = projectId_; 877 } 878 if (((from_bitField0_ & 0x00000002) != 0)) { 879 result.region_ = region_; 880 } 881 if (((from_bitField0_ & 0x00000004) != 0)) { 882 result.pageSize_ = pageSize_; 883 } 884 if (((from_bitField0_ & 0x00000008) != 0)) { 885 result.pageToken_ = pageToken_; 886 } 887 if (((from_bitField0_ & 0x00000010) != 0)) { 888 result.clusterName_ = clusterName_; 889 } 890 if (((from_bitField0_ & 0x00000020) != 0)) { 891 result.jobStateMatcher_ = jobStateMatcher_; 892 } 893 if (((from_bitField0_ & 0x00000040) != 0)) { 894 result.filter_ = filter_; 895 } 896 } 897 898 @java.lang.Override clone()899 public Builder clone() { 900 return super.clone(); 901 } 902 903 @java.lang.Override setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)904 public Builder setField( 905 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 906 return super.setField(field, value); 907 } 908 909 @java.lang.Override clearField(com.google.protobuf.Descriptors.FieldDescriptor field)910 public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { 911 return super.clearField(field); 912 } 913 914 @java.lang.Override clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)915 public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { 916 return super.clearOneof(oneof); 917 } 918 919 @java.lang.Override setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)920 public Builder setRepeatedField( 921 com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { 922 return super.setRepeatedField(field, index, value); 923 } 924 925 @java.lang.Override addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)926 public Builder addRepeatedField( 927 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 928 return super.addRepeatedField(field, value); 929 } 930 931 @java.lang.Override mergeFrom(com.google.protobuf.Message other)932 public Builder mergeFrom(com.google.protobuf.Message other) { 933 if (other instanceof com.google.cloud.dataproc.v1.ListJobsRequest) { 934 return mergeFrom((com.google.cloud.dataproc.v1.ListJobsRequest) other); 935 } else { 936 super.mergeFrom(other); 937 return this; 938 } 939 } 940 mergeFrom(com.google.cloud.dataproc.v1.ListJobsRequest other)941 public Builder mergeFrom(com.google.cloud.dataproc.v1.ListJobsRequest other) { 942 if (other == com.google.cloud.dataproc.v1.ListJobsRequest.getDefaultInstance()) return this; 943 if (!other.getProjectId().isEmpty()) { 944 projectId_ = other.projectId_; 945 bitField0_ |= 0x00000001; 946 onChanged(); 947 } 948 if (!other.getRegion().isEmpty()) { 949 region_ = other.region_; 950 bitField0_ |= 0x00000002; 951 onChanged(); 952 } 953 if (other.getPageSize() != 0) { 954 setPageSize(other.getPageSize()); 955 } 956 if (!other.getPageToken().isEmpty()) { 957 pageToken_ = other.pageToken_; 958 bitField0_ |= 0x00000008; 959 onChanged(); 960 } 961 if (!other.getClusterName().isEmpty()) { 962 clusterName_ = other.clusterName_; 963 bitField0_ |= 0x00000010; 964 onChanged(); 965 } 966 if (other.jobStateMatcher_ != 0) { 967 setJobStateMatcherValue(other.getJobStateMatcherValue()); 968 } 969 if (!other.getFilter().isEmpty()) { 970 filter_ = other.filter_; 971 bitField0_ |= 0x00000040; 972 onChanged(); 973 } 974 this.mergeUnknownFields(other.getUnknownFields()); 975 onChanged(); 976 return this; 977 } 978 979 @java.lang.Override isInitialized()980 public final boolean isInitialized() { 981 return true; 982 } 983 984 @java.lang.Override mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)985 public Builder mergeFrom( 986 com.google.protobuf.CodedInputStream input, 987 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 988 throws java.io.IOException { 989 if (extensionRegistry == null) { 990 throw new java.lang.NullPointerException(); 991 } 992 try { 993 boolean done = false; 994 while (!done) { 995 int tag = input.readTag(); 996 switch (tag) { 997 case 0: 998 done = true; 999 break; 1000 case 10: 1001 { 1002 projectId_ = input.readStringRequireUtf8(); 1003 bitField0_ |= 0x00000001; 1004 break; 1005 } // case 10 1006 case 16: 1007 { 1008 pageSize_ = input.readInt32(); 1009 bitField0_ |= 0x00000004; 1010 break; 1011 } // case 16 1012 case 26: 1013 { 1014 pageToken_ = input.readStringRequireUtf8(); 1015 bitField0_ |= 0x00000008; 1016 break; 1017 } // case 26 1018 case 34: 1019 { 1020 clusterName_ = input.readStringRequireUtf8(); 1021 bitField0_ |= 0x00000010; 1022 break; 1023 } // case 34 1024 case 40: 1025 { 1026 jobStateMatcher_ = input.readEnum(); 1027 bitField0_ |= 0x00000020; 1028 break; 1029 } // case 40 1030 case 50: 1031 { 1032 region_ = input.readStringRequireUtf8(); 1033 bitField0_ |= 0x00000002; 1034 break; 1035 } // case 50 1036 case 58: 1037 { 1038 filter_ = input.readStringRequireUtf8(); 1039 bitField0_ |= 0x00000040; 1040 break; 1041 } // case 58 1042 default: 1043 { 1044 if (!super.parseUnknownField(input, extensionRegistry, tag)) { 1045 done = true; // was an endgroup tag 1046 } 1047 break; 1048 } // default: 1049 } // switch (tag) 1050 } // while (!done) 1051 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 1052 throw e.unwrapIOException(); 1053 } finally { 1054 onChanged(); 1055 } // finally 1056 return this; 1057 } 1058 1059 private int bitField0_; 1060 1061 private java.lang.Object projectId_ = ""; 1062 /** 1063 * 1064 * 1065 * <pre> 1066 * Required. The ID of the Google Cloud Platform project that the job 1067 * belongs to. 1068 * </pre> 1069 * 1070 * <code>string project_id = 1 [(.google.api.field_behavior) = REQUIRED];</code> 1071 * 1072 * @return The projectId. 1073 */ getProjectId()1074 public java.lang.String getProjectId() { 1075 java.lang.Object ref = projectId_; 1076 if (!(ref instanceof java.lang.String)) { 1077 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1078 java.lang.String s = bs.toStringUtf8(); 1079 projectId_ = s; 1080 return s; 1081 } else { 1082 return (java.lang.String) ref; 1083 } 1084 } 1085 /** 1086 * 1087 * 1088 * <pre> 1089 * Required. The ID of the Google Cloud Platform project that the job 1090 * belongs to. 1091 * </pre> 1092 * 1093 * <code>string project_id = 1 [(.google.api.field_behavior) = REQUIRED];</code> 1094 * 1095 * @return The bytes for projectId. 1096 */ getProjectIdBytes()1097 public com.google.protobuf.ByteString getProjectIdBytes() { 1098 java.lang.Object ref = projectId_; 1099 if (ref instanceof String) { 1100 com.google.protobuf.ByteString b = 1101 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1102 projectId_ = b; 1103 return b; 1104 } else { 1105 return (com.google.protobuf.ByteString) ref; 1106 } 1107 } 1108 /** 1109 * 1110 * 1111 * <pre> 1112 * Required. The ID of the Google Cloud Platform project that the job 1113 * belongs to. 1114 * </pre> 1115 * 1116 * <code>string project_id = 1 [(.google.api.field_behavior) = REQUIRED];</code> 1117 * 1118 * @param value The projectId to set. 1119 * @return This builder for chaining. 1120 */ setProjectId(java.lang.String value)1121 public Builder setProjectId(java.lang.String value) { 1122 if (value == null) { 1123 throw new NullPointerException(); 1124 } 1125 projectId_ = value; 1126 bitField0_ |= 0x00000001; 1127 onChanged(); 1128 return this; 1129 } 1130 /** 1131 * 1132 * 1133 * <pre> 1134 * Required. The ID of the Google Cloud Platform project that the job 1135 * belongs to. 1136 * </pre> 1137 * 1138 * <code>string project_id = 1 [(.google.api.field_behavior) = REQUIRED];</code> 1139 * 1140 * @return This builder for chaining. 1141 */ clearProjectId()1142 public Builder clearProjectId() { 1143 projectId_ = getDefaultInstance().getProjectId(); 1144 bitField0_ = (bitField0_ & ~0x00000001); 1145 onChanged(); 1146 return this; 1147 } 1148 /** 1149 * 1150 * 1151 * <pre> 1152 * Required. The ID of the Google Cloud Platform project that the job 1153 * belongs to. 1154 * </pre> 1155 * 1156 * <code>string project_id = 1 [(.google.api.field_behavior) = REQUIRED];</code> 1157 * 1158 * @param value The bytes for projectId to set. 1159 * @return This builder for chaining. 1160 */ setProjectIdBytes(com.google.protobuf.ByteString value)1161 public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { 1162 if (value == null) { 1163 throw new NullPointerException(); 1164 } 1165 checkByteStringIsUtf8(value); 1166 projectId_ = value; 1167 bitField0_ |= 0x00000001; 1168 onChanged(); 1169 return this; 1170 } 1171 1172 private java.lang.Object region_ = ""; 1173 /** 1174 * 1175 * 1176 * <pre> 1177 * Required. The Dataproc region in which to handle the request. 1178 * </pre> 1179 * 1180 * <code>string region = 6 [(.google.api.field_behavior) = REQUIRED];</code> 1181 * 1182 * @return The region. 1183 */ getRegion()1184 public java.lang.String getRegion() { 1185 java.lang.Object ref = region_; 1186 if (!(ref instanceof java.lang.String)) { 1187 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1188 java.lang.String s = bs.toStringUtf8(); 1189 region_ = s; 1190 return s; 1191 } else { 1192 return (java.lang.String) ref; 1193 } 1194 } 1195 /** 1196 * 1197 * 1198 * <pre> 1199 * Required. The Dataproc region in which to handle the request. 1200 * </pre> 1201 * 1202 * <code>string region = 6 [(.google.api.field_behavior) = REQUIRED];</code> 1203 * 1204 * @return The bytes for region. 1205 */ getRegionBytes()1206 public com.google.protobuf.ByteString getRegionBytes() { 1207 java.lang.Object ref = region_; 1208 if (ref instanceof String) { 1209 com.google.protobuf.ByteString b = 1210 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1211 region_ = b; 1212 return b; 1213 } else { 1214 return (com.google.protobuf.ByteString) ref; 1215 } 1216 } 1217 /** 1218 * 1219 * 1220 * <pre> 1221 * Required. The Dataproc region in which to handle the request. 1222 * </pre> 1223 * 1224 * <code>string region = 6 [(.google.api.field_behavior) = REQUIRED];</code> 1225 * 1226 * @param value The region to set. 1227 * @return This builder for chaining. 1228 */ setRegion(java.lang.String value)1229 public Builder setRegion(java.lang.String value) { 1230 if (value == null) { 1231 throw new NullPointerException(); 1232 } 1233 region_ = value; 1234 bitField0_ |= 0x00000002; 1235 onChanged(); 1236 return this; 1237 } 1238 /** 1239 * 1240 * 1241 * <pre> 1242 * Required. The Dataproc region in which to handle the request. 1243 * </pre> 1244 * 1245 * <code>string region = 6 [(.google.api.field_behavior) = REQUIRED];</code> 1246 * 1247 * @return This builder for chaining. 1248 */ clearRegion()1249 public Builder clearRegion() { 1250 region_ = getDefaultInstance().getRegion(); 1251 bitField0_ = (bitField0_ & ~0x00000002); 1252 onChanged(); 1253 return this; 1254 } 1255 /** 1256 * 1257 * 1258 * <pre> 1259 * Required. The Dataproc region in which to handle the request. 1260 * </pre> 1261 * 1262 * <code>string region = 6 [(.google.api.field_behavior) = REQUIRED];</code> 1263 * 1264 * @param value The bytes for region to set. 1265 * @return This builder for chaining. 1266 */ setRegionBytes(com.google.protobuf.ByteString value)1267 public Builder setRegionBytes(com.google.protobuf.ByteString value) { 1268 if (value == null) { 1269 throw new NullPointerException(); 1270 } 1271 checkByteStringIsUtf8(value); 1272 region_ = value; 1273 bitField0_ |= 0x00000002; 1274 onChanged(); 1275 return this; 1276 } 1277 1278 private int pageSize_; 1279 /** 1280 * 1281 * 1282 * <pre> 1283 * Optional. The number of results to return in each response. 1284 * </pre> 1285 * 1286 * <code>int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL];</code> 1287 * 1288 * @return The pageSize. 1289 */ 1290 @java.lang.Override getPageSize()1291 public int getPageSize() { 1292 return pageSize_; 1293 } 1294 /** 1295 * 1296 * 1297 * <pre> 1298 * Optional. The number of results to return in each response. 1299 * </pre> 1300 * 1301 * <code>int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL];</code> 1302 * 1303 * @param value The pageSize to set. 1304 * @return This builder for chaining. 1305 */ setPageSize(int value)1306 public Builder setPageSize(int value) { 1307 1308 pageSize_ = value; 1309 bitField0_ |= 0x00000004; 1310 onChanged(); 1311 return this; 1312 } 1313 /** 1314 * 1315 * 1316 * <pre> 1317 * Optional. The number of results to return in each response. 1318 * </pre> 1319 * 1320 * <code>int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL];</code> 1321 * 1322 * @return This builder for chaining. 1323 */ clearPageSize()1324 public Builder clearPageSize() { 1325 bitField0_ = (bitField0_ & ~0x00000004); 1326 pageSize_ = 0; 1327 onChanged(); 1328 return this; 1329 } 1330 1331 private java.lang.Object pageToken_ = ""; 1332 /** 1333 * 1334 * 1335 * <pre> 1336 * Optional. The page token, returned by a previous call, to request the 1337 * next page of results. 1338 * </pre> 1339 * 1340 * <code>string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];</code> 1341 * 1342 * @return The pageToken. 1343 */ getPageToken()1344 public java.lang.String getPageToken() { 1345 java.lang.Object ref = pageToken_; 1346 if (!(ref instanceof java.lang.String)) { 1347 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1348 java.lang.String s = bs.toStringUtf8(); 1349 pageToken_ = s; 1350 return s; 1351 } else { 1352 return (java.lang.String) ref; 1353 } 1354 } 1355 /** 1356 * 1357 * 1358 * <pre> 1359 * Optional. The page token, returned by a previous call, to request the 1360 * next page of results. 1361 * </pre> 1362 * 1363 * <code>string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];</code> 1364 * 1365 * @return The bytes for pageToken. 1366 */ getPageTokenBytes()1367 public com.google.protobuf.ByteString getPageTokenBytes() { 1368 java.lang.Object ref = pageToken_; 1369 if (ref instanceof String) { 1370 com.google.protobuf.ByteString b = 1371 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1372 pageToken_ = b; 1373 return b; 1374 } else { 1375 return (com.google.protobuf.ByteString) ref; 1376 } 1377 } 1378 /** 1379 * 1380 * 1381 * <pre> 1382 * Optional. The page token, returned by a previous call, to request the 1383 * next page of results. 1384 * </pre> 1385 * 1386 * <code>string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];</code> 1387 * 1388 * @param value The pageToken to set. 1389 * @return This builder for chaining. 1390 */ setPageToken(java.lang.String value)1391 public Builder setPageToken(java.lang.String value) { 1392 if (value == null) { 1393 throw new NullPointerException(); 1394 } 1395 pageToken_ = value; 1396 bitField0_ |= 0x00000008; 1397 onChanged(); 1398 return this; 1399 } 1400 /** 1401 * 1402 * 1403 * <pre> 1404 * Optional. The page token, returned by a previous call, to request the 1405 * next page of results. 1406 * </pre> 1407 * 1408 * <code>string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];</code> 1409 * 1410 * @return This builder for chaining. 1411 */ clearPageToken()1412 public Builder clearPageToken() { 1413 pageToken_ = getDefaultInstance().getPageToken(); 1414 bitField0_ = (bitField0_ & ~0x00000008); 1415 onChanged(); 1416 return this; 1417 } 1418 /** 1419 * 1420 * 1421 * <pre> 1422 * Optional. The page token, returned by a previous call, to request the 1423 * next page of results. 1424 * </pre> 1425 * 1426 * <code>string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];</code> 1427 * 1428 * @param value The bytes for pageToken to set. 1429 * @return This builder for chaining. 1430 */ setPageTokenBytes(com.google.protobuf.ByteString value)1431 public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { 1432 if (value == null) { 1433 throw new NullPointerException(); 1434 } 1435 checkByteStringIsUtf8(value); 1436 pageToken_ = value; 1437 bitField0_ |= 0x00000008; 1438 onChanged(); 1439 return this; 1440 } 1441 1442 private java.lang.Object clusterName_ = ""; 1443 /** 1444 * 1445 * 1446 * <pre> 1447 * Optional. If set, the returned jobs list includes only jobs that were 1448 * submitted to the named cluster. 1449 * </pre> 1450 * 1451 * <code>string cluster_name = 4 [(.google.api.field_behavior) = OPTIONAL];</code> 1452 * 1453 * @return The clusterName. 1454 */ getClusterName()1455 public java.lang.String getClusterName() { 1456 java.lang.Object ref = clusterName_; 1457 if (!(ref instanceof java.lang.String)) { 1458 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1459 java.lang.String s = bs.toStringUtf8(); 1460 clusterName_ = s; 1461 return s; 1462 } else { 1463 return (java.lang.String) ref; 1464 } 1465 } 1466 /** 1467 * 1468 * 1469 * <pre> 1470 * Optional. If set, the returned jobs list includes only jobs that were 1471 * submitted to the named cluster. 1472 * </pre> 1473 * 1474 * <code>string cluster_name = 4 [(.google.api.field_behavior) = OPTIONAL];</code> 1475 * 1476 * @return The bytes for clusterName. 1477 */ getClusterNameBytes()1478 public com.google.protobuf.ByteString getClusterNameBytes() { 1479 java.lang.Object ref = clusterName_; 1480 if (ref instanceof String) { 1481 com.google.protobuf.ByteString b = 1482 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1483 clusterName_ = b; 1484 return b; 1485 } else { 1486 return (com.google.protobuf.ByteString) ref; 1487 } 1488 } 1489 /** 1490 * 1491 * 1492 * <pre> 1493 * Optional. If set, the returned jobs list includes only jobs that were 1494 * submitted to the named cluster. 1495 * </pre> 1496 * 1497 * <code>string cluster_name = 4 [(.google.api.field_behavior) = OPTIONAL];</code> 1498 * 1499 * @param value The clusterName to set. 1500 * @return This builder for chaining. 1501 */ setClusterName(java.lang.String value)1502 public Builder setClusterName(java.lang.String value) { 1503 if (value == null) { 1504 throw new NullPointerException(); 1505 } 1506 clusterName_ = value; 1507 bitField0_ |= 0x00000010; 1508 onChanged(); 1509 return this; 1510 } 1511 /** 1512 * 1513 * 1514 * <pre> 1515 * Optional. If set, the returned jobs list includes only jobs that were 1516 * submitted to the named cluster. 1517 * </pre> 1518 * 1519 * <code>string cluster_name = 4 [(.google.api.field_behavior) = OPTIONAL];</code> 1520 * 1521 * @return This builder for chaining. 1522 */ clearClusterName()1523 public Builder clearClusterName() { 1524 clusterName_ = getDefaultInstance().getClusterName(); 1525 bitField0_ = (bitField0_ & ~0x00000010); 1526 onChanged(); 1527 return this; 1528 } 1529 /** 1530 * 1531 * 1532 * <pre> 1533 * Optional. If set, the returned jobs list includes only jobs that were 1534 * submitted to the named cluster. 1535 * </pre> 1536 * 1537 * <code>string cluster_name = 4 [(.google.api.field_behavior) = OPTIONAL];</code> 1538 * 1539 * @param value The bytes for clusterName to set. 1540 * @return This builder for chaining. 1541 */ setClusterNameBytes(com.google.protobuf.ByteString value)1542 public Builder setClusterNameBytes(com.google.protobuf.ByteString value) { 1543 if (value == null) { 1544 throw new NullPointerException(); 1545 } 1546 checkByteStringIsUtf8(value); 1547 clusterName_ = value; 1548 bitField0_ |= 0x00000010; 1549 onChanged(); 1550 return this; 1551 } 1552 1553 private int jobStateMatcher_ = 0; 1554 /** 1555 * 1556 * 1557 * <pre> 1558 * Optional. Specifies enumerated categories of jobs to list. 1559 * (default = match ALL jobs). 1560 * If `filter` is provided, `jobStateMatcher` will be ignored. 1561 * </pre> 1562 * 1563 * <code> 1564 * .google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher job_state_matcher = 5 [(.google.api.field_behavior) = OPTIONAL]; 1565 * </code> 1566 * 1567 * @return The enum numeric value on the wire for jobStateMatcher. 1568 */ 1569 @java.lang.Override getJobStateMatcherValue()1570 public int getJobStateMatcherValue() { 1571 return jobStateMatcher_; 1572 } 1573 /** 1574 * 1575 * 1576 * <pre> 1577 * Optional. Specifies enumerated categories of jobs to list. 1578 * (default = match ALL jobs). 1579 * If `filter` is provided, `jobStateMatcher` will be ignored. 1580 * </pre> 1581 * 1582 * <code> 1583 * .google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher job_state_matcher = 5 [(.google.api.field_behavior) = OPTIONAL]; 1584 * </code> 1585 * 1586 * @param value The enum numeric value on the wire for jobStateMatcher to set. 1587 * @return This builder for chaining. 1588 */ setJobStateMatcherValue(int value)1589 public Builder setJobStateMatcherValue(int value) { 1590 jobStateMatcher_ = value; 1591 bitField0_ |= 0x00000020; 1592 onChanged(); 1593 return this; 1594 } 1595 /** 1596 * 1597 * 1598 * <pre> 1599 * Optional. Specifies enumerated categories of jobs to list. 1600 * (default = match ALL jobs). 1601 * If `filter` is provided, `jobStateMatcher` will be ignored. 1602 * </pre> 1603 * 1604 * <code> 1605 * .google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher job_state_matcher = 5 [(.google.api.field_behavior) = OPTIONAL]; 1606 * </code> 1607 * 1608 * @return The jobStateMatcher. 1609 */ 1610 @java.lang.Override getJobStateMatcher()1611 public com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher getJobStateMatcher() { 1612 com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher result = 1613 com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher.forNumber(jobStateMatcher_); 1614 return result == null 1615 ? com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher.UNRECOGNIZED 1616 : result; 1617 } 1618 /** 1619 * 1620 * 1621 * <pre> 1622 * Optional. Specifies enumerated categories of jobs to list. 1623 * (default = match ALL jobs). 1624 * If `filter` is provided, `jobStateMatcher` will be ignored. 1625 * </pre> 1626 * 1627 * <code> 1628 * .google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher job_state_matcher = 5 [(.google.api.field_behavior) = OPTIONAL]; 1629 * </code> 1630 * 1631 * @param value The jobStateMatcher to set. 1632 * @return This builder for chaining. 1633 */ setJobStateMatcher( com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher value)1634 public Builder setJobStateMatcher( 1635 com.google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher value) { 1636 if (value == null) { 1637 throw new NullPointerException(); 1638 } 1639 bitField0_ |= 0x00000020; 1640 jobStateMatcher_ = value.getNumber(); 1641 onChanged(); 1642 return this; 1643 } 1644 /** 1645 * 1646 * 1647 * <pre> 1648 * Optional. Specifies enumerated categories of jobs to list. 1649 * (default = match ALL jobs). 1650 * If `filter` is provided, `jobStateMatcher` will be ignored. 1651 * </pre> 1652 * 1653 * <code> 1654 * .google.cloud.dataproc.v1.ListJobsRequest.JobStateMatcher job_state_matcher = 5 [(.google.api.field_behavior) = OPTIONAL]; 1655 * </code> 1656 * 1657 * @return This builder for chaining. 1658 */ clearJobStateMatcher()1659 public Builder clearJobStateMatcher() { 1660 bitField0_ = (bitField0_ & ~0x00000020); 1661 jobStateMatcher_ = 0; 1662 onChanged(); 1663 return this; 1664 } 1665 1666 private java.lang.Object filter_ = ""; 1667 /** 1668 * 1669 * 1670 * <pre> 1671 * Optional. A filter constraining the jobs to list. Filters are 1672 * case-sensitive and have the following syntax: 1673 * [field = value] AND [field [= value]] ... 1674 * where **field** is `status.state` or `labels.[KEY]`, and `[KEY]` is a label 1675 * key. **value** can be `*` to match all values. 1676 * `status.state` can be either `ACTIVE` or `NON_ACTIVE`. 1677 * Only the logical `AND` operator is supported; space-separated items are 1678 * treated as having an implicit `AND` operator. 1679 * Example filter: 1680 * status.state = ACTIVE AND labels.env = staging AND labels.starred = * 1681 * </pre> 1682 * 1683 * <code>string filter = 7 [(.google.api.field_behavior) = OPTIONAL];</code> 1684 * 1685 * @return The filter. 1686 */ getFilter()1687 public java.lang.String getFilter() { 1688 java.lang.Object ref = filter_; 1689 if (!(ref instanceof java.lang.String)) { 1690 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1691 java.lang.String s = bs.toStringUtf8(); 1692 filter_ = s; 1693 return s; 1694 } else { 1695 return (java.lang.String) ref; 1696 } 1697 } 1698 /** 1699 * 1700 * 1701 * <pre> 1702 * Optional. A filter constraining the jobs to list. Filters are 1703 * case-sensitive and have the following syntax: 1704 * [field = value] AND [field [= value]] ... 1705 * where **field** is `status.state` or `labels.[KEY]`, and `[KEY]` is a label 1706 * key. **value** can be `*` to match all values. 1707 * `status.state` can be either `ACTIVE` or `NON_ACTIVE`. 1708 * Only the logical `AND` operator is supported; space-separated items are 1709 * treated as having an implicit `AND` operator. 1710 * Example filter: 1711 * status.state = ACTIVE AND labels.env = staging AND labels.starred = * 1712 * </pre> 1713 * 1714 * <code>string filter = 7 [(.google.api.field_behavior) = OPTIONAL];</code> 1715 * 1716 * @return The bytes for filter. 1717 */ getFilterBytes()1718 public com.google.protobuf.ByteString getFilterBytes() { 1719 java.lang.Object ref = filter_; 1720 if (ref instanceof String) { 1721 com.google.protobuf.ByteString b = 1722 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1723 filter_ = b; 1724 return b; 1725 } else { 1726 return (com.google.protobuf.ByteString) ref; 1727 } 1728 } 1729 /** 1730 * 1731 * 1732 * <pre> 1733 * Optional. A filter constraining the jobs to list. Filters are 1734 * case-sensitive and have the following syntax: 1735 * [field = value] AND [field [= value]] ... 1736 * where **field** is `status.state` or `labels.[KEY]`, and `[KEY]` is a label 1737 * key. **value** can be `*` to match all values. 1738 * `status.state` can be either `ACTIVE` or `NON_ACTIVE`. 1739 * Only the logical `AND` operator is supported; space-separated items are 1740 * treated as having an implicit `AND` operator. 1741 * Example filter: 1742 * status.state = ACTIVE AND labels.env = staging AND labels.starred = * 1743 * </pre> 1744 * 1745 * <code>string filter = 7 [(.google.api.field_behavior) = OPTIONAL];</code> 1746 * 1747 * @param value The filter to set. 1748 * @return This builder for chaining. 1749 */ setFilter(java.lang.String value)1750 public Builder setFilter(java.lang.String value) { 1751 if (value == null) { 1752 throw new NullPointerException(); 1753 } 1754 filter_ = value; 1755 bitField0_ |= 0x00000040; 1756 onChanged(); 1757 return this; 1758 } 1759 /** 1760 * 1761 * 1762 * <pre> 1763 * Optional. A filter constraining the jobs to list. Filters are 1764 * case-sensitive and have the following syntax: 1765 * [field = value] AND [field [= value]] ... 1766 * where **field** is `status.state` or `labels.[KEY]`, and `[KEY]` is a label 1767 * key. **value** can be `*` to match all values. 1768 * `status.state` can be either `ACTIVE` or `NON_ACTIVE`. 1769 * Only the logical `AND` operator is supported; space-separated items are 1770 * treated as having an implicit `AND` operator. 1771 * Example filter: 1772 * status.state = ACTIVE AND labels.env = staging AND labels.starred = * 1773 * </pre> 1774 * 1775 * <code>string filter = 7 [(.google.api.field_behavior) = OPTIONAL];</code> 1776 * 1777 * @return This builder for chaining. 1778 */ clearFilter()1779 public Builder clearFilter() { 1780 filter_ = getDefaultInstance().getFilter(); 1781 bitField0_ = (bitField0_ & ~0x00000040); 1782 onChanged(); 1783 return this; 1784 } 1785 /** 1786 * 1787 * 1788 * <pre> 1789 * Optional. A filter constraining the jobs to list. Filters are 1790 * case-sensitive and have the following syntax: 1791 * [field = value] AND [field [= value]] ... 1792 * where **field** is `status.state` or `labels.[KEY]`, and `[KEY]` is a label 1793 * key. **value** can be `*` to match all values. 1794 * `status.state` can be either `ACTIVE` or `NON_ACTIVE`. 1795 * Only the logical `AND` operator is supported; space-separated items are 1796 * treated as having an implicit `AND` operator. 1797 * Example filter: 1798 * status.state = ACTIVE AND labels.env = staging AND labels.starred = * 1799 * </pre> 1800 * 1801 * <code>string filter = 7 [(.google.api.field_behavior) = OPTIONAL];</code> 1802 * 1803 * @param value The bytes for filter to set. 1804 * @return This builder for chaining. 1805 */ setFilterBytes(com.google.protobuf.ByteString value)1806 public Builder setFilterBytes(com.google.protobuf.ByteString value) { 1807 if (value == null) { 1808 throw new NullPointerException(); 1809 } 1810 checkByteStringIsUtf8(value); 1811 filter_ = value; 1812 bitField0_ |= 0x00000040; 1813 onChanged(); 1814 return this; 1815 } 1816 1817 @java.lang.Override setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields)1818 public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { 1819 return super.setUnknownFields(unknownFields); 1820 } 1821 1822 @java.lang.Override mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)1823 public final Builder mergeUnknownFields( 1824 final com.google.protobuf.UnknownFieldSet unknownFields) { 1825 return super.mergeUnknownFields(unknownFields); 1826 } 1827 1828 // @@protoc_insertion_point(builder_scope:google.cloud.dataproc.v1.ListJobsRequest) 1829 } 1830 1831 // @@protoc_insertion_point(class_scope:google.cloud.dataproc.v1.ListJobsRequest) 1832 private static final com.google.cloud.dataproc.v1.ListJobsRequest DEFAULT_INSTANCE; 1833 1834 static { 1835 DEFAULT_INSTANCE = new com.google.cloud.dataproc.v1.ListJobsRequest(); 1836 } 1837 getDefaultInstance()1838 public static com.google.cloud.dataproc.v1.ListJobsRequest getDefaultInstance() { 1839 return DEFAULT_INSTANCE; 1840 } 1841 1842 private static final com.google.protobuf.Parser<ListJobsRequest> PARSER = 1843 new com.google.protobuf.AbstractParser<ListJobsRequest>() { 1844 @java.lang.Override 1845 public ListJobsRequest parsePartialFrom( 1846 com.google.protobuf.CodedInputStream input, 1847 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 1848 throws com.google.protobuf.InvalidProtocolBufferException { 1849 Builder builder = newBuilder(); 1850 try { 1851 builder.mergeFrom(input, extensionRegistry); 1852 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 1853 throw e.setUnfinishedMessage(builder.buildPartial()); 1854 } catch (com.google.protobuf.UninitializedMessageException e) { 1855 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); 1856 } catch (java.io.IOException e) { 1857 throw new com.google.protobuf.InvalidProtocolBufferException(e) 1858 .setUnfinishedMessage(builder.buildPartial()); 1859 } 1860 return builder.buildPartial(); 1861 } 1862 }; 1863 parser()1864 public static com.google.protobuf.Parser<ListJobsRequest> parser() { 1865 return PARSER; 1866 } 1867 1868 @java.lang.Override getParserForType()1869 public com.google.protobuf.Parser<ListJobsRequest> getParserForType() { 1870 return PARSER; 1871 } 1872 1873 @java.lang.Override getDefaultInstanceForType()1874 public com.google.cloud.dataproc.v1.ListJobsRequest getDefaultInstanceForType() { 1875 return DEFAULT_INSTANCE; 1876 } 1877 } 1878