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/talent/v4beta1/tenant.proto 18 19 package com.google.cloud.talent.v4beta1; 20 21 /** 22 * 23 * 24 * <pre> 25 * A Tenant resource represents a tenant in the service. A tenant is a group or 26 * entity that shares common access with specific privileges for resources like 27 * profiles. Customer may create multiple tenants to provide data isolation for 28 * different groups. 29 * </pre> 30 * 31 * Protobuf type {@code google.cloud.talent.v4beta1.Tenant} 32 */ 33 public final class Tenant extends com.google.protobuf.GeneratedMessageV3 34 implements 35 // @@protoc_insertion_point(message_implements:google.cloud.talent.v4beta1.Tenant) 36 TenantOrBuilder { 37 private static final long serialVersionUID = 0L; 38 // Use Tenant.newBuilder() to construct. Tenant(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)39 private Tenant(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { 40 super(builder); 41 } 42 Tenant()43 private Tenant() { 44 name_ = ""; 45 externalId_ = ""; 46 usageType_ = 0; 47 keywordSearchableProfileCustomAttributes_ = com.google.protobuf.LazyStringArrayList.EMPTY; 48 } 49 50 @java.lang.Override 51 @SuppressWarnings({"unused"}) newInstance(UnusedPrivateParameter unused)52 protected java.lang.Object newInstance(UnusedPrivateParameter unused) { 53 return new Tenant(); 54 } 55 56 @java.lang.Override getUnknownFields()57 public final com.google.protobuf.UnknownFieldSet getUnknownFields() { 58 return this.unknownFields; 59 } 60 getDescriptor()61 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 62 return com.google.cloud.talent.v4beta1.TenantResourceProto 63 .internal_static_google_cloud_talent_v4beta1_Tenant_descriptor; 64 } 65 66 @java.lang.Override 67 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()68 internalGetFieldAccessorTable() { 69 return com.google.cloud.talent.v4beta1.TenantResourceProto 70 .internal_static_google_cloud_talent_v4beta1_Tenant_fieldAccessorTable 71 .ensureFieldAccessorsInitialized( 72 com.google.cloud.talent.v4beta1.Tenant.class, 73 com.google.cloud.talent.v4beta1.Tenant.Builder.class); 74 } 75 76 /** 77 * 78 * 79 * <pre> 80 * Enum that represents how user data owned by the tenant is used. 81 * </pre> 82 * 83 * Protobuf enum {@code google.cloud.talent.v4beta1.Tenant.DataUsageType} 84 */ 85 public enum DataUsageType implements com.google.protobuf.ProtocolMessageEnum { 86 /** 87 * 88 * 89 * <pre> 90 * Default value. 91 * </pre> 92 * 93 * <code>DATA_USAGE_TYPE_UNSPECIFIED = 0;</code> 94 */ 95 DATA_USAGE_TYPE_UNSPECIFIED(0), 96 /** 97 * 98 * 99 * <pre> 100 * Data owned by this tenant is used to improve search/recommendation 101 * quality across tenants. 102 * </pre> 103 * 104 * <code>AGGREGATED = 1;</code> 105 */ 106 AGGREGATED(1), 107 /** 108 * 109 * 110 * <pre> 111 * Data owned by this tenant is used to improve search/recommendation 112 * quality for this tenant only. 113 * </pre> 114 * 115 * <code>ISOLATED = 2;</code> 116 */ 117 ISOLATED(2), 118 UNRECOGNIZED(-1), 119 ; 120 121 /** 122 * 123 * 124 * <pre> 125 * Default value. 126 * </pre> 127 * 128 * <code>DATA_USAGE_TYPE_UNSPECIFIED = 0;</code> 129 */ 130 public static final int DATA_USAGE_TYPE_UNSPECIFIED_VALUE = 0; 131 /** 132 * 133 * 134 * <pre> 135 * Data owned by this tenant is used to improve search/recommendation 136 * quality across tenants. 137 * </pre> 138 * 139 * <code>AGGREGATED = 1;</code> 140 */ 141 public static final int AGGREGATED_VALUE = 1; 142 /** 143 * 144 * 145 * <pre> 146 * Data owned by this tenant is used to improve search/recommendation 147 * quality for this tenant only. 148 * </pre> 149 * 150 * <code>ISOLATED = 2;</code> 151 */ 152 public static final int ISOLATED_VALUE = 2; 153 getNumber()154 public final int getNumber() { 155 if (this == UNRECOGNIZED) { 156 throw new java.lang.IllegalArgumentException( 157 "Can't get the number of an unknown enum value."); 158 } 159 return value; 160 } 161 162 /** 163 * @param value The numeric wire value of the corresponding enum entry. 164 * @return The enum associated with the given numeric wire value. 165 * @deprecated Use {@link #forNumber(int)} instead. 166 */ 167 @java.lang.Deprecated valueOf(int value)168 public static DataUsageType valueOf(int value) { 169 return forNumber(value); 170 } 171 172 /** 173 * @param value The numeric wire value of the corresponding enum entry. 174 * @return The enum associated with the given numeric wire value. 175 */ forNumber(int value)176 public static DataUsageType forNumber(int value) { 177 switch (value) { 178 case 0: 179 return DATA_USAGE_TYPE_UNSPECIFIED; 180 case 1: 181 return AGGREGATED; 182 case 2: 183 return ISOLATED; 184 default: 185 return null; 186 } 187 } 188 internalGetValueMap()189 public static com.google.protobuf.Internal.EnumLiteMap<DataUsageType> internalGetValueMap() { 190 return internalValueMap; 191 } 192 193 private static final com.google.protobuf.Internal.EnumLiteMap<DataUsageType> internalValueMap = 194 new com.google.protobuf.Internal.EnumLiteMap<DataUsageType>() { 195 public DataUsageType findValueByNumber(int number) { 196 return DataUsageType.forNumber(number); 197 } 198 }; 199 getValueDescriptor()200 public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { 201 if (this == UNRECOGNIZED) { 202 throw new java.lang.IllegalStateException( 203 "Can't get the descriptor of an unrecognized enum value."); 204 } 205 return getDescriptor().getValues().get(ordinal()); 206 } 207 getDescriptorForType()208 public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { 209 return getDescriptor(); 210 } 211 getDescriptor()212 public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { 213 return com.google.cloud.talent.v4beta1.Tenant.getDescriptor().getEnumTypes().get(0); 214 } 215 216 private static final DataUsageType[] VALUES = values(); 217 valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)218 public static DataUsageType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { 219 if (desc.getType() != getDescriptor()) { 220 throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); 221 } 222 if (desc.getIndex() == -1) { 223 return UNRECOGNIZED; 224 } 225 return VALUES[desc.getIndex()]; 226 } 227 228 private final int value; 229 DataUsageType(int value)230 private DataUsageType(int value) { 231 this.value = value; 232 } 233 234 // @@protoc_insertion_point(enum_scope:google.cloud.talent.v4beta1.Tenant.DataUsageType) 235 } 236 237 public static final int NAME_FIELD_NUMBER = 1; 238 239 @SuppressWarnings("serial") 240 private volatile java.lang.Object name_ = ""; 241 /** 242 * 243 * 244 * <pre> 245 * Required during tenant update. 246 * The resource name for a tenant. This is generated by the service when a 247 * tenant is created. 248 * The format is "projects/{project_id}/tenants/{tenant_id}", for example, 249 * "projects/foo/tenants/bar". 250 * </pre> 251 * 252 * <code>string name = 1;</code> 253 * 254 * @return The name. 255 */ 256 @java.lang.Override getName()257 public java.lang.String getName() { 258 java.lang.Object ref = name_; 259 if (ref instanceof java.lang.String) { 260 return (java.lang.String) ref; 261 } else { 262 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 263 java.lang.String s = bs.toStringUtf8(); 264 name_ = s; 265 return s; 266 } 267 } 268 /** 269 * 270 * 271 * <pre> 272 * Required during tenant update. 273 * The resource name for a tenant. This is generated by the service when a 274 * tenant is created. 275 * The format is "projects/{project_id}/tenants/{tenant_id}", for example, 276 * "projects/foo/tenants/bar". 277 * </pre> 278 * 279 * <code>string name = 1;</code> 280 * 281 * @return The bytes for name. 282 */ 283 @java.lang.Override getNameBytes()284 public com.google.protobuf.ByteString getNameBytes() { 285 java.lang.Object ref = name_; 286 if (ref instanceof java.lang.String) { 287 com.google.protobuf.ByteString b = 288 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 289 name_ = b; 290 return b; 291 } else { 292 return (com.google.protobuf.ByteString) ref; 293 } 294 } 295 296 public static final int EXTERNAL_ID_FIELD_NUMBER = 2; 297 298 @SuppressWarnings("serial") 299 private volatile java.lang.Object externalId_ = ""; 300 /** 301 * 302 * 303 * <pre> 304 * Required. Client side tenant identifier, used to uniquely identify the 305 * tenant. 306 * The maximum number of allowed characters is 255. 307 * </pre> 308 * 309 * <code>string external_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 310 * 311 * @return The externalId. 312 */ 313 @java.lang.Override getExternalId()314 public java.lang.String getExternalId() { 315 java.lang.Object ref = externalId_; 316 if (ref instanceof java.lang.String) { 317 return (java.lang.String) ref; 318 } else { 319 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 320 java.lang.String s = bs.toStringUtf8(); 321 externalId_ = s; 322 return s; 323 } 324 } 325 /** 326 * 327 * 328 * <pre> 329 * Required. Client side tenant identifier, used to uniquely identify the 330 * tenant. 331 * The maximum number of allowed characters is 255. 332 * </pre> 333 * 334 * <code>string external_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 335 * 336 * @return The bytes for externalId. 337 */ 338 @java.lang.Override getExternalIdBytes()339 public com.google.protobuf.ByteString getExternalIdBytes() { 340 java.lang.Object ref = externalId_; 341 if (ref instanceof java.lang.String) { 342 com.google.protobuf.ByteString b = 343 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 344 externalId_ = b; 345 return b; 346 } else { 347 return (com.google.protobuf.ByteString) ref; 348 } 349 } 350 351 public static final int USAGE_TYPE_FIELD_NUMBER = 3; 352 private int usageType_ = 0; 353 /** 354 * 355 * 356 * <pre> 357 * Indicates whether data owned by this tenant may be used to provide product 358 * improvements across other tenants. 359 * Defaults behavior is 360 * [DataUsageType.ISOLATED][google.cloud.talent.v4beta1.Tenant.DataUsageType.ISOLATED] 361 * if it's unset. 362 * </pre> 363 * 364 * <code>.google.cloud.talent.v4beta1.Tenant.DataUsageType usage_type = 3;</code> 365 * 366 * @return The enum numeric value on the wire for usageType. 367 */ 368 @java.lang.Override getUsageTypeValue()369 public int getUsageTypeValue() { 370 return usageType_; 371 } 372 /** 373 * 374 * 375 * <pre> 376 * Indicates whether data owned by this tenant may be used to provide product 377 * improvements across other tenants. 378 * Defaults behavior is 379 * [DataUsageType.ISOLATED][google.cloud.talent.v4beta1.Tenant.DataUsageType.ISOLATED] 380 * if it's unset. 381 * </pre> 382 * 383 * <code>.google.cloud.talent.v4beta1.Tenant.DataUsageType usage_type = 3;</code> 384 * 385 * @return The usageType. 386 */ 387 @java.lang.Override getUsageType()388 public com.google.cloud.talent.v4beta1.Tenant.DataUsageType getUsageType() { 389 com.google.cloud.talent.v4beta1.Tenant.DataUsageType result = 390 com.google.cloud.talent.v4beta1.Tenant.DataUsageType.forNumber(usageType_); 391 return result == null 392 ? com.google.cloud.talent.v4beta1.Tenant.DataUsageType.UNRECOGNIZED 393 : result; 394 } 395 396 public static final int KEYWORD_SEARCHABLE_PROFILE_CUSTOM_ATTRIBUTES_FIELD_NUMBER = 4; 397 398 @SuppressWarnings("serial") 399 private com.google.protobuf.LazyStringList keywordSearchableProfileCustomAttributes_; 400 /** 401 * 402 * 403 * <pre> 404 * A list of keys of filterable 405 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 406 * whose corresponding `string_values` are used in keyword searches. Profiles 407 * with `string_values` under these specified field keys are returned if any 408 * of the values match the search keyword. Custom field values with 409 * parenthesis, brackets and special symbols are not searchable as-is, 410 * and must be surrounded by quotes. 411 * </pre> 412 * 413 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 414 * 415 * @return A list containing the keywordSearchableProfileCustomAttributes. 416 */ getKeywordSearchableProfileCustomAttributesList()417 public com.google.protobuf.ProtocolStringList getKeywordSearchableProfileCustomAttributesList() { 418 return keywordSearchableProfileCustomAttributes_; 419 } 420 /** 421 * 422 * 423 * <pre> 424 * A list of keys of filterable 425 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 426 * whose corresponding `string_values` are used in keyword searches. Profiles 427 * with `string_values` under these specified field keys are returned if any 428 * of the values match the search keyword. Custom field values with 429 * parenthesis, brackets and special symbols are not searchable as-is, 430 * and must be surrounded by quotes. 431 * </pre> 432 * 433 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 434 * 435 * @return The count of keywordSearchableProfileCustomAttributes. 436 */ getKeywordSearchableProfileCustomAttributesCount()437 public int getKeywordSearchableProfileCustomAttributesCount() { 438 return keywordSearchableProfileCustomAttributes_.size(); 439 } 440 /** 441 * 442 * 443 * <pre> 444 * A list of keys of filterable 445 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 446 * whose corresponding `string_values` are used in keyword searches. Profiles 447 * with `string_values` under these specified field keys are returned if any 448 * of the values match the search keyword. Custom field values with 449 * parenthesis, brackets and special symbols are not searchable as-is, 450 * and must be surrounded by quotes. 451 * </pre> 452 * 453 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 454 * 455 * @param index The index of the element to return. 456 * @return The keywordSearchableProfileCustomAttributes at the given index. 457 */ getKeywordSearchableProfileCustomAttributes(int index)458 public java.lang.String getKeywordSearchableProfileCustomAttributes(int index) { 459 return keywordSearchableProfileCustomAttributes_.get(index); 460 } 461 /** 462 * 463 * 464 * <pre> 465 * A list of keys of filterable 466 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 467 * whose corresponding `string_values` are used in keyword searches. Profiles 468 * with `string_values` under these specified field keys are returned if any 469 * of the values match the search keyword. Custom field values with 470 * parenthesis, brackets and special symbols are not searchable as-is, 471 * and must be surrounded by quotes. 472 * </pre> 473 * 474 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 475 * 476 * @param index The index of the value to return. 477 * @return The bytes of the keywordSearchableProfileCustomAttributes at the given index. 478 */ getKeywordSearchableProfileCustomAttributesBytes( int index)479 public com.google.protobuf.ByteString getKeywordSearchableProfileCustomAttributesBytes( 480 int index) { 481 return keywordSearchableProfileCustomAttributes_.getByteString(index); 482 } 483 484 private byte memoizedIsInitialized = -1; 485 486 @java.lang.Override isInitialized()487 public final boolean isInitialized() { 488 byte isInitialized = memoizedIsInitialized; 489 if (isInitialized == 1) return true; 490 if (isInitialized == 0) return false; 491 492 memoizedIsInitialized = 1; 493 return true; 494 } 495 496 @java.lang.Override writeTo(com.google.protobuf.CodedOutputStream output)497 public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { 498 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { 499 com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); 500 } 501 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(externalId_)) { 502 com.google.protobuf.GeneratedMessageV3.writeString(output, 2, externalId_); 503 } 504 if (usageType_ 505 != com.google.cloud.talent.v4beta1.Tenant.DataUsageType.DATA_USAGE_TYPE_UNSPECIFIED 506 .getNumber()) { 507 output.writeEnum(3, usageType_); 508 } 509 for (int i = 0; i < keywordSearchableProfileCustomAttributes_.size(); i++) { 510 com.google.protobuf.GeneratedMessageV3.writeString( 511 output, 4, keywordSearchableProfileCustomAttributes_.getRaw(i)); 512 } 513 getUnknownFields().writeTo(output); 514 } 515 516 @java.lang.Override getSerializedSize()517 public int getSerializedSize() { 518 int size = memoizedSize; 519 if (size != -1) return size; 520 521 size = 0; 522 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { 523 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); 524 } 525 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(externalId_)) { 526 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, externalId_); 527 } 528 if (usageType_ 529 != com.google.cloud.talent.v4beta1.Tenant.DataUsageType.DATA_USAGE_TYPE_UNSPECIFIED 530 .getNumber()) { 531 size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, usageType_); 532 } 533 { 534 int dataSize = 0; 535 for (int i = 0; i < keywordSearchableProfileCustomAttributes_.size(); i++) { 536 dataSize += computeStringSizeNoTag(keywordSearchableProfileCustomAttributes_.getRaw(i)); 537 } 538 size += dataSize; 539 size += 1 * getKeywordSearchableProfileCustomAttributesList().size(); 540 } 541 size += getUnknownFields().getSerializedSize(); 542 memoizedSize = size; 543 return size; 544 } 545 546 @java.lang.Override equals(final java.lang.Object obj)547 public boolean equals(final java.lang.Object obj) { 548 if (obj == this) { 549 return true; 550 } 551 if (!(obj instanceof com.google.cloud.talent.v4beta1.Tenant)) { 552 return super.equals(obj); 553 } 554 com.google.cloud.talent.v4beta1.Tenant other = (com.google.cloud.talent.v4beta1.Tenant) obj; 555 556 if (!getName().equals(other.getName())) return false; 557 if (!getExternalId().equals(other.getExternalId())) return false; 558 if (usageType_ != other.usageType_) return false; 559 if (!getKeywordSearchableProfileCustomAttributesList() 560 .equals(other.getKeywordSearchableProfileCustomAttributesList())) return false; 561 if (!getUnknownFields().equals(other.getUnknownFields())) return false; 562 return true; 563 } 564 565 @java.lang.Override hashCode()566 public int hashCode() { 567 if (memoizedHashCode != 0) { 568 return memoizedHashCode; 569 } 570 int hash = 41; 571 hash = (19 * hash) + getDescriptor().hashCode(); 572 hash = (37 * hash) + NAME_FIELD_NUMBER; 573 hash = (53 * hash) + getName().hashCode(); 574 hash = (37 * hash) + EXTERNAL_ID_FIELD_NUMBER; 575 hash = (53 * hash) + getExternalId().hashCode(); 576 hash = (37 * hash) + USAGE_TYPE_FIELD_NUMBER; 577 hash = (53 * hash) + usageType_; 578 if (getKeywordSearchableProfileCustomAttributesCount() > 0) { 579 hash = (37 * hash) + KEYWORD_SEARCHABLE_PROFILE_CUSTOM_ATTRIBUTES_FIELD_NUMBER; 580 hash = (53 * hash) + getKeywordSearchableProfileCustomAttributesList().hashCode(); 581 } 582 hash = (29 * hash) + getUnknownFields().hashCode(); 583 memoizedHashCode = hash; 584 return hash; 585 } 586 parseFrom(java.nio.ByteBuffer data)587 public static com.google.cloud.talent.v4beta1.Tenant parseFrom(java.nio.ByteBuffer data) 588 throws com.google.protobuf.InvalidProtocolBufferException { 589 return PARSER.parseFrom(data); 590 } 591 parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)592 public static com.google.cloud.talent.v4beta1.Tenant parseFrom( 593 java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 594 throws com.google.protobuf.InvalidProtocolBufferException { 595 return PARSER.parseFrom(data, extensionRegistry); 596 } 597 parseFrom( com.google.protobuf.ByteString data)598 public static com.google.cloud.talent.v4beta1.Tenant parseFrom( 599 com.google.protobuf.ByteString data) 600 throws com.google.protobuf.InvalidProtocolBufferException { 601 return PARSER.parseFrom(data); 602 } 603 parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)604 public static com.google.cloud.talent.v4beta1.Tenant parseFrom( 605 com.google.protobuf.ByteString data, 606 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 607 throws com.google.protobuf.InvalidProtocolBufferException { 608 return PARSER.parseFrom(data, extensionRegistry); 609 } 610 parseFrom(byte[] data)611 public static com.google.cloud.talent.v4beta1.Tenant parseFrom(byte[] data) 612 throws com.google.protobuf.InvalidProtocolBufferException { 613 return PARSER.parseFrom(data); 614 } 615 parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)616 public static com.google.cloud.talent.v4beta1.Tenant parseFrom( 617 byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 618 throws com.google.protobuf.InvalidProtocolBufferException { 619 return PARSER.parseFrom(data, extensionRegistry); 620 } 621 parseFrom(java.io.InputStream input)622 public static com.google.cloud.talent.v4beta1.Tenant parseFrom(java.io.InputStream input) 623 throws java.io.IOException { 624 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 625 } 626 parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)627 public static com.google.cloud.talent.v4beta1.Tenant parseFrom( 628 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 629 throws java.io.IOException { 630 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 631 PARSER, input, extensionRegistry); 632 } 633 parseDelimitedFrom(java.io.InputStream input)634 public static com.google.cloud.talent.v4beta1.Tenant parseDelimitedFrom(java.io.InputStream input) 635 throws java.io.IOException { 636 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); 637 } 638 parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)639 public static com.google.cloud.talent.v4beta1.Tenant parseDelimitedFrom( 640 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 641 throws java.io.IOException { 642 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( 643 PARSER, input, extensionRegistry); 644 } 645 parseFrom( com.google.protobuf.CodedInputStream input)646 public static com.google.cloud.talent.v4beta1.Tenant parseFrom( 647 com.google.protobuf.CodedInputStream input) throws java.io.IOException { 648 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 649 } 650 parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)651 public static com.google.cloud.talent.v4beta1.Tenant parseFrom( 652 com.google.protobuf.CodedInputStream input, 653 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 654 throws java.io.IOException { 655 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 656 PARSER, input, extensionRegistry); 657 } 658 659 @java.lang.Override newBuilderForType()660 public Builder newBuilderForType() { 661 return newBuilder(); 662 } 663 newBuilder()664 public static Builder newBuilder() { 665 return DEFAULT_INSTANCE.toBuilder(); 666 } 667 newBuilder(com.google.cloud.talent.v4beta1.Tenant prototype)668 public static Builder newBuilder(com.google.cloud.talent.v4beta1.Tenant prototype) { 669 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); 670 } 671 672 @java.lang.Override toBuilder()673 public Builder toBuilder() { 674 return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); 675 } 676 677 @java.lang.Override newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)678 protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 679 Builder builder = new Builder(parent); 680 return builder; 681 } 682 /** 683 * 684 * 685 * <pre> 686 * A Tenant resource represents a tenant in the service. A tenant is a group or 687 * entity that shares common access with specific privileges for resources like 688 * profiles. Customer may create multiple tenants to provide data isolation for 689 * different groups. 690 * </pre> 691 * 692 * Protobuf type {@code google.cloud.talent.v4beta1.Tenant} 693 */ 694 public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> 695 implements 696 // @@protoc_insertion_point(builder_implements:google.cloud.talent.v4beta1.Tenant) 697 com.google.cloud.talent.v4beta1.TenantOrBuilder { getDescriptor()698 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 699 return com.google.cloud.talent.v4beta1.TenantResourceProto 700 .internal_static_google_cloud_talent_v4beta1_Tenant_descriptor; 701 } 702 703 @java.lang.Override 704 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()705 internalGetFieldAccessorTable() { 706 return com.google.cloud.talent.v4beta1.TenantResourceProto 707 .internal_static_google_cloud_talent_v4beta1_Tenant_fieldAccessorTable 708 .ensureFieldAccessorsInitialized( 709 com.google.cloud.talent.v4beta1.Tenant.class, 710 com.google.cloud.talent.v4beta1.Tenant.Builder.class); 711 } 712 713 // Construct using com.google.cloud.talent.v4beta1.Tenant.newBuilder() Builder()714 private Builder() {} 715 Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)716 private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 717 super(parent); 718 } 719 720 @java.lang.Override clear()721 public Builder clear() { 722 super.clear(); 723 bitField0_ = 0; 724 name_ = ""; 725 externalId_ = ""; 726 usageType_ = 0; 727 keywordSearchableProfileCustomAttributes_ = com.google.protobuf.LazyStringArrayList.EMPTY; 728 bitField0_ = (bitField0_ & ~0x00000008); 729 return this; 730 } 731 732 @java.lang.Override getDescriptorForType()733 public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { 734 return com.google.cloud.talent.v4beta1.TenantResourceProto 735 .internal_static_google_cloud_talent_v4beta1_Tenant_descriptor; 736 } 737 738 @java.lang.Override getDefaultInstanceForType()739 public com.google.cloud.talent.v4beta1.Tenant getDefaultInstanceForType() { 740 return com.google.cloud.talent.v4beta1.Tenant.getDefaultInstance(); 741 } 742 743 @java.lang.Override build()744 public com.google.cloud.talent.v4beta1.Tenant build() { 745 com.google.cloud.talent.v4beta1.Tenant result = buildPartial(); 746 if (!result.isInitialized()) { 747 throw newUninitializedMessageException(result); 748 } 749 return result; 750 } 751 752 @java.lang.Override buildPartial()753 public com.google.cloud.talent.v4beta1.Tenant buildPartial() { 754 com.google.cloud.talent.v4beta1.Tenant result = 755 new com.google.cloud.talent.v4beta1.Tenant(this); 756 buildPartialRepeatedFields(result); 757 if (bitField0_ != 0) { 758 buildPartial0(result); 759 } 760 onBuilt(); 761 return result; 762 } 763 buildPartialRepeatedFields(com.google.cloud.talent.v4beta1.Tenant result)764 private void buildPartialRepeatedFields(com.google.cloud.talent.v4beta1.Tenant result) { 765 if (((bitField0_ & 0x00000008) != 0)) { 766 keywordSearchableProfileCustomAttributes_ = 767 keywordSearchableProfileCustomAttributes_.getUnmodifiableView(); 768 bitField0_ = (bitField0_ & ~0x00000008); 769 } 770 result.keywordSearchableProfileCustomAttributes_ = keywordSearchableProfileCustomAttributes_; 771 } 772 buildPartial0(com.google.cloud.talent.v4beta1.Tenant result)773 private void buildPartial0(com.google.cloud.talent.v4beta1.Tenant result) { 774 int from_bitField0_ = bitField0_; 775 if (((from_bitField0_ & 0x00000001) != 0)) { 776 result.name_ = name_; 777 } 778 if (((from_bitField0_ & 0x00000002) != 0)) { 779 result.externalId_ = externalId_; 780 } 781 if (((from_bitField0_ & 0x00000004) != 0)) { 782 result.usageType_ = usageType_; 783 } 784 } 785 786 @java.lang.Override clone()787 public Builder clone() { 788 return super.clone(); 789 } 790 791 @java.lang.Override setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)792 public Builder setField( 793 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 794 return super.setField(field, value); 795 } 796 797 @java.lang.Override clearField(com.google.protobuf.Descriptors.FieldDescriptor field)798 public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { 799 return super.clearField(field); 800 } 801 802 @java.lang.Override clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)803 public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { 804 return super.clearOneof(oneof); 805 } 806 807 @java.lang.Override setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)808 public Builder setRepeatedField( 809 com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { 810 return super.setRepeatedField(field, index, value); 811 } 812 813 @java.lang.Override addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)814 public Builder addRepeatedField( 815 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 816 return super.addRepeatedField(field, value); 817 } 818 819 @java.lang.Override mergeFrom(com.google.protobuf.Message other)820 public Builder mergeFrom(com.google.protobuf.Message other) { 821 if (other instanceof com.google.cloud.talent.v4beta1.Tenant) { 822 return mergeFrom((com.google.cloud.talent.v4beta1.Tenant) other); 823 } else { 824 super.mergeFrom(other); 825 return this; 826 } 827 } 828 mergeFrom(com.google.cloud.talent.v4beta1.Tenant other)829 public Builder mergeFrom(com.google.cloud.talent.v4beta1.Tenant other) { 830 if (other == com.google.cloud.talent.v4beta1.Tenant.getDefaultInstance()) return this; 831 if (!other.getName().isEmpty()) { 832 name_ = other.name_; 833 bitField0_ |= 0x00000001; 834 onChanged(); 835 } 836 if (!other.getExternalId().isEmpty()) { 837 externalId_ = other.externalId_; 838 bitField0_ |= 0x00000002; 839 onChanged(); 840 } 841 if (other.usageType_ != 0) { 842 setUsageTypeValue(other.getUsageTypeValue()); 843 } 844 if (!other.keywordSearchableProfileCustomAttributes_.isEmpty()) { 845 if (keywordSearchableProfileCustomAttributes_.isEmpty()) { 846 keywordSearchableProfileCustomAttributes_ = 847 other.keywordSearchableProfileCustomAttributes_; 848 bitField0_ = (bitField0_ & ~0x00000008); 849 } else { 850 ensureKeywordSearchableProfileCustomAttributesIsMutable(); 851 keywordSearchableProfileCustomAttributes_.addAll( 852 other.keywordSearchableProfileCustomAttributes_); 853 } 854 onChanged(); 855 } 856 this.mergeUnknownFields(other.getUnknownFields()); 857 onChanged(); 858 return this; 859 } 860 861 @java.lang.Override isInitialized()862 public final boolean isInitialized() { 863 return true; 864 } 865 866 @java.lang.Override mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)867 public Builder mergeFrom( 868 com.google.protobuf.CodedInputStream input, 869 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 870 throws java.io.IOException { 871 if (extensionRegistry == null) { 872 throw new java.lang.NullPointerException(); 873 } 874 try { 875 boolean done = false; 876 while (!done) { 877 int tag = input.readTag(); 878 switch (tag) { 879 case 0: 880 done = true; 881 break; 882 case 10: 883 { 884 name_ = input.readStringRequireUtf8(); 885 bitField0_ |= 0x00000001; 886 break; 887 } // case 10 888 case 18: 889 { 890 externalId_ = input.readStringRequireUtf8(); 891 bitField0_ |= 0x00000002; 892 break; 893 } // case 18 894 case 24: 895 { 896 usageType_ = input.readEnum(); 897 bitField0_ |= 0x00000004; 898 break; 899 } // case 24 900 case 34: 901 { 902 java.lang.String s = input.readStringRequireUtf8(); 903 ensureKeywordSearchableProfileCustomAttributesIsMutable(); 904 keywordSearchableProfileCustomAttributes_.add(s); 905 break; 906 } // case 34 907 default: 908 { 909 if (!super.parseUnknownField(input, extensionRegistry, tag)) { 910 done = true; // was an endgroup tag 911 } 912 break; 913 } // default: 914 } // switch (tag) 915 } // while (!done) 916 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 917 throw e.unwrapIOException(); 918 } finally { 919 onChanged(); 920 } // finally 921 return this; 922 } 923 924 private int bitField0_; 925 926 private java.lang.Object name_ = ""; 927 /** 928 * 929 * 930 * <pre> 931 * Required during tenant update. 932 * The resource name for a tenant. This is generated by the service when a 933 * tenant is created. 934 * The format is "projects/{project_id}/tenants/{tenant_id}", for example, 935 * "projects/foo/tenants/bar". 936 * </pre> 937 * 938 * <code>string name = 1;</code> 939 * 940 * @return The name. 941 */ getName()942 public java.lang.String getName() { 943 java.lang.Object ref = name_; 944 if (!(ref instanceof java.lang.String)) { 945 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 946 java.lang.String s = bs.toStringUtf8(); 947 name_ = s; 948 return s; 949 } else { 950 return (java.lang.String) ref; 951 } 952 } 953 /** 954 * 955 * 956 * <pre> 957 * Required during tenant update. 958 * The resource name for a tenant. This is generated by the service when a 959 * tenant is created. 960 * The format is "projects/{project_id}/tenants/{tenant_id}", for example, 961 * "projects/foo/tenants/bar". 962 * </pre> 963 * 964 * <code>string name = 1;</code> 965 * 966 * @return The bytes for name. 967 */ getNameBytes()968 public com.google.protobuf.ByteString getNameBytes() { 969 java.lang.Object ref = name_; 970 if (ref instanceof String) { 971 com.google.protobuf.ByteString b = 972 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 973 name_ = b; 974 return b; 975 } else { 976 return (com.google.protobuf.ByteString) ref; 977 } 978 } 979 /** 980 * 981 * 982 * <pre> 983 * Required during tenant update. 984 * The resource name for a tenant. This is generated by the service when a 985 * tenant is created. 986 * The format is "projects/{project_id}/tenants/{tenant_id}", for example, 987 * "projects/foo/tenants/bar". 988 * </pre> 989 * 990 * <code>string name = 1;</code> 991 * 992 * @param value The name to set. 993 * @return This builder for chaining. 994 */ setName(java.lang.String value)995 public Builder setName(java.lang.String value) { 996 if (value == null) { 997 throw new NullPointerException(); 998 } 999 name_ = value; 1000 bitField0_ |= 0x00000001; 1001 onChanged(); 1002 return this; 1003 } 1004 /** 1005 * 1006 * 1007 * <pre> 1008 * Required during tenant update. 1009 * The resource name for a tenant. This is generated by the service when a 1010 * tenant is created. 1011 * The format is "projects/{project_id}/tenants/{tenant_id}", for example, 1012 * "projects/foo/tenants/bar". 1013 * </pre> 1014 * 1015 * <code>string name = 1;</code> 1016 * 1017 * @return This builder for chaining. 1018 */ clearName()1019 public Builder clearName() { 1020 name_ = getDefaultInstance().getName(); 1021 bitField0_ = (bitField0_ & ~0x00000001); 1022 onChanged(); 1023 return this; 1024 } 1025 /** 1026 * 1027 * 1028 * <pre> 1029 * Required during tenant update. 1030 * The resource name for a tenant. This is generated by the service when a 1031 * tenant is created. 1032 * The format is "projects/{project_id}/tenants/{tenant_id}", for example, 1033 * "projects/foo/tenants/bar". 1034 * </pre> 1035 * 1036 * <code>string name = 1;</code> 1037 * 1038 * @param value The bytes for name to set. 1039 * @return This builder for chaining. 1040 */ setNameBytes(com.google.protobuf.ByteString value)1041 public Builder setNameBytes(com.google.protobuf.ByteString value) { 1042 if (value == null) { 1043 throw new NullPointerException(); 1044 } 1045 checkByteStringIsUtf8(value); 1046 name_ = value; 1047 bitField0_ |= 0x00000001; 1048 onChanged(); 1049 return this; 1050 } 1051 1052 private java.lang.Object externalId_ = ""; 1053 /** 1054 * 1055 * 1056 * <pre> 1057 * Required. Client side tenant identifier, used to uniquely identify the 1058 * tenant. 1059 * The maximum number of allowed characters is 255. 1060 * </pre> 1061 * 1062 * <code>string external_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 1063 * 1064 * @return The externalId. 1065 */ getExternalId()1066 public java.lang.String getExternalId() { 1067 java.lang.Object ref = externalId_; 1068 if (!(ref instanceof java.lang.String)) { 1069 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1070 java.lang.String s = bs.toStringUtf8(); 1071 externalId_ = s; 1072 return s; 1073 } else { 1074 return (java.lang.String) ref; 1075 } 1076 } 1077 /** 1078 * 1079 * 1080 * <pre> 1081 * Required. Client side tenant identifier, used to uniquely identify the 1082 * tenant. 1083 * The maximum number of allowed characters is 255. 1084 * </pre> 1085 * 1086 * <code>string external_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 1087 * 1088 * @return The bytes for externalId. 1089 */ getExternalIdBytes()1090 public com.google.protobuf.ByteString getExternalIdBytes() { 1091 java.lang.Object ref = externalId_; 1092 if (ref instanceof String) { 1093 com.google.protobuf.ByteString b = 1094 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1095 externalId_ = b; 1096 return b; 1097 } else { 1098 return (com.google.protobuf.ByteString) ref; 1099 } 1100 } 1101 /** 1102 * 1103 * 1104 * <pre> 1105 * Required. Client side tenant identifier, used to uniquely identify the 1106 * tenant. 1107 * The maximum number of allowed characters is 255. 1108 * </pre> 1109 * 1110 * <code>string external_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 1111 * 1112 * @param value The externalId to set. 1113 * @return This builder for chaining. 1114 */ setExternalId(java.lang.String value)1115 public Builder setExternalId(java.lang.String value) { 1116 if (value == null) { 1117 throw new NullPointerException(); 1118 } 1119 externalId_ = value; 1120 bitField0_ |= 0x00000002; 1121 onChanged(); 1122 return this; 1123 } 1124 /** 1125 * 1126 * 1127 * <pre> 1128 * Required. Client side tenant identifier, used to uniquely identify the 1129 * tenant. 1130 * The maximum number of allowed characters is 255. 1131 * </pre> 1132 * 1133 * <code>string external_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 1134 * 1135 * @return This builder for chaining. 1136 */ clearExternalId()1137 public Builder clearExternalId() { 1138 externalId_ = getDefaultInstance().getExternalId(); 1139 bitField0_ = (bitField0_ & ~0x00000002); 1140 onChanged(); 1141 return this; 1142 } 1143 /** 1144 * 1145 * 1146 * <pre> 1147 * Required. Client side tenant identifier, used to uniquely identify the 1148 * tenant. 1149 * The maximum number of allowed characters is 255. 1150 * </pre> 1151 * 1152 * <code>string external_id = 2 [(.google.api.field_behavior) = REQUIRED];</code> 1153 * 1154 * @param value The bytes for externalId to set. 1155 * @return This builder for chaining. 1156 */ setExternalIdBytes(com.google.protobuf.ByteString value)1157 public Builder setExternalIdBytes(com.google.protobuf.ByteString value) { 1158 if (value == null) { 1159 throw new NullPointerException(); 1160 } 1161 checkByteStringIsUtf8(value); 1162 externalId_ = value; 1163 bitField0_ |= 0x00000002; 1164 onChanged(); 1165 return this; 1166 } 1167 1168 private int usageType_ = 0; 1169 /** 1170 * 1171 * 1172 * <pre> 1173 * Indicates whether data owned by this tenant may be used to provide product 1174 * improvements across other tenants. 1175 * Defaults behavior is 1176 * [DataUsageType.ISOLATED][google.cloud.talent.v4beta1.Tenant.DataUsageType.ISOLATED] 1177 * if it's unset. 1178 * </pre> 1179 * 1180 * <code>.google.cloud.talent.v4beta1.Tenant.DataUsageType usage_type = 3;</code> 1181 * 1182 * @return The enum numeric value on the wire for usageType. 1183 */ 1184 @java.lang.Override getUsageTypeValue()1185 public int getUsageTypeValue() { 1186 return usageType_; 1187 } 1188 /** 1189 * 1190 * 1191 * <pre> 1192 * Indicates whether data owned by this tenant may be used to provide product 1193 * improvements across other tenants. 1194 * Defaults behavior is 1195 * [DataUsageType.ISOLATED][google.cloud.talent.v4beta1.Tenant.DataUsageType.ISOLATED] 1196 * if it's unset. 1197 * </pre> 1198 * 1199 * <code>.google.cloud.talent.v4beta1.Tenant.DataUsageType usage_type = 3;</code> 1200 * 1201 * @param value The enum numeric value on the wire for usageType to set. 1202 * @return This builder for chaining. 1203 */ setUsageTypeValue(int value)1204 public Builder setUsageTypeValue(int value) { 1205 usageType_ = value; 1206 bitField0_ |= 0x00000004; 1207 onChanged(); 1208 return this; 1209 } 1210 /** 1211 * 1212 * 1213 * <pre> 1214 * Indicates whether data owned by this tenant may be used to provide product 1215 * improvements across other tenants. 1216 * Defaults behavior is 1217 * [DataUsageType.ISOLATED][google.cloud.talent.v4beta1.Tenant.DataUsageType.ISOLATED] 1218 * if it's unset. 1219 * </pre> 1220 * 1221 * <code>.google.cloud.talent.v4beta1.Tenant.DataUsageType usage_type = 3;</code> 1222 * 1223 * @return The usageType. 1224 */ 1225 @java.lang.Override getUsageType()1226 public com.google.cloud.talent.v4beta1.Tenant.DataUsageType getUsageType() { 1227 com.google.cloud.talent.v4beta1.Tenant.DataUsageType result = 1228 com.google.cloud.talent.v4beta1.Tenant.DataUsageType.forNumber(usageType_); 1229 return result == null 1230 ? com.google.cloud.talent.v4beta1.Tenant.DataUsageType.UNRECOGNIZED 1231 : result; 1232 } 1233 /** 1234 * 1235 * 1236 * <pre> 1237 * Indicates whether data owned by this tenant may be used to provide product 1238 * improvements across other tenants. 1239 * Defaults behavior is 1240 * [DataUsageType.ISOLATED][google.cloud.talent.v4beta1.Tenant.DataUsageType.ISOLATED] 1241 * if it's unset. 1242 * </pre> 1243 * 1244 * <code>.google.cloud.talent.v4beta1.Tenant.DataUsageType usage_type = 3;</code> 1245 * 1246 * @param value The usageType to set. 1247 * @return This builder for chaining. 1248 */ setUsageType(com.google.cloud.talent.v4beta1.Tenant.DataUsageType value)1249 public Builder setUsageType(com.google.cloud.talent.v4beta1.Tenant.DataUsageType value) { 1250 if (value == null) { 1251 throw new NullPointerException(); 1252 } 1253 bitField0_ |= 0x00000004; 1254 usageType_ = value.getNumber(); 1255 onChanged(); 1256 return this; 1257 } 1258 /** 1259 * 1260 * 1261 * <pre> 1262 * Indicates whether data owned by this tenant may be used to provide product 1263 * improvements across other tenants. 1264 * Defaults behavior is 1265 * [DataUsageType.ISOLATED][google.cloud.talent.v4beta1.Tenant.DataUsageType.ISOLATED] 1266 * if it's unset. 1267 * </pre> 1268 * 1269 * <code>.google.cloud.talent.v4beta1.Tenant.DataUsageType usage_type = 3;</code> 1270 * 1271 * @return This builder for chaining. 1272 */ clearUsageType()1273 public Builder clearUsageType() { 1274 bitField0_ = (bitField0_ & ~0x00000004); 1275 usageType_ = 0; 1276 onChanged(); 1277 return this; 1278 } 1279 1280 private com.google.protobuf.LazyStringList keywordSearchableProfileCustomAttributes_ = 1281 com.google.protobuf.LazyStringArrayList.EMPTY; 1282 ensureKeywordSearchableProfileCustomAttributesIsMutable()1283 private void ensureKeywordSearchableProfileCustomAttributesIsMutable() { 1284 if (!((bitField0_ & 0x00000008) != 0)) { 1285 keywordSearchableProfileCustomAttributes_ = 1286 new com.google.protobuf.LazyStringArrayList(keywordSearchableProfileCustomAttributes_); 1287 bitField0_ |= 0x00000008; 1288 } 1289 } 1290 /** 1291 * 1292 * 1293 * <pre> 1294 * A list of keys of filterable 1295 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 1296 * whose corresponding `string_values` are used in keyword searches. Profiles 1297 * with `string_values` under these specified field keys are returned if any 1298 * of the values match the search keyword. Custom field values with 1299 * parenthesis, brackets and special symbols are not searchable as-is, 1300 * and must be surrounded by quotes. 1301 * </pre> 1302 * 1303 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 1304 * 1305 * @return A list containing the keywordSearchableProfileCustomAttributes. 1306 */ 1307 public com.google.protobuf.ProtocolStringList getKeywordSearchableProfileCustomAttributesList()1308 getKeywordSearchableProfileCustomAttributesList() { 1309 return keywordSearchableProfileCustomAttributes_.getUnmodifiableView(); 1310 } 1311 /** 1312 * 1313 * 1314 * <pre> 1315 * A list of keys of filterable 1316 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 1317 * whose corresponding `string_values` are used in keyword searches. Profiles 1318 * with `string_values` under these specified field keys are returned if any 1319 * of the values match the search keyword. Custom field values with 1320 * parenthesis, brackets and special symbols are not searchable as-is, 1321 * and must be surrounded by quotes. 1322 * </pre> 1323 * 1324 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 1325 * 1326 * @return The count of keywordSearchableProfileCustomAttributes. 1327 */ getKeywordSearchableProfileCustomAttributesCount()1328 public int getKeywordSearchableProfileCustomAttributesCount() { 1329 return keywordSearchableProfileCustomAttributes_.size(); 1330 } 1331 /** 1332 * 1333 * 1334 * <pre> 1335 * A list of keys of filterable 1336 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 1337 * whose corresponding `string_values` are used in keyword searches. Profiles 1338 * with `string_values` under these specified field keys are returned if any 1339 * of the values match the search keyword. Custom field values with 1340 * parenthesis, brackets and special symbols are not searchable as-is, 1341 * and must be surrounded by quotes. 1342 * </pre> 1343 * 1344 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 1345 * 1346 * @param index The index of the element to return. 1347 * @return The keywordSearchableProfileCustomAttributes at the given index. 1348 */ getKeywordSearchableProfileCustomAttributes(int index)1349 public java.lang.String getKeywordSearchableProfileCustomAttributes(int index) { 1350 return keywordSearchableProfileCustomAttributes_.get(index); 1351 } 1352 /** 1353 * 1354 * 1355 * <pre> 1356 * A list of keys of filterable 1357 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 1358 * whose corresponding `string_values` are used in keyword searches. Profiles 1359 * with `string_values` under these specified field keys are returned if any 1360 * of the values match the search keyword. Custom field values with 1361 * parenthesis, brackets and special symbols are not searchable as-is, 1362 * and must be surrounded by quotes. 1363 * </pre> 1364 * 1365 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 1366 * 1367 * @param index The index of the value to return. 1368 * @return The bytes of the keywordSearchableProfileCustomAttributes at the given index. 1369 */ getKeywordSearchableProfileCustomAttributesBytes( int index)1370 public com.google.protobuf.ByteString getKeywordSearchableProfileCustomAttributesBytes( 1371 int index) { 1372 return keywordSearchableProfileCustomAttributes_.getByteString(index); 1373 } 1374 /** 1375 * 1376 * 1377 * <pre> 1378 * A list of keys of filterable 1379 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 1380 * whose corresponding `string_values` are used in keyword searches. Profiles 1381 * with `string_values` under these specified field keys are returned if any 1382 * of the values match the search keyword. Custom field values with 1383 * parenthesis, brackets and special symbols are not searchable as-is, 1384 * and must be surrounded by quotes. 1385 * </pre> 1386 * 1387 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 1388 * 1389 * @param index The index to set the value at. 1390 * @param value The keywordSearchableProfileCustomAttributes to set. 1391 * @return This builder for chaining. 1392 */ setKeywordSearchableProfileCustomAttributes(int index, java.lang.String value)1393 public Builder setKeywordSearchableProfileCustomAttributes(int index, java.lang.String value) { 1394 if (value == null) { 1395 throw new NullPointerException(); 1396 } 1397 ensureKeywordSearchableProfileCustomAttributesIsMutable(); 1398 keywordSearchableProfileCustomAttributes_.set(index, value); 1399 onChanged(); 1400 return this; 1401 } 1402 /** 1403 * 1404 * 1405 * <pre> 1406 * A list of keys of filterable 1407 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 1408 * whose corresponding `string_values` are used in keyword searches. Profiles 1409 * with `string_values` under these specified field keys are returned if any 1410 * of the values match the search keyword. Custom field values with 1411 * parenthesis, brackets and special symbols are not searchable as-is, 1412 * and must be surrounded by quotes. 1413 * </pre> 1414 * 1415 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 1416 * 1417 * @param value The keywordSearchableProfileCustomAttributes to add. 1418 * @return This builder for chaining. 1419 */ addKeywordSearchableProfileCustomAttributes(java.lang.String value)1420 public Builder addKeywordSearchableProfileCustomAttributes(java.lang.String value) { 1421 if (value == null) { 1422 throw new NullPointerException(); 1423 } 1424 ensureKeywordSearchableProfileCustomAttributesIsMutable(); 1425 keywordSearchableProfileCustomAttributes_.add(value); 1426 onChanged(); 1427 return this; 1428 } 1429 /** 1430 * 1431 * 1432 * <pre> 1433 * A list of keys of filterable 1434 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 1435 * whose corresponding `string_values` are used in keyword searches. Profiles 1436 * with `string_values` under these specified field keys are returned if any 1437 * of the values match the search keyword. Custom field values with 1438 * parenthesis, brackets and special symbols are not searchable as-is, 1439 * and must be surrounded by quotes. 1440 * </pre> 1441 * 1442 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 1443 * 1444 * @param values The keywordSearchableProfileCustomAttributes to add. 1445 * @return This builder for chaining. 1446 */ addAllKeywordSearchableProfileCustomAttributes( java.lang.Iterable<java.lang.String> values)1447 public Builder addAllKeywordSearchableProfileCustomAttributes( 1448 java.lang.Iterable<java.lang.String> values) { 1449 ensureKeywordSearchableProfileCustomAttributesIsMutable(); 1450 com.google.protobuf.AbstractMessageLite.Builder.addAll( 1451 values, keywordSearchableProfileCustomAttributes_); 1452 onChanged(); 1453 return this; 1454 } 1455 /** 1456 * 1457 * 1458 * <pre> 1459 * A list of keys of filterable 1460 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 1461 * whose corresponding `string_values` are used in keyword searches. Profiles 1462 * with `string_values` under these specified field keys are returned if any 1463 * of the values match the search keyword. Custom field values with 1464 * parenthesis, brackets and special symbols are not searchable as-is, 1465 * and must be surrounded by quotes. 1466 * </pre> 1467 * 1468 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 1469 * 1470 * @return This builder for chaining. 1471 */ clearKeywordSearchableProfileCustomAttributes()1472 public Builder clearKeywordSearchableProfileCustomAttributes() { 1473 keywordSearchableProfileCustomAttributes_ = com.google.protobuf.LazyStringArrayList.EMPTY; 1474 bitField0_ = (bitField0_ & ~0x00000008); 1475 onChanged(); 1476 return this; 1477 } 1478 /** 1479 * 1480 * 1481 * <pre> 1482 * A list of keys of filterable 1483 * [Profile.custom_attributes][google.cloud.talent.v4beta1.Profile.custom_attributes], 1484 * whose corresponding `string_values` are used in keyword searches. Profiles 1485 * with `string_values` under these specified field keys are returned if any 1486 * of the values match the search keyword. Custom field values with 1487 * parenthesis, brackets and special symbols are not searchable as-is, 1488 * and must be surrounded by quotes. 1489 * </pre> 1490 * 1491 * <code>repeated string keyword_searchable_profile_custom_attributes = 4;</code> 1492 * 1493 * @param value The bytes of the keywordSearchableProfileCustomAttributes to add. 1494 * @return This builder for chaining. 1495 */ addKeywordSearchableProfileCustomAttributesBytes( com.google.protobuf.ByteString value)1496 public Builder addKeywordSearchableProfileCustomAttributesBytes( 1497 com.google.protobuf.ByteString value) { 1498 if (value == null) { 1499 throw new NullPointerException(); 1500 } 1501 checkByteStringIsUtf8(value); 1502 ensureKeywordSearchableProfileCustomAttributesIsMutable(); 1503 keywordSearchableProfileCustomAttributes_.add(value); 1504 onChanged(); 1505 return this; 1506 } 1507 1508 @java.lang.Override setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields)1509 public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { 1510 return super.setUnknownFields(unknownFields); 1511 } 1512 1513 @java.lang.Override mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)1514 public final Builder mergeUnknownFields( 1515 final com.google.protobuf.UnknownFieldSet unknownFields) { 1516 return super.mergeUnknownFields(unknownFields); 1517 } 1518 1519 // @@protoc_insertion_point(builder_scope:google.cloud.talent.v4beta1.Tenant) 1520 } 1521 1522 // @@protoc_insertion_point(class_scope:google.cloud.talent.v4beta1.Tenant) 1523 private static final com.google.cloud.talent.v4beta1.Tenant DEFAULT_INSTANCE; 1524 1525 static { 1526 DEFAULT_INSTANCE = new com.google.cloud.talent.v4beta1.Tenant(); 1527 } 1528 getDefaultInstance()1529 public static com.google.cloud.talent.v4beta1.Tenant getDefaultInstance() { 1530 return DEFAULT_INSTANCE; 1531 } 1532 1533 private static final com.google.protobuf.Parser<Tenant> PARSER = 1534 new com.google.protobuf.AbstractParser<Tenant>() { 1535 @java.lang.Override 1536 public Tenant parsePartialFrom( 1537 com.google.protobuf.CodedInputStream input, 1538 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 1539 throws com.google.protobuf.InvalidProtocolBufferException { 1540 Builder builder = newBuilder(); 1541 try { 1542 builder.mergeFrom(input, extensionRegistry); 1543 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 1544 throw e.setUnfinishedMessage(builder.buildPartial()); 1545 } catch (com.google.protobuf.UninitializedMessageException e) { 1546 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); 1547 } catch (java.io.IOException e) { 1548 throw new com.google.protobuf.InvalidProtocolBufferException(e) 1549 .setUnfinishedMessage(builder.buildPartial()); 1550 } 1551 return builder.buildPartial(); 1552 } 1553 }; 1554 parser()1555 public static com.google.protobuf.Parser<Tenant> parser() { 1556 return PARSER; 1557 } 1558 1559 @java.lang.Override getParserForType()1560 public com.google.protobuf.Parser<Tenant> getParserForType() { 1561 return PARSER; 1562 } 1563 1564 @java.lang.Override getDefaultInstanceForType()1565 public com.google.cloud.talent.v4beta1.Tenant getDefaultInstanceForType() { 1566 return DEFAULT_INSTANCE; 1567 } 1568 } 1569