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/functions/v1/functions.proto 18 19 package com.google.cloud.functions.v1; 20 21 /** 22 * 23 * 24 * <pre> 25 * Describes a Cloud Function that contains user computation executed in 26 * response to an event. It encapsulates function and triggers configurations. 27 * </pre> 28 * 29 * Protobuf type {@code google.cloud.functions.v1.CloudFunction} 30 */ 31 public final class CloudFunction extends com.google.protobuf.GeneratedMessageV3 32 implements 33 // @@protoc_insertion_point(message_implements:google.cloud.functions.v1.CloudFunction) 34 CloudFunctionOrBuilder { 35 private static final long serialVersionUID = 0L; 36 // Use CloudFunction.newBuilder() to construct. CloudFunction(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)37 private CloudFunction(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) { 38 super(builder); 39 } 40 CloudFunction()41 private CloudFunction() { 42 name_ = ""; 43 description_ = ""; 44 status_ = 0; 45 entryPoint_ = ""; 46 runtime_ = ""; 47 serviceAccountEmail_ = ""; 48 network_ = ""; 49 vpcConnector_ = ""; 50 vpcConnectorEgressSettings_ = 0; 51 ingressSettings_ = 0; 52 kmsKeyName_ = ""; 53 buildWorkerPool_ = ""; 54 buildId_ = ""; 55 buildName_ = ""; 56 secretEnvironmentVariables_ = java.util.Collections.emptyList(); 57 secretVolumes_ = java.util.Collections.emptyList(); 58 sourceToken_ = ""; 59 dockerRepository_ = ""; 60 dockerRegistry_ = 0; 61 } 62 63 @java.lang.Override 64 @SuppressWarnings({"unused"}) newInstance(UnusedPrivateParameter unused)65 protected java.lang.Object newInstance(UnusedPrivateParameter unused) { 66 return new CloudFunction(); 67 } 68 69 @java.lang.Override getUnknownFields()70 public final com.google.protobuf.UnknownFieldSet getUnknownFields() { 71 return this.unknownFields; 72 } 73 getDescriptor()74 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 75 return com.google.cloud.functions.v1.FunctionsProto 76 .internal_static_google_cloud_functions_v1_CloudFunction_descriptor; 77 } 78 79 @SuppressWarnings({"rawtypes"}) 80 @java.lang.Override internalGetMapField(int number)81 protected com.google.protobuf.MapField internalGetMapField(int number) { 82 switch (number) { 83 case 15: 84 return internalGetLabels(); 85 case 17: 86 return internalGetEnvironmentVariables(); 87 case 28: 88 return internalGetBuildEnvironmentVariables(); 89 default: 90 throw new RuntimeException("Invalid map field number: " + number); 91 } 92 } 93 94 @java.lang.Override 95 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()96 internalGetFieldAccessorTable() { 97 return com.google.cloud.functions.v1.FunctionsProto 98 .internal_static_google_cloud_functions_v1_CloudFunction_fieldAccessorTable 99 .ensureFieldAccessorsInitialized( 100 com.google.cloud.functions.v1.CloudFunction.class, 101 com.google.cloud.functions.v1.CloudFunction.Builder.class); 102 } 103 104 /** 105 * 106 * 107 * <pre> 108 * Available egress settings. 109 * This controls what traffic is diverted through the Serverless VPC Access 110 * connector resource. By default, PRIVATE_RANGES_ONLY is used. 111 * </pre> 112 * 113 * Protobuf enum {@code google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings} 114 */ 115 public enum VpcConnectorEgressSettings implements com.google.protobuf.ProtocolMessageEnum { 116 /** 117 * 118 * 119 * <pre> 120 * Unspecified. 121 * </pre> 122 * 123 * <code>VPC_CONNECTOR_EGRESS_SETTINGS_UNSPECIFIED = 0;</code> 124 */ 125 VPC_CONNECTOR_EGRESS_SETTINGS_UNSPECIFIED(0), 126 /** 127 * 128 * 129 * <pre> 130 * Use the Serverless VPC Access connector only for private IP space from 131 * RFC1918. 132 * </pre> 133 * 134 * <code>PRIVATE_RANGES_ONLY = 1;</code> 135 */ 136 PRIVATE_RANGES_ONLY(1), 137 /** 138 * 139 * 140 * <pre> 141 * Force the use of Serverless VPC Access connector for all egress traffic 142 * from the function. 143 * </pre> 144 * 145 * <code>ALL_TRAFFIC = 2;</code> 146 */ 147 ALL_TRAFFIC(2), 148 UNRECOGNIZED(-1), 149 ; 150 151 /** 152 * 153 * 154 * <pre> 155 * Unspecified. 156 * </pre> 157 * 158 * <code>VPC_CONNECTOR_EGRESS_SETTINGS_UNSPECIFIED = 0;</code> 159 */ 160 public static final int VPC_CONNECTOR_EGRESS_SETTINGS_UNSPECIFIED_VALUE = 0; 161 /** 162 * 163 * 164 * <pre> 165 * Use the Serverless VPC Access connector only for private IP space from 166 * RFC1918. 167 * </pre> 168 * 169 * <code>PRIVATE_RANGES_ONLY = 1;</code> 170 */ 171 public static final int PRIVATE_RANGES_ONLY_VALUE = 1; 172 /** 173 * 174 * 175 * <pre> 176 * Force the use of Serverless VPC Access connector for all egress traffic 177 * from the function. 178 * </pre> 179 * 180 * <code>ALL_TRAFFIC = 2;</code> 181 */ 182 public static final int ALL_TRAFFIC_VALUE = 2; 183 getNumber()184 public final int getNumber() { 185 if (this == UNRECOGNIZED) { 186 throw new java.lang.IllegalArgumentException( 187 "Can't get the number of an unknown enum value."); 188 } 189 return value; 190 } 191 192 /** 193 * @param value The numeric wire value of the corresponding enum entry. 194 * @return The enum associated with the given numeric wire value. 195 * @deprecated Use {@link #forNumber(int)} instead. 196 */ 197 @java.lang.Deprecated valueOf(int value)198 public static VpcConnectorEgressSettings valueOf(int value) { 199 return forNumber(value); 200 } 201 202 /** 203 * @param value The numeric wire value of the corresponding enum entry. 204 * @return The enum associated with the given numeric wire value. 205 */ forNumber(int value)206 public static VpcConnectorEgressSettings forNumber(int value) { 207 switch (value) { 208 case 0: 209 return VPC_CONNECTOR_EGRESS_SETTINGS_UNSPECIFIED; 210 case 1: 211 return PRIVATE_RANGES_ONLY; 212 case 2: 213 return ALL_TRAFFIC; 214 default: 215 return null; 216 } 217 } 218 219 public static com.google.protobuf.Internal.EnumLiteMap<VpcConnectorEgressSettings> internalGetValueMap()220 internalGetValueMap() { 221 return internalValueMap; 222 } 223 224 private static final com.google.protobuf.Internal.EnumLiteMap<VpcConnectorEgressSettings> 225 internalValueMap = 226 new com.google.protobuf.Internal.EnumLiteMap<VpcConnectorEgressSettings>() { 227 public VpcConnectorEgressSettings findValueByNumber(int number) { 228 return VpcConnectorEgressSettings.forNumber(number); 229 } 230 }; 231 getValueDescriptor()232 public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { 233 if (this == UNRECOGNIZED) { 234 throw new java.lang.IllegalStateException( 235 "Can't get the descriptor of an unrecognized enum value."); 236 } 237 return getDescriptor().getValues().get(ordinal()); 238 } 239 getDescriptorForType()240 public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { 241 return getDescriptor(); 242 } 243 getDescriptor()244 public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { 245 return com.google.cloud.functions.v1.CloudFunction.getDescriptor().getEnumTypes().get(0); 246 } 247 248 private static final VpcConnectorEgressSettings[] VALUES = values(); 249 valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc)250 public static VpcConnectorEgressSettings valueOf( 251 com.google.protobuf.Descriptors.EnumValueDescriptor desc) { 252 if (desc.getType() != getDescriptor()) { 253 throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); 254 } 255 if (desc.getIndex() == -1) { 256 return UNRECOGNIZED; 257 } 258 return VALUES[desc.getIndex()]; 259 } 260 261 private final int value; 262 VpcConnectorEgressSettings(int value)263 private VpcConnectorEgressSettings(int value) { 264 this.value = value; 265 } 266 267 // @@protoc_insertion_point(enum_scope:google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings) 268 } 269 270 /** 271 * 272 * 273 * <pre> 274 * Available ingress settings. 275 * This controls what traffic can reach the function. 276 * If unspecified, ALLOW_ALL is used. 277 * </pre> 278 * 279 * Protobuf enum {@code google.cloud.functions.v1.CloudFunction.IngressSettings} 280 */ 281 public enum IngressSettings implements com.google.protobuf.ProtocolMessageEnum { 282 /** 283 * 284 * 285 * <pre> 286 * Unspecified. 287 * </pre> 288 * 289 * <code>INGRESS_SETTINGS_UNSPECIFIED = 0;</code> 290 */ 291 INGRESS_SETTINGS_UNSPECIFIED(0), 292 /** 293 * 294 * 295 * <pre> 296 * Allow HTTP traffic from public and private sources. 297 * </pre> 298 * 299 * <code>ALLOW_ALL = 1;</code> 300 */ 301 ALLOW_ALL(1), 302 /** 303 * 304 * 305 * <pre> 306 * Allow HTTP traffic from only private VPC sources. 307 * </pre> 308 * 309 * <code>ALLOW_INTERNAL_ONLY = 2;</code> 310 */ 311 ALLOW_INTERNAL_ONLY(2), 312 /** 313 * 314 * 315 * <pre> 316 * Allow HTTP traffic from private VPC sources and through GCLB. 317 * </pre> 318 * 319 * <code>ALLOW_INTERNAL_AND_GCLB = 3;</code> 320 */ 321 ALLOW_INTERNAL_AND_GCLB(3), 322 UNRECOGNIZED(-1), 323 ; 324 325 /** 326 * 327 * 328 * <pre> 329 * Unspecified. 330 * </pre> 331 * 332 * <code>INGRESS_SETTINGS_UNSPECIFIED = 0;</code> 333 */ 334 public static final int INGRESS_SETTINGS_UNSPECIFIED_VALUE = 0; 335 /** 336 * 337 * 338 * <pre> 339 * Allow HTTP traffic from public and private sources. 340 * </pre> 341 * 342 * <code>ALLOW_ALL = 1;</code> 343 */ 344 public static final int ALLOW_ALL_VALUE = 1; 345 /** 346 * 347 * 348 * <pre> 349 * Allow HTTP traffic from only private VPC sources. 350 * </pre> 351 * 352 * <code>ALLOW_INTERNAL_ONLY = 2;</code> 353 */ 354 public static final int ALLOW_INTERNAL_ONLY_VALUE = 2; 355 /** 356 * 357 * 358 * <pre> 359 * Allow HTTP traffic from private VPC sources and through GCLB. 360 * </pre> 361 * 362 * <code>ALLOW_INTERNAL_AND_GCLB = 3;</code> 363 */ 364 public static final int ALLOW_INTERNAL_AND_GCLB_VALUE = 3; 365 getNumber()366 public final int getNumber() { 367 if (this == UNRECOGNIZED) { 368 throw new java.lang.IllegalArgumentException( 369 "Can't get the number of an unknown enum value."); 370 } 371 return value; 372 } 373 374 /** 375 * @param value The numeric wire value of the corresponding enum entry. 376 * @return The enum associated with the given numeric wire value. 377 * @deprecated Use {@link #forNumber(int)} instead. 378 */ 379 @java.lang.Deprecated valueOf(int value)380 public static IngressSettings valueOf(int value) { 381 return forNumber(value); 382 } 383 384 /** 385 * @param value The numeric wire value of the corresponding enum entry. 386 * @return The enum associated with the given numeric wire value. 387 */ forNumber(int value)388 public static IngressSettings forNumber(int value) { 389 switch (value) { 390 case 0: 391 return INGRESS_SETTINGS_UNSPECIFIED; 392 case 1: 393 return ALLOW_ALL; 394 case 2: 395 return ALLOW_INTERNAL_ONLY; 396 case 3: 397 return ALLOW_INTERNAL_AND_GCLB; 398 default: 399 return null; 400 } 401 } 402 internalGetValueMap()403 public static com.google.protobuf.Internal.EnumLiteMap<IngressSettings> internalGetValueMap() { 404 return internalValueMap; 405 } 406 407 private static final com.google.protobuf.Internal.EnumLiteMap<IngressSettings> 408 internalValueMap = 409 new com.google.protobuf.Internal.EnumLiteMap<IngressSettings>() { 410 public IngressSettings findValueByNumber(int number) { 411 return IngressSettings.forNumber(number); 412 } 413 }; 414 getValueDescriptor()415 public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { 416 if (this == UNRECOGNIZED) { 417 throw new java.lang.IllegalStateException( 418 "Can't get the descriptor of an unrecognized enum value."); 419 } 420 return getDescriptor().getValues().get(ordinal()); 421 } 422 getDescriptorForType()423 public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { 424 return getDescriptor(); 425 } 426 getDescriptor()427 public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { 428 return com.google.cloud.functions.v1.CloudFunction.getDescriptor().getEnumTypes().get(1); 429 } 430 431 private static final IngressSettings[] VALUES = values(); 432 valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc)433 public static IngressSettings valueOf( 434 com.google.protobuf.Descriptors.EnumValueDescriptor desc) { 435 if (desc.getType() != getDescriptor()) { 436 throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); 437 } 438 if (desc.getIndex() == -1) { 439 return UNRECOGNIZED; 440 } 441 return VALUES[desc.getIndex()]; 442 } 443 444 private final int value; 445 IngressSettings(int value)446 private IngressSettings(int value) { 447 this.value = value; 448 } 449 450 // @@protoc_insertion_point(enum_scope:google.cloud.functions.v1.CloudFunction.IngressSettings) 451 } 452 453 /** 454 * 455 * 456 * <pre> 457 * Docker Registry to use for storing function Docker images. 458 * </pre> 459 * 460 * Protobuf enum {@code google.cloud.functions.v1.CloudFunction.DockerRegistry} 461 */ 462 public enum DockerRegistry implements com.google.protobuf.ProtocolMessageEnum { 463 /** 464 * 465 * 466 * <pre> 467 * Unspecified. 468 * </pre> 469 * 470 * <code>DOCKER_REGISTRY_UNSPECIFIED = 0;</code> 471 */ 472 DOCKER_REGISTRY_UNSPECIFIED(0), 473 /** 474 * 475 * 476 * <pre> 477 * Docker images are stored in multi-regional Container Registry 478 * repositories named `gcf`. 479 * </pre> 480 * 481 * <code>CONTAINER_REGISTRY = 1;</code> 482 */ 483 CONTAINER_REGISTRY(1), 484 /** 485 * 486 * 487 * <pre> 488 * Docker images are stored in regional Artifact Registry repositories. 489 * By default, Cloud Functions creates and uses repositories named 490 * `gcf-artifacts` in every region in which a function is deployed. But the 491 * repository to use can also be specified by the user by using the 492 * `docker_repository` field. 493 * </pre> 494 * 495 * <code>ARTIFACT_REGISTRY = 2;</code> 496 */ 497 ARTIFACT_REGISTRY(2), 498 UNRECOGNIZED(-1), 499 ; 500 501 /** 502 * 503 * 504 * <pre> 505 * Unspecified. 506 * </pre> 507 * 508 * <code>DOCKER_REGISTRY_UNSPECIFIED = 0;</code> 509 */ 510 public static final int DOCKER_REGISTRY_UNSPECIFIED_VALUE = 0; 511 /** 512 * 513 * 514 * <pre> 515 * Docker images are stored in multi-regional Container Registry 516 * repositories named `gcf`. 517 * </pre> 518 * 519 * <code>CONTAINER_REGISTRY = 1;</code> 520 */ 521 public static final int CONTAINER_REGISTRY_VALUE = 1; 522 /** 523 * 524 * 525 * <pre> 526 * Docker images are stored in regional Artifact Registry repositories. 527 * By default, Cloud Functions creates and uses repositories named 528 * `gcf-artifacts` in every region in which a function is deployed. But the 529 * repository to use can also be specified by the user by using the 530 * `docker_repository` field. 531 * </pre> 532 * 533 * <code>ARTIFACT_REGISTRY = 2;</code> 534 */ 535 public static final int ARTIFACT_REGISTRY_VALUE = 2; 536 getNumber()537 public final int getNumber() { 538 if (this == UNRECOGNIZED) { 539 throw new java.lang.IllegalArgumentException( 540 "Can't get the number of an unknown enum value."); 541 } 542 return value; 543 } 544 545 /** 546 * @param value The numeric wire value of the corresponding enum entry. 547 * @return The enum associated with the given numeric wire value. 548 * @deprecated Use {@link #forNumber(int)} instead. 549 */ 550 @java.lang.Deprecated valueOf(int value)551 public static DockerRegistry valueOf(int value) { 552 return forNumber(value); 553 } 554 555 /** 556 * @param value The numeric wire value of the corresponding enum entry. 557 * @return The enum associated with the given numeric wire value. 558 */ forNumber(int value)559 public static DockerRegistry forNumber(int value) { 560 switch (value) { 561 case 0: 562 return DOCKER_REGISTRY_UNSPECIFIED; 563 case 1: 564 return CONTAINER_REGISTRY; 565 case 2: 566 return ARTIFACT_REGISTRY; 567 default: 568 return null; 569 } 570 } 571 internalGetValueMap()572 public static com.google.protobuf.Internal.EnumLiteMap<DockerRegistry> internalGetValueMap() { 573 return internalValueMap; 574 } 575 576 private static final com.google.protobuf.Internal.EnumLiteMap<DockerRegistry> internalValueMap = 577 new com.google.protobuf.Internal.EnumLiteMap<DockerRegistry>() { 578 public DockerRegistry findValueByNumber(int number) { 579 return DockerRegistry.forNumber(number); 580 } 581 }; 582 getValueDescriptor()583 public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { 584 if (this == UNRECOGNIZED) { 585 throw new java.lang.IllegalStateException( 586 "Can't get the descriptor of an unrecognized enum value."); 587 } 588 return getDescriptor().getValues().get(ordinal()); 589 } 590 getDescriptorForType()591 public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { 592 return getDescriptor(); 593 } 594 getDescriptor()595 public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { 596 return com.google.cloud.functions.v1.CloudFunction.getDescriptor().getEnumTypes().get(2); 597 } 598 599 private static final DockerRegistry[] VALUES = values(); 600 valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc)601 public static DockerRegistry valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { 602 if (desc.getType() != getDescriptor()) { 603 throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); 604 } 605 if (desc.getIndex() == -1) { 606 return UNRECOGNIZED; 607 } 608 return VALUES[desc.getIndex()]; 609 } 610 611 private final int value; 612 DockerRegistry(int value)613 private DockerRegistry(int value) { 614 this.value = value; 615 } 616 617 // @@protoc_insertion_point(enum_scope:google.cloud.functions.v1.CloudFunction.DockerRegistry) 618 } 619 620 private int sourceCodeCase_ = 0; 621 private java.lang.Object sourceCode_; 622 623 public enum SourceCodeCase 624 implements 625 com.google.protobuf.Internal.EnumLite, 626 com.google.protobuf.AbstractMessage.InternalOneOfEnum { 627 SOURCE_ARCHIVE_URL(3), 628 SOURCE_REPOSITORY(4), 629 SOURCE_UPLOAD_URL(16), 630 SOURCECODE_NOT_SET(0); 631 private final int value; 632 SourceCodeCase(int value)633 private SourceCodeCase(int value) { 634 this.value = value; 635 } 636 /** 637 * @param value The number of the enum to look for. 638 * @return The enum associated with the given number. 639 * @deprecated Use {@link #forNumber(int)} instead. 640 */ 641 @java.lang.Deprecated valueOf(int value)642 public static SourceCodeCase valueOf(int value) { 643 return forNumber(value); 644 } 645 forNumber(int value)646 public static SourceCodeCase forNumber(int value) { 647 switch (value) { 648 case 3: 649 return SOURCE_ARCHIVE_URL; 650 case 4: 651 return SOURCE_REPOSITORY; 652 case 16: 653 return SOURCE_UPLOAD_URL; 654 case 0: 655 return SOURCECODE_NOT_SET; 656 default: 657 return null; 658 } 659 } 660 getNumber()661 public int getNumber() { 662 return this.value; 663 } 664 }; 665 getSourceCodeCase()666 public SourceCodeCase getSourceCodeCase() { 667 return SourceCodeCase.forNumber(sourceCodeCase_); 668 } 669 670 private int triggerCase_ = 0; 671 private java.lang.Object trigger_; 672 673 public enum TriggerCase 674 implements 675 com.google.protobuf.Internal.EnumLite, 676 com.google.protobuf.AbstractMessage.InternalOneOfEnum { 677 HTTPS_TRIGGER(5), 678 EVENT_TRIGGER(6), 679 TRIGGER_NOT_SET(0); 680 private final int value; 681 TriggerCase(int value)682 private TriggerCase(int value) { 683 this.value = value; 684 } 685 /** 686 * @param value The number of the enum to look for. 687 * @return The enum associated with the given number. 688 * @deprecated Use {@link #forNumber(int)} instead. 689 */ 690 @java.lang.Deprecated valueOf(int value)691 public static TriggerCase valueOf(int value) { 692 return forNumber(value); 693 } 694 forNumber(int value)695 public static TriggerCase forNumber(int value) { 696 switch (value) { 697 case 5: 698 return HTTPS_TRIGGER; 699 case 6: 700 return EVENT_TRIGGER; 701 case 0: 702 return TRIGGER_NOT_SET; 703 default: 704 return null; 705 } 706 } 707 getNumber()708 public int getNumber() { 709 return this.value; 710 } 711 }; 712 getTriggerCase()713 public TriggerCase getTriggerCase() { 714 return TriggerCase.forNumber(triggerCase_); 715 } 716 717 public static final int NAME_FIELD_NUMBER = 1; 718 719 @SuppressWarnings("serial") 720 private volatile java.lang.Object name_ = ""; 721 /** 722 * 723 * 724 * <pre> 725 * A user-defined name of the function. Function names must be unique 726 * globally and match pattern `projects/*/locations/*/functions/*` 727 * </pre> 728 * 729 * <code>string name = 1;</code> 730 * 731 * @return The name. 732 */ 733 @java.lang.Override getName()734 public java.lang.String getName() { 735 java.lang.Object ref = name_; 736 if (ref instanceof java.lang.String) { 737 return (java.lang.String) ref; 738 } else { 739 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 740 java.lang.String s = bs.toStringUtf8(); 741 name_ = s; 742 return s; 743 } 744 } 745 /** 746 * 747 * 748 * <pre> 749 * A user-defined name of the function. Function names must be unique 750 * globally and match pattern `projects/*/locations/*/functions/*` 751 * </pre> 752 * 753 * <code>string name = 1;</code> 754 * 755 * @return The bytes for name. 756 */ 757 @java.lang.Override getNameBytes()758 public com.google.protobuf.ByteString getNameBytes() { 759 java.lang.Object ref = name_; 760 if (ref instanceof java.lang.String) { 761 com.google.protobuf.ByteString b = 762 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 763 name_ = b; 764 return b; 765 } else { 766 return (com.google.protobuf.ByteString) ref; 767 } 768 } 769 770 public static final int DESCRIPTION_FIELD_NUMBER = 2; 771 772 @SuppressWarnings("serial") 773 private volatile java.lang.Object description_ = ""; 774 /** 775 * 776 * 777 * <pre> 778 * User-provided description of a function. 779 * </pre> 780 * 781 * <code>string description = 2;</code> 782 * 783 * @return The description. 784 */ 785 @java.lang.Override getDescription()786 public java.lang.String getDescription() { 787 java.lang.Object ref = description_; 788 if (ref instanceof java.lang.String) { 789 return (java.lang.String) ref; 790 } else { 791 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 792 java.lang.String s = bs.toStringUtf8(); 793 description_ = s; 794 return s; 795 } 796 } 797 /** 798 * 799 * 800 * <pre> 801 * User-provided description of a function. 802 * </pre> 803 * 804 * <code>string description = 2;</code> 805 * 806 * @return The bytes for description. 807 */ 808 @java.lang.Override getDescriptionBytes()809 public com.google.protobuf.ByteString getDescriptionBytes() { 810 java.lang.Object ref = description_; 811 if (ref instanceof java.lang.String) { 812 com.google.protobuf.ByteString b = 813 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 814 description_ = b; 815 return b; 816 } else { 817 return (com.google.protobuf.ByteString) ref; 818 } 819 } 820 821 public static final int SOURCE_ARCHIVE_URL_FIELD_NUMBER = 3; 822 /** 823 * 824 * 825 * <pre> 826 * The Google Cloud Storage URL, starting with `gs://`, pointing to the zip 827 * archive which contains the function. 828 * </pre> 829 * 830 * <code>string source_archive_url = 3;</code> 831 * 832 * @return Whether the sourceArchiveUrl field is set. 833 */ hasSourceArchiveUrl()834 public boolean hasSourceArchiveUrl() { 835 return sourceCodeCase_ == 3; 836 } 837 /** 838 * 839 * 840 * <pre> 841 * The Google Cloud Storage URL, starting with `gs://`, pointing to the zip 842 * archive which contains the function. 843 * </pre> 844 * 845 * <code>string source_archive_url = 3;</code> 846 * 847 * @return The sourceArchiveUrl. 848 */ getSourceArchiveUrl()849 public java.lang.String getSourceArchiveUrl() { 850 java.lang.Object ref = ""; 851 if (sourceCodeCase_ == 3) { 852 ref = sourceCode_; 853 } 854 if (ref instanceof java.lang.String) { 855 return (java.lang.String) ref; 856 } else { 857 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 858 java.lang.String s = bs.toStringUtf8(); 859 if (sourceCodeCase_ == 3) { 860 sourceCode_ = s; 861 } 862 return s; 863 } 864 } 865 /** 866 * 867 * 868 * <pre> 869 * The Google Cloud Storage URL, starting with `gs://`, pointing to the zip 870 * archive which contains the function. 871 * </pre> 872 * 873 * <code>string source_archive_url = 3;</code> 874 * 875 * @return The bytes for sourceArchiveUrl. 876 */ getSourceArchiveUrlBytes()877 public com.google.protobuf.ByteString getSourceArchiveUrlBytes() { 878 java.lang.Object ref = ""; 879 if (sourceCodeCase_ == 3) { 880 ref = sourceCode_; 881 } 882 if (ref instanceof java.lang.String) { 883 com.google.protobuf.ByteString b = 884 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 885 if (sourceCodeCase_ == 3) { 886 sourceCode_ = b; 887 } 888 return b; 889 } else { 890 return (com.google.protobuf.ByteString) ref; 891 } 892 } 893 894 public static final int SOURCE_REPOSITORY_FIELD_NUMBER = 4; 895 /** 896 * 897 * 898 * <pre> 899 * **Beta Feature** 900 * The source repository where a function is hosted. 901 * </pre> 902 * 903 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 904 * 905 * @return Whether the sourceRepository field is set. 906 */ 907 @java.lang.Override hasSourceRepository()908 public boolean hasSourceRepository() { 909 return sourceCodeCase_ == 4; 910 } 911 /** 912 * 913 * 914 * <pre> 915 * **Beta Feature** 916 * The source repository where a function is hosted. 917 * </pre> 918 * 919 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 920 * 921 * @return The sourceRepository. 922 */ 923 @java.lang.Override getSourceRepository()924 public com.google.cloud.functions.v1.SourceRepository getSourceRepository() { 925 if (sourceCodeCase_ == 4) { 926 return (com.google.cloud.functions.v1.SourceRepository) sourceCode_; 927 } 928 return com.google.cloud.functions.v1.SourceRepository.getDefaultInstance(); 929 } 930 /** 931 * 932 * 933 * <pre> 934 * **Beta Feature** 935 * The source repository where a function is hosted. 936 * </pre> 937 * 938 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 939 */ 940 @java.lang.Override getSourceRepositoryOrBuilder()941 public com.google.cloud.functions.v1.SourceRepositoryOrBuilder getSourceRepositoryOrBuilder() { 942 if (sourceCodeCase_ == 4) { 943 return (com.google.cloud.functions.v1.SourceRepository) sourceCode_; 944 } 945 return com.google.cloud.functions.v1.SourceRepository.getDefaultInstance(); 946 } 947 948 public static final int SOURCE_UPLOAD_URL_FIELD_NUMBER = 16; 949 /** 950 * 951 * 952 * <pre> 953 * The Google Cloud Storage-signed URL used for source uploading, generated 954 * by calling [google.cloud.functions.v1.GenerateUploadUrl]. 955 * The signature is validated on write methods (Create, Update) 956 * The signature is stripped from the Function object on read methods (Get, 957 * List) 958 * </pre> 959 * 960 * <code>string source_upload_url = 16;</code> 961 * 962 * @return Whether the sourceUploadUrl field is set. 963 */ hasSourceUploadUrl()964 public boolean hasSourceUploadUrl() { 965 return sourceCodeCase_ == 16; 966 } 967 /** 968 * 969 * 970 * <pre> 971 * The Google Cloud Storage-signed URL used for source uploading, generated 972 * by calling [google.cloud.functions.v1.GenerateUploadUrl]. 973 * The signature is validated on write methods (Create, Update) 974 * The signature is stripped from the Function object on read methods (Get, 975 * List) 976 * </pre> 977 * 978 * <code>string source_upload_url = 16;</code> 979 * 980 * @return The sourceUploadUrl. 981 */ getSourceUploadUrl()982 public java.lang.String getSourceUploadUrl() { 983 java.lang.Object ref = ""; 984 if (sourceCodeCase_ == 16) { 985 ref = sourceCode_; 986 } 987 if (ref instanceof java.lang.String) { 988 return (java.lang.String) ref; 989 } else { 990 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 991 java.lang.String s = bs.toStringUtf8(); 992 if (sourceCodeCase_ == 16) { 993 sourceCode_ = s; 994 } 995 return s; 996 } 997 } 998 /** 999 * 1000 * 1001 * <pre> 1002 * The Google Cloud Storage-signed URL used for source uploading, generated 1003 * by calling [google.cloud.functions.v1.GenerateUploadUrl]. 1004 * The signature is validated on write methods (Create, Update) 1005 * The signature is stripped from the Function object on read methods (Get, 1006 * List) 1007 * </pre> 1008 * 1009 * <code>string source_upload_url = 16;</code> 1010 * 1011 * @return The bytes for sourceUploadUrl. 1012 */ getSourceUploadUrlBytes()1013 public com.google.protobuf.ByteString getSourceUploadUrlBytes() { 1014 java.lang.Object ref = ""; 1015 if (sourceCodeCase_ == 16) { 1016 ref = sourceCode_; 1017 } 1018 if (ref instanceof java.lang.String) { 1019 com.google.protobuf.ByteString b = 1020 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1021 if (sourceCodeCase_ == 16) { 1022 sourceCode_ = b; 1023 } 1024 return b; 1025 } else { 1026 return (com.google.protobuf.ByteString) ref; 1027 } 1028 } 1029 1030 public static final int HTTPS_TRIGGER_FIELD_NUMBER = 5; 1031 /** 1032 * 1033 * 1034 * <pre> 1035 * An HTTPS endpoint type of source that can be triggered via URL. 1036 * </pre> 1037 * 1038 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 1039 * 1040 * @return Whether the httpsTrigger field is set. 1041 */ 1042 @java.lang.Override hasHttpsTrigger()1043 public boolean hasHttpsTrigger() { 1044 return triggerCase_ == 5; 1045 } 1046 /** 1047 * 1048 * 1049 * <pre> 1050 * An HTTPS endpoint type of source that can be triggered via URL. 1051 * </pre> 1052 * 1053 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 1054 * 1055 * @return The httpsTrigger. 1056 */ 1057 @java.lang.Override getHttpsTrigger()1058 public com.google.cloud.functions.v1.HttpsTrigger getHttpsTrigger() { 1059 if (triggerCase_ == 5) { 1060 return (com.google.cloud.functions.v1.HttpsTrigger) trigger_; 1061 } 1062 return com.google.cloud.functions.v1.HttpsTrigger.getDefaultInstance(); 1063 } 1064 /** 1065 * 1066 * 1067 * <pre> 1068 * An HTTPS endpoint type of source that can be triggered via URL. 1069 * </pre> 1070 * 1071 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 1072 */ 1073 @java.lang.Override getHttpsTriggerOrBuilder()1074 public com.google.cloud.functions.v1.HttpsTriggerOrBuilder getHttpsTriggerOrBuilder() { 1075 if (triggerCase_ == 5) { 1076 return (com.google.cloud.functions.v1.HttpsTrigger) trigger_; 1077 } 1078 return com.google.cloud.functions.v1.HttpsTrigger.getDefaultInstance(); 1079 } 1080 1081 public static final int EVENT_TRIGGER_FIELD_NUMBER = 6; 1082 /** 1083 * 1084 * 1085 * <pre> 1086 * A source that fires events in response to a condition in another service. 1087 * </pre> 1088 * 1089 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 1090 * 1091 * @return Whether the eventTrigger field is set. 1092 */ 1093 @java.lang.Override hasEventTrigger()1094 public boolean hasEventTrigger() { 1095 return triggerCase_ == 6; 1096 } 1097 /** 1098 * 1099 * 1100 * <pre> 1101 * A source that fires events in response to a condition in another service. 1102 * </pre> 1103 * 1104 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 1105 * 1106 * @return The eventTrigger. 1107 */ 1108 @java.lang.Override getEventTrigger()1109 public com.google.cloud.functions.v1.EventTrigger getEventTrigger() { 1110 if (triggerCase_ == 6) { 1111 return (com.google.cloud.functions.v1.EventTrigger) trigger_; 1112 } 1113 return com.google.cloud.functions.v1.EventTrigger.getDefaultInstance(); 1114 } 1115 /** 1116 * 1117 * 1118 * <pre> 1119 * A source that fires events in response to a condition in another service. 1120 * </pre> 1121 * 1122 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 1123 */ 1124 @java.lang.Override getEventTriggerOrBuilder()1125 public com.google.cloud.functions.v1.EventTriggerOrBuilder getEventTriggerOrBuilder() { 1126 if (triggerCase_ == 6) { 1127 return (com.google.cloud.functions.v1.EventTrigger) trigger_; 1128 } 1129 return com.google.cloud.functions.v1.EventTrigger.getDefaultInstance(); 1130 } 1131 1132 public static final int STATUS_FIELD_NUMBER = 7; 1133 private int status_ = 0; 1134 /** 1135 * 1136 * 1137 * <pre> 1138 * Output only. Status of the function deployment. 1139 * </pre> 1140 * 1141 * <code> 1142 * .google.cloud.functions.v1.CloudFunctionStatus status = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; 1143 * </code> 1144 * 1145 * @return The enum numeric value on the wire for status. 1146 */ 1147 @java.lang.Override getStatusValue()1148 public int getStatusValue() { 1149 return status_; 1150 } 1151 /** 1152 * 1153 * 1154 * <pre> 1155 * Output only. Status of the function deployment. 1156 * </pre> 1157 * 1158 * <code> 1159 * .google.cloud.functions.v1.CloudFunctionStatus status = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; 1160 * </code> 1161 * 1162 * @return The status. 1163 */ 1164 @java.lang.Override getStatus()1165 public com.google.cloud.functions.v1.CloudFunctionStatus getStatus() { 1166 com.google.cloud.functions.v1.CloudFunctionStatus result = 1167 com.google.cloud.functions.v1.CloudFunctionStatus.forNumber(status_); 1168 return result == null ? com.google.cloud.functions.v1.CloudFunctionStatus.UNRECOGNIZED : result; 1169 } 1170 1171 public static final int ENTRY_POINT_FIELD_NUMBER = 8; 1172 1173 @SuppressWarnings("serial") 1174 private volatile java.lang.Object entryPoint_ = ""; 1175 /** 1176 * 1177 * 1178 * <pre> 1179 * The name of the function (as defined in source code) that is executed. 1180 * Defaults to the resource name suffix, if not specified. For 1181 * backward compatibility, if function with given name is not found, the 1182 * system tries to use the function named "function". 1183 * For Node.js, this is the name of a function exported by the module 1184 * as specified in `source_location`. 1185 * </pre> 1186 * 1187 * <code>string entry_point = 8;</code> 1188 * 1189 * @return The entryPoint. 1190 */ 1191 @java.lang.Override getEntryPoint()1192 public java.lang.String getEntryPoint() { 1193 java.lang.Object ref = entryPoint_; 1194 if (ref instanceof java.lang.String) { 1195 return (java.lang.String) ref; 1196 } else { 1197 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1198 java.lang.String s = bs.toStringUtf8(); 1199 entryPoint_ = s; 1200 return s; 1201 } 1202 } 1203 /** 1204 * 1205 * 1206 * <pre> 1207 * The name of the function (as defined in source code) that is executed. 1208 * Defaults to the resource name suffix, if not specified. For 1209 * backward compatibility, if function with given name is not found, the 1210 * system tries to use the function named "function". 1211 * For Node.js, this is the name of a function exported by the module 1212 * as specified in `source_location`. 1213 * </pre> 1214 * 1215 * <code>string entry_point = 8;</code> 1216 * 1217 * @return The bytes for entryPoint. 1218 */ 1219 @java.lang.Override getEntryPointBytes()1220 public com.google.protobuf.ByteString getEntryPointBytes() { 1221 java.lang.Object ref = entryPoint_; 1222 if (ref instanceof java.lang.String) { 1223 com.google.protobuf.ByteString b = 1224 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1225 entryPoint_ = b; 1226 return b; 1227 } else { 1228 return (com.google.protobuf.ByteString) ref; 1229 } 1230 } 1231 1232 public static final int RUNTIME_FIELD_NUMBER = 19; 1233 1234 @SuppressWarnings("serial") 1235 private volatile java.lang.Object runtime_ = ""; 1236 /** 1237 * 1238 * 1239 * <pre> 1240 * The runtime in which to run the function. Required when deploying a new 1241 * function, optional when updating an existing function. For a complete 1242 * list of possible choices, see the 1243 * [`gcloud` command 1244 * reference](https://cloud.google.com/sdk/gcloud/reference/functions/deploy#--runtime). 1245 * </pre> 1246 * 1247 * <code>string runtime = 19;</code> 1248 * 1249 * @return The runtime. 1250 */ 1251 @java.lang.Override getRuntime()1252 public java.lang.String getRuntime() { 1253 java.lang.Object ref = runtime_; 1254 if (ref instanceof java.lang.String) { 1255 return (java.lang.String) ref; 1256 } else { 1257 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1258 java.lang.String s = bs.toStringUtf8(); 1259 runtime_ = s; 1260 return s; 1261 } 1262 } 1263 /** 1264 * 1265 * 1266 * <pre> 1267 * The runtime in which to run the function. Required when deploying a new 1268 * function, optional when updating an existing function. For a complete 1269 * list of possible choices, see the 1270 * [`gcloud` command 1271 * reference](https://cloud.google.com/sdk/gcloud/reference/functions/deploy#--runtime). 1272 * </pre> 1273 * 1274 * <code>string runtime = 19;</code> 1275 * 1276 * @return The bytes for runtime. 1277 */ 1278 @java.lang.Override getRuntimeBytes()1279 public com.google.protobuf.ByteString getRuntimeBytes() { 1280 java.lang.Object ref = runtime_; 1281 if (ref instanceof java.lang.String) { 1282 com.google.protobuf.ByteString b = 1283 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1284 runtime_ = b; 1285 return b; 1286 } else { 1287 return (com.google.protobuf.ByteString) ref; 1288 } 1289 } 1290 1291 public static final int TIMEOUT_FIELD_NUMBER = 9; 1292 private com.google.protobuf.Duration timeout_; 1293 /** 1294 * 1295 * 1296 * <pre> 1297 * The function execution timeout. Execution is considered failed and 1298 * can be terminated if the function is not completed at the end of the 1299 * timeout period. Defaults to 60 seconds. 1300 * </pre> 1301 * 1302 * <code>.google.protobuf.Duration timeout = 9;</code> 1303 * 1304 * @return Whether the timeout field is set. 1305 */ 1306 @java.lang.Override hasTimeout()1307 public boolean hasTimeout() { 1308 return timeout_ != null; 1309 } 1310 /** 1311 * 1312 * 1313 * <pre> 1314 * The function execution timeout. Execution is considered failed and 1315 * can be terminated if the function is not completed at the end of the 1316 * timeout period. Defaults to 60 seconds. 1317 * </pre> 1318 * 1319 * <code>.google.protobuf.Duration timeout = 9;</code> 1320 * 1321 * @return The timeout. 1322 */ 1323 @java.lang.Override getTimeout()1324 public com.google.protobuf.Duration getTimeout() { 1325 return timeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : timeout_; 1326 } 1327 /** 1328 * 1329 * 1330 * <pre> 1331 * The function execution timeout. Execution is considered failed and 1332 * can be terminated if the function is not completed at the end of the 1333 * timeout period. Defaults to 60 seconds. 1334 * </pre> 1335 * 1336 * <code>.google.protobuf.Duration timeout = 9;</code> 1337 */ 1338 @java.lang.Override getTimeoutOrBuilder()1339 public com.google.protobuf.DurationOrBuilder getTimeoutOrBuilder() { 1340 return timeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : timeout_; 1341 } 1342 1343 public static final int AVAILABLE_MEMORY_MB_FIELD_NUMBER = 10; 1344 private int availableMemoryMb_ = 0; 1345 /** 1346 * 1347 * 1348 * <pre> 1349 * The amount of memory in MB available for a function. 1350 * Defaults to 256MB. 1351 * </pre> 1352 * 1353 * <code>int32 available_memory_mb = 10;</code> 1354 * 1355 * @return The availableMemoryMb. 1356 */ 1357 @java.lang.Override getAvailableMemoryMb()1358 public int getAvailableMemoryMb() { 1359 return availableMemoryMb_; 1360 } 1361 1362 public static final int SERVICE_ACCOUNT_EMAIL_FIELD_NUMBER = 11; 1363 1364 @SuppressWarnings("serial") 1365 private volatile java.lang.Object serviceAccountEmail_ = ""; 1366 /** 1367 * 1368 * 1369 * <pre> 1370 * The email of the function's service account. If empty, defaults to 1371 * `{project_id}@appspot.gserviceaccount.com`. 1372 * </pre> 1373 * 1374 * <code>string service_account_email = 11;</code> 1375 * 1376 * @return The serviceAccountEmail. 1377 */ 1378 @java.lang.Override getServiceAccountEmail()1379 public java.lang.String getServiceAccountEmail() { 1380 java.lang.Object ref = serviceAccountEmail_; 1381 if (ref instanceof java.lang.String) { 1382 return (java.lang.String) ref; 1383 } else { 1384 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1385 java.lang.String s = bs.toStringUtf8(); 1386 serviceAccountEmail_ = s; 1387 return s; 1388 } 1389 } 1390 /** 1391 * 1392 * 1393 * <pre> 1394 * The email of the function's service account. If empty, defaults to 1395 * `{project_id}@appspot.gserviceaccount.com`. 1396 * </pre> 1397 * 1398 * <code>string service_account_email = 11;</code> 1399 * 1400 * @return The bytes for serviceAccountEmail. 1401 */ 1402 @java.lang.Override getServiceAccountEmailBytes()1403 public com.google.protobuf.ByteString getServiceAccountEmailBytes() { 1404 java.lang.Object ref = serviceAccountEmail_; 1405 if (ref instanceof java.lang.String) { 1406 com.google.protobuf.ByteString b = 1407 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1408 serviceAccountEmail_ = b; 1409 return b; 1410 } else { 1411 return (com.google.protobuf.ByteString) ref; 1412 } 1413 } 1414 1415 public static final int UPDATE_TIME_FIELD_NUMBER = 12; 1416 private com.google.protobuf.Timestamp updateTime_; 1417 /** 1418 * 1419 * 1420 * <pre> 1421 * Output only. The last update timestamp of a Cloud Function. 1422 * </pre> 1423 * 1424 * <code>.google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 1425 * </code> 1426 * 1427 * @return Whether the updateTime field is set. 1428 */ 1429 @java.lang.Override hasUpdateTime()1430 public boolean hasUpdateTime() { 1431 return updateTime_ != null; 1432 } 1433 /** 1434 * 1435 * 1436 * <pre> 1437 * Output only. The last update timestamp of a Cloud Function. 1438 * </pre> 1439 * 1440 * <code>.google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 1441 * </code> 1442 * 1443 * @return The updateTime. 1444 */ 1445 @java.lang.Override getUpdateTime()1446 public com.google.protobuf.Timestamp getUpdateTime() { 1447 return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; 1448 } 1449 /** 1450 * 1451 * 1452 * <pre> 1453 * Output only. The last update timestamp of a Cloud Function. 1454 * </pre> 1455 * 1456 * <code>.google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 1457 * </code> 1458 */ 1459 @java.lang.Override getUpdateTimeOrBuilder()1460 public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { 1461 return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; 1462 } 1463 1464 public static final int VERSION_ID_FIELD_NUMBER = 14; 1465 private long versionId_ = 0L; 1466 /** 1467 * 1468 * 1469 * <pre> 1470 * Output only. The version identifier of the Cloud Function. Each deployment 1471 * attempt results in a new version of a function being created. 1472 * </pre> 1473 * 1474 * <code>int64 version_id = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 1475 * 1476 * @return The versionId. 1477 */ 1478 @java.lang.Override getVersionId()1479 public long getVersionId() { 1480 return versionId_; 1481 } 1482 1483 public static final int LABELS_FIELD_NUMBER = 15; 1484 1485 private static final class LabelsDefaultEntryHolder { 1486 static final com.google.protobuf.MapEntry<java.lang.String, java.lang.String> defaultEntry = 1487 com.google.protobuf.MapEntry.<java.lang.String, java.lang.String>newDefaultInstance( 1488 com.google.cloud.functions.v1.FunctionsProto 1489 .internal_static_google_cloud_functions_v1_CloudFunction_LabelsEntry_descriptor, 1490 com.google.protobuf.WireFormat.FieldType.STRING, 1491 "", 1492 com.google.protobuf.WireFormat.FieldType.STRING, 1493 ""); 1494 } 1495 1496 @SuppressWarnings("serial") 1497 private com.google.protobuf.MapField<java.lang.String, java.lang.String> labels_; 1498 internalGetLabels()1499 private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetLabels() { 1500 if (labels_ == null) { 1501 return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); 1502 } 1503 return labels_; 1504 } 1505 getLabelsCount()1506 public int getLabelsCount() { 1507 return internalGetLabels().getMap().size(); 1508 } 1509 /** 1510 * 1511 * 1512 * <pre> 1513 * Labels associated with this Cloud Function. 1514 * </pre> 1515 * 1516 * <code>map<string, string> labels = 15;</code> 1517 */ 1518 @java.lang.Override containsLabels(java.lang.String key)1519 public boolean containsLabels(java.lang.String key) { 1520 if (key == null) { 1521 throw new NullPointerException("map key"); 1522 } 1523 return internalGetLabels().getMap().containsKey(key); 1524 } 1525 /** Use {@link #getLabelsMap()} instead. */ 1526 @java.lang.Override 1527 @java.lang.Deprecated getLabels()1528 public java.util.Map<java.lang.String, java.lang.String> getLabels() { 1529 return getLabelsMap(); 1530 } 1531 /** 1532 * 1533 * 1534 * <pre> 1535 * Labels associated with this Cloud Function. 1536 * </pre> 1537 * 1538 * <code>map<string, string> labels = 15;</code> 1539 */ 1540 @java.lang.Override getLabelsMap()1541 public java.util.Map<java.lang.String, java.lang.String> getLabelsMap() { 1542 return internalGetLabels().getMap(); 1543 } 1544 /** 1545 * 1546 * 1547 * <pre> 1548 * Labels associated with this Cloud Function. 1549 * </pre> 1550 * 1551 * <code>map<string, string> labels = 15;</code> 1552 */ 1553 @java.lang.Override getLabelsOrDefault( java.lang.String key, java.lang.String defaultValue)1554 public /* nullable */ java.lang.String getLabelsOrDefault( 1555 java.lang.String key, 1556 /* nullable */ 1557 java.lang.String defaultValue) { 1558 if (key == null) { 1559 throw new NullPointerException("map key"); 1560 } 1561 java.util.Map<java.lang.String, java.lang.String> map = internalGetLabels().getMap(); 1562 return map.containsKey(key) ? map.get(key) : defaultValue; 1563 } 1564 /** 1565 * 1566 * 1567 * <pre> 1568 * Labels associated with this Cloud Function. 1569 * </pre> 1570 * 1571 * <code>map<string, string> labels = 15;</code> 1572 */ 1573 @java.lang.Override getLabelsOrThrow(java.lang.String key)1574 public java.lang.String getLabelsOrThrow(java.lang.String key) { 1575 if (key == null) { 1576 throw new NullPointerException("map key"); 1577 } 1578 java.util.Map<java.lang.String, java.lang.String> map = internalGetLabels().getMap(); 1579 if (!map.containsKey(key)) { 1580 throw new java.lang.IllegalArgumentException(); 1581 } 1582 return map.get(key); 1583 } 1584 1585 public static final int ENVIRONMENT_VARIABLES_FIELD_NUMBER = 17; 1586 1587 private static final class EnvironmentVariablesDefaultEntryHolder { 1588 static final com.google.protobuf.MapEntry<java.lang.String, java.lang.String> defaultEntry = 1589 com.google.protobuf.MapEntry.<java.lang.String, java.lang.String>newDefaultInstance( 1590 com.google.cloud.functions.v1.FunctionsProto 1591 .internal_static_google_cloud_functions_v1_CloudFunction_EnvironmentVariablesEntry_descriptor, 1592 com.google.protobuf.WireFormat.FieldType.STRING, 1593 "", 1594 com.google.protobuf.WireFormat.FieldType.STRING, 1595 ""); 1596 } 1597 1598 @SuppressWarnings("serial") 1599 private com.google.protobuf.MapField<java.lang.String, java.lang.String> environmentVariables_; 1600 1601 private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetEnvironmentVariables()1602 internalGetEnvironmentVariables() { 1603 if (environmentVariables_ == null) { 1604 return com.google.protobuf.MapField.emptyMapField( 1605 EnvironmentVariablesDefaultEntryHolder.defaultEntry); 1606 } 1607 return environmentVariables_; 1608 } 1609 getEnvironmentVariablesCount()1610 public int getEnvironmentVariablesCount() { 1611 return internalGetEnvironmentVariables().getMap().size(); 1612 } 1613 /** 1614 * 1615 * 1616 * <pre> 1617 * Environment variables that shall be available during function execution. 1618 * </pre> 1619 * 1620 * <code>map<string, string> environment_variables = 17;</code> 1621 */ 1622 @java.lang.Override containsEnvironmentVariables(java.lang.String key)1623 public boolean containsEnvironmentVariables(java.lang.String key) { 1624 if (key == null) { 1625 throw new NullPointerException("map key"); 1626 } 1627 return internalGetEnvironmentVariables().getMap().containsKey(key); 1628 } 1629 /** Use {@link #getEnvironmentVariablesMap()} instead. */ 1630 @java.lang.Override 1631 @java.lang.Deprecated getEnvironmentVariables()1632 public java.util.Map<java.lang.String, java.lang.String> getEnvironmentVariables() { 1633 return getEnvironmentVariablesMap(); 1634 } 1635 /** 1636 * 1637 * 1638 * <pre> 1639 * Environment variables that shall be available during function execution. 1640 * </pre> 1641 * 1642 * <code>map<string, string> environment_variables = 17;</code> 1643 */ 1644 @java.lang.Override getEnvironmentVariablesMap()1645 public java.util.Map<java.lang.String, java.lang.String> getEnvironmentVariablesMap() { 1646 return internalGetEnvironmentVariables().getMap(); 1647 } 1648 /** 1649 * 1650 * 1651 * <pre> 1652 * Environment variables that shall be available during function execution. 1653 * </pre> 1654 * 1655 * <code>map<string, string> environment_variables = 17;</code> 1656 */ 1657 @java.lang.Override getEnvironmentVariablesOrDefault( java.lang.String key, java.lang.String defaultValue)1658 public /* nullable */ java.lang.String getEnvironmentVariablesOrDefault( 1659 java.lang.String key, 1660 /* nullable */ 1661 java.lang.String defaultValue) { 1662 if (key == null) { 1663 throw new NullPointerException("map key"); 1664 } 1665 java.util.Map<java.lang.String, java.lang.String> map = 1666 internalGetEnvironmentVariables().getMap(); 1667 return map.containsKey(key) ? map.get(key) : defaultValue; 1668 } 1669 /** 1670 * 1671 * 1672 * <pre> 1673 * Environment variables that shall be available during function execution. 1674 * </pre> 1675 * 1676 * <code>map<string, string> environment_variables = 17;</code> 1677 */ 1678 @java.lang.Override getEnvironmentVariablesOrThrow(java.lang.String key)1679 public java.lang.String getEnvironmentVariablesOrThrow(java.lang.String key) { 1680 if (key == null) { 1681 throw new NullPointerException("map key"); 1682 } 1683 java.util.Map<java.lang.String, java.lang.String> map = 1684 internalGetEnvironmentVariables().getMap(); 1685 if (!map.containsKey(key)) { 1686 throw new java.lang.IllegalArgumentException(); 1687 } 1688 return map.get(key); 1689 } 1690 1691 public static final int BUILD_ENVIRONMENT_VARIABLES_FIELD_NUMBER = 28; 1692 1693 private static final class BuildEnvironmentVariablesDefaultEntryHolder { 1694 static final com.google.protobuf.MapEntry<java.lang.String, java.lang.String> defaultEntry = 1695 com.google.protobuf.MapEntry.<java.lang.String, java.lang.String>newDefaultInstance( 1696 com.google.cloud.functions.v1.FunctionsProto 1697 .internal_static_google_cloud_functions_v1_CloudFunction_BuildEnvironmentVariablesEntry_descriptor, 1698 com.google.protobuf.WireFormat.FieldType.STRING, 1699 "", 1700 com.google.protobuf.WireFormat.FieldType.STRING, 1701 ""); 1702 } 1703 1704 @SuppressWarnings("serial") 1705 private com.google.protobuf.MapField<java.lang.String, java.lang.String> 1706 buildEnvironmentVariables_; 1707 1708 private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetBuildEnvironmentVariables()1709 internalGetBuildEnvironmentVariables() { 1710 if (buildEnvironmentVariables_ == null) { 1711 return com.google.protobuf.MapField.emptyMapField( 1712 BuildEnvironmentVariablesDefaultEntryHolder.defaultEntry); 1713 } 1714 return buildEnvironmentVariables_; 1715 } 1716 getBuildEnvironmentVariablesCount()1717 public int getBuildEnvironmentVariablesCount() { 1718 return internalGetBuildEnvironmentVariables().getMap().size(); 1719 } 1720 /** 1721 * 1722 * 1723 * <pre> 1724 * Build environment variables that shall be available during build time. 1725 * </pre> 1726 * 1727 * <code>map<string, string> build_environment_variables = 28;</code> 1728 */ 1729 @java.lang.Override containsBuildEnvironmentVariables(java.lang.String key)1730 public boolean containsBuildEnvironmentVariables(java.lang.String key) { 1731 if (key == null) { 1732 throw new NullPointerException("map key"); 1733 } 1734 return internalGetBuildEnvironmentVariables().getMap().containsKey(key); 1735 } 1736 /** Use {@link #getBuildEnvironmentVariablesMap()} instead. */ 1737 @java.lang.Override 1738 @java.lang.Deprecated getBuildEnvironmentVariables()1739 public java.util.Map<java.lang.String, java.lang.String> getBuildEnvironmentVariables() { 1740 return getBuildEnvironmentVariablesMap(); 1741 } 1742 /** 1743 * 1744 * 1745 * <pre> 1746 * Build environment variables that shall be available during build time. 1747 * </pre> 1748 * 1749 * <code>map<string, string> build_environment_variables = 28;</code> 1750 */ 1751 @java.lang.Override getBuildEnvironmentVariablesMap()1752 public java.util.Map<java.lang.String, java.lang.String> getBuildEnvironmentVariablesMap() { 1753 return internalGetBuildEnvironmentVariables().getMap(); 1754 } 1755 /** 1756 * 1757 * 1758 * <pre> 1759 * Build environment variables that shall be available during build time. 1760 * </pre> 1761 * 1762 * <code>map<string, string> build_environment_variables = 28;</code> 1763 */ 1764 @java.lang.Override getBuildEnvironmentVariablesOrDefault( java.lang.String key, java.lang.String defaultValue)1765 public /* nullable */ java.lang.String getBuildEnvironmentVariablesOrDefault( 1766 java.lang.String key, 1767 /* nullable */ 1768 java.lang.String defaultValue) { 1769 if (key == null) { 1770 throw new NullPointerException("map key"); 1771 } 1772 java.util.Map<java.lang.String, java.lang.String> map = 1773 internalGetBuildEnvironmentVariables().getMap(); 1774 return map.containsKey(key) ? map.get(key) : defaultValue; 1775 } 1776 /** 1777 * 1778 * 1779 * <pre> 1780 * Build environment variables that shall be available during build time. 1781 * </pre> 1782 * 1783 * <code>map<string, string> build_environment_variables = 28;</code> 1784 */ 1785 @java.lang.Override getBuildEnvironmentVariablesOrThrow(java.lang.String key)1786 public java.lang.String getBuildEnvironmentVariablesOrThrow(java.lang.String key) { 1787 if (key == null) { 1788 throw new NullPointerException("map key"); 1789 } 1790 java.util.Map<java.lang.String, java.lang.String> map = 1791 internalGetBuildEnvironmentVariables().getMap(); 1792 if (!map.containsKey(key)) { 1793 throw new java.lang.IllegalArgumentException(); 1794 } 1795 return map.get(key); 1796 } 1797 1798 public static final int NETWORK_FIELD_NUMBER = 18; 1799 1800 @SuppressWarnings("serial") 1801 private volatile java.lang.Object network_ = ""; 1802 /** 1803 * 1804 * 1805 * <pre> 1806 * The Serverless VPC Access connector that this cloud function can connect 1807 * to. It can be either the fully qualified URI, or the short name of the 1808 * connector resource. If the connector name is used, the connector must 1809 * belong to the same project as the function. Otherwise, it must belong to a 1810 * project within the same organization. The format of this field is either 1811 * `projects/{project}/global/networks/{network}` or `{network}`, where 1812 * `{project}` is a project id where the network is defined, and `{network}` 1813 * is the short name of the network. 1814 * This field is mutually exclusive with `vpc_connector` and will be replaced 1815 * by it. 1816 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 1817 * more information on connecting Cloud projects. 1818 * </pre> 1819 * 1820 * <code>string network = 18;</code> 1821 * 1822 * @return The network. 1823 */ 1824 @java.lang.Override getNetwork()1825 public java.lang.String getNetwork() { 1826 java.lang.Object ref = network_; 1827 if (ref instanceof java.lang.String) { 1828 return (java.lang.String) ref; 1829 } else { 1830 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1831 java.lang.String s = bs.toStringUtf8(); 1832 network_ = s; 1833 return s; 1834 } 1835 } 1836 /** 1837 * 1838 * 1839 * <pre> 1840 * The Serverless VPC Access connector that this cloud function can connect 1841 * to. It can be either the fully qualified URI, or the short name of the 1842 * connector resource. If the connector name is used, the connector must 1843 * belong to the same project as the function. Otherwise, it must belong to a 1844 * project within the same organization. The format of this field is either 1845 * `projects/{project}/global/networks/{network}` or `{network}`, where 1846 * `{project}` is a project id where the network is defined, and `{network}` 1847 * is the short name of the network. 1848 * This field is mutually exclusive with `vpc_connector` and will be replaced 1849 * by it. 1850 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 1851 * more information on connecting Cloud projects. 1852 * </pre> 1853 * 1854 * <code>string network = 18;</code> 1855 * 1856 * @return The bytes for network. 1857 */ 1858 @java.lang.Override getNetworkBytes()1859 public com.google.protobuf.ByteString getNetworkBytes() { 1860 java.lang.Object ref = network_; 1861 if (ref instanceof java.lang.String) { 1862 com.google.protobuf.ByteString b = 1863 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1864 network_ = b; 1865 return b; 1866 } else { 1867 return (com.google.protobuf.ByteString) ref; 1868 } 1869 } 1870 1871 public static final int MAX_INSTANCES_FIELD_NUMBER = 20; 1872 private int maxInstances_ = 0; 1873 /** 1874 * 1875 * 1876 * <pre> 1877 * The limit on the maximum number of function instances that can coexist at a 1878 * given time. 1879 * In some cases, such as rapid traffic surges, Cloud Functions can for a 1880 * short period of time create more instances than the specified max 1881 * instances limit. If your function cannot tolerate this temporary behavior, 1882 * you might want to factor in a safety margin and set a lower max instances 1883 * value than your function can tolerate. 1884 * See the [Max 1885 * Instances](https://cloud.google.com/functions/docs/max-instances) Guide for 1886 * more details. 1887 * </pre> 1888 * 1889 * <code>int32 max_instances = 20;</code> 1890 * 1891 * @return The maxInstances. 1892 */ 1893 @java.lang.Override getMaxInstances()1894 public int getMaxInstances() { 1895 return maxInstances_; 1896 } 1897 1898 public static final int MIN_INSTANCES_FIELD_NUMBER = 32; 1899 private int minInstances_ = 0; 1900 /** 1901 * 1902 * 1903 * <pre> 1904 * A lower bound for the number function instances that can coexist at a 1905 * given time. 1906 * </pre> 1907 * 1908 * <code>int32 min_instances = 32;</code> 1909 * 1910 * @return The minInstances. 1911 */ 1912 @java.lang.Override getMinInstances()1913 public int getMinInstances() { 1914 return minInstances_; 1915 } 1916 1917 public static final int VPC_CONNECTOR_FIELD_NUMBER = 22; 1918 1919 @SuppressWarnings("serial") 1920 private volatile java.lang.Object vpcConnector_ = ""; 1921 /** 1922 * 1923 * 1924 * <pre> 1925 * The VPC Network Connector that this cloud function can connect to. It can 1926 * be either the fully qualified URI, or the short name of the network 1927 * connector resource. The format of this field is 1928 * `projects/*/locations/*/connectors/*` 1929 * This field is mutually exclusive with `network` field and will eventually 1930 * replace it. 1931 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 1932 * more information on connecting Cloud projects. 1933 * </pre> 1934 * 1935 * <code>string vpc_connector = 22;</code> 1936 * 1937 * @return The vpcConnector. 1938 */ 1939 @java.lang.Override getVpcConnector()1940 public java.lang.String getVpcConnector() { 1941 java.lang.Object ref = vpcConnector_; 1942 if (ref instanceof java.lang.String) { 1943 return (java.lang.String) ref; 1944 } else { 1945 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 1946 java.lang.String s = bs.toStringUtf8(); 1947 vpcConnector_ = s; 1948 return s; 1949 } 1950 } 1951 /** 1952 * 1953 * 1954 * <pre> 1955 * The VPC Network Connector that this cloud function can connect to. It can 1956 * be either the fully qualified URI, or the short name of the network 1957 * connector resource. The format of this field is 1958 * `projects/*/locations/*/connectors/*` 1959 * This field is mutually exclusive with `network` field and will eventually 1960 * replace it. 1961 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 1962 * more information on connecting Cloud projects. 1963 * </pre> 1964 * 1965 * <code>string vpc_connector = 22;</code> 1966 * 1967 * @return The bytes for vpcConnector. 1968 */ 1969 @java.lang.Override getVpcConnectorBytes()1970 public com.google.protobuf.ByteString getVpcConnectorBytes() { 1971 java.lang.Object ref = vpcConnector_; 1972 if (ref instanceof java.lang.String) { 1973 com.google.protobuf.ByteString b = 1974 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 1975 vpcConnector_ = b; 1976 return b; 1977 } else { 1978 return (com.google.protobuf.ByteString) ref; 1979 } 1980 } 1981 1982 public static final int VPC_CONNECTOR_EGRESS_SETTINGS_FIELD_NUMBER = 23; 1983 private int vpcConnectorEgressSettings_ = 0; 1984 /** 1985 * 1986 * 1987 * <pre> 1988 * The egress settings for the connector, controlling what traffic is diverted 1989 * through it. 1990 * </pre> 1991 * 1992 * <code> 1993 * .google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings vpc_connector_egress_settings = 23; 1994 * </code> 1995 * 1996 * @return The enum numeric value on the wire for vpcConnectorEgressSettings. 1997 */ 1998 @java.lang.Override getVpcConnectorEgressSettingsValue()1999 public int getVpcConnectorEgressSettingsValue() { 2000 return vpcConnectorEgressSettings_; 2001 } 2002 /** 2003 * 2004 * 2005 * <pre> 2006 * The egress settings for the connector, controlling what traffic is diverted 2007 * through it. 2008 * </pre> 2009 * 2010 * <code> 2011 * .google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings vpc_connector_egress_settings = 23; 2012 * </code> 2013 * 2014 * @return The vpcConnectorEgressSettings. 2015 */ 2016 @java.lang.Override 2017 public com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings getVpcConnectorEgressSettings()2018 getVpcConnectorEgressSettings() { 2019 com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings result = 2020 com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings.forNumber( 2021 vpcConnectorEgressSettings_); 2022 return result == null 2023 ? com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings.UNRECOGNIZED 2024 : result; 2025 } 2026 2027 public static final int INGRESS_SETTINGS_FIELD_NUMBER = 24; 2028 private int ingressSettings_ = 0; 2029 /** 2030 * 2031 * 2032 * <pre> 2033 * The ingress settings for the function, controlling what traffic can reach 2034 * it. 2035 * </pre> 2036 * 2037 * <code>.google.cloud.functions.v1.CloudFunction.IngressSettings ingress_settings = 24;</code> 2038 * 2039 * @return The enum numeric value on the wire for ingressSettings. 2040 */ 2041 @java.lang.Override getIngressSettingsValue()2042 public int getIngressSettingsValue() { 2043 return ingressSettings_; 2044 } 2045 /** 2046 * 2047 * 2048 * <pre> 2049 * The ingress settings for the function, controlling what traffic can reach 2050 * it. 2051 * </pre> 2052 * 2053 * <code>.google.cloud.functions.v1.CloudFunction.IngressSettings ingress_settings = 24;</code> 2054 * 2055 * @return The ingressSettings. 2056 */ 2057 @java.lang.Override getIngressSettings()2058 public com.google.cloud.functions.v1.CloudFunction.IngressSettings getIngressSettings() { 2059 com.google.cloud.functions.v1.CloudFunction.IngressSettings result = 2060 com.google.cloud.functions.v1.CloudFunction.IngressSettings.forNumber(ingressSettings_); 2061 return result == null 2062 ? com.google.cloud.functions.v1.CloudFunction.IngressSettings.UNRECOGNIZED 2063 : result; 2064 } 2065 2066 public static final int KMS_KEY_NAME_FIELD_NUMBER = 25; 2067 2068 @SuppressWarnings("serial") 2069 private volatile java.lang.Object kmsKeyName_ = ""; 2070 /** 2071 * 2072 * 2073 * <pre> 2074 * Resource name of a KMS crypto key (managed by the user) used to 2075 * encrypt/decrypt function resources. 2076 * It must match the pattern 2077 * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. 2078 * If specified, you must also provide an artifact registry repository using 2079 * the `docker_repository` field that was created with the same KMS crypto 2080 * key. 2081 * The following service accounts need to be granted the role 'Cloud KMS 2082 * CryptoKey Encrypter/Decrypter (roles/cloudkms.cryptoKeyEncrypterDecrypter)' 2083 * on the Key/KeyRing/Project/Organization (least access preferred). 2084 * 1. Google Cloud Functions service account 2085 * (service-{project_number}@gcf-admin-robot.iam.gserviceaccount.com) - 2086 * Required to protect the function's image. 2087 * 2. Google Storage service account 2088 * (service-{project_number}@gs-project-accounts.iam.gserviceaccount.com) - 2089 * Required to protect the function's source code. 2090 * If this service account does not exist, deploying a function without a 2091 * KMS key or retrieving the service agent name provisions it. For more 2092 * information, see 2093 * https://cloud.google.com/storage/docs/projects#service-agents and 2094 * https://cloud.google.com/storage/docs/getting-service-agent#gsutil. 2095 * Google Cloud Functions delegates access to service agents to protect 2096 * function resources in internal projects that are not accessible by the 2097 * end user. 2098 * </pre> 2099 * 2100 * <code>string kms_key_name = 25 [(.google.api.resource_reference) = { ... }</code> 2101 * 2102 * @return The kmsKeyName. 2103 */ 2104 @java.lang.Override getKmsKeyName()2105 public java.lang.String getKmsKeyName() { 2106 java.lang.Object ref = kmsKeyName_; 2107 if (ref instanceof java.lang.String) { 2108 return (java.lang.String) ref; 2109 } else { 2110 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 2111 java.lang.String s = bs.toStringUtf8(); 2112 kmsKeyName_ = s; 2113 return s; 2114 } 2115 } 2116 /** 2117 * 2118 * 2119 * <pre> 2120 * Resource name of a KMS crypto key (managed by the user) used to 2121 * encrypt/decrypt function resources. 2122 * It must match the pattern 2123 * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. 2124 * If specified, you must also provide an artifact registry repository using 2125 * the `docker_repository` field that was created with the same KMS crypto 2126 * key. 2127 * The following service accounts need to be granted the role 'Cloud KMS 2128 * CryptoKey Encrypter/Decrypter (roles/cloudkms.cryptoKeyEncrypterDecrypter)' 2129 * on the Key/KeyRing/Project/Organization (least access preferred). 2130 * 1. Google Cloud Functions service account 2131 * (service-{project_number}@gcf-admin-robot.iam.gserviceaccount.com) - 2132 * Required to protect the function's image. 2133 * 2. Google Storage service account 2134 * (service-{project_number}@gs-project-accounts.iam.gserviceaccount.com) - 2135 * Required to protect the function's source code. 2136 * If this service account does not exist, deploying a function without a 2137 * KMS key or retrieving the service agent name provisions it. For more 2138 * information, see 2139 * https://cloud.google.com/storage/docs/projects#service-agents and 2140 * https://cloud.google.com/storage/docs/getting-service-agent#gsutil. 2141 * Google Cloud Functions delegates access to service agents to protect 2142 * function resources in internal projects that are not accessible by the 2143 * end user. 2144 * </pre> 2145 * 2146 * <code>string kms_key_name = 25 [(.google.api.resource_reference) = { ... }</code> 2147 * 2148 * @return The bytes for kmsKeyName. 2149 */ 2150 @java.lang.Override getKmsKeyNameBytes()2151 public com.google.protobuf.ByteString getKmsKeyNameBytes() { 2152 java.lang.Object ref = kmsKeyName_; 2153 if (ref instanceof java.lang.String) { 2154 com.google.protobuf.ByteString b = 2155 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 2156 kmsKeyName_ = b; 2157 return b; 2158 } else { 2159 return (com.google.protobuf.ByteString) ref; 2160 } 2161 } 2162 2163 public static final int BUILD_WORKER_POOL_FIELD_NUMBER = 26; 2164 2165 @SuppressWarnings("serial") 2166 private volatile java.lang.Object buildWorkerPool_ = ""; 2167 /** 2168 * 2169 * 2170 * <pre> 2171 * Name of the Cloud Build Custom Worker Pool that should be used to build the 2172 * function. The format of this field is 2173 * `projects/{project}/locations/{region}/workerPools/{workerPool}` where 2174 * `{project}` and `{region}` are the project id and region respectively where 2175 * the worker pool is defined and `{workerPool}` is the short name of the 2176 * worker pool. 2177 * If the project id is not the same as the function, then the Cloud 2178 * Functions Service Agent 2179 * (`service-<project_number>@gcf-admin-robot.iam.gserviceaccount.com`) must 2180 * be granted the role Cloud Build Custom Workers Builder 2181 * (`roles/cloudbuild.customworkers.builder`) in the project. 2182 * </pre> 2183 * 2184 * <code>string build_worker_pool = 26;</code> 2185 * 2186 * @return The buildWorkerPool. 2187 */ 2188 @java.lang.Override getBuildWorkerPool()2189 public java.lang.String getBuildWorkerPool() { 2190 java.lang.Object ref = buildWorkerPool_; 2191 if (ref instanceof java.lang.String) { 2192 return (java.lang.String) ref; 2193 } else { 2194 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 2195 java.lang.String s = bs.toStringUtf8(); 2196 buildWorkerPool_ = s; 2197 return s; 2198 } 2199 } 2200 /** 2201 * 2202 * 2203 * <pre> 2204 * Name of the Cloud Build Custom Worker Pool that should be used to build the 2205 * function. The format of this field is 2206 * `projects/{project}/locations/{region}/workerPools/{workerPool}` where 2207 * `{project}` and `{region}` are the project id and region respectively where 2208 * the worker pool is defined and `{workerPool}` is the short name of the 2209 * worker pool. 2210 * If the project id is not the same as the function, then the Cloud 2211 * Functions Service Agent 2212 * (`service-<project_number>@gcf-admin-robot.iam.gserviceaccount.com`) must 2213 * be granted the role Cloud Build Custom Workers Builder 2214 * (`roles/cloudbuild.customworkers.builder`) in the project. 2215 * </pre> 2216 * 2217 * <code>string build_worker_pool = 26;</code> 2218 * 2219 * @return The bytes for buildWorkerPool. 2220 */ 2221 @java.lang.Override getBuildWorkerPoolBytes()2222 public com.google.protobuf.ByteString getBuildWorkerPoolBytes() { 2223 java.lang.Object ref = buildWorkerPool_; 2224 if (ref instanceof java.lang.String) { 2225 com.google.protobuf.ByteString b = 2226 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 2227 buildWorkerPool_ = b; 2228 return b; 2229 } else { 2230 return (com.google.protobuf.ByteString) ref; 2231 } 2232 } 2233 2234 public static final int BUILD_ID_FIELD_NUMBER = 27; 2235 2236 @SuppressWarnings("serial") 2237 private volatile java.lang.Object buildId_ = ""; 2238 /** 2239 * 2240 * 2241 * <pre> 2242 * Output only. The Cloud Build ID of the latest successful deployment of the 2243 * function. 2244 * </pre> 2245 * 2246 * <code>string build_id = 27 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 2247 * 2248 * @return The buildId. 2249 */ 2250 @java.lang.Override getBuildId()2251 public java.lang.String getBuildId() { 2252 java.lang.Object ref = buildId_; 2253 if (ref instanceof java.lang.String) { 2254 return (java.lang.String) ref; 2255 } else { 2256 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 2257 java.lang.String s = bs.toStringUtf8(); 2258 buildId_ = s; 2259 return s; 2260 } 2261 } 2262 /** 2263 * 2264 * 2265 * <pre> 2266 * Output only. The Cloud Build ID of the latest successful deployment of the 2267 * function. 2268 * </pre> 2269 * 2270 * <code>string build_id = 27 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 2271 * 2272 * @return The bytes for buildId. 2273 */ 2274 @java.lang.Override getBuildIdBytes()2275 public com.google.protobuf.ByteString getBuildIdBytes() { 2276 java.lang.Object ref = buildId_; 2277 if (ref instanceof java.lang.String) { 2278 com.google.protobuf.ByteString b = 2279 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 2280 buildId_ = b; 2281 return b; 2282 } else { 2283 return (com.google.protobuf.ByteString) ref; 2284 } 2285 } 2286 2287 public static final int BUILD_NAME_FIELD_NUMBER = 33; 2288 2289 @SuppressWarnings("serial") 2290 private volatile java.lang.Object buildName_ = ""; 2291 /** 2292 * 2293 * 2294 * <pre> 2295 * Output only. The Cloud Build Name of the function deployment. 2296 * `projects/<project-number>/locations/<region>/builds/<build-id>`. 2297 * </pre> 2298 * 2299 * <code>string build_name = 33 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 2300 * 2301 * @return The buildName. 2302 */ 2303 @java.lang.Override getBuildName()2304 public java.lang.String getBuildName() { 2305 java.lang.Object ref = buildName_; 2306 if (ref instanceof java.lang.String) { 2307 return (java.lang.String) ref; 2308 } else { 2309 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 2310 java.lang.String s = bs.toStringUtf8(); 2311 buildName_ = s; 2312 return s; 2313 } 2314 } 2315 /** 2316 * 2317 * 2318 * <pre> 2319 * Output only. The Cloud Build Name of the function deployment. 2320 * `projects/<project-number>/locations/<region>/builds/<build-id>`. 2321 * </pre> 2322 * 2323 * <code>string build_name = 33 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 2324 * 2325 * @return The bytes for buildName. 2326 */ 2327 @java.lang.Override getBuildNameBytes()2328 public com.google.protobuf.ByteString getBuildNameBytes() { 2329 java.lang.Object ref = buildName_; 2330 if (ref instanceof java.lang.String) { 2331 com.google.protobuf.ByteString b = 2332 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 2333 buildName_ = b; 2334 return b; 2335 } else { 2336 return (com.google.protobuf.ByteString) ref; 2337 } 2338 } 2339 2340 public static final int SECRET_ENVIRONMENT_VARIABLES_FIELD_NUMBER = 29; 2341 2342 @SuppressWarnings("serial") 2343 private java.util.List<com.google.cloud.functions.v1.SecretEnvVar> secretEnvironmentVariables_; 2344 /** 2345 * 2346 * 2347 * <pre> 2348 * Secret environment variables configuration. 2349 * </pre> 2350 * 2351 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 2352 * </code> 2353 */ 2354 @java.lang.Override 2355 public java.util.List<com.google.cloud.functions.v1.SecretEnvVar> getSecretEnvironmentVariablesList()2356 getSecretEnvironmentVariablesList() { 2357 return secretEnvironmentVariables_; 2358 } 2359 /** 2360 * 2361 * 2362 * <pre> 2363 * Secret environment variables configuration. 2364 * </pre> 2365 * 2366 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 2367 * </code> 2368 */ 2369 @java.lang.Override 2370 public java.util.List<? extends com.google.cloud.functions.v1.SecretEnvVarOrBuilder> getSecretEnvironmentVariablesOrBuilderList()2371 getSecretEnvironmentVariablesOrBuilderList() { 2372 return secretEnvironmentVariables_; 2373 } 2374 /** 2375 * 2376 * 2377 * <pre> 2378 * Secret environment variables configuration. 2379 * </pre> 2380 * 2381 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 2382 * </code> 2383 */ 2384 @java.lang.Override getSecretEnvironmentVariablesCount()2385 public int getSecretEnvironmentVariablesCount() { 2386 return secretEnvironmentVariables_.size(); 2387 } 2388 /** 2389 * 2390 * 2391 * <pre> 2392 * Secret environment variables configuration. 2393 * </pre> 2394 * 2395 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 2396 * </code> 2397 */ 2398 @java.lang.Override getSecretEnvironmentVariables(int index)2399 public com.google.cloud.functions.v1.SecretEnvVar getSecretEnvironmentVariables(int index) { 2400 return secretEnvironmentVariables_.get(index); 2401 } 2402 /** 2403 * 2404 * 2405 * <pre> 2406 * Secret environment variables configuration. 2407 * </pre> 2408 * 2409 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 2410 * </code> 2411 */ 2412 @java.lang.Override getSecretEnvironmentVariablesOrBuilder( int index)2413 public com.google.cloud.functions.v1.SecretEnvVarOrBuilder getSecretEnvironmentVariablesOrBuilder( 2414 int index) { 2415 return secretEnvironmentVariables_.get(index); 2416 } 2417 2418 public static final int SECRET_VOLUMES_FIELD_NUMBER = 30; 2419 2420 @SuppressWarnings("serial") 2421 private java.util.List<com.google.cloud.functions.v1.SecretVolume> secretVolumes_; 2422 /** 2423 * 2424 * 2425 * <pre> 2426 * Secret volumes configuration. 2427 * </pre> 2428 * 2429 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 2430 */ 2431 @java.lang.Override getSecretVolumesList()2432 public java.util.List<com.google.cloud.functions.v1.SecretVolume> getSecretVolumesList() { 2433 return secretVolumes_; 2434 } 2435 /** 2436 * 2437 * 2438 * <pre> 2439 * Secret volumes configuration. 2440 * </pre> 2441 * 2442 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 2443 */ 2444 @java.lang.Override 2445 public java.util.List<? extends com.google.cloud.functions.v1.SecretVolumeOrBuilder> getSecretVolumesOrBuilderList()2446 getSecretVolumesOrBuilderList() { 2447 return secretVolumes_; 2448 } 2449 /** 2450 * 2451 * 2452 * <pre> 2453 * Secret volumes configuration. 2454 * </pre> 2455 * 2456 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 2457 */ 2458 @java.lang.Override getSecretVolumesCount()2459 public int getSecretVolumesCount() { 2460 return secretVolumes_.size(); 2461 } 2462 /** 2463 * 2464 * 2465 * <pre> 2466 * Secret volumes configuration. 2467 * </pre> 2468 * 2469 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 2470 */ 2471 @java.lang.Override getSecretVolumes(int index)2472 public com.google.cloud.functions.v1.SecretVolume getSecretVolumes(int index) { 2473 return secretVolumes_.get(index); 2474 } 2475 /** 2476 * 2477 * 2478 * <pre> 2479 * Secret volumes configuration. 2480 * </pre> 2481 * 2482 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 2483 */ 2484 @java.lang.Override getSecretVolumesOrBuilder(int index)2485 public com.google.cloud.functions.v1.SecretVolumeOrBuilder getSecretVolumesOrBuilder(int index) { 2486 return secretVolumes_.get(index); 2487 } 2488 2489 public static final int SOURCE_TOKEN_FIELD_NUMBER = 31; 2490 2491 @SuppressWarnings("serial") 2492 private volatile java.lang.Object sourceToken_ = ""; 2493 /** 2494 * 2495 * 2496 * <pre> 2497 * Input only. An identifier for Firebase function sources. Disclaimer: This 2498 * field is only supported for Firebase function deployments. 2499 * </pre> 2500 * 2501 * <code>string source_token = 31 [(.google.api.field_behavior) = INPUT_ONLY];</code> 2502 * 2503 * @return The sourceToken. 2504 */ 2505 @java.lang.Override getSourceToken()2506 public java.lang.String getSourceToken() { 2507 java.lang.Object ref = sourceToken_; 2508 if (ref instanceof java.lang.String) { 2509 return (java.lang.String) ref; 2510 } else { 2511 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 2512 java.lang.String s = bs.toStringUtf8(); 2513 sourceToken_ = s; 2514 return s; 2515 } 2516 } 2517 /** 2518 * 2519 * 2520 * <pre> 2521 * Input only. An identifier for Firebase function sources. Disclaimer: This 2522 * field is only supported for Firebase function deployments. 2523 * </pre> 2524 * 2525 * <code>string source_token = 31 [(.google.api.field_behavior) = INPUT_ONLY];</code> 2526 * 2527 * @return The bytes for sourceToken. 2528 */ 2529 @java.lang.Override getSourceTokenBytes()2530 public com.google.protobuf.ByteString getSourceTokenBytes() { 2531 java.lang.Object ref = sourceToken_; 2532 if (ref instanceof java.lang.String) { 2533 com.google.protobuf.ByteString b = 2534 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 2535 sourceToken_ = b; 2536 return b; 2537 } else { 2538 return (com.google.protobuf.ByteString) ref; 2539 } 2540 } 2541 2542 public static final int DOCKER_REPOSITORY_FIELD_NUMBER = 34; 2543 2544 @SuppressWarnings("serial") 2545 private volatile java.lang.Object dockerRepository_ = ""; 2546 /** 2547 * 2548 * 2549 * <pre> 2550 * User managed repository created in Artifact Registry optionally with a 2551 * customer managed encryption key. If specified, deployments will use 2552 * Artifact Registry. If unspecified and the deployment is eligible to use 2553 * Artifact Registry, GCF will create and use a repository named 2554 * 'gcf-artifacts' for every deployed region. This is the repository to which 2555 * the function docker image is pushed after it is built by Cloud Build. 2556 * It must match the pattern 2557 * `projects/{project}/locations/{location}/repositories/{repository}`. 2558 * Cross-project repositories are not supported. 2559 * Cross-location repositories are not supported. 2560 * Repository format must be 'DOCKER'. 2561 * </pre> 2562 * 2563 * <code>string docker_repository = 34 [(.google.api.resource_reference) = { ... }</code> 2564 * 2565 * @return The dockerRepository. 2566 */ 2567 @java.lang.Override getDockerRepository()2568 public java.lang.String getDockerRepository() { 2569 java.lang.Object ref = dockerRepository_; 2570 if (ref instanceof java.lang.String) { 2571 return (java.lang.String) ref; 2572 } else { 2573 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 2574 java.lang.String s = bs.toStringUtf8(); 2575 dockerRepository_ = s; 2576 return s; 2577 } 2578 } 2579 /** 2580 * 2581 * 2582 * <pre> 2583 * User managed repository created in Artifact Registry optionally with a 2584 * customer managed encryption key. If specified, deployments will use 2585 * Artifact Registry. If unspecified and the deployment is eligible to use 2586 * Artifact Registry, GCF will create and use a repository named 2587 * 'gcf-artifacts' for every deployed region. This is the repository to which 2588 * the function docker image is pushed after it is built by Cloud Build. 2589 * It must match the pattern 2590 * `projects/{project}/locations/{location}/repositories/{repository}`. 2591 * Cross-project repositories are not supported. 2592 * Cross-location repositories are not supported. 2593 * Repository format must be 'DOCKER'. 2594 * </pre> 2595 * 2596 * <code>string docker_repository = 34 [(.google.api.resource_reference) = { ... }</code> 2597 * 2598 * @return The bytes for dockerRepository. 2599 */ 2600 @java.lang.Override getDockerRepositoryBytes()2601 public com.google.protobuf.ByteString getDockerRepositoryBytes() { 2602 java.lang.Object ref = dockerRepository_; 2603 if (ref instanceof java.lang.String) { 2604 com.google.protobuf.ByteString b = 2605 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 2606 dockerRepository_ = b; 2607 return b; 2608 } else { 2609 return (com.google.protobuf.ByteString) ref; 2610 } 2611 } 2612 2613 public static final int DOCKER_REGISTRY_FIELD_NUMBER = 35; 2614 private int dockerRegistry_ = 0; 2615 /** 2616 * 2617 * 2618 * <pre> 2619 * Docker Registry to use for this deployment. 2620 * If `docker_repository` field is specified, this field is automatically 2621 * set as `ARTIFACT_REGISTRY`. 2622 * If unspecified, it currently defaults to `CONTAINER_REGISTRY`. 2623 * This field may be overridden by the backend for eligible deployments. 2624 * </pre> 2625 * 2626 * <code>.google.cloud.functions.v1.CloudFunction.DockerRegistry docker_registry = 35;</code> 2627 * 2628 * @return The enum numeric value on the wire for dockerRegistry. 2629 */ 2630 @java.lang.Override getDockerRegistryValue()2631 public int getDockerRegistryValue() { 2632 return dockerRegistry_; 2633 } 2634 /** 2635 * 2636 * 2637 * <pre> 2638 * Docker Registry to use for this deployment. 2639 * If `docker_repository` field is specified, this field is automatically 2640 * set as `ARTIFACT_REGISTRY`. 2641 * If unspecified, it currently defaults to `CONTAINER_REGISTRY`. 2642 * This field may be overridden by the backend for eligible deployments. 2643 * </pre> 2644 * 2645 * <code>.google.cloud.functions.v1.CloudFunction.DockerRegistry docker_registry = 35;</code> 2646 * 2647 * @return The dockerRegistry. 2648 */ 2649 @java.lang.Override getDockerRegistry()2650 public com.google.cloud.functions.v1.CloudFunction.DockerRegistry getDockerRegistry() { 2651 com.google.cloud.functions.v1.CloudFunction.DockerRegistry result = 2652 com.google.cloud.functions.v1.CloudFunction.DockerRegistry.forNumber(dockerRegistry_); 2653 return result == null 2654 ? com.google.cloud.functions.v1.CloudFunction.DockerRegistry.UNRECOGNIZED 2655 : result; 2656 } 2657 2658 private byte memoizedIsInitialized = -1; 2659 2660 @java.lang.Override isInitialized()2661 public final boolean isInitialized() { 2662 byte isInitialized = memoizedIsInitialized; 2663 if (isInitialized == 1) return true; 2664 if (isInitialized == 0) return false; 2665 2666 memoizedIsInitialized = 1; 2667 return true; 2668 } 2669 2670 @java.lang.Override writeTo(com.google.protobuf.CodedOutputStream output)2671 public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { 2672 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { 2673 com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); 2674 } 2675 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { 2676 com.google.protobuf.GeneratedMessageV3.writeString(output, 2, description_); 2677 } 2678 if (sourceCodeCase_ == 3) { 2679 com.google.protobuf.GeneratedMessageV3.writeString(output, 3, sourceCode_); 2680 } 2681 if (sourceCodeCase_ == 4) { 2682 output.writeMessage(4, (com.google.cloud.functions.v1.SourceRepository) sourceCode_); 2683 } 2684 if (triggerCase_ == 5) { 2685 output.writeMessage(5, (com.google.cloud.functions.v1.HttpsTrigger) trigger_); 2686 } 2687 if (triggerCase_ == 6) { 2688 output.writeMessage(6, (com.google.cloud.functions.v1.EventTrigger) trigger_); 2689 } 2690 if (status_ 2691 != com.google.cloud.functions.v1.CloudFunctionStatus.CLOUD_FUNCTION_STATUS_UNSPECIFIED 2692 .getNumber()) { 2693 output.writeEnum(7, status_); 2694 } 2695 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(entryPoint_)) { 2696 com.google.protobuf.GeneratedMessageV3.writeString(output, 8, entryPoint_); 2697 } 2698 if (timeout_ != null) { 2699 output.writeMessage(9, getTimeout()); 2700 } 2701 if (availableMemoryMb_ != 0) { 2702 output.writeInt32(10, availableMemoryMb_); 2703 } 2704 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccountEmail_)) { 2705 com.google.protobuf.GeneratedMessageV3.writeString(output, 11, serviceAccountEmail_); 2706 } 2707 if (updateTime_ != null) { 2708 output.writeMessage(12, getUpdateTime()); 2709 } 2710 if (versionId_ != 0L) { 2711 output.writeInt64(14, versionId_); 2712 } 2713 com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( 2714 output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 15); 2715 if (sourceCodeCase_ == 16) { 2716 com.google.protobuf.GeneratedMessageV3.writeString(output, 16, sourceCode_); 2717 } 2718 com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( 2719 output, 2720 internalGetEnvironmentVariables(), 2721 EnvironmentVariablesDefaultEntryHolder.defaultEntry, 2722 17); 2723 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(network_)) { 2724 com.google.protobuf.GeneratedMessageV3.writeString(output, 18, network_); 2725 } 2726 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(runtime_)) { 2727 com.google.protobuf.GeneratedMessageV3.writeString(output, 19, runtime_); 2728 } 2729 if (maxInstances_ != 0) { 2730 output.writeInt32(20, maxInstances_); 2731 } 2732 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(vpcConnector_)) { 2733 com.google.protobuf.GeneratedMessageV3.writeString(output, 22, vpcConnector_); 2734 } 2735 if (vpcConnectorEgressSettings_ 2736 != com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings 2737 .VPC_CONNECTOR_EGRESS_SETTINGS_UNSPECIFIED 2738 .getNumber()) { 2739 output.writeEnum(23, vpcConnectorEgressSettings_); 2740 } 2741 if (ingressSettings_ 2742 != com.google.cloud.functions.v1.CloudFunction.IngressSettings.INGRESS_SETTINGS_UNSPECIFIED 2743 .getNumber()) { 2744 output.writeEnum(24, ingressSettings_); 2745 } 2746 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) { 2747 com.google.protobuf.GeneratedMessageV3.writeString(output, 25, kmsKeyName_); 2748 } 2749 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(buildWorkerPool_)) { 2750 com.google.protobuf.GeneratedMessageV3.writeString(output, 26, buildWorkerPool_); 2751 } 2752 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(buildId_)) { 2753 com.google.protobuf.GeneratedMessageV3.writeString(output, 27, buildId_); 2754 } 2755 com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( 2756 output, 2757 internalGetBuildEnvironmentVariables(), 2758 BuildEnvironmentVariablesDefaultEntryHolder.defaultEntry, 2759 28); 2760 for (int i = 0; i < secretEnvironmentVariables_.size(); i++) { 2761 output.writeMessage(29, secretEnvironmentVariables_.get(i)); 2762 } 2763 for (int i = 0; i < secretVolumes_.size(); i++) { 2764 output.writeMessage(30, secretVolumes_.get(i)); 2765 } 2766 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sourceToken_)) { 2767 com.google.protobuf.GeneratedMessageV3.writeString(output, 31, sourceToken_); 2768 } 2769 if (minInstances_ != 0) { 2770 output.writeInt32(32, minInstances_); 2771 } 2772 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(buildName_)) { 2773 com.google.protobuf.GeneratedMessageV3.writeString(output, 33, buildName_); 2774 } 2775 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(dockerRepository_)) { 2776 com.google.protobuf.GeneratedMessageV3.writeString(output, 34, dockerRepository_); 2777 } 2778 if (dockerRegistry_ 2779 != com.google.cloud.functions.v1.CloudFunction.DockerRegistry.DOCKER_REGISTRY_UNSPECIFIED 2780 .getNumber()) { 2781 output.writeEnum(35, dockerRegistry_); 2782 } 2783 getUnknownFields().writeTo(output); 2784 } 2785 2786 @java.lang.Override getSerializedSize()2787 public int getSerializedSize() { 2788 int size = memoizedSize; 2789 if (size != -1) return size; 2790 2791 size = 0; 2792 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { 2793 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); 2794 } 2795 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { 2796 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, description_); 2797 } 2798 if (sourceCodeCase_ == 3) { 2799 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, sourceCode_); 2800 } 2801 if (sourceCodeCase_ == 4) { 2802 size += 2803 com.google.protobuf.CodedOutputStream.computeMessageSize( 2804 4, (com.google.cloud.functions.v1.SourceRepository) sourceCode_); 2805 } 2806 if (triggerCase_ == 5) { 2807 size += 2808 com.google.protobuf.CodedOutputStream.computeMessageSize( 2809 5, (com.google.cloud.functions.v1.HttpsTrigger) trigger_); 2810 } 2811 if (triggerCase_ == 6) { 2812 size += 2813 com.google.protobuf.CodedOutputStream.computeMessageSize( 2814 6, (com.google.cloud.functions.v1.EventTrigger) trigger_); 2815 } 2816 if (status_ 2817 != com.google.cloud.functions.v1.CloudFunctionStatus.CLOUD_FUNCTION_STATUS_UNSPECIFIED 2818 .getNumber()) { 2819 size += com.google.protobuf.CodedOutputStream.computeEnumSize(7, status_); 2820 } 2821 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(entryPoint_)) { 2822 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, entryPoint_); 2823 } 2824 if (timeout_ != null) { 2825 size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getTimeout()); 2826 } 2827 if (availableMemoryMb_ != 0) { 2828 size += com.google.protobuf.CodedOutputStream.computeInt32Size(10, availableMemoryMb_); 2829 } 2830 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccountEmail_)) { 2831 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(11, serviceAccountEmail_); 2832 } 2833 if (updateTime_ != null) { 2834 size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, getUpdateTime()); 2835 } 2836 if (versionId_ != 0L) { 2837 size += com.google.protobuf.CodedOutputStream.computeInt64Size(14, versionId_); 2838 } 2839 for (java.util.Map.Entry<java.lang.String, java.lang.String> entry : 2840 internalGetLabels().getMap().entrySet()) { 2841 com.google.protobuf.MapEntry<java.lang.String, java.lang.String> labels__ = 2842 LabelsDefaultEntryHolder.defaultEntry 2843 .newBuilderForType() 2844 .setKey(entry.getKey()) 2845 .setValue(entry.getValue()) 2846 .build(); 2847 size += com.google.protobuf.CodedOutputStream.computeMessageSize(15, labels__); 2848 } 2849 if (sourceCodeCase_ == 16) { 2850 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(16, sourceCode_); 2851 } 2852 for (java.util.Map.Entry<java.lang.String, java.lang.String> entry : 2853 internalGetEnvironmentVariables().getMap().entrySet()) { 2854 com.google.protobuf.MapEntry<java.lang.String, java.lang.String> environmentVariables__ = 2855 EnvironmentVariablesDefaultEntryHolder.defaultEntry 2856 .newBuilderForType() 2857 .setKey(entry.getKey()) 2858 .setValue(entry.getValue()) 2859 .build(); 2860 size += com.google.protobuf.CodedOutputStream.computeMessageSize(17, environmentVariables__); 2861 } 2862 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(network_)) { 2863 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(18, network_); 2864 } 2865 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(runtime_)) { 2866 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(19, runtime_); 2867 } 2868 if (maxInstances_ != 0) { 2869 size += com.google.protobuf.CodedOutputStream.computeInt32Size(20, maxInstances_); 2870 } 2871 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(vpcConnector_)) { 2872 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(22, vpcConnector_); 2873 } 2874 if (vpcConnectorEgressSettings_ 2875 != com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings 2876 .VPC_CONNECTOR_EGRESS_SETTINGS_UNSPECIFIED 2877 .getNumber()) { 2878 size += 2879 com.google.protobuf.CodedOutputStream.computeEnumSize(23, vpcConnectorEgressSettings_); 2880 } 2881 if (ingressSettings_ 2882 != com.google.cloud.functions.v1.CloudFunction.IngressSettings.INGRESS_SETTINGS_UNSPECIFIED 2883 .getNumber()) { 2884 size += com.google.protobuf.CodedOutputStream.computeEnumSize(24, ingressSettings_); 2885 } 2886 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) { 2887 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(25, kmsKeyName_); 2888 } 2889 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(buildWorkerPool_)) { 2890 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(26, buildWorkerPool_); 2891 } 2892 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(buildId_)) { 2893 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(27, buildId_); 2894 } 2895 for (java.util.Map.Entry<java.lang.String, java.lang.String> entry : 2896 internalGetBuildEnvironmentVariables().getMap().entrySet()) { 2897 com.google.protobuf.MapEntry<java.lang.String, java.lang.String> buildEnvironmentVariables__ = 2898 BuildEnvironmentVariablesDefaultEntryHolder.defaultEntry 2899 .newBuilderForType() 2900 .setKey(entry.getKey()) 2901 .setValue(entry.getValue()) 2902 .build(); 2903 size += 2904 com.google.protobuf.CodedOutputStream.computeMessageSize(28, buildEnvironmentVariables__); 2905 } 2906 for (int i = 0; i < secretEnvironmentVariables_.size(); i++) { 2907 size += 2908 com.google.protobuf.CodedOutputStream.computeMessageSize( 2909 29, secretEnvironmentVariables_.get(i)); 2910 } 2911 for (int i = 0; i < secretVolumes_.size(); i++) { 2912 size += com.google.protobuf.CodedOutputStream.computeMessageSize(30, secretVolumes_.get(i)); 2913 } 2914 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sourceToken_)) { 2915 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(31, sourceToken_); 2916 } 2917 if (minInstances_ != 0) { 2918 size += com.google.protobuf.CodedOutputStream.computeInt32Size(32, minInstances_); 2919 } 2920 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(buildName_)) { 2921 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(33, buildName_); 2922 } 2923 if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(dockerRepository_)) { 2924 size += com.google.protobuf.GeneratedMessageV3.computeStringSize(34, dockerRepository_); 2925 } 2926 if (dockerRegistry_ 2927 != com.google.cloud.functions.v1.CloudFunction.DockerRegistry.DOCKER_REGISTRY_UNSPECIFIED 2928 .getNumber()) { 2929 size += com.google.protobuf.CodedOutputStream.computeEnumSize(35, dockerRegistry_); 2930 } 2931 size += getUnknownFields().getSerializedSize(); 2932 memoizedSize = size; 2933 return size; 2934 } 2935 2936 @java.lang.Override equals(final java.lang.Object obj)2937 public boolean equals(final java.lang.Object obj) { 2938 if (obj == this) { 2939 return true; 2940 } 2941 if (!(obj instanceof com.google.cloud.functions.v1.CloudFunction)) { 2942 return super.equals(obj); 2943 } 2944 com.google.cloud.functions.v1.CloudFunction other = 2945 (com.google.cloud.functions.v1.CloudFunction) obj; 2946 2947 if (!getName().equals(other.getName())) return false; 2948 if (!getDescription().equals(other.getDescription())) return false; 2949 if (status_ != other.status_) return false; 2950 if (!getEntryPoint().equals(other.getEntryPoint())) return false; 2951 if (!getRuntime().equals(other.getRuntime())) return false; 2952 if (hasTimeout() != other.hasTimeout()) return false; 2953 if (hasTimeout()) { 2954 if (!getTimeout().equals(other.getTimeout())) return false; 2955 } 2956 if (getAvailableMemoryMb() != other.getAvailableMemoryMb()) return false; 2957 if (!getServiceAccountEmail().equals(other.getServiceAccountEmail())) return false; 2958 if (hasUpdateTime() != other.hasUpdateTime()) return false; 2959 if (hasUpdateTime()) { 2960 if (!getUpdateTime().equals(other.getUpdateTime())) return false; 2961 } 2962 if (getVersionId() != other.getVersionId()) return false; 2963 if (!internalGetLabels().equals(other.internalGetLabels())) return false; 2964 if (!internalGetEnvironmentVariables().equals(other.internalGetEnvironmentVariables())) 2965 return false; 2966 if (!internalGetBuildEnvironmentVariables() 2967 .equals(other.internalGetBuildEnvironmentVariables())) return false; 2968 if (!getNetwork().equals(other.getNetwork())) return false; 2969 if (getMaxInstances() != other.getMaxInstances()) return false; 2970 if (getMinInstances() != other.getMinInstances()) return false; 2971 if (!getVpcConnector().equals(other.getVpcConnector())) return false; 2972 if (vpcConnectorEgressSettings_ != other.vpcConnectorEgressSettings_) return false; 2973 if (ingressSettings_ != other.ingressSettings_) return false; 2974 if (!getKmsKeyName().equals(other.getKmsKeyName())) return false; 2975 if (!getBuildWorkerPool().equals(other.getBuildWorkerPool())) return false; 2976 if (!getBuildId().equals(other.getBuildId())) return false; 2977 if (!getBuildName().equals(other.getBuildName())) return false; 2978 if (!getSecretEnvironmentVariablesList().equals(other.getSecretEnvironmentVariablesList())) 2979 return false; 2980 if (!getSecretVolumesList().equals(other.getSecretVolumesList())) return false; 2981 if (!getSourceToken().equals(other.getSourceToken())) return false; 2982 if (!getDockerRepository().equals(other.getDockerRepository())) return false; 2983 if (dockerRegistry_ != other.dockerRegistry_) return false; 2984 if (!getSourceCodeCase().equals(other.getSourceCodeCase())) return false; 2985 switch (sourceCodeCase_) { 2986 case 3: 2987 if (!getSourceArchiveUrl().equals(other.getSourceArchiveUrl())) return false; 2988 break; 2989 case 4: 2990 if (!getSourceRepository().equals(other.getSourceRepository())) return false; 2991 break; 2992 case 16: 2993 if (!getSourceUploadUrl().equals(other.getSourceUploadUrl())) return false; 2994 break; 2995 case 0: 2996 default: 2997 } 2998 if (!getTriggerCase().equals(other.getTriggerCase())) return false; 2999 switch (triggerCase_) { 3000 case 5: 3001 if (!getHttpsTrigger().equals(other.getHttpsTrigger())) return false; 3002 break; 3003 case 6: 3004 if (!getEventTrigger().equals(other.getEventTrigger())) return false; 3005 break; 3006 case 0: 3007 default: 3008 } 3009 if (!getUnknownFields().equals(other.getUnknownFields())) return false; 3010 return true; 3011 } 3012 3013 @java.lang.Override hashCode()3014 public int hashCode() { 3015 if (memoizedHashCode != 0) { 3016 return memoizedHashCode; 3017 } 3018 int hash = 41; 3019 hash = (19 * hash) + getDescriptor().hashCode(); 3020 hash = (37 * hash) + NAME_FIELD_NUMBER; 3021 hash = (53 * hash) + getName().hashCode(); 3022 hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; 3023 hash = (53 * hash) + getDescription().hashCode(); 3024 hash = (37 * hash) + STATUS_FIELD_NUMBER; 3025 hash = (53 * hash) + status_; 3026 hash = (37 * hash) + ENTRY_POINT_FIELD_NUMBER; 3027 hash = (53 * hash) + getEntryPoint().hashCode(); 3028 hash = (37 * hash) + RUNTIME_FIELD_NUMBER; 3029 hash = (53 * hash) + getRuntime().hashCode(); 3030 if (hasTimeout()) { 3031 hash = (37 * hash) + TIMEOUT_FIELD_NUMBER; 3032 hash = (53 * hash) + getTimeout().hashCode(); 3033 } 3034 hash = (37 * hash) + AVAILABLE_MEMORY_MB_FIELD_NUMBER; 3035 hash = (53 * hash) + getAvailableMemoryMb(); 3036 hash = (37 * hash) + SERVICE_ACCOUNT_EMAIL_FIELD_NUMBER; 3037 hash = (53 * hash) + getServiceAccountEmail().hashCode(); 3038 if (hasUpdateTime()) { 3039 hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; 3040 hash = (53 * hash) + getUpdateTime().hashCode(); 3041 } 3042 hash = (37 * hash) + VERSION_ID_FIELD_NUMBER; 3043 hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getVersionId()); 3044 if (!internalGetLabels().getMap().isEmpty()) { 3045 hash = (37 * hash) + LABELS_FIELD_NUMBER; 3046 hash = (53 * hash) + internalGetLabels().hashCode(); 3047 } 3048 if (!internalGetEnvironmentVariables().getMap().isEmpty()) { 3049 hash = (37 * hash) + ENVIRONMENT_VARIABLES_FIELD_NUMBER; 3050 hash = (53 * hash) + internalGetEnvironmentVariables().hashCode(); 3051 } 3052 if (!internalGetBuildEnvironmentVariables().getMap().isEmpty()) { 3053 hash = (37 * hash) + BUILD_ENVIRONMENT_VARIABLES_FIELD_NUMBER; 3054 hash = (53 * hash) + internalGetBuildEnvironmentVariables().hashCode(); 3055 } 3056 hash = (37 * hash) + NETWORK_FIELD_NUMBER; 3057 hash = (53 * hash) + getNetwork().hashCode(); 3058 hash = (37 * hash) + MAX_INSTANCES_FIELD_NUMBER; 3059 hash = (53 * hash) + getMaxInstances(); 3060 hash = (37 * hash) + MIN_INSTANCES_FIELD_NUMBER; 3061 hash = (53 * hash) + getMinInstances(); 3062 hash = (37 * hash) + VPC_CONNECTOR_FIELD_NUMBER; 3063 hash = (53 * hash) + getVpcConnector().hashCode(); 3064 hash = (37 * hash) + VPC_CONNECTOR_EGRESS_SETTINGS_FIELD_NUMBER; 3065 hash = (53 * hash) + vpcConnectorEgressSettings_; 3066 hash = (37 * hash) + INGRESS_SETTINGS_FIELD_NUMBER; 3067 hash = (53 * hash) + ingressSettings_; 3068 hash = (37 * hash) + KMS_KEY_NAME_FIELD_NUMBER; 3069 hash = (53 * hash) + getKmsKeyName().hashCode(); 3070 hash = (37 * hash) + BUILD_WORKER_POOL_FIELD_NUMBER; 3071 hash = (53 * hash) + getBuildWorkerPool().hashCode(); 3072 hash = (37 * hash) + BUILD_ID_FIELD_NUMBER; 3073 hash = (53 * hash) + getBuildId().hashCode(); 3074 hash = (37 * hash) + BUILD_NAME_FIELD_NUMBER; 3075 hash = (53 * hash) + getBuildName().hashCode(); 3076 if (getSecretEnvironmentVariablesCount() > 0) { 3077 hash = (37 * hash) + SECRET_ENVIRONMENT_VARIABLES_FIELD_NUMBER; 3078 hash = (53 * hash) + getSecretEnvironmentVariablesList().hashCode(); 3079 } 3080 if (getSecretVolumesCount() > 0) { 3081 hash = (37 * hash) + SECRET_VOLUMES_FIELD_NUMBER; 3082 hash = (53 * hash) + getSecretVolumesList().hashCode(); 3083 } 3084 hash = (37 * hash) + SOURCE_TOKEN_FIELD_NUMBER; 3085 hash = (53 * hash) + getSourceToken().hashCode(); 3086 hash = (37 * hash) + DOCKER_REPOSITORY_FIELD_NUMBER; 3087 hash = (53 * hash) + getDockerRepository().hashCode(); 3088 hash = (37 * hash) + DOCKER_REGISTRY_FIELD_NUMBER; 3089 hash = (53 * hash) + dockerRegistry_; 3090 switch (sourceCodeCase_) { 3091 case 3: 3092 hash = (37 * hash) + SOURCE_ARCHIVE_URL_FIELD_NUMBER; 3093 hash = (53 * hash) + getSourceArchiveUrl().hashCode(); 3094 break; 3095 case 4: 3096 hash = (37 * hash) + SOURCE_REPOSITORY_FIELD_NUMBER; 3097 hash = (53 * hash) + getSourceRepository().hashCode(); 3098 break; 3099 case 16: 3100 hash = (37 * hash) + SOURCE_UPLOAD_URL_FIELD_NUMBER; 3101 hash = (53 * hash) + getSourceUploadUrl().hashCode(); 3102 break; 3103 case 0: 3104 default: 3105 } 3106 switch (triggerCase_) { 3107 case 5: 3108 hash = (37 * hash) + HTTPS_TRIGGER_FIELD_NUMBER; 3109 hash = (53 * hash) + getHttpsTrigger().hashCode(); 3110 break; 3111 case 6: 3112 hash = (37 * hash) + EVENT_TRIGGER_FIELD_NUMBER; 3113 hash = (53 * hash) + getEventTrigger().hashCode(); 3114 break; 3115 case 0: 3116 default: 3117 } 3118 hash = (29 * hash) + getUnknownFields().hashCode(); 3119 memoizedHashCode = hash; 3120 return hash; 3121 } 3122 parseFrom(java.nio.ByteBuffer data)3123 public static com.google.cloud.functions.v1.CloudFunction parseFrom(java.nio.ByteBuffer data) 3124 throws com.google.protobuf.InvalidProtocolBufferException { 3125 return PARSER.parseFrom(data); 3126 } 3127 parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3128 public static com.google.cloud.functions.v1.CloudFunction parseFrom( 3129 java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 3130 throws com.google.protobuf.InvalidProtocolBufferException { 3131 return PARSER.parseFrom(data, extensionRegistry); 3132 } 3133 parseFrom( com.google.protobuf.ByteString data)3134 public static com.google.cloud.functions.v1.CloudFunction parseFrom( 3135 com.google.protobuf.ByteString data) 3136 throws com.google.protobuf.InvalidProtocolBufferException { 3137 return PARSER.parseFrom(data); 3138 } 3139 parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3140 public static com.google.cloud.functions.v1.CloudFunction parseFrom( 3141 com.google.protobuf.ByteString data, 3142 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 3143 throws com.google.protobuf.InvalidProtocolBufferException { 3144 return PARSER.parseFrom(data, extensionRegistry); 3145 } 3146 parseFrom(byte[] data)3147 public static com.google.cloud.functions.v1.CloudFunction parseFrom(byte[] data) 3148 throws com.google.protobuf.InvalidProtocolBufferException { 3149 return PARSER.parseFrom(data); 3150 } 3151 parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3152 public static com.google.cloud.functions.v1.CloudFunction parseFrom( 3153 byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 3154 throws com.google.protobuf.InvalidProtocolBufferException { 3155 return PARSER.parseFrom(data, extensionRegistry); 3156 } 3157 parseFrom(java.io.InputStream input)3158 public static com.google.cloud.functions.v1.CloudFunction parseFrom(java.io.InputStream input) 3159 throws java.io.IOException { 3160 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 3161 } 3162 parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3163 public static com.google.cloud.functions.v1.CloudFunction parseFrom( 3164 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 3165 throws java.io.IOException { 3166 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 3167 PARSER, input, extensionRegistry); 3168 } 3169 parseDelimitedFrom( java.io.InputStream input)3170 public static com.google.cloud.functions.v1.CloudFunction parseDelimitedFrom( 3171 java.io.InputStream input) throws java.io.IOException { 3172 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); 3173 } 3174 parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3175 public static com.google.cloud.functions.v1.CloudFunction parseDelimitedFrom( 3176 java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) 3177 throws java.io.IOException { 3178 return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( 3179 PARSER, input, extensionRegistry); 3180 } 3181 parseFrom( com.google.protobuf.CodedInputStream input)3182 public static com.google.cloud.functions.v1.CloudFunction parseFrom( 3183 com.google.protobuf.CodedInputStream input) throws java.io.IOException { 3184 return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); 3185 } 3186 parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3187 public static com.google.cloud.functions.v1.CloudFunction parseFrom( 3188 com.google.protobuf.CodedInputStream input, 3189 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 3190 throws java.io.IOException { 3191 return com.google.protobuf.GeneratedMessageV3.parseWithIOException( 3192 PARSER, input, extensionRegistry); 3193 } 3194 3195 @java.lang.Override newBuilderForType()3196 public Builder newBuilderForType() { 3197 return newBuilder(); 3198 } 3199 newBuilder()3200 public static Builder newBuilder() { 3201 return DEFAULT_INSTANCE.toBuilder(); 3202 } 3203 newBuilder(com.google.cloud.functions.v1.CloudFunction prototype)3204 public static Builder newBuilder(com.google.cloud.functions.v1.CloudFunction prototype) { 3205 return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); 3206 } 3207 3208 @java.lang.Override toBuilder()3209 public Builder toBuilder() { 3210 return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); 3211 } 3212 3213 @java.lang.Override newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)3214 protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 3215 Builder builder = new Builder(parent); 3216 return builder; 3217 } 3218 /** 3219 * 3220 * 3221 * <pre> 3222 * Describes a Cloud Function that contains user computation executed in 3223 * response to an event. It encapsulates function and triggers configurations. 3224 * </pre> 3225 * 3226 * Protobuf type {@code google.cloud.functions.v1.CloudFunction} 3227 */ 3228 public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder> 3229 implements 3230 // @@protoc_insertion_point(builder_implements:google.cloud.functions.v1.CloudFunction) 3231 com.google.cloud.functions.v1.CloudFunctionOrBuilder { getDescriptor()3232 public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { 3233 return com.google.cloud.functions.v1.FunctionsProto 3234 .internal_static_google_cloud_functions_v1_CloudFunction_descriptor; 3235 } 3236 3237 @SuppressWarnings({"rawtypes"}) internalGetMapField(int number)3238 protected com.google.protobuf.MapField internalGetMapField(int number) { 3239 switch (number) { 3240 case 15: 3241 return internalGetLabels(); 3242 case 17: 3243 return internalGetEnvironmentVariables(); 3244 case 28: 3245 return internalGetBuildEnvironmentVariables(); 3246 default: 3247 throw new RuntimeException("Invalid map field number: " + number); 3248 } 3249 } 3250 3251 @SuppressWarnings({"rawtypes"}) internalGetMutableMapField(int number)3252 protected com.google.protobuf.MapField internalGetMutableMapField(int number) { 3253 switch (number) { 3254 case 15: 3255 return internalGetMutableLabels(); 3256 case 17: 3257 return internalGetMutableEnvironmentVariables(); 3258 case 28: 3259 return internalGetMutableBuildEnvironmentVariables(); 3260 default: 3261 throw new RuntimeException("Invalid map field number: " + number); 3262 } 3263 } 3264 3265 @java.lang.Override 3266 protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()3267 internalGetFieldAccessorTable() { 3268 return com.google.cloud.functions.v1.FunctionsProto 3269 .internal_static_google_cloud_functions_v1_CloudFunction_fieldAccessorTable 3270 .ensureFieldAccessorsInitialized( 3271 com.google.cloud.functions.v1.CloudFunction.class, 3272 com.google.cloud.functions.v1.CloudFunction.Builder.class); 3273 } 3274 3275 // Construct using com.google.cloud.functions.v1.CloudFunction.newBuilder() Builder()3276 private Builder() {} 3277 Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)3278 private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { 3279 super(parent); 3280 } 3281 3282 @java.lang.Override clear()3283 public Builder clear() { 3284 super.clear(); 3285 bitField0_ = 0; 3286 bitField1_ = 0; 3287 name_ = ""; 3288 description_ = ""; 3289 if (sourceRepositoryBuilder_ != null) { 3290 sourceRepositoryBuilder_.clear(); 3291 } 3292 if (httpsTriggerBuilder_ != null) { 3293 httpsTriggerBuilder_.clear(); 3294 } 3295 if (eventTriggerBuilder_ != null) { 3296 eventTriggerBuilder_.clear(); 3297 } 3298 status_ = 0; 3299 entryPoint_ = ""; 3300 runtime_ = ""; 3301 timeout_ = null; 3302 if (timeoutBuilder_ != null) { 3303 timeoutBuilder_.dispose(); 3304 timeoutBuilder_ = null; 3305 } 3306 availableMemoryMb_ = 0; 3307 serviceAccountEmail_ = ""; 3308 updateTime_ = null; 3309 if (updateTimeBuilder_ != null) { 3310 updateTimeBuilder_.dispose(); 3311 updateTimeBuilder_ = null; 3312 } 3313 versionId_ = 0L; 3314 internalGetMutableLabels().clear(); 3315 internalGetMutableEnvironmentVariables().clear(); 3316 internalGetMutableBuildEnvironmentVariables().clear(); 3317 network_ = ""; 3318 maxInstances_ = 0; 3319 minInstances_ = 0; 3320 vpcConnector_ = ""; 3321 vpcConnectorEgressSettings_ = 0; 3322 ingressSettings_ = 0; 3323 kmsKeyName_ = ""; 3324 buildWorkerPool_ = ""; 3325 buildId_ = ""; 3326 buildName_ = ""; 3327 if (secretEnvironmentVariablesBuilder_ == null) { 3328 secretEnvironmentVariables_ = java.util.Collections.emptyList(); 3329 } else { 3330 secretEnvironmentVariables_ = null; 3331 secretEnvironmentVariablesBuilder_.clear(); 3332 } 3333 bitField0_ = (bitField0_ & ~0x10000000); 3334 if (secretVolumesBuilder_ == null) { 3335 secretVolumes_ = java.util.Collections.emptyList(); 3336 } else { 3337 secretVolumes_ = null; 3338 secretVolumesBuilder_.clear(); 3339 } 3340 bitField0_ = (bitField0_ & ~0x20000000); 3341 sourceToken_ = ""; 3342 dockerRepository_ = ""; 3343 dockerRegistry_ = 0; 3344 sourceCodeCase_ = 0; 3345 sourceCode_ = null; 3346 triggerCase_ = 0; 3347 trigger_ = null; 3348 return this; 3349 } 3350 3351 @java.lang.Override getDescriptorForType()3352 public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { 3353 return com.google.cloud.functions.v1.FunctionsProto 3354 .internal_static_google_cloud_functions_v1_CloudFunction_descriptor; 3355 } 3356 3357 @java.lang.Override getDefaultInstanceForType()3358 public com.google.cloud.functions.v1.CloudFunction getDefaultInstanceForType() { 3359 return com.google.cloud.functions.v1.CloudFunction.getDefaultInstance(); 3360 } 3361 3362 @java.lang.Override build()3363 public com.google.cloud.functions.v1.CloudFunction build() { 3364 com.google.cloud.functions.v1.CloudFunction result = buildPartial(); 3365 if (!result.isInitialized()) { 3366 throw newUninitializedMessageException(result); 3367 } 3368 return result; 3369 } 3370 3371 @java.lang.Override buildPartial()3372 public com.google.cloud.functions.v1.CloudFunction buildPartial() { 3373 com.google.cloud.functions.v1.CloudFunction result = 3374 new com.google.cloud.functions.v1.CloudFunction(this); 3375 buildPartialRepeatedFields(result); 3376 if (bitField0_ != 0) { 3377 buildPartial0(result); 3378 } 3379 if (bitField1_ != 0) { 3380 buildPartial1(result); 3381 } 3382 buildPartialOneofs(result); 3383 onBuilt(); 3384 return result; 3385 } 3386 buildPartialRepeatedFields(com.google.cloud.functions.v1.CloudFunction result)3387 private void buildPartialRepeatedFields(com.google.cloud.functions.v1.CloudFunction result) { 3388 if (secretEnvironmentVariablesBuilder_ == null) { 3389 if (((bitField0_ & 0x10000000) != 0)) { 3390 secretEnvironmentVariables_ = 3391 java.util.Collections.unmodifiableList(secretEnvironmentVariables_); 3392 bitField0_ = (bitField0_ & ~0x10000000); 3393 } 3394 result.secretEnvironmentVariables_ = secretEnvironmentVariables_; 3395 } else { 3396 result.secretEnvironmentVariables_ = secretEnvironmentVariablesBuilder_.build(); 3397 } 3398 if (secretVolumesBuilder_ == null) { 3399 if (((bitField0_ & 0x20000000) != 0)) { 3400 secretVolumes_ = java.util.Collections.unmodifiableList(secretVolumes_); 3401 bitField0_ = (bitField0_ & ~0x20000000); 3402 } 3403 result.secretVolumes_ = secretVolumes_; 3404 } else { 3405 result.secretVolumes_ = secretVolumesBuilder_.build(); 3406 } 3407 } 3408 buildPartial0(com.google.cloud.functions.v1.CloudFunction result)3409 private void buildPartial0(com.google.cloud.functions.v1.CloudFunction result) { 3410 int from_bitField0_ = bitField0_; 3411 if (((from_bitField0_ & 0x00000001) != 0)) { 3412 result.name_ = name_; 3413 } 3414 if (((from_bitField0_ & 0x00000002) != 0)) { 3415 result.description_ = description_; 3416 } 3417 if (((from_bitField0_ & 0x00000080) != 0)) { 3418 result.status_ = status_; 3419 } 3420 if (((from_bitField0_ & 0x00000100) != 0)) { 3421 result.entryPoint_ = entryPoint_; 3422 } 3423 if (((from_bitField0_ & 0x00000200) != 0)) { 3424 result.runtime_ = runtime_; 3425 } 3426 if (((from_bitField0_ & 0x00000400) != 0)) { 3427 result.timeout_ = timeoutBuilder_ == null ? timeout_ : timeoutBuilder_.build(); 3428 } 3429 if (((from_bitField0_ & 0x00000800) != 0)) { 3430 result.availableMemoryMb_ = availableMemoryMb_; 3431 } 3432 if (((from_bitField0_ & 0x00001000) != 0)) { 3433 result.serviceAccountEmail_ = serviceAccountEmail_; 3434 } 3435 if (((from_bitField0_ & 0x00002000) != 0)) { 3436 result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); 3437 } 3438 if (((from_bitField0_ & 0x00004000) != 0)) { 3439 result.versionId_ = versionId_; 3440 } 3441 if (((from_bitField0_ & 0x00008000) != 0)) { 3442 result.labels_ = internalGetLabels(); 3443 result.labels_.makeImmutable(); 3444 } 3445 if (((from_bitField0_ & 0x00010000) != 0)) { 3446 result.environmentVariables_ = internalGetEnvironmentVariables(); 3447 result.environmentVariables_.makeImmutable(); 3448 } 3449 if (((from_bitField0_ & 0x00020000) != 0)) { 3450 result.buildEnvironmentVariables_ = internalGetBuildEnvironmentVariables(); 3451 result.buildEnvironmentVariables_.makeImmutable(); 3452 } 3453 if (((from_bitField0_ & 0x00040000) != 0)) { 3454 result.network_ = network_; 3455 } 3456 if (((from_bitField0_ & 0x00080000) != 0)) { 3457 result.maxInstances_ = maxInstances_; 3458 } 3459 if (((from_bitField0_ & 0x00100000) != 0)) { 3460 result.minInstances_ = minInstances_; 3461 } 3462 if (((from_bitField0_ & 0x00200000) != 0)) { 3463 result.vpcConnector_ = vpcConnector_; 3464 } 3465 if (((from_bitField0_ & 0x00400000) != 0)) { 3466 result.vpcConnectorEgressSettings_ = vpcConnectorEgressSettings_; 3467 } 3468 if (((from_bitField0_ & 0x00800000) != 0)) { 3469 result.ingressSettings_ = ingressSettings_; 3470 } 3471 if (((from_bitField0_ & 0x01000000) != 0)) { 3472 result.kmsKeyName_ = kmsKeyName_; 3473 } 3474 if (((from_bitField0_ & 0x02000000) != 0)) { 3475 result.buildWorkerPool_ = buildWorkerPool_; 3476 } 3477 if (((from_bitField0_ & 0x04000000) != 0)) { 3478 result.buildId_ = buildId_; 3479 } 3480 if (((from_bitField0_ & 0x08000000) != 0)) { 3481 result.buildName_ = buildName_; 3482 } 3483 if (((from_bitField0_ & 0x40000000) != 0)) { 3484 result.sourceToken_ = sourceToken_; 3485 } 3486 if (((from_bitField0_ & 0x80000000) != 0)) { 3487 result.dockerRepository_ = dockerRepository_; 3488 } 3489 } 3490 buildPartial1(com.google.cloud.functions.v1.CloudFunction result)3491 private void buildPartial1(com.google.cloud.functions.v1.CloudFunction result) { 3492 int from_bitField1_ = bitField1_; 3493 if (((from_bitField1_ & 0x00000001) != 0)) { 3494 result.dockerRegistry_ = dockerRegistry_; 3495 } 3496 } 3497 buildPartialOneofs(com.google.cloud.functions.v1.CloudFunction result)3498 private void buildPartialOneofs(com.google.cloud.functions.v1.CloudFunction result) { 3499 result.sourceCodeCase_ = sourceCodeCase_; 3500 result.sourceCode_ = this.sourceCode_; 3501 if (sourceCodeCase_ == 4 && sourceRepositoryBuilder_ != null) { 3502 result.sourceCode_ = sourceRepositoryBuilder_.build(); 3503 } 3504 result.triggerCase_ = triggerCase_; 3505 result.trigger_ = this.trigger_; 3506 if (triggerCase_ == 5 && httpsTriggerBuilder_ != null) { 3507 result.trigger_ = httpsTriggerBuilder_.build(); 3508 } 3509 if (triggerCase_ == 6 && eventTriggerBuilder_ != null) { 3510 result.trigger_ = eventTriggerBuilder_.build(); 3511 } 3512 } 3513 3514 @java.lang.Override clone()3515 public Builder clone() { 3516 return super.clone(); 3517 } 3518 3519 @java.lang.Override setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)3520 public Builder setField( 3521 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 3522 return super.setField(field, value); 3523 } 3524 3525 @java.lang.Override clearField(com.google.protobuf.Descriptors.FieldDescriptor field)3526 public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { 3527 return super.clearField(field); 3528 } 3529 3530 @java.lang.Override clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)3531 public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { 3532 return super.clearOneof(oneof); 3533 } 3534 3535 @java.lang.Override setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)3536 public Builder setRepeatedField( 3537 com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { 3538 return super.setRepeatedField(field, index, value); 3539 } 3540 3541 @java.lang.Override addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)3542 public Builder addRepeatedField( 3543 com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { 3544 return super.addRepeatedField(field, value); 3545 } 3546 3547 @java.lang.Override mergeFrom(com.google.protobuf.Message other)3548 public Builder mergeFrom(com.google.protobuf.Message other) { 3549 if (other instanceof com.google.cloud.functions.v1.CloudFunction) { 3550 return mergeFrom((com.google.cloud.functions.v1.CloudFunction) other); 3551 } else { 3552 super.mergeFrom(other); 3553 return this; 3554 } 3555 } 3556 mergeFrom(com.google.cloud.functions.v1.CloudFunction other)3557 public Builder mergeFrom(com.google.cloud.functions.v1.CloudFunction other) { 3558 if (other == com.google.cloud.functions.v1.CloudFunction.getDefaultInstance()) return this; 3559 if (!other.getName().isEmpty()) { 3560 name_ = other.name_; 3561 bitField0_ |= 0x00000001; 3562 onChanged(); 3563 } 3564 if (!other.getDescription().isEmpty()) { 3565 description_ = other.description_; 3566 bitField0_ |= 0x00000002; 3567 onChanged(); 3568 } 3569 if (other.status_ != 0) { 3570 setStatusValue(other.getStatusValue()); 3571 } 3572 if (!other.getEntryPoint().isEmpty()) { 3573 entryPoint_ = other.entryPoint_; 3574 bitField0_ |= 0x00000100; 3575 onChanged(); 3576 } 3577 if (!other.getRuntime().isEmpty()) { 3578 runtime_ = other.runtime_; 3579 bitField0_ |= 0x00000200; 3580 onChanged(); 3581 } 3582 if (other.hasTimeout()) { 3583 mergeTimeout(other.getTimeout()); 3584 } 3585 if (other.getAvailableMemoryMb() != 0) { 3586 setAvailableMemoryMb(other.getAvailableMemoryMb()); 3587 } 3588 if (!other.getServiceAccountEmail().isEmpty()) { 3589 serviceAccountEmail_ = other.serviceAccountEmail_; 3590 bitField0_ |= 0x00001000; 3591 onChanged(); 3592 } 3593 if (other.hasUpdateTime()) { 3594 mergeUpdateTime(other.getUpdateTime()); 3595 } 3596 if (other.getVersionId() != 0L) { 3597 setVersionId(other.getVersionId()); 3598 } 3599 internalGetMutableLabels().mergeFrom(other.internalGetLabels()); 3600 bitField0_ |= 0x00008000; 3601 internalGetMutableEnvironmentVariables().mergeFrom(other.internalGetEnvironmentVariables()); 3602 bitField0_ |= 0x00010000; 3603 internalGetMutableBuildEnvironmentVariables() 3604 .mergeFrom(other.internalGetBuildEnvironmentVariables()); 3605 bitField0_ |= 0x00020000; 3606 if (!other.getNetwork().isEmpty()) { 3607 network_ = other.network_; 3608 bitField0_ |= 0x00040000; 3609 onChanged(); 3610 } 3611 if (other.getMaxInstances() != 0) { 3612 setMaxInstances(other.getMaxInstances()); 3613 } 3614 if (other.getMinInstances() != 0) { 3615 setMinInstances(other.getMinInstances()); 3616 } 3617 if (!other.getVpcConnector().isEmpty()) { 3618 vpcConnector_ = other.vpcConnector_; 3619 bitField0_ |= 0x00200000; 3620 onChanged(); 3621 } 3622 if (other.vpcConnectorEgressSettings_ != 0) { 3623 setVpcConnectorEgressSettingsValue(other.getVpcConnectorEgressSettingsValue()); 3624 } 3625 if (other.ingressSettings_ != 0) { 3626 setIngressSettingsValue(other.getIngressSettingsValue()); 3627 } 3628 if (!other.getKmsKeyName().isEmpty()) { 3629 kmsKeyName_ = other.kmsKeyName_; 3630 bitField0_ |= 0x01000000; 3631 onChanged(); 3632 } 3633 if (!other.getBuildWorkerPool().isEmpty()) { 3634 buildWorkerPool_ = other.buildWorkerPool_; 3635 bitField0_ |= 0x02000000; 3636 onChanged(); 3637 } 3638 if (!other.getBuildId().isEmpty()) { 3639 buildId_ = other.buildId_; 3640 bitField0_ |= 0x04000000; 3641 onChanged(); 3642 } 3643 if (!other.getBuildName().isEmpty()) { 3644 buildName_ = other.buildName_; 3645 bitField0_ |= 0x08000000; 3646 onChanged(); 3647 } 3648 if (secretEnvironmentVariablesBuilder_ == null) { 3649 if (!other.secretEnvironmentVariables_.isEmpty()) { 3650 if (secretEnvironmentVariables_.isEmpty()) { 3651 secretEnvironmentVariables_ = other.secretEnvironmentVariables_; 3652 bitField0_ = (bitField0_ & ~0x10000000); 3653 } else { 3654 ensureSecretEnvironmentVariablesIsMutable(); 3655 secretEnvironmentVariables_.addAll(other.secretEnvironmentVariables_); 3656 } 3657 onChanged(); 3658 } 3659 } else { 3660 if (!other.secretEnvironmentVariables_.isEmpty()) { 3661 if (secretEnvironmentVariablesBuilder_.isEmpty()) { 3662 secretEnvironmentVariablesBuilder_.dispose(); 3663 secretEnvironmentVariablesBuilder_ = null; 3664 secretEnvironmentVariables_ = other.secretEnvironmentVariables_; 3665 bitField0_ = (bitField0_ & ~0x10000000); 3666 secretEnvironmentVariablesBuilder_ = 3667 com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders 3668 ? getSecretEnvironmentVariablesFieldBuilder() 3669 : null; 3670 } else { 3671 secretEnvironmentVariablesBuilder_.addAllMessages(other.secretEnvironmentVariables_); 3672 } 3673 } 3674 } 3675 if (secretVolumesBuilder_ == null) { 3676 if (!other.secretVolumes_.isEmpty()) { 3677 if (secretVolumes_.isEmpty()) { 3678 secretVolumes_ = other.secretVolumes_; 3679 bitField0_ = (bitField0_ & ~0x20000000); 3680 } else { 3681 ensureSecretVolumesIsMutable(); 3682 secretVolumes_.addAll(other.secretVolumes_); 3683 } 3684 onChanged(); 3685 } 3686 } else { 3687 if (!other.secretVolumes_.isEmpty()) { 3688 if (secretVolumesBuilder_.isEmpty()) { 3689 secretVolumesBuilder_.dispose(); 3690 secretVolumesBuilder_ = null; 3691 secretVolumes_ = other.secretVolumes_; 3692 bitField0_ = (bitField0_ & ~0x20000000); 3693 secretVolumesBuilder_ = 3694 com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders 3695 ? getSecretVolumesFieldBuilder() 3696 : null; 3697 } else { 3698 secretVolumesBuilder_.addAllMessages(other.secretVolumes_); 3699 } 3700 } 3701 } 3702 if (!other.getSourceToken().isEmpty()) { 3703 sourceToken_ = other.sourceToken_; 3704 bitField0_ |= 0x40000000; 3705 onChanged(); 3706 } 3707 if (!other.getDockerRepository().isEmpty()) { 3708 dockerRepository_ = other.dockerRepository_; 3709 bitField0_ |= 0x80000000; 3710 onChanged(); 3711 } 3712 if (other.dockerRegistry_ != 0) { 3713 setDockerRegistryValue(other.getDockerRegistryValue()); 3714 } 3715 switch (other.getSourceCodeCase()) { 3716 case SOURCE_ARCHIVE_URL: 3717 { 3718 sourceCodeCase_ = 3; 3719 sourceCode_ = other.sourceCode_; 3720 onChanged(); 3721 break; 3722 } 3723 case SOURCE_REPOSITORY: 3724 { 3725 mergeSourceRepository(other.getSourceRepository()); 3726 break; 3727 } 3728 case SOURCE_UPLOAD_URL: 3729 { 3730 sourceCodeCase_ = 16; 3731 sourceCode_ = other.sourceCode_; 3732 onChanged(); 3733 break; 3734 } 3735 case SOURCECODE_NOT_SET: 3736 { 3737 break; 3738 } 3739 } 3740 switch (other.getTriggerCase()) { 3741 case HTTPS_TRIGGER: 3742 { 3743 mergeHttpsTrigger(other.getHttpsTrigger()); 3744 break; 3745 } 3746 case EVENT_TRIGGER: 3747 { 3748 mergeEventTrigger(other.getEventTrigger()); 3749 break; 3750 } 3751 case TRIGGER_NOT_SET: 3752 { 3753 break; 3754 } 3755 } 3756 this.mergeUnknownFields(other.getUnknownFields()); 3757 onChanged(); 3758 return this; 3759 } 3760 3761 @java.lang.Override isInitialized()3762 public final boolean isInitialized() { 3763 return true; 3764 } 3765 3766 @java.lang.Override mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)3767 public Builder mergeFrom( 3768 com.google.protobuf.CodedInputStream input, 3769 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 3770 throws java.io.IOException { 3771 if (extensionRegistry == null) { 3772 throw new java.lang.NullPointerException(); 3773 } 3774 try { 3775 boolean done = false; 3776 while (!done) { 3777 int tag = input.readTag(); 3778 switch (tag) { 3779 case 0: 3780 done = true; 3781 break; 3782 case 10: 3783 { 3784 name_ = input.readStringRequireUtf8(); 3785 bitField0_ |= 0x00000001; 3786 break; 3787 } // case 10 3788 case 18: 3789 { 3790 description_ = input.readStringRequireUtf8(); 3791 bitField0_ |= 0x00000002; 3792 break; 3793 } // case 18 3794 case 26: 3795 { 3796 java.lang.String s = input.readStringRequireUtf8(); 3797 sourceCodeCase_ = 3; 3798 sourceCode_ = s; 3799 break; 3800 } // case 26 3801 case 34: 3802 { 3803 input.readMessage( 3804 getSourceRepositoryFieldBuilder().getBuilder(), extensionRegistry); 3805 sourceCodeCase_ = 4; 3806 break; 3807 } // case 34 3808 case 42: 3809 { 3810 input.readMessage(getHttpsTriggerFieldBuilder().getBuilder(), extensionRegistry); 3811 triggerCase_ = 5; 3812 break; 3813 } // case 42 3814 case 50: 3815 { 3816 input.readMessage(getEventTriggerFieldBuilder().getBuilder(), extensionRegistry); 3817 triggerCase_ = 6; 3818 break; 3819 } // case 50 3820 case 56: 3821 { 3822 status_ = input.readEnum(); 3823 bitField0_ |= 0x00000080; 3824 break; 3825 } // case 56 3826 case 66: 3827 { 3828 entryPoint_ = input.readStringRequireUtf8(); 3829 bitField0_ |= 0x00000100; 3830 break; 3831 } // case 66 3832 case 74: 3833 { 3834 input.readMessage(getTimeoutFieldBuilder().getBuilder(), extensionRegistry); 3835 bitField0_ |= 0x00000400; 3836 break; 3837 } // case 74 3838 case 80: 3839 { 3840 availableMemoryMb_ = input.readInt32(); 3841 bitField0_ |= 0x00000800; 3842 break; 3843 } // case 80 3844 case 90: 3845 { 3846 serviceAccountEmail_ = input.readStringRequireUtf8(); 3847 bitField0_ |= 0x00001000; 3848 break; 3849 } // case 90 3850 case 98: 3851 { 3852 input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); 3853 bitField0_ |= 0x00002000; 3854 break; 3855 } // case 98 3856 case 112: 3857 { 3858 versionId_ = input.readInt64(); 3859 bitField0_ |= 0x00004000; 3860 break; 3861 } // case 112 3862 case 122: 3863 { 3864 com.google.protobuf.MapEntry<java.lang.String, java.lang.String> labels__ = 3865 input.readMessage( 3866 LabelsDefaultEntryHolder.defaultEntry.getParserForType(), 3867 extensionRegistry); 3868 internalGetMutableLabels() 3869 .getMutableMap() 3870 .put(labels__.getKey(), labels__.getValue()); 3871 bitField0_ |= 0x00008000; 3872 break; 3873 } // case 122 3874 case 130: 3875 { 3876 java.lang.String s = input.readStringRequireUtf8(); 3877 sourceCodeCase_ = 16; 3878 sourceCode_ = s; 3879 break; 3880 } // case 130 3881 case 138: 3882 { 3883 com.google.protobuf.MapEntry<java.lang.String, java.lang.String> 3884 environmentVariables__ = 3885 input.readMessage( 3886 EnvironmentVariablesDefaultEntryHolder.defaultEntry.getParserForType(), 3887 extensionRegistry); 3888 internalGetMutableEnvironmentVariables() 3889 .getMutableMap() 3890 .put(environmentVariables__.getKey(), environmentVariables__.getValue()); 3891 bitField0_ |= 0x00010000; 3892 break; 3893 } // case 138 3894 case 146: 3895 { 3896 network_ = input.readStringRequireUtf8(); 3897 bitField0_ |= 0x00040000; 3898 break; 3899 } // case 146 3900 case 154: 3901 { 3902 runtime_ = input.readStringRequireUtf8(); 3903 bitField0_ |= 0x00000200; 3904 break; 3905 } // case 154 3906 case 160: 3907 { 3908 maxInstances_ = input.readInt32(); 3909 bitField0_ |= 0x00080000; 3910 break; 3911 } // case 160 3912 case 178: 3913 { 3914 vpcConnector_ = input.readStringRequireUtf8(); 3915 bitField0_ |= 0x00200000; 3916 break; 3917 } // case 178 3918 case 184: 3919 { 3920 vpcConnectorEgressSettings_ = input.readEnum(); 3921 bitField0_ |= 0x00400000; 3922 break; 3923 } // case 184 3924 case 192: 3925 { 3926 ingressSettings_ = input.readEnum(); 3927 bitField0_ |= 0x00800000; 3928 break; 3929 } // case 192 3930 case 202: 3931 { 3932 kmsKeyName_ = input.readStringRequireUtf8(); 3933 bitField0_ |= 0x01000000; 3934 break; 3935 } // case 202 3936 case 210: 3937 { 3938 buildWorkerPool_ = input.readStringRequireUtf8(); 3939 bitField0_ |= 0x02000000; 3940 break; 3941 } // case 210 3942 case 218: 3943 { 3944 buildId_ = input.readStringRequireUtf8(); 3945 bitField0_ |= 0x04000000; 3946 break; 3947 } // case 218 3948 case 226: 3949 { 3950 com.google.protobuf.MapEntry<java.lang.String, java.lang.String> 3951 buildEnvironmentVariables__ = 3952 input.readMessage( 3953 BuildEnvironmentVariablesDefaultEntryHolder.defaultEntry 3954 .getParserForType(), 3955 extensionRegistry); 3956 internalGetMutableBuildEnvironmentVariables() 3957 .getMutableMap() 3958 .put( 3959 buildEnvironmentVariables__.getKey(), 3960 buildEnvironmentVariables__.getValue()); 3961 bitField0_ |= 0x00020000; 3962 break; 3963 } // case 226 3964 case 234: 3965 { 3966 com.google.cloud.functions.v1.SecretEnvVar m = 3967 input.readMessage( 3968 com.google.cloud.functions.v1.SecretEnvVar.parser(), extensionRegistry); 3969 if (secretEnvironmentVariablesBuilder_ == null) { 3970 ensureSecretEnvironmentVariablesIsMutable(); 3971 secretEnvironmentVariables_.add(m); 3972 } else { 3973 secretEnvironmentVariablesBuilder_.addMessage(m); 3974 } 3975 break; 3976 } // case 234 3977 case 242: 3978 { 3979 com.google.cloud.functions.v1.SecretVolume m = 3980 input.readMessage( 3981 com.google.cloud.functions.v1.SecretVolume.parser(), extensionRegistry); 3982 if (secretVolumesBuilder_ == null) { 3983 ensureSecretVolumesIsMutable(); 3984 secretVolumes_.add(m); 3985 } else { 3986 secretVolumesBuilder_.addMessage(m); 3987 } 3988 break; 3989 } // case 242 3990 case 250: 3991 { 3992 sourceToken_ = input.readStringRequireUtf8(); 3993 bitField0_ |= 0x40000000; 3994 break; 3995 } // case 250 3996 case 256: 3997 { 3998 minInstances_ = input.readInt32(); 3999 bitField0_ |= 0x00100000; 4000 break; 4001 } // case 256 4002 case 266: 4003 { 4004 buildName_ = input.readStringRequireUtf8(); 4005 bitField0_ |= 0x08000000; 4006 break; 4007 } // case 266 4008 case 274: 4009 { 4010 dockerRepository_ = input.readStringRequireUtf8(); 4011 bitField0_ |= 0x80000000; 4012 break; 4013 } // case 274 4014 case 280: 4015 { 4016 dockerRegistry_ = input.readEnum(); 4017 bitField1_ |= 0x00000001; 4018 break; 4019 } // case 280 4020 default: 4021 { 4022 if (!super.parseUnknownField(input, extensionRegistry, tag)) { 4023 done = true; // was an endgroup tag 4024 } 4025 break; 4026 } // default: 4027 } // switch (tag) 4028 } // while (!done) 4029 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 4030 throw e.unwrapIOException(); 4031 } finally { 4032 onChanged(); 4033 } // finally 4034 return this; 4035 } 4036 4037 private int sourceCodeCase_ = 0; 4038 private java.lang.Object sourceCode_; 4039 getSourceCodeCase()4040 public SourceCodeCase getSourceCodeCase() { 4041 return SourceCodeCase.forNumber(sourceCodeCase_); 4042 } 4043 clearSourceCode()4044 public Builder clearSourceCode() { 4045 sourceCodeCase_ = 0; 4046 sourceCode_ = null; 4047 onChanged(); 4048 return this; 4049 } 4050 4051 private int triggerCase_ = 0; 4052 private java.lang.Object trigger_; 4053 getTriggerCase()4054 public TriggerCase getTriggerCase() { 4055 return TriggerCase.forNumber(triggerCase_); 4056 } 4057 clearTrigger()4058 public Builder clearTrigger() { 4059 triggerCase_ = 0; 4060 trigger_ = null; 4061 onChanged(); 4062 return this; 4063 } 4064 4065 private int bitField0_; 4066 private int bitField1_; 4067 4068 private java.lang.Object name_ = ""; 4069 /** 4070 * 4071 * 4072 * <pre> 4073 * A user-defined name of the function. Function names must be unique 4074 * globally and match pattern `projects/*/locations/*/functions/*` 4075 * </pre> 4076 * 4077 * <code>string name = 1;</code> 4078 * 4079 * @return The name. 4080 */ getName()4081 public java.lang.String getName() { 4082 java.lang.Object ref = name_; 4083 if (!(ref instanceof java.lang.String)) { 4084 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 4085 java.lang.String s = bs.toStringUtf8(); 4086 name_ = s; 4087 return s; 4088 } else { 4089 return (java.lang.String) ref; 4090 } 4091 } 4092 /** 4093 * 4094 * 4095 * <pre> 4096 * A user-defined name of the function. Function names must be unique 4097 * globally and match pattern `projects/*/locations/*/functions/*` 4098 * </pre> 4099 * 4100 * <code>string name = 1;</code> 4101 * 4102 * @return The bytes for name. 4103 */ getNameBytes()4104 public com.google.protobuf.ByteString getNameBytes() { 4105 java.lang.Object ref = name_; 4106 if (ref instanceof String) { 4107 com.google.protobuf.ByteString b = 4108 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 4109 name_ = b; 4110 return b; 4111 } else { 4112 return (com.google.protobuf.ByteString) ref; 4113 } 4114 } 4115 /** 4116 * 4117 * 4118 * <pre> 4119 * A user-defined name of the function. Function names must be unique 4120 * globally and match pattern `projects/*/locations/*/functions/*` 4121 * </pre> 4122 * 4123 * <code>string name = 1;</code> 4124 * 4125 * @param value The name to set. 4126 * @return This builder for chaining. 4127 */ setName(java.lang.String value)4128 public Builder setName(java.lang.String value) { 4129 if (value == null) { 4130 throw new NullPointerException(); 4131 } 4132 name_ = value; 4133 bitField0_ |= 0x00000001; 4134 onChanged(); 4135 return this; 4136 } 4137 /** 4138 * 4139 * 4140 * <pre> 4141 * A user-defined name of the function. Function names must be unique 4142 * globally and match pattern `projects/*/locations/*/functions/*` 4143 * </pre> 4144 * 4145 * <code>string name = 1;</code> 4146 * 4147 * @return This builder for chaining. 4148 */ clearName()4149 public Builder clearName() { 4150 name_ = getDefaultInstance().getName(); 4151 bitField0_ = (bitField0_ & ~0x00000001); 4152 onChanged(); 4153 return this; 4154 } 4155 /** 4156 * 4157 * 4158 * <pre> 4159 * A user-defined name of the function. Function names must be unique 4160 * globally and match pattern `projects/*/locations/*/functions/*` 4161 * </pre> 4162 * 4163 * <code>string name = 1;</code> 4164 * 4165 * @param value The bytes for name to set. 4166 * @return This builder for chaining. 4167 */ setNameBytes(com.google.protobuf.ByteString value)4168 public Builder setNameBytes(com.google.protobuf.ByteString value) { 4169 if (value == null) { 4170 throw new NullPointerException(); 4171 } 4172 checkByteStringIsUtf8(value); 4173 name_ = value; 4174 bitField0_ |= 0x00000001; 4175 onChanged(); 4176 return this; 4177 } 4178 4179 private java.lang.Object description_ = ""; 4180 /** 4181 * 4182 * 4183 * <pre> 4184 * User-provided description of a function. 4185 * </pre> 4186 * 4187 * <code>string description = 2;</code> 4188 * 4189 * @return The description. 4190 */ getDescription()4191 public java.lang.String getDescription() { 4192 java.lang.Object ref = description_; 4193 if (!(ref instanceof java.lang.String)) { 4194 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 4195 java.lang.String s = bs.toStringUtf8(); 4196 description_ = s; 4197 return s; 4198 } else { 4199 return (java.lang.String) ref; 4200 } 4201 } 4202 /** 4203 * 4204 * 4205 * <pre> 4206 * User-provided description of a function. 4207 * </pre> 4208 * 4209 * <code>string description = 2;</code> 4210 * 4211 * @return The bytes for description. 4212 */ getDescriptionBytes()4213 public com.google.protobuf.ByteString getDescriptionBytes() { 4214 java.lang.Object ref = description_; 4215 if (ref instanceof String) { 4216 com.google.protobuf.ByteString b = 4217 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 4218 description_ = b; 4219 return b; 4220 } else { 4221 return (com.google.protobuf.ByteString) ref; 4222 } 4223 } 4224 /** 4225 * 4226 * 4227 * <pre> 4228 * User-provided description of a function. 4229 * </pre> 4230 * 4231 * <code>string description = 2;</code> 4232 * 4233 * @param value The description to set. 4234 * @return This builder for chaining. 4235 */ setDescription(java.lang.String value)4236 public Builder setDescription(java.lang.String value) { 4237 if (value == null) { 4238 throw new NullPointerException(); 4239 } 4240 description_ = value; 4241 bitField0_ |= 0x00000002; 4242 onChanged(); 4243 return this; 4244 } 4245 /** 4246 * 4247 * 4248 * <pre> 4249 * User-provided description of a function. 4250 * </pre> 4251 * 4252 * <code>string description = 2;</code> 4253 * 4254 * @return This builder for chaining. 4255 */ clearDescription()4256 public Builder clearDescription() { 4257 description_ = getDefaultInstance().getDescription(); 4258 bitField0_ = (bitField0_ & ~0x00000002); 4259 onChanged(); 4260 return this; 4261 } 4262 /** 4263 * 4264 * 4265 * <pre> 4266 * User-provided description of a function. 4267 * </pre> 4268 * 4269 * <code>string description = 2;</code> 4270 * 4271 * @param value The bytes for description to set. 4272 * @return This builder for chaining. 4273 */ setDescriptionBytes(com.google.protobuf.ByteString value)4274 public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { 4275 if (value == null) { 4276 throw new NullPointerException(); 4277 } 4278 checkByteStringIsUtf8(value); 4279 description_ = value; 4280 bitField0_ |= 0x00000002; 4281 onChanged(); 4282 return this; 4283 } 4284 4285 /** 4286 * 4287 * 4288 * <pre> 4289 * The Google Cloud Storage URL, starting with `gs://`, pointing to the zip 4290 * archive which contains the function. 4291 * </pre> 4292 * 4293 * <code>string source_archive_url = 3;</code> 4294 * 4295 * @return Whether the sourceArchiveUrl field is set. 4296 */ 4297 @java.lang.Override hasSourceArchiveUrl()4298 public boolean hasSourceArchiveUrl() { 4299 return sourceCodeCase_ == 3; 4300 } 4301 /** 4302 * 4303 * 4304 * <pre> 4305 * The Google Cloud Storage URL, starting with `gs://`, pointing to the zip 4306 * archive which contains the function. 4307 * </pre> 4308 * 4309 * <code>string source_archive_url = 3;</code> 4310 * 4311 * @return The sourceArchiveUrl. 4312 */ 4313 @java.lang.Override getSourceArchiveUrl()4314 public java.lang.String getSourceArchiveUrl() { 4315 java.lang.Object ref = ""; 4316 if (sourceCodeCase_ == 3) { 4317 ref = sourceCode_; 4318 } 4319 if (!(ref instanceof java.lang.String)) { 4320 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 4321 java.lang.String s = bs.toStringUtf8(); 4322 if (sourceCodeCase_ == 3) { 4323 sourceCode_ = s; 4324 } 4325 return s; 4326 } else { 4327 return (java.lang.String) ref; 4328 } 4329 } 4330 /** 4331 * 4332 * 4333 * <pre> 4334 * The Google Cloud Storage URL, starting with `gs://`, pointing to the zip 4335 * archive which contains the function. 4336 * </pre> 4337 * 4338 * <code>string source_archive_url = 3;</code> 4339 * 4340 * @return The bytes for sourceArchiveUrl. 4341 */ 4342 @java.lang.Override getSourceArchiveUrlBytes()4343 public com.google.protobuf.ByteString getSourceArchiveUrlBytes() { 4344 java.lang.Object ref = ""; 4345 if (sourceCodeCase_ == 3) { 4346 ref = sourceCode_; 4347 } 4348 if (ref instanceof String) { 4349 com.google.protobuf.ByteString b = 4350 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 4351 if (sourceCodeCase_ == 3) { 4352 sourceCode_ = b; 4353 } 4354 return b; 4355 } else { 4356 return (com.google.protobuf.ByteString) ref; 4357 } 4358 } 4359 /** 4360 * 4361 * 4362 * <pre> 4363 * The Google Cloud Storage URL, starting with `gs://`, pointing to the zip 4364 * archive which contains the function. 4365 * </pre> 4366 * 4367 * <code>string source_archive_url = 3;</code> 4368 * 4369 * @param value The sourceArchiveUrl to set. 4370 * @return This builder for chaining. 4371 */ setSourceArchiveUrl(java.lang.String value)4372 public Builder setSourceArchiveUrl(java.lang.String value) { 4373 if (value == null) { 4374 throw new NullPointerException(); 4375 } 4376 sourceCodeCase_ = 3; 4377 sourceCode_ = value; 4378 onChanged(); 4379 return this; 4380 } 4381 /** 4382 * 4383 * 4384 * <pre> 4385 * The Google Cloud Storage URL, starting with `gs://`, pointing to the zip 4386 * archive which contains the function. 4387 * </pre> 4388 * 4389 * <code>string source_archive_url = 3;</code> 4390 * 4391 * @return This builder for chaining. 4392 */ clearSourceArchiveUrl()4393 public Builder clearSourceArchiveUrl() { 4394 if (sourceCodeCase_ == 3) { 4395 sourceCodeCase_ = 0; 4396 sourceCode_ = null; 4397 onChanged(); 4398 } 4399 return this; 4400 } 4401 /** 4402 * 4403 * 4404 * <pre> 4405 * The Google Cloud Storage URL, starting with `gs://`, pointing to the zip 4406 * archive which contains the function. 4407 * </pre> 4408 * 4409 * <code>string source_archive_url = 3;</code> 4410 * 4411 * @param value The bytes for sourceArchiveUrl to set. 4412 * @return This builder for chaining. 4413 */ setSourceArchiveUrlBytes(com.google.protobuf.ByteString value)4414 public Builder setSourceArchiveUrlBytes(com.google.protobuf.ByteString value) { 4415 if (value == null) { 4416 throw new NullPointerException(); 4417 } 4418 checkByteStringIsUtf8(value); 4419 sourceCodeCase_ = 3; 4420 sourceCode_ = value; 4421 onChanged(); 4422 return this; 4423 } 4424 4425 private com.google.protobuf.SingleFieldBuilderV3< 4426 com.google.cloud.functions.v1.SourceRepository, 4427 com.google.cloud.functions.v1.SourceRepository.Builder, 4428 com.google.cloud.functions.v1.SourceRepositoryOrBuilder> 4429 sourceRepositoryBuilder_; 4430 /** 4431 * 4432 * 4433 * <pre> 4434 * **Beta Feature** 4435 * The source repository where a function is hosted. 4436 * </pre> 4437 * 4438 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 4439 * 4440 * @return Whether the sourceRepository field is set. 4441 */ 4442 @java.lang.Override hasSourceRepository()4443 public boolean hasSourceRepository() { 4444 return sourceCodeCase_ == 4; 4445 } 4446 /** 4447 * 4448 * 4449 * <pre> 4450 * **Beta Feature** 4451 * The source repository where a function is hosted. 4452 * </pre> 4453 * 4454 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 4455 * 4456 * @return The sourceRepository. 4457 */ 4458 @java.lang.Override getSourceRepository()4459 public com.google.cloud.functions.v1.SourceRepository getSourceRepository() { 4460 if (sourceRepositoryBuilder_ == null) { 4461 if (sourceCodeCase_ == 4) { 4462 return (com.google.cloud.functions.v1.SourceRepository) sourceCode_; 4463 } 4464 return com.google.cloud.functions.v1.SourceRepository.getDefaultInstance(); 4465 } else { 4466 if (sourceCodeCase_ == 4) { 4467 return sourceRepositoryBuilder_.getMessage(); 4468 } 4469 return com.google.cloud.functions.v1.SourceRepository.getDefaultInstance(); 4470 } 4471 } 4472 /** 4473 * 4474 * 4475 * <pre> 4476 * **Beta Feature** 4477 * The source repository where a function is hosted. 4478 * </pre> 4479 * 4480 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 4481 */ setSourceRepository(com.google.cloud.functions.v1.SourceRepository value)4482 public Builder setSourceRepository(com.google.cloud.functions.v1.SourceRepository value) { 4483 if (sourceRepositoryBuilder_ == null) { 4484 if (value == null) { 4485 throw new NullPointerException(); 4486 } 4487 sourceCode_ = value; 4488 onChanged(); 4489 } else { 4490 sourceRepositoryBuilder_.setMessage(value); 4491 } 4492 sourceCodeCase_ = 4; 4493 return this; 4494 } 4495 /** 4496 * 4497 * 4498 * <pre> 4499 * **Beta Feature** 4500 * The source repository where a function is hosted. 4501 * </pre> 4502 * 4503 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 4504 */ setSourceRepository( com.google.cloud.functions.v1.SourceRepository.Builder builderForValue)4505 public Builder setSourceRepository( 4506 com.google.cloud.functions.v1.SourceRepository.Builder builderForValue) { 4507 if (sourceRepositoryBuilder_ == null) { 4508 sourceCode_ = builderForValue.build(); 4509 onChanged(); 4510 } else { 4511 sourceRepositoryBuilder_.setMessage(builderForValue.build()); 4512 } 4513 sourceCodeCase_ = 4; 4514 return this; 4515 } 4516 /** 4517 * 4518 * 4519 * <pre> 4520 * **Beta Feature** 4521 * The source repository where a function is hosted. 4522 * </pre> 4523 * 4524 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 4525 */ mergeSourceRepository(com.google.cloud.functions.v1.SourceRepository value)4526 public Builder mergeSourceRepository(com.google.cloud.functions.v1.SourceRepository value) { 4527 if (sourceRepositoryBuilder_ == null) { 4528 if (sourceCodeCase_ == 4 4529 && sourceCode_ != com.google.cloud.functions.v1.SourceRepository.getDefaultInstance()) { 4530 sourceCode_ = 4531 com.google.cloud.functions.v1.SourceRepository.newBuilder( 4532 (com.google.cloud.functions.v1.SourceRepository) sourceCode_) 4533 .mergeFrom(value) 4534 .buildPartial(); 4535 } else { 4536 sourceCode_ = value; 4537 } 4538 onChanged(); 4539 } else { 4540 if (sourceCodeCase_ == 4) { 4541 sourceRepositoryBuilder_.mergeFrom(value); 4542 } else { 4543 sourceRepositoryBuilder_.setMessage(value); 4544 } 4545 } 4546 sourceCodeCase_ = 4; 4547 return this; 4548 } 4549 /** 4550 * 4551 * 4552 * <pre> 4553 * **Beta Feature** 4554 * The source repository where a function is hosted. 4555 * </pre> 4556 * 4557 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 4558 */ clearSourceRepository()4559 public Builder clearSourceRepository() { 4560 if (sourceRepositoryBuilder_ == null) { 4561 if (sourceCodeCase_ == 4) { 4562 sourceCodeCase_ = 0; 4563 sourceCode_ = null; 4564 onChanged(); 4565 } 4566 } else { 4567 if (sourceCodeCase_ == 4) { 4568 sourceCodeCase_ = 0; 4569 sourceCode_ = null; 4570 } 4571 sourceRepositoryBuilder_.clear(); 4572 } 4573 return this; 4574 } 4575 /** 4576 * 4577 * 4578 * <pre> 4579 * **Beta Feature** 4580 * The source repository where a function is hosted. 4581 * </pre> 4582 * 4583 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 4584 */ getSourceRepositoryBuilder()4585 public com.google.cloud.functions.v1.SourceRepository.Builder getSourceRepositoryBuilder() { 4586 return getSourceRepositoryFieldBuilder().getBuilder(); 4587 } 4588 /** 4589 * 4590 * 4591 * <pre> 4592 * **Beta Feature** 4593 * The source repository where a function is hosted. 4594 * </pre> 4595 * 4596 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 4597 */ 4598 @java.lang.Override getSourceRepositoryOrBuilder()4599 public com.google.cloud.functions.v1.SourceRepositoryOrBuilder getSourceRepositoryOrBuilder() { 4600 if ((sourceCodeCase_ == 4) && (sourceRepositoryBuilder_ != null)) { 4601 return sourceRepositoryBuilder_.getMessageOrBuilder(); 4602 } else { 4603 if (sourceCodeCase_ == 4) { 4604 return (com.google.cloud.functions.v1.SourceRepository) sourceCode_; 4605 } 4606 return com.google.cloud.functions.v1.SourceRepository.getDefaultInstance(); 4607 } 4608 } 4609 /** 4610 * 4611 * 4612 * <pre> 4613 * **Beta Feature** 4614 * The source repository where a function is hosted. 4615 * </pre> 4616 * 4617 * <code>.google.cloud.functions.v1.SourceRepository source_repository = 4;</code> 4618 */ 4619 private com.google.protobuf.SingleFieldBuilderV3< 4620 com.google.cloud.functions.v1.SourceRepository, 4621 com.google.cloud.functions.v1.SourceRepository.Builder, 4622 com.google.cloud.functions.v1.SourceRepositoryOrBuilder> getSourceRepositoryFieldBuilder()4623 getSourceRepositoryFieldBuilder() { 4624 if (sourceRepositoryBuilder_ == null) { 4625 if (!(sourceCodeCase_ == 4)) { 4626 sourceCode_ = com.google.cloud.functions.v1.SourceRepository.getDefaultInstance(); 4627 } 4628 sourceRepositoryBuilder_ = 4629 new com.google.protobuf.SingleFieldBuilderV3< 4630 com.google.cloud.functions.v1.SourceRepository, 4631 com.google.cloud.functions.v1.SourceRepository.Builder, 4632 com.google.cloud.functions.v1.SourceRepositoryOrBuilder>( 4633 (com.google.cloud.functions.v1.SourceRepository) sourceCode_, 4634 getParentForChildren(), 4635 isClean()); 4636 sourceCode_ = null; 4637 } 4638 sourceCodeCase_ = 4; 4639 onChanged(); 4640 return sourceRepositoryBuilder_; 4641 } 4642 4643 /** 4644 * 4645 * 4646 * <pre> 4647 * The Google Cloud Storage-signed URL used for source uploading, generated 4648 * by calling [google.cloud.functions.v1.GenerateUploadUrl]. 4649 * The signature is validated on write methods (Create, Update) 4650 * The signature is stripped from the Function object on read methods (Get, 4651 * List) 4652 * </pre> 4653 * 4654 * <code>string source_upload_url = 16;</code> 4655 * 4656 * @return Whether the sourceUploadUrl field is set. 4657 */ 4658 @java.lang.Override hasSourceUploadUrl()4659 public boolean hasSourceUploadUrl() { 4660 return sourceCodeCase_ == 16; 4661 } 4662 /** 4663 * 4664 * 4665 * <pre> 4666 * The Google Cloud Storage-signed URL used for source uploading, generated 4667 * by calling [google.cloud.functions.v1.GenerateUploadUrl]. 4668 * The signature is validated on write methods (Create, Update) 4669 * The signature is stripped from the Function object on read methods (Get, 4670 * List) 4671 * </pre> 4672 * 4673 * <code>string source_upload_url = 16;</code> 4674 * 4675 * @return The sourceUploadUrl. 4676 */ 4677 @java.lang.Override getSourceUploadUrl()4678 public java.lang.String getSourceUploadUrl() { 4679 java.lang.Object ref = ""; 4680 if (sourceCodeCase_ == 16) { 4681 ref = sourceCode_; 4682 } 4683 if (!(ref instanceof java.lang.String)) { 4684 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 4685 java.lang.String s = bs.toStringUtf8(); 4686 if (sourceCodeCase_ == 16) { 4687 sourceCode_ = s; 4688 } 4689 return s; 4690 } else { 4691 return (java.lang.String) ref; 4692 } 4693 } 4694 /** 4695 * 4696 * 4697 * <pre> 4698 * The Google Cloud Storage-signed URL used for source uploading, generated 4699 * by calling [google.cloud.functions.v1.GenerateUploadUrl]. 4700 * The signature is validated on write methods (Create, Update) 4701 * The signature is stripped from the Function object on read methods (Get, 4702 * List) 4703 * </pre> 4704 * 4705 * <code>string source_upload_url = 16;</code> 4706 * 4707 * @return The bytes for sourceUploadUrl. 4708 */ 4709 @java.lang.Override getSourceUploadUrlBytes()4710 public com.google.protobuf.ByteString getSourceUploadUrlBytes() { 4711 java.lang.Object ref = ""; 4712 if (sourceCodeCase_ == 16) { 4713 ref = sourceCode_; 4714 } 4715 if (ref instanceof String) { 4716 com.google.protobuf.ByteString b = 4717 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 4718 if (sourceCodeCase_ == 16) { 4719 sourceCode_ = b; 4720 } 4721 return b; 4722 } else { 4723 return (com.google.protobuf.ByteString) ref; 4724 } 4725 } 4726 /** 4727 * 4728 * 4729 * <pre> 4730 * The Google Cloud Storage-signed URL used for source uploading, generated 4731 * by calling [google.cloud.functions.v1.GenerateUploadUrl]. 4732 * The signature is validated on write methods (Create, Update) 4733 * The signature is stripped from the Function object on read methods (Get, 4734 * List) 4735 * </pre> 4736 * 4737 * <code>string source_upload_url = 16;</code> 4738 * 4739 * @param value The sourceUploadUrl to set. 4740 * @return This builder for chaining. 4741 */ setSourceUploadUrl(java.lang.String value)4742 public Builder setSourceUploadUrl(java.lang.String value) { 4743 if (value == null) { 4744 throw new NullPointerException(); 4745 } 4746 sourceCodeCase_ = 16; 4747 sourceCode_ = value; 4748 onChanged(); 4749 return this; 4750 } 4751 /** 4752 * 4753 * 4754 * <pre> 4755 * The Google Cloud Storage-signed URL used for source uploading, generated 4756 * by calling [google.cloud.functions.v1.GenerateUploadUrl]. 4757 * The signature is validated on write methods (Create, Update) 4758 * The signature is stripped from the Function object on read methods (Get, 4759 * List) 4760 * </pre> 4761 * 4762 * <code>string source_upload_url = 16;</code> 4763 * 4764 * @return This builder for chaining. 4765 */ clearSourceUploadUrl()4766 public Builder clearSourceUploadUrl() { 4767 if (sourceCodeCase_ == 16) { 4768 sourceCodeCase_ = 0; 4769 sourceCode_ = null; 4770 onChanged(); 4771 } 4772 return this; 4773 } 4774 /** 4775 * 4776 * 4777 * <pre> 4778 * The Google Cloud Storage-signed URL used for source uploading, generated 4779 * by calling [google.cloud.functions.v1.GenerateUploadUrl]. 4780 * The signature is validated on write methods (Create, Update) 4781 * The signature is stripped from the Function object on read methods (Get, 4782 * List) 4783 * </pre> 4784 * 4785 * <code>string source_upload_url = 16;</code> 4786 * 4787 * @param value The bytes for sourceUploadUrl to set. 4788 * @return This builder for chaining. 4789 */ setSourceUploadUrlBytes(com.google.protobuf.ByteString value)4790 public Builder setSourceUploadUrlBytes(com.google.protobuf.ByteString value) { 4791 if (value == null) { 4792 throw new NullPointerException(); 4793 } 4794 checkByteStringIsUtf8(value); 4795 sourceCodeCase_ = 16; 4796 sourceCode_ = value; 4797 onChanged(); 4798 return this; 4799 } 4800 4801 private com.google.protobuf.SingleFieldBuilderV3< 4802 com.google.cloud.functions.v1.HttpsTrigger, 4803 com.google.cloud.functions.v1.HttpsTrigger.Builder, 4804 com.google.cloud.functions.v1.HttpsTriggerOrBuilder> 4805 httpsTriggerBuilder_; 4806 /** 4807 * 4808 * 4809 * <pre> 4810 * An HTTPS endpoint type of source that can be triggered via URL. 4811 * </pre> 4812 * 4813 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 4814 * 4815 * @return Whether the httpsTrigger field is set. 4816 */ 4817 @java.lang.Override hasHttpsTrigger()4818 public boolean hasHttpsTrigger() { 4819 return triggerCase_ == 5; 4820 } 4821 /** 4822 * 4823 * 4824 * <pre> 4825 * An HTTPS endpoint type of source that can be triggered via URL. 4826 * </pre> 4827 * 4828 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 4829 * 4830 * @return The httpsTrigger. 4831 */ 4832 @java.lang.Override getHttpsTrigger()4833 public com.google.cloud.functions.v1.HttpsTrigger getHttpsTrigger() { 4834 if (httpsTriggerBuilder_ == null) { 4835 if (triggerCase_ == 5) { 4836 return (com.google.cloud.functions.v1.HttpsTrigger) trigger_; 4837 } 4838 return com.google.cloud.functions.v1.HttpsTrigger.getDefaultInstance(); 4839 } else { 4840 if (triggerCase_ == 5) { 4841 return httpsTriggerBuilder_.getMessage(); 4842 } 4843 return com.google.cloud.functions.v1.HttpsTrigger.getDefaultInstance(); 4844 } 4845 } 4846 /** 4847 * 4848 * 4849 * <pre> 4850 * An HTTPS endpoint type of source that can be triggered via URL. 4851 * </pre> 4852 * 4853 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 4854 */ setHttpsTrigger(com.google.cloud.functions.v1.HttpsTrigger value)4855 public Builder setHttpsTrigger(com.google.cloud.functions.v1.HttpsTrigger value) { 4856 if (httpsTriggerBuilder_ == null) { 4857 if (value == null) { 4858 throw new NullPointerException(); 4859 } 4860 trigger_ = value; 4861 onChanged(); 4862 } else { 4863 httpsTriggerBuilder_.setMessage(value); 4864 } 4865 triggerCase_ = 5; 4866 return this; 4867 } 4868 /** 4869 * 4870 * 4871 * <pre> 4872 * An HTTPS endpoint type of source that can be triggered via URL. 4873 * </pre> 4874 * 4875 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 4876 */ setHttpsTrigger( com.google.cloud.functions.v1.HttpsTrigger.Builder builderForValue)4877 public Builder setHttpsTrigger( 4878 com.google.cloud.functions.v1.HttpsTrigger.Builder builderForValue) { 4879 if (httpsTriggerBuilder_ == null) { 4880 trigger_ = builderForValue.build(); 4881 onChanged(); 4882 } else { 4883 httpsTriggerBuilder_.setMessage(builderForValue.build()); 4884 } 4885 triggerCase_ = 5; 4886 return this; 4887 } 4888 /** 4889 * 4890 * 4891 * <pre> 4892 * An HTTPS endpoint type of source that can be triggered via URL. 4893 * </pre> 4894 * 4895 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 4896 */ mergeHttpsTrigger(com.google.cloud.functions.v1.HttpsTrigger value)4897 public Builder mergeHttpsTrigger(com.google.cloud.functions.v1.HttpsTrigger value) { 4898 if (httpsTriggerBuilder_ == null) { 4899 if (triggerCase_ == 5 4900 && trigger_ != com.google.cloud.functions.v1.HttpsTrigger.getDefaultInstance()) { 4901 trigger_ = 4902 com.google.cloud.functions.v1.HttpsTrigger.newBuilder( 4903 (com.google.cloud.functions.v1.HttpsTrigger) trigger_) 4904 .mergeFrom(value) 4905 .buildPartial(); 4906 } else { 4907 trigger_ = value; 4908 } 4909 onChanged(); 4910 } else { 4911 if (triggerCase_ == 5) { 4912 httpsTriggerBuilder_.mergeFrom(value); 4913 } else { 4914 httpsTriggerBuilder_.setMessage(value); 4915 } 4916 } 4917 triggerCase_ = 5; 4918 return this; 4919 } 4920 /** 4921 * 4922 * 4923 * <pre> 4924 * An HTTPS endpoint type of source that can be triggered via URL. 4925 * </pre> 4926 * 4927 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 4928 */ clearHttpsTrigger()4929 public Builder clearHttpsTrigger() { 4930 if (httpsTriggerBuilder_ == null) { 4931 if (triggerCase_ == 5) { 4932 triggerCase_ = 0; 4933 trigger_ = null; 4934 onChanged(); 4935 } 4936 } else { 4937 if (triggerCase_ == 5) { 4938 triggerCase_ = 0; 4939 trigger_ = null; 4940 } 4941 httpsTriggerBuilder_.clear(); 4942 } 4943 return this; 4944 } 4945 /** 4946 * 4947 * 4948 * <pre> 4949 * An HTTPS endpoint type of source that can be triggered via URL. 4950 * </pre> 4951 * 4952 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 4953 */ getHttpsTriggerBuilder()4954 public com.google.cloud.functions.v1.HttpsTrigger.Builder getHttpsTriggerBuilder() { 4955 return getHttpsTriggerFieldBuilder().getBuilder(); 4956 } 4957 /** 4958 * 4959 * 4960 * <pre> 4961 * An HTTPS endpoint type of source that can be triggered via URL. 4962 * </pre> 4963 * 4964 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 4965 */ 4966 @java.lang.Override getHttpsTriggerOrBuilder()4967 public com.google.cloud.functions.v1.HttpsTriggerOrBuilder getHttpsTriggerOrBuilder() { 4968 if ((triggerCase_ == 5) && (httpsTriggerBuilder_ != null)) { 4969 return httpsTriggerBuilder_.getMessageOrBuilder(); 4970 } else { 4971 if (triggerCase_ == 5) { 4972 return (com.google.cloud.functions.v1.HttpsTrigger) trigger_; 4973 } 4974 return com.google.cloud.functions.v1.HttpsTrigger.getDefaultInstance(); 4975 } 4976 } 4977 /** 4978 * 4979 * 4980 * <pre> 4981 * An HTTPS endpoint type of source that can be triggered via URL. 4982 * </pre> 4983 * 4984 * <code>.google.cloud.functions.v1.HttpsTrigger https_trigger = 5;</code> 4985 */ 4986 private com.google.protobuf.SingleFieldBuilderV3< 4987 com.google.cloud.functions.v1.HttpsTrigger, 4988 com.google.cloud.functions.v1.HttpsTrigger.Builder, 4989 com.google.cloud.functions.v1.HttpsTriggerOrBuilder> getHttpsTriggerFieldBuilder()4990 getHttpsTriggerFieldBuilder() { 4991 if (httpsTriggerBuilder_ == null) { 4992 if (!(triggerCase_ == 5)) { 4993 trigger_ = com.google.cloud.functions.v1.HttpsTrigger.getDefaultInstance(); 4994 } 4995 httpsTriggerBuilder_ = 4996 new com.google.protobuf.SingleFieldBuilderV3< 4997 com.google.cloud.functions.v1.HttpsTrigger, 4998 com.google.cloud.functions.v1.HttpsTrigger.Builder, 4999 com.google.cloud.functions.v1.HttpsTriggerOrBuilder>( 5000 (com.google.cloud.functions.v1.HttpsTrigger) trigger_, 5001 getParentForChildren(), 5002 isClean()); 5003 trigger_ = null; 5004 } 5005 triggerCase_ = 5; 5006 onChanged(); 5007 return httpsTriggerBuilder_; 5008 } 5009 5010 private com.google.protobuf.SingleFieldBuilderV3< 5011 com.google.cloud.functions.v1.EventTrigger, 5012 com.google.cloud.functions.v1.EventTrigger.Builder, 5013 com.google.cloud.functions.v1.EventTriggerOrBuilder> 5014 eventTriggerBuilder_; 5015 /** 5016 * 5017 * 5018 * <pre> 5019 * A source that fires events in response to a condition in another service. 5020 * </pre> 5021 * 5022 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 5023 * 5024 * @return Whether the eventTrigger field is set. 5025 */ 5026 @java.lang.Override hasEventTrigger()5027 public boolean hasEventTrigger() { 5028 return triggerCase_ == 6; 5029 } 5030 /** 5031 * 5032 * 5033 * <pre> 5034 * A source that fires events in response to a condition in another service. 5035 * </pre> 5036 * 5037 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 5038 * 5039 * @return The eventTrigger. 5040 */ 5041 @java.lang.Override getEventTrigger()5042 public com.google.cloud.functions.v1.EventTrigger getEventTrigger() { 5043 if (eventTriggerBuilder_ == null) { 5044 if (triggerCase_ == 6) { 5045 return (com.google.cloud.functions.v1.EventTrigger) trigger_; 5046 } 5047 return com.google.cloud.functions.v1.EventTrigger.getDefaultInstance(); 5048 } else { 5049 if (triggerCase_ == 6) { 5050 return eventTriggerBuilder_.getMessage(); 5051 } 5052 return com.google.cloud.functions.v1.EventTrigger.getDefaultInstance(); 5053 } 5054 } 5055 /** 5056 * 5057 * 5058 * <pre> 5059 * A source that fires events in response to a condition in another service. 5060 * </pre> 5061 * 5062 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 5063 */ setEventTrigger(com.google.cloud.functions.v1.EventTrigger value)5064 public Builder setEventTrigger(com.google.cloud.functions.v1.EventTrigger value) { 5065 if (eventTriggerBuilder_ == null) { 5066 if (value == null) { 5067 throw new NullPointerException(); 5068 } 5069 trigger_ = value; 5070 onChanged(); 5071 } else { 5072 eventTriggerBuilder_.setMessage(value); 5073 } 5074 triggerCase_ = 6; 5075 return this; 5076 } 5077 /** 5078 * 5079 * 5080 * <pre> 5081 * A source that fires events in response to a condition in another service. 5082 * </pre> 5083 * 5084 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 5085 */ setEventTrigger( com.google.cloud.functions.v1.EventTrigger.Builder builderForValue)5086 public Builder setEventTrigger( 5087 com.google.cloud.functions.v1.EventTrigger.Builder builderForValue) { 5088 if (eventTriggerBuilder_ == null) { 5089 trigger_ = builderForValue.build(); 5090 onChanged(); 5091 } else { 5092 eventTriggerBuilder_.setMessage(builderForValue.build()); 5093 } 5094 triggerCase_ = 6; 5095 return this; 5096 } 5097 /** 5098 * 5099 * 5100 * <pre> 5101 * A source that fires events in response to a condition in another service. 5102 * </pre> 5103 * 5104 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 5105 */ mergeEventTrigger(com.google.cloud.functions.v1.EventTrigger value)5106 public Builder mergeEventTrigger(com.google.cloud.functions.v1.EventTrigger value) { 5107 if (eventTriggerBuilder_ == null) { 5108 if (triggerCase_ == 6 5109 && trigger_ != com.google.cloud.functions.v1.EventTrigger.getDefaultInstance()) { 5110 trigger_ = 5111 com.google.cloud.functions.v1.EventTrigger.newBuilder( 5112 (com.google.cloud.functions.v1.EventTrigger) trigger_) 5113 .mergeFrom(value) 5114 .buildPartial(); 5115 } else { 5116 trigger_ = value; 5117 } 5118 onChanged(); 5119 } else { 5120 if (triggerCase_ == 6) { 5121 eventTriggerBuilder_.mergeFrom(value); 5122 } else { 5123 eventTriggerBuilder_.setMessage(value); 5124 } 5125 } 5126 triggerCase_ = 6; 5127 return this; 5128 } 5129 /** 5130 * 5131 * 5132 * <pre> 5133 * A source that fires events in response to a condition in another service. 5134 * </pre> 5135 * 5136 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 5137 */ clearEventTrigger()5138 public Builder clearEventTrigger() { 5139 if (eventTriggerBuilder_ == null) { 5140 if (triggerCase_ == 6) { 5141 triggerCase_ = 0; 5142 trigger_ = null; 5143 onChanged(); 5144 } 5145 } else { 5146 if (triggerCase_ == 6) { 5147 triggerCase_ = 0; 5148 trigger_ = null; 5149 } 5150 eventTriggerBuilder_.clear(); 5151 } 5152 return this; 5153 } 5154 /** 5155 * 5156 * 5157 * <pre> 5158 * A source that fires events in response to a condition in another service. 5159 * </pre> 5160 * 5161 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 5162 */ getEventTriggerBuilder()5163 public com.google.cloud.functions.v1.EventTrigger.Builder getEventTriggerBuilder() { 5164 return getEventTriggerFieldBuilder().getBuilder(); 5165 } 5166 /** 5167 * 5168 * 5169 * <pre> 5170 * A source that fires events in response to a condition in another service. 5171 * </pre> 5172 * 5173 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 5174 */ 5175 @java.lang.Override getEventTriggerOrBuilder()5176 public com.google.cloud.functions.v1.EventTriggerOrBuilder getEventTriggerOrBuilder() { 5177 if ((triggerCase_ == 6) && (eventTriggerBuilder_ != null)) { 5178 return eventTriggerBuilder_.getMessageOrBuilder(); 5179 } else { 5180 if (triggerCase_ == 6) { 5181 return (com.google.cloud.functions.v1.EventTrigger) trigger_; 5182 } 5183 return com.google.cloud.functions.v1.EventTrigger.getDefaultInstance(); 5184 } 5185 } 5186 /** 5187 * 5188 * 5189 * <pre> 5190 * A source that fires events in response to a condition in another service. 5191 * </pre> 5192 * 5193 * <code>.google.cloud.functions.v1.EventTrigger event_trigger = 6;</code> 5194 */ 5195 private com.google.protobuf.SingleFieldBuilderV3< 5196 com.google.cloud.functions.v1.EventTrigger, 5197 com.google.cloud.functions.v1.EventTrigger.Builder, 5198 com.google.cloud.functions.v1.EventTriggerOrBuilder> getEventTriggerFieldBuilder()5199 getEventTriggerFieldBuilder() { 5200 if (eventTriggerBuilder_ == null) { 5201 if (!(triggerCase_ == 6)) { 5202 trigger_ = com.google.cloud.functions.v1.EventTrigger.getDefaultInstance(); 5203 } 5204 eventTriggerBuilder_ = 5205 new com.google.protobuf.SingleFieldBuilderV3< 5206 com.google.cloud.functions.v1.EventTrigger, 5207 com.google.cloud.functions.v1.EventTrigger.Builder, 5208 com.google.cloud.functions.v1.EventTriggerOrBuilder>( 5209 (com.google.cloud.functions.v1.EventTrigger) trigger_, 5210 getParentForChildren(), 5211 isClean()); 5212 trigger_ = null; 5213 } 5214 triggerCase_ = 6; 5215 onChanged(); 5216 return eventTriggerBuilder_; 5217 } 5218 5219 private int status_ = 0; 5220 /** 5221 * 5222 * 5223 * <pre> 5224 * Output only. Status of the function deployment. 5225 * </pre> 5226 * 5227 * <code> 5228 * .google.cloud.functions.v1.CloudFunctionStatus status = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; 5229 * </code> 5230 * 5231 * @return The enum numeric value on the wire for status. 5232 */ 5233 @java.lang.Override getStatusValue()5234 public int getStatusValue() { 5235 return status_; 5236 } 5237 /** 5238 * 5239 * 5240 * <pre> 5241 * Output only. Status of the function deployment. 5242 * </pre> 5243 * 5244 * <code> 5245 * .google.cloud.functions.v1.CloudFunctionStatus status = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; 5246 * </code> 5247 * 5248 * @param value The enum numeric value on the wire for status to set. 5249 * @return This builder for chaining. 5250 */ setStatusValue(int value)5251 public Builder setStatusValue(int value) { 5252 status_ = value; 5253 bitField0_ |= 0x00000080; 5254 onChanged(); 5255 return this; 5256 } 5257 /** 5258 * 5259 * 5260 * <pre> 5261 * Output only. Status of the function deployment. 5262 * </pre> 5263 * 5264 * <code> 5265 * .google.cloud.functions.v1.CloudFunctionStatus status = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; 5266 * </code> 5267 * 5268 * @return The status. 5269 */ 5270 @java.lang.Override getStatus()5271 public com.google.cloud.functions.v1.CloudFunctionStatus getStatus() { 5272 com.google.cloud.functions.v1.CloudFunctionStatus result = 5273 com.google.cloud.functions.v1.CloudFunctionStatus.forNumber(status_); 5274 return result == null 5275 ? com.google.cloud.functions.v1.CloudFunctionStatus.UNRECOGNIZED 5276 : result; 5277 } 5278 /** 5279 * 5280 * 5281 * <pre> 5282 * Output only. Status of the function deployment. 5283 * </pre> 5284 * 5285 * <code> 5286 * .google.cloud.functions.v1.CloudFunctionStatus status = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; 5287 * </code> 5288 * 5289 * @param value The status to set. 5290 * @return This builder for chaining. 5291 */ setStatus(com.google.cloud.functions.v1.CloudFunctionStatus value)5292 public Builder setStatus(com.google.cloud.functions.v1.CloudFunctionStatus value) { 5293 if (value == null) { 5294 throw new NullPointerException(); 5295 } 5296 bitField0_ |= 0x00000080; 5297 status_ = value.getNumber(); 5298 onChanged(); 5299 return this; 5300 } 5301 /** 5302 * 5303 * 5304 * <pre> 5305 * Output only. Status of the function deployment. 5306 * </pre> 5307 * 5308 * <code> 5309 * .google.cloud.functions.v1.CloudFunctionStatus status = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; 5310 * </code> 5311 * 5312 * @return This builder for chaining. 5313 */ clearStatus()5314 public Builder clearStatus() { 5315 bitField0_ = (bitField0_ & ~0x00000080); 5316 status_ = 0; 5317 onChanged(); 5318 return this; 5319 } 5320 5321 private java.lang.Object entryPoint_ = ""; 5322 /** 5323 * 5324 * 5325 * <pre> 5326 * The name of the function (as defined in source code) that is executed. 5327 * Defaults to the resource name suffix, if not specified. For 5328 * backward compatibility, if function with given name is not found, the 5329 * system tries to use the function named "function". 5330 * For Node.js, this is the name of a function exported by the module 5331 * as specified in `source_location`. 5332 * </pre> 5333 * 5334 * <code>string entry_point = 8;</code> 5335 * 5336 * @return The entryPoint. 5337 */ getEntryPoint()5338 public java.lang.String getEntryPoint() { 5339 java.lang.Object ref = entryPoint_; 5340 if (!(ref instanceof java.lang.String)) { 5341 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 5342 java.lang.String s = bs.toStringUtf8(); 5343 entryPoint_ = s; 5344 return s; 5345 } else { 5346 return (java.lang.String) ref; 5347 } 5348 } 5349 /** 5350 * 5351 * 5352 * <pre> 5353 * The name of the function (as defined in source code) that is executed. 5354 * Defaults to the resource name suffix, if not specified. For 5355 * backward compatibility, if function with given name is not found, the 5356 * system tries to use the function named "function". 5357 * For Node.js, this is the name of a function exported by the module 5358 * as specified in `source_location`. 5359 * </pre> 5360 * 5361 * <code>string entry_point = 8;</code> 5362 * 5363 * @return The bytes for entryPoint. 5364 */ getEntryPointBytes()5365 public com.google.protobuf.ByteString getEntryPointBytes() { 5366 java.lang.Object ref = entryPoint_; 5367 if (ref instanceof String) { 5368 com.google.protobuf.ByteString b = 5369 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 5370 entryPoint_ = b; 5371 return b; 5372 } else { 5373 return (com.google.protobuf.ByteString) ref; 5374 } 5375 } 5376 /** 5377 * 5378 * 5379 * <pre> 5380 * The name of the function (as defined in source code) that is executed. 5381 * Defaults to the resource name suffix, if not specified. For 5382 * backward compatibility, if function with given name is not found, the 5383 * system tries to use the function named "function". 5384 * For Node.js, this is the name of a function exported by the module 5385 * as specified in `source_location`. 5386 * </pre> 5387 * 5388 * <code>string entry_point = 8;</code> 5389 * 5390 * @param value The entryPoint to set. 5391 * @return This builder for chaining. 5392 */ setEntryPoint(java.lang.String value)5393 public Builder setEntryPoint(java.lang.String value) { 5394 if (value == null) { 5395 throw new NullPointerException(); 5396 } 5397 entryPoint_ = value; 5398 bitField0_ |= 0x00000100; 5399 onChanged(); 5400 return this; 5401 } 5402 /** 5403 * 5404 * 5405 * <pre> 5406 * The name of the function (as defined in source code) that is executed. 5407 * Defaults to the resource name suffix, if not specified. For 5408 * backward compatibility, if function with given name is not found, the 5409 * system tries to use the function named "function". 5410 * For Node.js, this is the name of a function exported by the module 5411 * as specified in `source_location`. 5412 * </pre> 5413 * 5414 * <code>string entry_point = 8;</code> 5415 * 5416 * @return This builder for chaining. 5417 */ clearEntryPoint()5418 public Builder clearEntryPoint() { 5419 entryPoint_ = getDefaultInstance().getEntryPoint(); 5420 bitField0_ = (bitField0_ & ~0x00000100); 5421 onChanged(); 5422 return this; 5423 } 5424 /** 5425 * 5426 * 5427 * <pre> 5428 * The name of the function (as defined in source code) that is executed. 5429 * Defaults to the resource name suffix, if not specified. For 5430 * backward compatibility, if function with given name is not found, the 5431 * system tries to use the function named "function". 5432 * For Node.js, this is the name of a function exported by the module 5433 * as specified in `source_location`. 5434 * </pre> 5435 * 5436 * <code>string entry_point = 8;</code> 5437 * 5438 * @param value The bytes for entryPoint to set. 5439 * @return This builder for chaining. 5440 */ setEntryPointBytes(com.google.protobuf.ByteString value)5441 public Builder setEntryPointBytes(com.google.protobuf.ByteString value) { 5442 if (value == null) { 5443 throw new NullPointerException(); 5444 } 5445 checkByteStringIsUtf8(value); 5446 entryPoint_ = value; 5447 bitField0_ |= 0x00000100; 5448 onChanged(); 5449 return this; 5450 } 5451 5452 private java.lang.Object runtime_ = ""; 5453 /** 5454 * 5455 * 5456 * <pre> 5457 * The runtime in which to run the function. Required when deploying a new 5458 * function, optional when updating an existing function. For a complete 5459 * list of possible choices, see the 5460 * [`gcloud` command 5461 * reference](https://cloud.google.com/sdk/gcloud/reference/functions/deploy#--runtime). 5462 * </pre> 5463 * 5464 * <code>string runtime = 19;</code> 5465 * 5466 * @return The runtime. 5467 */ getRuntime()5468 public java.lang.String getRuntime() { 5469 java.lang.Object ref = runtime_; 5470 if (!(ref instanceof java.lang.String)) { 5471 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 5472 java.lang.String s = bs.toStringUtf8(); 5473 runtime_ = s; 5474 return s; 5475 } else { 5476 return (java.lang.String) ref; 5477 } 5478 } 5479 /** 5480 * 5481 * 5482 * <pre> 5483 * The runtime in which to run the function. Required when deploying a new 5484 * function, optional when updating an existing function. For a complete 5485 * list of possible choices, see the 5486 * [`gcloud` command 5487 * reference](https://cloud.google.com/sdk/gcloud/reference/functions/deploy#--runtime). 5488 * </pre> 5489 * 5490 * <code>string runtime = 19;</code> 5491 * 5492 * @return The bytes for runtime. 5493 */ getRuntimeBytes()5494 public com.google.protobuf.ByteString getRuntimeBytes() { 5495 java.lang.Object ref = runtime_; 5496 if (ref instanceof String) { 5497 com.google.protobuf.ByteString b = 5498 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 5499 runtime_ = b; 5500 return b; 5501 } else { 5502 return (com.google.protobuf.ByteString) ref; 5503 } 5504 } 5505 /** 5506 * 5507 * 5508 * <pre> 5509 * The runtime in which to run the function. Required when deploying a new 5510 * function, optional when updating an existing function. For a complete 5511 * list of possible choices, see the 5512 * [`gcloud` command 5513 * reference](https://cloud.google.com/sdk/gcloud/reference/functions/deploy#--runtime). 5514 * </pre> 5515 * 5516 * <code>string runtime = 19;</code> 5517 * 5518 * @param value The runtime to set. 5519 * @return This builder for chaining. 5520 */ setRuntime(java.lang.String value)5521 public Builder setRuntime(java.lang.String value) { 5522 if (value == null) { 5523 throw new NullPointerException(); 5524 } 5525 runtime_ = value; 5526 bitField0_ |= 0x00000200; 5527 onChanged(); 5528 return this; 5529 } 5530 /** 5531 * 5532 * 5533 * <pre> 5534 * The runtime in which to run the function. Required when deploying a new 5535 * function, optional when updating an existing function. For a complete 5536 * list of possible choices, see the 5537 * [`gcloud` command 5538 * reference](https://cloud.google.com/sdk/gcloud/reference/functions/deploy#--runtime). 5539 * </pre> 5540 * 5541 * <code>string runtime = 19;</code> 5542 * 5543 * @return This builder for chaining. 5544 */ clearRuntime()5545 public Builder clearRuntime() { 5546 runtime_ = getDefaultInstance().getRuntime(); 5547 bitField0_ = (bitField0_ & ~0x00000200); 5548 onChanged(); 5549 return this; 5550 } 5551 /** 5552 * 5553 * 5554 * <pre> 5555 * The runtime in which to run the function. Required when deploying a new 5556 * function, optional when updating an existing function. For a complete 5557 * list of possible choices, see the 5558 * [`gcloud` command 5559 * reference](https://cloud.google.com/sdk/gcloud/reference/functions/deploy#--runtime). 5560 * </pre> 5561 * 5562 * <code>string runtime = 19;</code> 5563 * 5564 * @param value The bytes for runtime to set. 5565 * @return This builder for chaining. 5566 */ setRuntimeBytes(com.google.protobuf.ByteString value)5567 public Builder setRuntimeBytes(com.google.protobuf.ByteString value) { 5568 if (value == null) { 5569 throw new NullPointerException(); 5570 } 5571 checkByteStringIsUtf8(value); 5572 runtime_ = value; 5573 bitField0_ |= 0x00000200; 5574 onChanged(); 5575 return this; 5576 } 5577 5578 private com.google.protobuf.Duration timeout_; 5579 private com.google.protobuf.SingleFieldBuilderV3< 5580 com.google.protobuf.Duration, 5581 com.google.protobuf.Duration.Builder, 5582 com.google.protobuf.DurationOrBuilder> 5583 timeoutBuilder_; 5584 /** 5585 * 5586 * 5587 * <pre> 5588 * The function execution timeout. Execution is considered failed and 5589 * can be terminated if the function is not completed at the end of the 5590 * timeout period. Defaults to 60 seconds. 5591 * </pre> 5592 * 5593 * <code>.google.protobuf.Duration timeout = 9;</code> 5594 * 5595 * @return Whether the timeout field is set. 5596 */ hasTimeout()5597 public boolean hasTimeout() { 5598 return ((bitField0_ & 0x00000400) != 0); 5599 } 5600 /** 5601 * 5602 * 5603 * <pre> 5604 * The function execution timeout. Execution is considered failed and 5605 * can be terminated if the function is not completed at the end of the 5606 * timeout period. Defaults to 60 seconds. 5607 * </pre> 5608 * 5609 * <code>.google.protobuf.Duration timeout = 9;</code> 5610 * 5611 * @return The timeout. 5612 */ getTimeout()5613 public com.google.protobuf.Duration getTimeout() { 5614 if (timeoutBuilder_ == null) { 5615 return timeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : timeout_; 5616 } else { 5617 return timeoutBuilder_.getMessage(); 5618 } 5619 } 5620 /** 5621 * 5622 * 5623 * <pre> 5624 * The function execution timeout. Execution is considered failed and 5625 * can be terminated if the function is not completed at the end of the 5626 * timeout period. Defaults to 60 seconds. 5627 * </pre> 5628 * 5629 * <code>.google.protobuf.Duration timeout = 9;</code> 5630 */ setTimeout(com.google.protobuf.Duration value)5631 public Builder setTimeout(com.google.protobuf.Duration value) { 5632 if (timeoutBuilder_ == null) { 5633 if (value == null) { 5634 throw new NullPointerException(); 5635 } 5636 timeout_ = value; 5637 } else { 5638 timeoutBuilder_.setMessage(value); 5639 } 5640 bitField0_ |= 0x00000400; 5641 onChanged(); 5642 return this; 5643 } 5644 /** 5645 * 5646 * 5647 * <pre> 5648 * The function execution timeout. Execution is considered failed and 5649 * can be terminated if the function is not completed at the end of the 5650 * timeout period. Defaults to 60 seconds. 5651 * </pre> 5652 * 5653 * <code>.google.protobuf.Duration timeout = 9;</code> 5654 */ setTimeout(com.google.protobuf.Duration.Builder builderForValue)5655 public Builder setTimeout(com.google.protobuf.Duration.Builder builderForValue) { 5656 if (timeoutBuilder_ == null) { 5657 timeout_ = builderForValue.build(); 5658 } else { 5659 timeoutBuilder_.setMessage(builderForValue.build()); 5660 } 5661 bitField0_ |= 0x00000400; 5662 onChanged(); 5663 return this; 5664 } 5665 /** 5666 * 5667 * 5668 * <pre> 5669 * The function execution timeout. Execution is considered failed and 5670 * can be terminated if the function is not completed at the end of the 5671 * timeout period. Defaults to 60 seconds. 5672 * </pre> 5673 * 5674 * <code>.google.protobuf.Duration timeout = 9;</code> 5675 */ mergeTimeout(com.google.protobuf.Duration value)5676 public Builder mergeTimeout(com.google.protobuf.Duration value) { 5677 if (timeoutBuilder_ == null) { 5678 if (((bitField0_ & 0x00000400) != 0) 5679 && timeout_ != null 5680 && timeout_ != com.google.protobuf.Duration.getDefaultInstance()) { 5681 getTimeoutBuilder().mergeFrom(value); 5682 } else { 5683 timeout_ = value; 5684 } 5685 } else { 5686 timeoutBuilder_.mergeFrom(value); 5687 } 5688 bitField0_ |= 0x00000400; 5689 onChanged(); 5690 return this; 5691 } 5692 /** 5693 * 5694 * 5695 * <pre> 5696 * The function execution timeout. Execution is considered failed and 5697 * can be terminated if the function is not completed at the end of the 5698 * timeout period. Defaults to 60 seconds. 5699 * </pre> 5700 * 5701 * <code>.google.protobuf.Duration timeout = 9;</code> 5702 */ clearTimeout()5703 public Builder clearTimeout() { 5704 bitField0_ = (bitField0_ & ~0x00000400); 5705 timeout_ = null; 5706 if (timeoutBuilder_ != null) { 5707 timeoutBuilder_.dispose(); 5708 timeoutBuilder_ = null; 5709 } 5710 onChanged(); 5711 return this; 5712 } 5713 /** 5714 * 5715 * 5716 * <pre> 5717 * The function execution timeout. Execution is considered failed and 5718 * can be terminated if the function is not completed at the end of the 5719 * timeout period. Defaults to 60 seconds. 5720 * </pre> 5721 * 5722 * <code>.google.protobuf.Duration timeout = 9;</code> 5723 */ getTimeoutBuilder()5724 public com.google.protobuf.Duration.Builder getTimeoutBuilder() { 5725 bitField0_ |= 0x00000400; 5726 onChanged(); 5727 return getTimeoutFieldBuilder().getBuilder(); 5728 } 5729 /** 5730 * 5731 * 5732 * <pre> 5733 * The function execution timeout. Execution is considered failed and 5734 * can be terminated if the function is not completed at the end of the 5735 * timeout period. Defaults to 60 seconds. 5736 * </pre> 5737 * 5738 * <code>.google.protobuf.Duration timeout = 9;</code> 5739 */ getTimeoutOrBuilder()5740 public com.google.protobuf.DurationOrBuilder getTimeoutOrBuilder() { 5741 if (timeoutBuilder_ != null) { 5742 return timeoutBuilder_.getMessageOrBuilder(); 5743 } else { 5744 return timeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : timeout_; 5745 } 5746 } 5747 /** 5748 * 5749 * 5750 * <pre> 5751 * The function execution timeout. Execution is considered failed and 5752 * can be terminated if the function is not completed at the end of the 5753 * timeout period. Defaults to 60 seconds. 5754 * </pre> 5755 * 5756 * <code>.google.protobuf.Duration timeout = 9;</code> 5757 */ 5758 private com.google.protobuf.SingleFieldBuilderV3< 5759 com.google.protobuf.Duration, 5760 com.google.protobuf.Duration.Builder, 5761 com.google.protobuf.DurationOrBuilder> getTimeoutFieldBuilder()5762 getTimeoutFieldBuilder() { 5763 if (timeoutBuilder_ == null) { 5764 timeoutBuilder_ = 5765 new com.google.protobuf.SingleFieldBuilderV3< 5766 com.google.protobuf.Duration, 5767 com.google.protobuf.Duration.Builder, 5768 com.google.protobuf.DurationOrBuilder>( 5769 getTimeout(), getParentForChildren(), isClean()); 5770 timeout_ = null; 5771 } 5772 return timeoutBuilder_; 5773 } 5774 5775 private int availableMemoryMb_; 5776 /** 5777 * 5778 * 5779 * <pre> 5780 * The amount of memory in MB available for a function. 5781 * Defaults to 256MB. 5782 * </pre> 5783 * 5784 * <code>int32 available_memory_mb = 10;</code> 5785 * 5786 * @return The availableMemoryMb. 5787 */ 5788 @java.lang.Override getAvailableMemoryMb()5789 public int getAvailableMemoryMb() { 5790 return availableMemoryMb_; 5791 } 5792 /** 5793 * 5794 * 5795 * <pre> 5796 * The amount of memory in MB available for a function. 5797 * Defaults to 256MB. 5798 * </pre> 5799 * 5800 * <code>int32 available_memory_mb = 10;</code> 5801 * 5802 * @param value The availableMemoryMb to set. 5803 * @return This builder for chaining. 5804 */ setAvailableMemoryMb(int value)5805 public Builder setAvailableMemoryMb(int value) { 5806 5807 availableMemoryMb_ = value; 5808 bitField0_ |= 0x00000800; 5809 onChanged(); 5810 return this; 5811 } 5812 /** 5813 * 5814 * 5815 * <pre> 5816 * The amount of memory in MB available for a function. 5817 * Defaults to 256MB. 5818 * </pre> 5819 * 5820 * <code>int32 available_memory_mb = 10;</code> 5821 * 5822 * @return This builder for chaining. 5823 */ clearAvailableMemoryMb()5824 public Builder clearAvailableMemoryMb() { 5825 bitField0_ = (bitField0_ & ~0x00000800); 5826 availableMemoryMb_ = 0; 5827 onChanged(); 5828 return this; 5829 } 5830 5831 private java.lang.Object serviceAccountEmail_ = ""; 5832 /** 5833 * 5834 * 5835 * <pre> 5836 * The email of the function's service account. If empty, defaults to 5837 * `{project_id}@appspot.gserviceaccount.com`. 5838 * </pre> 5839 * 5840 * <code>string service_account_email = 11;</code> 5841 * 5842 * @return The serviceAccountEmail. 5843 */ getServiceAccountEmail()5844 public java.lang.String getServiceAccountEmail() { 5845 java.lang.Object ref = serviceAccountEmail_; 5846 if (!(ref instanceof java.lang.String)) { 5847 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 5848 java.lang.String s = bs.toStringUtf8(); 5849 serviceAccountEmail_ = s; 5850 return s; 5851 } else { 5852 return (java.lang.String) ref; 5853 } 5854 } 5855 /** 5856 * 5857 * 5858 * <pre> 5859 * The email of the function's service account. If empty, defaults to 5860 * `{project_id}@appspot.gserviceaccount.com`. 5861 * </pre> 5862 * 5863 * <code>string service_account_email = 11;</code> 5864 * 5865 * @return The bytes for serviceAccountEmail. 5866 */ getServiceAccountEmailBytes()5867 public com.google.protobuf.ByteString getServiceAccountEmailBytes() { 5868 java.lang.Object ref = serviceAccountEmail_; 5869 if (ref instanceof String) { 5870 com.google.protobuf.ByteString b = 5871 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 5872 serviceAccountEmail_ = b; 5873 return b; 5874 } else { 5875 return (com.google.protobuf.ByteString) ref; 5876 } 5877 } 5878 /** 5879 * 5880 * 5881 * <pre> 5882 * The email of the function's service account. If empty, defaults to 5883 * `{project_id}@appspot.gserviceaccount.com`. 5884 * </pre> 5885 * 5886 * <code>string service_account_email = 11;</code> 5887 * 5888 * @param value The serviceAccountEmail to set. 5889 * @return This builder for chaining. 5890 */ setServiceAccountEmail(java.lang.String value)5891 public Builder setServiceAccountEmail(java.lang.String value) { 5892 if (value == null) { 5893 throw new NullPointerException(); 5894 } 5895 serviceAccountEmail_ = value; 5896 bitField0_ |= 0x00001000; 5897 onChanged(); 5898 return this; 5899 } 5900 /** 5901 * 5902 * 5903 * <pre> 5904 * The email of the function's service account. If empty, defaults to 5905 * `{project_id}@appspot.gserviceaccount.com`. 5906 * </pre> 5907 * 5908 * <code>string service_account_email = 11;</code> 5909 * 5910 * @return This builder for chaining. 5911 */ clearServiceAccountEmail()5912 public Builder clearServiceAccountEmail() { 5913 serviceAccountEmail_ = getDefaultInstance().getServiceAccountEmail(); 5914 bitField0_ = (bitField0_ & ~0x00001000); 5915 onChanged(); 5916 return this; 5917 } 5918 /** 5919 * 5920 * 5921 * <pre> 5922 * The email of the function's service account. If empty, defaults to 5923 * `{project_id}@appspot.gserviceaccount.com`. 5924 * </pre> 5925 * 5926 * <code>string service_account_email = 11;</code> 5927 * 5928 * @param value The bytes for serviceAccountEmail to set. 5929 * @return This builder for chaining. 5930 */ setServiceAccountEmailBytes(com.google.protobuf.ByteString value)5931 public Builder setServiceAccountEmailBytes(com.google.protobuf.ByteString value) { 5932 if (value == null) { 5933 throw new NullPointerException(); 5934 } 5935 checkByteStringIsUtf8(value); 5936 serviceAccountEmail_ = value; 5937 bitField0_ |= 0x00001000; 5938 onChanged(); 5939 return this; 5940 } 5941 5942 private com.google.protobuf.Timestamp updateTime_; 5943 private com.google.protobuf.SingleFieldBuilderV3< 5944 com.google.protobuf.Timestamp, 5945 com.google.protobuf.Timestamp.Builder, 5946 com.google.protobuf.TimestampOrBuilder> 5947 updateTimeBuilder_; 5948 /** 5949 * 5950 * 5951 * <pre> 5952 * Output only. The last update timestamp of a Cloud Function. 5953 * </pre> 5954 * 5955 * <code> 5956 * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 5957 * </code> 5958 * 5959 * @return Whether the updateTime field is set. 5960 */ hasUpdateTime()5961 public boolean hasUpdateTime() { 5962 return ((bitField0_ & 0x00002000) != 0); 5963 } 5964 /** 5965 * 5966 * 5967 * <pre> 5968 * Output only. The last update timestamp of a Cloud Function. 5969 * </pre> 5970 * 5971 * <code> 5972 * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 5973 * </code> 5974 * 5975 * @return The updateTime. 5976 */ getUpdateTime()5977 public com.google.protobuf.Timestamp getUpdateTime() { 5978 if (updateTimeBuilder_ == null) { 5979 return updateTime_ == null 5980 ? com.google.protobuf.Timestamp.getDefaultInstance() 5981 : updateTime_; 5982 } else { 5983 return updateTimeBuilder_.getMessage(); 5984 } 5985 } 5986 /** 5987 * 5988 * 5989 * <pre> 5990 * Output only. The last update timestamp of a Cloud Function. 5991 * </pre> 5992 * 5993 * <code> 5994 * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 5995 * </code> 5996 */ setUpdateTime(com.google.protobuf.Timestamp value)5997 public Builder setUpdateTime(com.google.protobuf.Timestamp value) { 5998 if (updateTimeBuilder_ == null) { 5999 if (value == null) { 6000 throw new NullPointerException(); 6001 } 6002 updateTime_ = value; 6003 } else { 6004 updateTimeBuilder_.setMessage(value); 6005 } 6006 bitField0_ |= 0x00002000; 6007 onChanged(); 6008 return this; 6009 } 6010 /** 6011 * 6012 * 6013 * <pre> 6014 * Output only. The last update timestamp of a Cloud Function. 6015 * </pre> 6016 * 6017 * <code> 6018 * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 6019 * </code> 6020 */ setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue)6021 public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { 6022 if (updateTimeBuilder_ == null) { 6023 updateTime_ = builderForValue.build(); 6024 } else { 6025 updateTimeBuilder_.setMessage(builderForValue.build()); 6026 } 6027 bitField0_ |= 0x00002000; 6028 onChanged(); 6029 return this; 6030 } 6031 /** 6032 * 6033 * 6034 * <pre> 6035 * Output only. The last update timestamp of a Cloud Function. 6036 * </pre> 6037 * 6038 * <code> 6039 * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 6040 * </code> 6041 */ mergeUpdateTime(com.google.protobuf.Timestamp value)6042 public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { 6043 if (updateTimeBuilder_ == null) { 6044 if (((bitField0_ & 0x00002000) != 0) 6045 && updateTime_ != null 6046 && updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) { 6047 getUpdateTimeBuilder().mergeFrom(value); 6048 } else { 6049 updateTime_ = value; 6050 } 6051 } else { 6052 updateTimeBuilder_.mergeFrom(value); 6053 } 6054 bitField0_ |= 0x00002000; 6055 onChanged(); 6056 return this; 6057 } 6058 /** 6059 * 6060 * 6061 * <pre> 6062 * Output only. The last update timestamp of a Cloud Function. 6063 * </pre> 6064 * 6065 * <code> 6066 * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 6067 * </code> 6068 */ clearUpdateTime()6069 public Builder clearUpdateTime() { 6070 bitField0_ = (bitField0_ & ~0x00002000); 6071 updateTime_ = null; 6072 if (updateTimeBuilder_ != null) { 6073 updateTimeBuilder_.dispose(); 6074 updateTimeBuilder_ = null; 6075 } 6076 onChanged(); 6077 return this; 6078 } 6079 /** 6080 * 6081 * 6082 * <pre> 6083 * Output only. The last update timestamp of a Cloud Function. 6084 * </pre> 6085 * 6086 * <code> 6087 * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 6088 * </code> 6089 */ getUpdateTimeBuilder()6090 public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { 6091 bitField0_ |= 0x00002000; 6092 onChanged(); 6093 return getUpdateTimeFieldBuilder().getBuilder(); 6094 } 6095 /** 6096 * 6097 * 6098 * <pre> 6099 * Output only. The last update timestamp of a Cloud Function. 6100 * </pre> 6101 * 6102 * <code> 6103 * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 6104 * </code> 6105 */ getUpdateTimeOrBuilder()6106 public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { 6107 if (updateTimeBuilder_ != null) { 6108 return updateTimeBuilder_.getMessageOrBuilder(); 6109 } else { 6110 return updateTime_ == null 6111 ? com.google.protobuf.Timestamp.getDefaultInstance() 6112 : updateTime_; 6113 } 6114 } 6115 /** 6116 * 6117 * 6118 * <pre> 6119 * Output only. The last update timestamp of a Cloud Function. 6120 * </pre> 6121 * 6122 * <code> 6123 * .google.protobuf.Timestamp update_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; 6124 * </code> 6125 */ 6126 private com.google.protobuf.SingleFieldBuilderV3< 6127 com.google.protobuf.Timestamp, 6128 com.google.protobuf.Timestamp.Builder, 6129 com.google.protobuf.TimestampOrBuilder> getUpdateTimeFieldBuilder()6130 getUpdateTimeFieldBuilder() { 6131 if (updateTimeBuilder_ == null) { 6132 updateTimeBuilder_ = 6133 new com.google.protobuf.SingleFieldBuilderV3< 6134 com.google.protobuf.Timestamp, 6135 com.google.protobuf.Timestamp.Builder, 6136 com.google.protobuf.TimestampOrBuilder>( 6137 getUpdateTime(), getParentForChildren(), isClean()); 6138 updateTime_ = null; 6139 } 6140 return updateTimeBuilder_; 6141 } 6142 6143 private long versionId_; 6144 /** 6145 * 6146 * 6147 * <pre> 6148 * Output only. The version identifier of the Cloud Function. Each deployment 6149 * attempt results in a new version of a function being created. 6150 * </pre> 6151 * 6152 * <code>int64 version_id = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 6153 * 6154 * @return The versionId. 6155 */ 6156 @java.lang.Override getVersionId()6157 public long getVersionId() { 6158 return versionId_; 6159 } 6160 /** 6161 * 6162 * 6163 * <pre> 6164 * Output only. The version identifier of the Cloud Function. Each deployment 6165 * attempt results in a new version of a function being created. 6166 * </pre> 6167 * 6168 * <code>int64 version_id = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 6169 * 6170 * @param value The versionId to set. 6171 * @return This builder for chaining. 6172 */ setVersionId(long value)6173 public Builder setVersionId(long value) { 6174 6175 versionId_ = value; 6176 bitField0_ |= 0x00004000; 6177 onChanged(); 6178 return this; 6179 } 6180 /** 6181 * 6182 * 6183 * <pre> 6184 * Output only. The version identifier of the Cloud Function. Each deployment 6185 * attempt results in a new version of a function being created. 6186 * </pre> 6187 * 6188 * <code>int64 version_id = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 6189 * 6190 * @return This builder for chaining. 6191 */ clearVersionId()6192 public Builder clearVersionId() { 6193 bitField0_ = (bitField0_ & ~0x00004000); 6194 versionId_ = 0L; 6195 onChanged(); 6196 return this; 6197 } 6198 6199 private com.google.protobuf.MapField<java.lang.String, java.lang.String> labels_; 6200 internalGetLabels()6201 private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetLabels() { 6202 if (labels_ == null) { 6203 return com.google.protobuf.MapField.emptyMapField(LabelsDefaultEntryHolder.defaultEntry); 6204 } 6205 return labels_; 6206 } 6207 6208 private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetMutableLabels()6209 internalGetMutableLabels() { 6210 if (labels_ == null) { 6211 labels_ = com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); 6212 } 6213 if (!labels_.isMutable()) { 6214 labels_ = labels_.copy(); 6215 } 6216 bitField0_ |= 0x00008000; 6217 onChanged(); 6218 return labels_; 6219 } 6220 getLabelsCount()6221 public int getLabelsCount() { 6222 return internalGetLabels().getMap().size(); 6223 } 6224 /** 6225 * 6226 * 6227 * <pre> 6228 * Labels associated with this Cloud Function. 6229 * </pre> 6230 * 6231 * <code>map<string, string> labels = 15;</code> 6232 */ 6233 @java.lang.Override containsLabels(java.lang.String key)6234 public boolean containsLabels(java.lang.String key) { 6235 if (key == null) { 6236 throw new NullPointerException("map key"); 6237 } 6238 return internalGetLabels().getMap().containsKey(key); 6239 } 6240 /** Use {@link #getLabelsMap()} instead. */ 6241 @java.lang.Override 6242 @java.lang.Deprecated getLabels()6243 public java.util.Map<java.lang.String, java.lang.String> getLabels() { 6244 return getLabelsMap(); 6245 } 6246 /** 6247 * 6248 * 6249 * <pre> 6250 * Labels associated with this Cloud Function. 6251 * </pre> 6252 * 6253 * <code>map<string, string> labels = 15;</code> 6254 */ 6255 @java.lang.Override getLabelsMap()6256 public java.util.Map<java.lang.String, java.lang.String> getLabelsMap() { 6257 return internalGetLabels().getMap(); 6258 } 6259 /** 6260 * 6261 * 6262 * <pre> 6263 * Labels associated with this Cloud Function. 6264 * </pre> 6265 * 6266 * <code>map<string, string> labels = 15;</code> 6267 */ 6268 @java.lang.Override getLabelsOrDefault( java.lang.String key, java.lang.String defaultValue)6269 public /* nullable */ java.lang.String getLabelsOrDefault( 6270 java.lang.String key, 6271 /* nullable */ 6272 java.lang.String defaultValue) { 6273 if (key == null) { 6274 throw new NullPointerException("map key"); 6275 } 6276 java.util.Map<java.lang.String, java.lang.String> map = internalGetLabels().getMap(); 6277 return map.containsKey(key) ? map.get(key) : defaultValue; 6278 } 6279 /** 6280 * 6281 * 6282 * <pre> 6283 * Labels associated with this Cloud Function. 6284 * </pre> 6285 * 6286 * <code>map<string, string> labels = 15;</code> 6287 */ 6288 @java.lang.Override getLabelsOrThrow(java.lang.String key)6289 public java.lang.String getLabelsOrThrow(java.lang.String key) { 6290 if (key == null) { 6291 throw new NullPointerException("map key"); 6292 } 6293 java.util.Map<java.lang.String, java.lang.String> map = internalGetLabels().getMap(); 6294 if (!map.containsKey(key)) { 6295 throw new java.lang.IllegalArgumentException(); 6296 } 6297 return map.get(key); 6298 } 6299 clearLabels()6300 public Builder clearLabels() { 6301 bitField0_ = (bitField0_ & ~0x00008000); 6302 internalGetMutableLabels().getMutableMap().clear(); 6303 return this; 6304 } 6305 /** 6306 * 6307 * 6308 * <pre> 6309 * Labels associated with this Cloud Function. 6310 * </pre> 6311 * 6312 * <code>map<string, string> labels = 15;</code> 6313 */ removeLabels(java.lang.String key)6314 public Builder removeLabels(java.lang.String key) { 6315 if (key == null) { 6316 throw new NullPointerException("map key"); 6317 } 6318 internalGetMutableLabels().getMutableMap().remove(key); 6319 return this; 6320 } 6321 /** Use alternate mutation accessors instead. */ 6322 @java.lang.Deprecated getMutableLabels()6323 public java.util.Map<java.lang.String, java.lang.String> getMutableLabels() { 6324 bitField0_ |= 0x00008000; 6325 return internalGetMutableLabels().getMutableMap(); 6326 } 6327 /** 6328 * 6329 * 6330 * <pre> 6331 * Labels associated with this Cloud Function. 6332 * </pre> 6333 * 6334 * <code>map<string, string> labels = 15;</code> 6335 */ putLabels(java.lang.String key, java.lang.String value)6336 public Builder putLabels(java.lang.String key, java.lang.String value) { 6337 if (key == null) { 6338 throw new NullPointerException("map key"); 6339 } 6340 if (value == null) { 6341 throw new NullPointerException("map value"); 6342 } 6343 internalGetMutableLabels().getMutableMap().put(key, value); 6344 bitField0_ |= 0x00008000; 6345 return this; 6346 } 6347 /** 6348 * 6349 * 6350 * <pre> 6351 * Labels associated with this Cloud Function. 6352 * </pre> 6353 * 6354 * <code>map<string, string> labels = 15;</code> 6355 */ putAllLabels(java.util.Map<java.lang.String, java.lang.String> values)6356 public Builder putAllLabels(java.util.Map<java.lang.String, java.lang.String> values) { 6357 internalGetMutableLabels().getMutableMap().putAll(values); 6358 bitField0_ |= 0x00008000; 6359 return this; 6360 } 6361 6362 private com.google.protobuf.MapField<java.lang.String, java.lang.String> environmentVariables_; 6363 6364 private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetEnvironmentVariables()6365 internalGetEnvironmentVariables() { 6366 if (environmentVariables_ == null) { 6367 return com.google.protobuf.MapField.emptyMapField( 6368 EnvironmentVariablesDefaultEntryHolder.defaultEntry); 6369 } 6370 return environmentVariables_; 6371 } 6372 6373 private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetMutableEnvironmentVariables()6374 internalGetMutableEnvironmentVariables() { 6375 if (environmentVariables_ == null) { 6376 environmentVariables_ = 6377 com.google.protobuf.MapField.newMapField( 6378 EnvironmentVariablesDefaultEntryHolder.defaultEntry); 6379 } 6380 if (!environmentVariables_.isMutable()) { 6381 environmentVariables_ = environmentVariables_.copy(); 6382 } 6383 bitField0_ |= 0x00010000; 6384 onChanged(); 6385 return environmentVariables_; 6386 } 6387 getEnvironmentVariablesCount()6388 public int getEnvironmentVariablesCount() { 6389 return internalGetEnvironmentVariables().getMap().size(); 6390 } 6391 /** 6392 * 6393 * 6394 * <pre> 6395 * Environment variables that shall be available during function execution. 6396 * </pre> 6397 * 6398 * <code>map<string, string> environment_variables = 17;</code> 6399 */ 6400 @java.lang.Override containsEnvironmentVariables(java.lang.String key)6401 public boolean containsEnvironmentVariables(java.lang.String key) { 6402 if (key == null) { 6403 throw new NullPointerException("map key"); 6404 } 6405 return internalGetEnvironmentVariables().getMap().containsKey(key); 6406 } 6407 /** Use {@link #getEnvironmentVariablesMap()} instead. */ 6408 @java.lang.Override 6409 @java.lang.Deprecated getEnvironmentVariables()6410 public java.util.Map<java.lang.String, java.lang.String> getEnvironmentVariables() { 6411 return getEnvironmentVariablesMap(); 6412 } 6413 /** 6414 * 6415 * 6416 * <pre> 6417 * Environment variables that shall be available during function execution. 6418 * </pre> 6419 * 6420 * <code>map<string, string> environment_variables = 17;</code> 6421 */ 6422 @java.lang.Override getEnvironmentVariablesMap()6423 public java.util.Map<java.lang.String, java.lang.String> getEnvironmentVariablesMap() { 6424 return internalGetEnvironmentVariables().getMap(); 6425 } 6426 /** 6427 * 6428 * 6429 * <pre> 6430 * Environment variables that shall be available during function execution. 6431 * </pre> 6432 * 6433 * <code>map<string, string> environment_variables = 17;</code> 6434 */ 6435 @java.lang.Override getEnvironmentVariablesOrDefault( java.lang.String key, java.lang.String defaultValue)6436 public /* nullable */ java.lang.String getEnvironmentVariablesOrDefault( 6437 java.lang.String key, 6438 /* nullable */ 6439 java.lang.String defaultValue) { 6440 if (key == null) { 6441 throw new NullPointerException("map key"); 6442 } 6443 java.util.Map<java.lang.String, java.lang.String> map = 6444 internalGetEnvironmentVariables().getMap(); 6445 return map.containsKey(key) ? map.get(key) : defaultValue; 6446 } 6447 /** 6448 * 6449 * 6450 * <pre> 6451 * Environment variables that shall be available during function execution. 6452 * </pre> 6453 * 6454 * <code>map<string, string> environment_variables = 17;</code> 6455 */ 6456 @java.lang.Override getEnvironmentVariablesOrThrow(java.lang.String key)6457 public java.lang.String getEnvironmentVariablesOrThrow(java.lang.String key) { 6458 if (key == null) { 6459 throw new NullPointerException("map key"); 6460 } 6461 java.util.Map<java.lang.String, java.lang.String> map = 6462 internalGetEnvironmentVariables().getMap(); 6463 if (!map.containsKey(key)) { 6464 throw new java.lang.IllegalArgumentException(); 6465 } 6466 return map.get(key); 6467 } 6468 clearEnvironmentVariables()6469 public Builder clearEnvironmentVariables() { 6470 bitField0_ = (bitField0_ & ~0x00010000); 6471 internalGetMutableEnvironmentVariables().getMutableMap().clear(); 6472 return this; 6473 } 6474 /** 6475 * 6476 * 6477 * <pre> 6478 * Environment variables that shall be available during function execution. 6479 * </pre> 6480 * 6481 * <code>map<string, string> environment_variables = 17;</code> 6482 */ removeEnvironmentVariables(java.lang.String key)6483 public Builder removeEnvironmentVariables(java.lang.String key) { 6484 if (key == null) { 6485 throw new NullPointerException("map key"); 6486 } 6487 internalGetMutableEnvironmentVariables().getMutableMap().remove(key); 6488 return this; 6489 } 6490 /** Use alternate mutation accessors instead. */ 6491 @java.lang.Deprecated getMutableEnvironmentVariables()6492 public java.util.Map<java.lang.String, java.lang.String> getMutableEnvironmentVariables() { 6493 bitField0_ |= 0x00010000; 6494 return internalGetMutableEnvironmentVariables().getMutableMap(); 6495 } 6496 /** 6497 * 6498 * 6499 * <pre> 6500 * Environment variables that shall be available during function execution. 6501 * </pre> 6502 * 6503 * <code>map<string, string> environment_variables = 17;</code> 6504 */ putEnvironmentVariables(java.lang.String key, java.lang.String value)6505 public Builder putEnvironmentVariables(java.lang.String key, java.lang.String value) { 6506 if (key == null) { 6507 throw new NullPointerException("map key"); 6508 } 6509 if (value == null) { 6510 throw new NullPointerException("map value"); 6511 } 6512 internalGetMutableEnvironmentVariables().getMutableMap().put(key, value); 6513 bitField0_ |= 0x00010000; 6514 return this; 6515 } 6516 /** 6517 * 6518 * 6519 * <pre> 6520 * Environment variables that shall be available during function execution. 6521 * </pre> 6522 * 6523 * <code>map<string, string> environment_variables = 17;</code> 6524 */ putAllEnvironmentVariables( java.util.Map<java.lang.String, java.lang.String> values)6525 public Builder putAllEnvironmentVariables( 6526 java.util.Map<java.lang.String, java.lang.String> values) { 6527 internalGetMutableEnvironmentVariables().getMutableMap().putAll(values); 6528 bitField0_ |= 0x00010000; 6529 return this; 6530 } 6531 6532 private com.google.protobuf.MapField<java.lang.String, java.lang.String> 6533 buildEnvironmentVariables_; 6534 6535 private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetBuildEnvironmentVariables()6536 internalGetBuildEnvironmentVariables() { 6537 if (buildEnvironmentVariables_ == null) { 6538 return com.google.protobuf.MapField.emptyMapField( 6539 BuildEnvironmentVariablesDefaultEntryHolder.defaultEntry); 6540 } 6541 return buildEnvironmentVariables_; 6542 } 6543 6544 private com.google.protobuf.MapField<java.lang.String, java.lang.String> internalGetMutableBuildEnvironmentVariables()6545 internalGetMutableBuildEnvironmentVariables() { 6546 if (buildEnvironmentVariables_ == null) { 6547 buildEnvironmentVariables_ = 6548 com.google.protobuf.MapField.newMapField( 6549 BuildEnvironmentVariablesDefaultEntryHolder.defaultEntry); 6550 } 6551 if (!buildEnvironmentVariables_.isMutable()) { 6552 buildEnvironmentVariables_ = buildEnvironmentVariables_.copy(); 6553 } 6554 bitField0_ |= 0x00020000; 6555 onChanged(); 6556 return buildEnvironmentVariables_; 6557 } 6558 getBuildEnvironmentVariablesCount()6559 public int getBuildEnvironmentVariablesCount() { 6560 return internalGetBuildEnvironmentVariables().getMap().size(); 6561 } 6562 /** 6563 * 6564 * 6565 * <pre> 6566 * Build environment variables that shall be available during build time. 6567 * </pre> 6568 * 6569 * <code>map<string, string> build_environment_variables = 28;</code> 6570 */ 6571 @java.lang.Override containsBuildEnvironmentVariables(java.lang.String key)6572 public boolean containsBuildEnvironmentVariables(java.lang.String key) { 6573 if (key == null) { 6574 throw new NullPointerException("map key"); 6575 } 6576 return internalGetBuildEnvironmentVariables().getMap().containsKey(key); 6577 } 6578 /** Use {@link #getBuildEnvironmentVariablesMap()} instead. */ 6579 @java.lang.Override 6580 @java.lang.Deprecated getBuildEnvironmentVariables()6581 public java.util.Map<java.lang.String, java.lang.String> getBuildEnvironmentVariables() { 6582 return getBuildEnvironmentVariablesMap(); 6583 } 6584 /** 6585 * 6586 * 6587 * <pre> 6588 * Build environment variables that shall be available during build time. 6589 * </pre> 6590 * 6591 * <code>map<string, string> build_environment_variables = 28;</code> 6592 */ 6593 @java.lang.Override getBuildEnvironmentVariablesMap()6594 public java.util.Map<java.lang.String, java.lang.String> getBuildEnvironmentVariablesMap() { 6595 return internalGetBuildEnvironmentVariables().getMap(); 6596 } 6597 /** 6598 * 6599 * 6600 * <pre> 6601 * Build environment variables that shall be available during build time. 6602 * </pre> 6603 * 6604 * <code>map<string, string> build_environment_variables = 28;</code> 6605 */ 6606 @java.lang.Override getBuildEnvironmentVariablesOrDefault( java.lang.String key, java.lang.String defaultValue)6607 public /* nullable */ java.lang.String getBuildEnvironmentVariablesOrDefault( 6608 java.lang.String key, 6609 /* nullable */ 6610 java.lang.String defaultValue) { 6611 if (key == null) { 6612 throw new NullPointerException("map key"); 6613 } 6614 java.util.Map<java.lang.String, java.lang.String> map = 6615 internalGetBuildEnvironmentVariables().getMap(); 6616 return map.containsKey(key) ? map.get(key) : defaultValue; 6617 } 6618 /** 6619 * 6620 * 6621 * <pre> 6622 * Build environment variables that shall be available during build time. 6623 * </pre> 6624 * 6625 * <code>map<string, string> build_environment_variables = 28;</code> 6626 */ 6627 @java.lang.Override getBuildEnvironmentVariablesOrThrow(java.lang.String key)6628 public java.lang.String getBuildEnvironmentVariablesOrThrow(java.lang.String key) { 6629 if (key == null) { 6630 throw new NullPointerException("map key"); 6631 } 6632 java.util.Map<java.lang.String, java.lang.String> map = 6633 internalGetBuildEnvironmentVariables().getMap(); 6634 if (!map.containsKey(key)) { 6635 throw new java.lang.IllegalArgumentException(); 6636 } 6637 return map.get(key); 6638 } 6639 clearBuildEnvironmentVariables()6640 public Builder clearBuildEnvironmentVariables() { 6641 bitField0_ = (bitField0_ & ~0x00020000); 6642 internalGetMutableBuildEnvironmentVariables().getMutableMap().clear(); 6643 return this; 6644 } 6645 /** 6646 * 6647 * 6648 * <pre> 6649 * Build environment variables that shall be available during build time. 6650 * </pre> 6651 * 6652 * <code>map<string, string> build_environment_variables = 28;</code> 6653 */ removeBuildEnvironmentVariables(java.lang.String key)6654 public Builder removeBuildEnvironmentVariables(java.lang.String key) { 6655 if (key == null) { 6656 throw new NullPointerException("map key"); 6657 } 6658 internalGetMutableBuildEnvironmentVariables().getMutableMap().remove(key); 6659 return this; 6660 } 6661 /** Use alternate mutation accessors instead. */ 6662 @java.lang.Deprecated getMutableBuildEnvironmentVariables()6663 public java.util.Map<java.lang.String, java.lang.String> getMutableBuildEnvironmentVariables() { 6664 bitField0_ |= 0x00020000; 6665 return internalGetMutableBuildEnvironmentVariables().getMutableMap(); 6666 } 6667 /** 6668 * 6669 * 6670 * <pre> 6671 * Build environment variables that shall be available during build time. 6672 * </pre> 6673 * 6674 * <code>map<string, string> build_environment_variables = 28;</code> 6675 */ putBuildEnvironmentVariables(java.lang.String key, java.lang.String value)6676 public Builder putBuildEnvironmentVariables(java.lang.String key, java.lang.String value) { 6677 if (key == null) { 6678 throw new NullPointerException("map key"); 6679 } 6680 if (value == null) { 6681 throw new NullPointerException("map value"); 6682 } 6683 internalGetMutableBuildEnvironmentVariables().getMutableMap().put(key, value); 6684 bitField0_ |= 0x00020000; 6685 return this; 6686 } 6687 /** 6688 * 6689 * 6690 * <pre> 6691 * Build environment variables that shall be available during build time. 6692 * </pre> 6693 * 6694 * <code>map<string, string> build_environment_variables = 28;</code> 6695 */ putAllBuildEnvironmentVariables( java.util.Map<java.lang.String, java.lang.String> values)6696 public Builder putAllBuildEnvironmentVariables( 6697 java.util.Map<java.lang.String, java.lang.String> values) { 6698 internalGetMutableBuildEnvironmentVariables().getMutableMap().putAll(values); 6699 bitField0_ |= 0x00020000; 6700 return this; 6701 } 6702 6703 private java.lang.Object network_ = ""; 6704 /** 6705 * 6706 * 6707 * <pre> 6708 * The Serverless VPC Access connector that this cloud function can connect 6709 * to. It can be either the fully qualified URI, or the short name of the 6710 * connector resource. If the connector name is used, the connector must 6711 * belong to the same project as the function. Otherwise, it must belong to a 6712 * project within the same organization. The format of this field is either 6713 * `projects/{project}/global/networks/{network}` or `{network}`, where 6714 * `{project}` is a project id where the network is defined, and `{network}` 6715 * is the short name of the network. 6716 * This field is mutually exclusive with `vpc_connector` and will be replaced 6717 * by it. 6718 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 6719 * more information on connecting Cloud projects. 6720 * </pre> 6721 * 6722 * <code>string network = 18;</code> 6723 * 6724 * @return The network. 6725 */ getNetwork()6726 public java.lang.String getNetwork() { 6727 java.lang.Object ref = network_; 6728 if (!(ref instanceof java.lang.String)) { 6729 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 6730 java.lang.String s = bs.toStringUtf8(); 6731 network_ = s; 6732 return s; 6733 } else { 6734 return (java.lang.String) ref; 6735 } 6736 } 6737 /** 6738 * 6739 * 6740 * <pre> 6741 * The Serverless VPC Access connector that this cloud function can connect 6742 * to. It can be either the fully qualified URI, or the short name of the 6743 * connector resource. If the connector name is used, the connector must 6744 * belong to the same project as the function. Otherwise, it must belong to a 6745 * project within the same organization. The format of this field is either 6746 * `projects/{project}/global/networks/{network}` or `{network}`, where 6747 * `{project}` is a project id where the network is defined, and `{network}` 6748 * is the short name of the network. 6749 * This field is mutually exclusive with `vpc_connector` and will be replaced 6750 * by it. 6751 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 6752 * more information on connecting Cloud projects. 6753 * </pre> 6754 * 6755 * <code>string network = 18;</code> 6756 * 6757 * @return The bytes for network. 6758 */ getNetworkBytes()6759 public com.google.protobuf.ByteString getNetworkBytes() { 6760 java.lang.Object ref = network_; 6761 if (ref instanceof String) { 6762 com.google.protobuf.ByteString b = 6763 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 6764 network_ = b; 6765 return b; 6766 } else { 6767 return (com.google.protobuf.ByteString) ref; 6768 } 6769 } 6770 /** 6771 * 6772 * 6773 * <pre> 6774 * The Serverless VPC Access connector that this cloud function can connect 6775 * to. It can be either the fully qualified URI, or the short name of the 6776 * connector resource. If the connector name is used, the connector must 6777 * belong to the same project as the function. Otherwise, it must belong to a 6778 * project within the same organization. The format of this field is either 6779 * `projects/{project}/global/networks/{network}` or `{network}`, where 6780 * `{project}` is a project id where the network is defined, and `{network}` 6781 * is the short name of the network. 6782 * This field is mutually exclusive with `vpc_connector` and will be replaced 6783 * by it. 6784 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 6785 * more information on connecting Cloud projects. 6786 * </pre> 6787 * 6788 * <code>string network = 18;</code> 6789 * 6790 * @param value The network to set. 6791 * @return This builder for chaining. 6792 */ setNetwork(java.lang.String value)6793 public Builder setNetwork(java.lang.String value) { 6794 if (value == null) { 6795 throw new NullPointerException(); 6796 } 6797 network_ = value; 6798 bitField0_ |= 0x00040000; 6799 onChanged(); 6800 return this; 6801 } 6802 /** 6803 * 6804 * 6805 * <pre> 6806 * The Serverless VPC Access connector that this cloud function can connect 6807 * to. It can be either the fully qualified URI, or the short name of the 6808 * connector resource. If the connector name is used, the connector must 6809 * belong to the same project as the function. Otherwise, it must belong to a 6810 * project within the same organization. The format of this field is either 6811 * `projects/{project}/global/networks/{network}` or `{network}`, where 6812 * `{project}` is a project id where the network is defined, and `{network}` 6813 * is the short name of the network. 6814 * This field is mutually exclusive with `vpc_connector` and will be replaced 6815 * by it. 6816 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 6817 * more information on connecting Cloud projects. 6818 * </pre> 6819 * 6820 * <code>string network = 18;</code> 6821 * 6822 * @return This builder for chaining. 6823 */ clearNetwork()6824 public Builder clearNetwork() { 6825 network_ = getDefaultInstance().getNetwork(); 6826 bitField0_ = (bitField0_ & ~0x00040000); 6827 onChanged(); 6828 return this; 6829 } 6830 /** 6831 * 6832 * 6833 * <pre> 6834 * The Serverless VPC Access connector that this cloud function can connect 6835 * to. It can be either the fully qualified URI, or the short name of the 6836 * connector resource. If the connector name is used, the connector must 6837 * belong to the same project as the function. Otherwise, it must belong to a 6838 * project within the same organization. The format of this field is either 6839 * `projects/{project}/global/networks/{network}` or `{network}`, where 6840 * `{project}` is a project id where the network is defined, and `{network}` 6841 * is the short name of the network. 6842 * This field is mutually exclusive with `vpc_connector` and will be replaced 6843 * by it. 6844 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 6845 * more information on connecting Cloud projects. 6846 * </pre> 6847 * 6848 * <code>string network = 18;</code> 6849 * 6850 * @param value The bytes for network to set. 6851 * @return This builder for chaining. 6852 */ setNetworkBytes(com.google.protobuf.ByteString value)6853 public Builder setNetworkBytes(com.google.protobuf.ByteString value) { 6854 if (value == null) { 6855 throw new NullPointerException(); 6856 } 6857 checkByteStringIsUtf8(value); 6858 network_ = value; 6859 bitField0_ |= 0x00040000; 6860 onChanged(); 6861 return this; 6862 } 6863 6864 private int maxInstances_; 6865 /** 6866 * 6867 * 6868 * <pre> 6869 * The limit on the maximum number of function instances that can coexist at a 6870 * given time. 6871 * In some cases, such as rapid traffic surges, Cloud Functions can for a 6872 * short period of time create more instances than the specified max 6873 * instances limit. If your function cannot tolerate this temporary behavior, 6874 * you might want to factor in a safety margin and set a lower max instances 6875 * value than your function can tolerate. 6876 * See the [Max 6877 * Instances](https://cloud.google.com/functions/docs/max-instances) Guide for 6878 * more details. 6879 * </pre> 6880 * 6881 * <code>int32 max_instances = 20;</code> 6882 * 6883 * @return The maxInstances. 6884 */ 6885 @java.lang.Override getMaxInstances()6886 public int getMaxInstances() { 6887 return maxInstances_; 6888 } 6889 /** 6890 * 6891 * 6892 * <pre> 6893 * The limit on the maximum number of function instances that can coexist at a 6894 * given time. 6895 * In some cases, such as rapid traffic surges, Cloud Functions can for a 6896 * short period of time create more instances than the specified max 6897 * instances limit. If your function cannot tolerate this temporary behavior, 6898 * you might want to factor in a safety margin and set a lower max instances 6899 * value than your function can tolerate. 6900 * See the [Max 6901 * Instances](https://cloud.google.com/functions/docs/max-instances) Guide for 6902 * more details. 6903 * </pre> 6904 * 6905 * <code>int32 max_instances = 20;</code> 6906 * 6907 * @param value The maxInstances to set. 6908 * @return This builder for chaining. 6909 */ setMaxInstances(int value)6910 public Builder setMaxInstances(int value) { 6911 6912 maxInstances_ = value; 6913 bitField0_ |= 0x00080000; 6914 onChanged(); 6915 return this; 6916 } 6917 /** 6918 * 6919 * 6920 * <pre> 6921 * The limit on the maximum number of function instances that can coexist at a 6922 * given time. 6923 * In some cases, such as rapid traffic surges, Cloud Functions can for a 6924 * short period of time create more instances than the specified max 6925 * instances limit. If your function cannot tolerate this temporary behavior, 6926 * you might want to factor in a safety margin and set a lower max instances 6927 * value than your function can tolerate. 6928 * See the [Max 6929 * Instances](https://cloud.google.com/functions/docs/max-instances) Guide for 6930 * more details. 6931 * </pre> 6932 * 6933 * <code>int32 max_instances = 20;</code> 6934 * 6935 * @return This builder for chaining. 6936 */ clearMaxInstances()6937 public Builder clearMaxInstances() { 6938 bitField0_ = (bitField0_ & ~0x00080000); 6939 maxInstances_ = 0; 6940 onChanged(); 6941 return this; 6942 } 6943 6944 private int minInstances_; 6945 /** 6946 * 6947 * 6948 * <pre> 6949 * A lower bound for the number function instances that can coexist at a 6950 * given time. 6951 * </pre> 6952 * 6953 * <code>int32 min_instances = 32;</code> 6954 * 6955 * @return The minInstances. 6956 */ 6957 @java.lang.Override getMinInstances()6958 public int getMinInstances() { 6959 return minInstances_; 6960 } 6961 /** 6962 * 6963 * 6964 * <pre> 6965 * A lower bound for the number function instances that can coexist at a 6966 * given time. 6967 * </pre> 6968 * 6969 * <code>int32 min_instances = 32;</code> 6970 * 6971 * @param value The minInstances to set. 6972 * @return This builder for chaining. 6973 */ setMinInstances(int value)6974 public Builder setMinInstances(int value) { 6975 6976 minInstances_ = value; 6977 bitField0_ |= 0x00100000; 6978 onChanged(); 6979 return this; 6980 } 6981 /** 6982 * 6983 * 6984 * <pre> 6985 * A lower bound for the number function instances that can coexist at a 6986 * given time. 6987 * </pre> 6988 * 6989 * <code>int32 min_instances = 32;</code> 6990 * 6991 * @return This builder for chaining. 6992 */ clearMinInstances()6993 public Builder clearMinInstances() { 6994 bitField0_ = (bitField0_ & ~0x00100000); 6995 minInstances_ = 0; 6996 onChanged(); 6997 return this; 6998 } 6999 7000 private java.lang.Object vpcConnector_ = ""; 7001 /** 7002 * 7003 * 7004 * <pre> 7005 * The VPC Network Connector that this cloud function can connect to. It can 7006 * be either the fully qualified URI, or the short name of the network 7007 * connector resource. The format of this field is 7008 * `projects/*/locations/*/connectors/*` 7009 * This field is mutually exclusive with `network` field and will eventually 7010 * replace it. 7011 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 7012 * more information on connecting Cloud projects. 7013 * </pre> 7014 * 7015 * <code>string vpc_connector = 22;</code> 7016 * 7017 * @return The vpcConnector. 7018 */ getVpcConnector()7019 public java.lang.String getVpcConnector() { 7020 java.lang.Object ref = vpcConnector_; 7021 if (!(ref instanceof java.lang.String)) { 7022 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 7023 java.lang.String s = bs.toStringUtf8(); 7024 vpcConnector_ = s; 7025 return s; 7026 } else { 7027 return (java.lang.String) ref; 7028 } 7029 } 7030 /** 7031 * 7032 * 7033 * <pre> 7034 * The VPC Network Connector that this cloud function can connect to. It can 7035 * be either the fully qualified URI, or the short name of the network 7036 * connector resource. The format of this field is 7037 * `projects/*/locations/*/connectors/*` 7038 * This field is mutually exclusive with `network` field and will eventually 7039 * replace it. 7040 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 7041 * more information on connecting Cloud projects. 7042 * </pre> 7043 * 7044 * <code>string vpc_connector = 22;</code> 7045 * 7046 * @return The bytes for vpcConnector. 7047 */ getVpcConnectorBytes()7048 public com.google.protobuf.ByteString getVpcConnectorBytes() { 7049 java.lang.Object ref = vpcConnector_; 7050 if (ref instanceof String) { 7051 com.google.protobuf.ByteString b = 7052 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 7053 vpcConnector_ = b; 7054 return b; 7055 } else { 7056 return (com.google.protobuf.ByteString) ref; 7057 } 7058 } 7059 /** 7060 * 7061 * 7062 * <pre> 7063 * The VPC Network Connector that this cloud function can connect to. It can 7064 * be either the fully qualified URI, or the short name of the network 7065 * connector resource. The format of this field is 7066 * `projects/*/locations/*/connectors/*` 7067 * This field is mutually exclusive with `network` field and will eventually 7068 * replace it. 7069 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 7070 * more information on connecting Cloud projects. 7071 * </pre> 7072 * 7073 * <code>string vpc_connector = 22;</code> 7074 * 7075 * @param value The vpcConnector to set. 7076 * @return This builder for chaining. 7077 */ setVpcConnector(java.lang.String value)7078 public Builder setVpcConnector(java.lang.String value) { 7079 if (value == null) { 7080 throw new NullPointerException(); 7081 } 7082 vpcConnector_ = value; 7083 bitField0_ |= 0x00200000; 7084 onChanged(); 7085 return this; 7086 } 7087 /** 7088 * 7089 * 7090 * <pre> 7091 * The VPC Network Connector that this cloud function can connect to. It can 7092 * be either the fully qualified URI, or the short name of the network 7093 * connector resource. The format of this field is 7094 * `projects/*/locations/*/connectors/*` 7095 * This field is mutually exclusive with `network` field and will eventually 7096 * replace it. 7097 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 7098 * more information on connecting Cloud projects. 7099 * </pre> 7100 * 7101 * <code>string vpc_connector = 22;</code> 7102 * 7103 * @return This builder for chaining. 7104 */ clearVpcConnector()7105 public Builder clearVpcConnector() { 7106 vpcConnector_ = getDefaultInstance().getVpcConnector(); 7107 bitField0_ = (bitField0_ & ~0x00200000); 7108 onChanged(); 7109 return this; 7110 } 7111 /** 7112 * 7113 * 7114 * <pre> 7115 * The VPC Network Connector that this cloud function can connect to. It can 7116 * be either the fully qualified URI, or the short name of the network 7117 * connector resource. The format of this field is 7118 * `projects/*/locations/*/connectors/*` 7119 * This field is mutually exclusive with `network` field and will eventually 7120 * replace it. 7121 * See [the VPC documentation](https://cloud.google.com/compute/docs/vpc) for 7122 * more information on connecting Cloud projects. 7123 * </pre> 7124 * 7125 * <code>string vpc_connector = 22;</code> 7126 * 7127 * @param value The bytes for vpcConnector to set. 7128 * @return This builder for chaining. 7129 */ setVpcConnectorBytes(com.google.protobuf.ByteString value)7130 public Builder setVpcConnectorBytes(com.google.protobuf.ByteString value) { 7131 if (value == null) { 7132 throw new NullPointerException(); 7133 } 7134 checkByteStringIsUtf8(value); 7135 vpcConnector_ = value; 7136 bitField0_ |= 0x00200000; 7137 onChanged(); 7138 return this; 7139 } 7140 7141 private int vpcConnectorEgressSettings_ = 0; 7142 /** 7143 * 7144 * 7145 * <pre> 7146 * The egress settings for the connector, controlling what traffic is diverted 7147 * through it. 7148 * </pre> 7149 * 7150 * <code> 7151 * .google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings vpc_connector_egress_settings = 23; 7152 * </code> 7153 * 7154 * @return The enum numeric value on the wire for vpcConnectorEgressSettings. 7155 */ 7156 @java.lang.Override getVpcConnectorEgressSettingsValue()7157 public int getVpcConnectorEgressSettingsValue() { 7158 return vpcConnectorEgressSettings_; 7159 } 7160 /** 7161 * 7162 * 7163 * <pre> 7164 * The egress settings for the connector, controlling what traffic is diverted 7165 * through it. 7166 * </pre> 7167 * 7168 * <code> 7169 * .google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings vpc_connector_egress_settings = 23; 7170 * </code> 7171 * 7172 * @param value The enum numeric value on the wire for vpcConnectorEgressSettings to set. 7173 * @return This builder for chaining. 7174 */ setVpcConnectorEgressSettingsValue(int value)7175 public Builder setVpcConnectorEgressSettingsValue(int value) { 7176 vpcConnectorEgressSettings_ = value; 7177 bitField0_ |= 0x00400000; 7178 onChanged(); 7179 return this; 7180 } 7181 /** 7182 * 7183 * 7184 * <pre> 7185 * The egress settings for the connector, controlling what traffic is diverted 7186 * through it. 7187 * </pre> 7188 * 7189 * <code> 7190 * .google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings vpc_connector_egress_settings = 23; 7191 * </code> 7192 * 7193 * @return The vpcConnectorEgressSettings. 7194 */ 7195 @java.lang.Override 7196 public com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings getVpcConnectorEgressSettings()7197 getVpcConnectorEgressSettings() { 7198 com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings result = 7199 com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings.forNumber( 7200 vpcConnectorEgressSettings_); 7201 return result == null 7202 ? com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings.UNRECOGNIZED 7203 : result; 7204 } 7205 /** 7206 * 7207 * 7208 * <pre> 7209 * The egress settings for the connector, controlling what traffic is diverted 7210 * through it. 7211 * </pre> 7212 * 7213 * <code> 7214 * .google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings vpc_connector_egress_settings = 23; 7215 * </code> 7216 * 7217 * @param value The vpcConnectorEgressSettings to set. 7218 * @return This builder for chaining. 7219 */ setVpcConnectorEgressSettings( com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings value)7220 public Builder setVpcConnectorEgressSettings( 7221 com.google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings value) { 7222 if (value == null) { 7223 throw new NullPointerException(); 7224 } 7225 bitField0_ |= 0x00400000; 7226 vpcConnectorEgressSettings_ = value.getNumber(); 7227 onChanged(); 7228 return this; 7229 } 7230 /** 7231 * 7232 * 7233 * <pre> 7234 * The egress settings for the connector, controlling what traffic is diverted 7235 * through it. 7236 * </pre> 7237 * 7238 * <code> 7239 * .google.cloud.functions.v1.CloudFunction.VpcConnectorEgressSettings vpc_connector_egress_settings = 23; 7240 * </code> 7241 * 7242 * @return This builder for chaining. 7243 */ clearVpcConnectorEgressSettings()7244 public Builder clearVpcConnectorEgressSettings() { 7245 bitField0_ = (bitField0_ & ~0x00400000); 7246 vpcConnectorEgressSettings_ = 0; 7247 onChanged(); 7248 return this; 7249 } 7250 7251 private int ingressSettings_ = 0; 7252 /** 7253 * 7254 * 7255 * <pre> 7256 * The ingress settings for the function, controlling what traffic can reach 7257 * it. 7258 * </pre> 7259 * 7260 * <code>.google.cloud.functions.v1.CloudFunction.IngressSettings ingress_settings = 24;</code> 7261 * 7262 * @return The enum numeric value on the wire for ingressSettings. 7263 */ 7264 @java.lang.Override getIngressSettingsValue()7265 public int getIngressSettingsValue() { 7266 return ingressSettings_; 7267 } 7268 /** 7269 * 7270 * 7271 * <pre> 7272 * The ingress settings for the function, controlling what traffic can reach 7273 * it. 7274 * </pre> 7275 * 7276 * <code>.google.cloud.functions.v1.CloudFunction.IngressSettings ingress_settings = 24;</code> 7277 * 7278 * @param value The enum numeric value on the wire for ingressSettings to set. 7279 * @return This builder for chaining. 7280 */ setIngressSettingsValue(int value)7281 public Builder setIngressSettingsValue(int value) { 7282 ingressSettings_ = value; 7283 bitField0_ |= 0x00800000; 7284 onChanged(); 7285 return this; 7286 } 7287 /** 7288 * 7289 * 7290 * <pre> 7291 * The ingress settings for the function, controlling what traffic can reach 7292 * it. 7293 * </pre> 7294 * 7295 * <code>.google.cloud.functions.v1.CloudFunction.IngressSettings ingress_settings = 24;</code> 7296 * 7297 * @return The ingressSettings. 7298 */ 7299 @java.lang.Override getIngressSettings()7300 public com.google.cloud.functions.v1.CloudFunction.IngressSettings getIngressSettings() { 7301 com.google.cloud.functions.v1.CloudFunction.IngressSettings result = 7302 com.google.cloud.functions.v1.CloudFunction.IngressSettings.forNumber(ingressSettings_); 7303 return result == null 7304 ? com.google.cloud.functions.v1.CloudFunction.IngressSettings.UNRECOGNIZED 7305 : result; 7306 } 7307 /** 7308 * 7309 * 7310 * <pre> 7311 * The ingress settings for the function, controlling what traffic can reach 7312 * it. 7313 * </pre> 7314 * 7315 * <code>.google.cloud.functions.v1.CloudFunction.IngressSettings ingress_settings = 24;</code> 7316 * 7317 * @param value The ingressSettings to set. 7318 * @return This builder for chaining. 7319 */ setIngressSettings( com.google.cloud.functions.v1.CloudFunction.IngressSettings value)7320 public Builder setIngressSettings( 7321 com.google.cloud.functions.v1.CloudFunction.IngressSettings value) { 7322 if (value == null) { 7323 throw new NullPointerException(); 7324 } 7325 bitField0_ |= 0x00800000; 7326 ingressSettings_ = value.getNumber(); 7327 onChanged(); 7328 return this; 7329 } 7330 /** 7331 * 7332 * 7333 * <pre> 7334 * The ingress settings for the function, controlling what traffic can reach 7335 * it. 7336 * </pre> 7337 * 7338 * <code>.google.cloud.functions.v1.CloudFunction.IngressSettings ingress_settings = 24;</code> 7339 * 7340 * @return This builder for chaining. 7341 */ clearIngressSettings()7342 public Builder clearIngressSettings() { 7343 bitField0_ = (bitField0_ & ~0x00800000); 7344 ingressSettings_ = 0; 7345 onChanged(); 7346 return this; 7347 } 7348 7349 private java.lang.Object kmsKeyName_ = ""; 7350 /** 7351 * 7352 * 7353 * <pre> 7354 * Resource name of a KMS crypto key (managed by the user) used to 7355 * encrypt/decrypt function resources. 7356 * It must match the pattern 7357 * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. 7358 * If specified, you must also provide an artifact registry repository using 7359 * the `docker_repository` field that was created with the same KMS crypto 7360 * key. 7361 * The following service accounts need to be granted the role 'Cloud KMS 7362 * CryptoKey Encrypter/Decrypter (roles/cloudkms.cryptoKeyEncrypterDecrypter)' 7363 * on the Key/KeyRing/Project/Organization (least access preferred). 7364 * 1. Google Cloud Functions service account 7365 * (service-{project_number}@gcf-admin-robot.iam.gserviceaccount.com) - 7366 * Required to protect the function's image. 7367 * 2. Google Storage service account 7368 * (service-{project_number}@gs-project-accounts.iam.gserviceaccount.com) - 7369 * Required to protect the function's source code. 7370 * If this service account does not exist, deploying a function without a 7371 * KMS key or retrieving the service agent name provisions it. For more 7372 * information, see 7373 * https://cloud.google.com/storage/docs/projects#service-agents and 7374 * https://cloud.google.com/storage/docs/getting-service-agent#gsutil. 7375 * Google Cloud Functions delegates access to service agents to protect 7376 * function resources in internal projects that are not accessible by the 7377 * end user. 7378 * </pre> 7379 * 7380 * <code>string kms_key_name = 25 [(.google.api.resource_reference) = { ... }</code> 7381 * 7382 * @return The kmsKeyName. 7383 */ getKmsKeyName()7384 public java.lang.String getKmsKeyName() { 7385 java.lang.Object ref = kmsKeyName_; 7386 if (!(ref instanceof java.lang.String)) { 7387 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 7388 java.lang.String s = bs.toStringUtf8(); 7389 kmsKeyName_ = s; 7390 return s; 7391 } else { 7392 return (java.lang.String) ref; 7393 } 7394 } 7395 /** 7396 * 7397 * 7398 * <pre> 7399 * Resource name of a KMS crypto key (managed by the user) used to 7400 * encrypt/decrypt function resources. 7401 * It must match the pattern 7402 * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. 7403 * If specified, you must also provide an artifact registry repository using 7404 * the `docker_repository` field that was created with the same KMS crypto 7405 * key. 7406 * The following service accounts need to be granted the role 'Cloud KMS 7407 * CryptoKey Encrypter/Decrypter (roles/cloudkms.cryptoKeyEncrypterDecrypter)' 7408 * on the Key/KeyRing/Project/Organization (least access preferred). 7409 * 1. Google Cloud Functions service account 7410 * (service-{project_number}@gcf-admin-robot.iam.gserviceaccount.com) - 7411 * Required to protect the function's image. 7412 * 2. Google Storage service account 7413 * (service-{project_number}@gs-project-accounts.iam.gserviceaccount.com) - 7414 * Required to protect the function's source code. 7415 * If this service account does not exist, deploying a function without a 7416 * KMS key or retrieving the service agent name provisions it. For more 7417 * information, see 7418 * https://cloud.google.com/storage/docs/projects#service-agents and 7419 * https://cloud.google.com/storage/docs/getting-service-agent#gsutil. 7420 * Google Cloud Functions delegates access to service agents to protect 7421 * function resources in internal projects that are not accessible by the 7422 * end user. 7423 * </pre> 7424 * 7425 * <code>string kms_key_name = 25 [(.google.api.resource_reference) = { ... }</code> 7426 * 7427 * @return The bytes for kmsKeyName. 7428 */ getKmsKeyNameBytes()7429 public com.google.protobuf.ByteString getKmsKeyNameBytes() { 7430 java.lang.Object ref = kmsKeyName_; 7431 if (ref instanceof String) { 7432 com.google.protobuf.ByteString b = 7433 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 7434 kmsKeyName_ = b; 7435 return b; 7436 } else { 7437 return (com.google.protobuf.ByteString) ref; 7438 } 7439 } 7440 /** 7441 * 7442 * 7443 * <pre> 7444 * Resource name of a KMS crypto key (managed by the user) used to 7445 * encrypt/decrypt function resources. 7446 * It must match the pattern 7447 * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. 7448 * If specified, you must also provide an artifact registry repository using 7449 * the `docker_repository` field that was created with the same KMS crypto 7450 * key. 7451 * The following service accounts need to be granted the role 'Cloud KMS 7452 * CryptoKey Encrypter/Decrypter (roles/cloudkms.cryptoKeyEncrypterDecrypter)' 7453 * on the Key/KeyRing/Project/Organization (least access preferred). 7454 * 1. Google Cloud Functions service account 7455 * (service-{project_number}@gcf-admin-robot.iam.gserviceaccount.com) - 7456 * Required to protect the function's image. 7457 * 2. Google Storage service account 7458 * (service-{project_number}@gs-project-accounts.iam.gserviceaccount.com) - 7459 * Required to protect the function's source code. 7460 * If this service account does not exist, deploying a function without a 7461 * KMS key or retrieving the service agent name provisions it. For more 7462 * information, see 7463 * https://cloud.google.com/storage/docs/projects#service-agents and 7464 * https://cloud.google.com/storage/docs/getting-service-agent#gsutil. 7465 * Google Cloud Functions delegates access to service agents to protect 7466 * function resources in internal projects that are not accessible by the 7467 * end user. 7468 * </pre> 7469 * 7470 * <code>string kms_key_name = 25 [(.google.api.resource_reference) = { ... }</code> 7471 * 7472 * @param value The kmsKeyName to set. 7473 * @return This builder for chaining. 7474 */ setKmsKeyName(java.lang.String value)7475 public Builder setKmsKeyName(java.lang.String value) { 7476 if (value == null) { 7477 throw new NullPointerException(); 7478 } 7479 kmsKeyName_ = value; 7480 bitField0_ |= 0x01000000; 7481 onChanged(); 7482 return this; 7483 } 7484 /** 7485 * 7486 * 7487 * <pre> 7488 * Resource name of a KMS crypto key (managed by the user) used to 7489 * encrypt/decrypt function resources. 7490 * It must match the pattern 7491 * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. 7492 * If specified, you must also provide an artifact registry repository using 7493 * the `docker_repository` field that was created with the same KMS crypto 7494 * key. 7495 * The following service accounts need to be granted the role 'Cloud KMS 7496 * CryptoKey Encrypter/Decrypter (roles/cloudkms.cryptoKeyEncrypterDecrypter)' 7497 * on the Key/KeyRing/Project/Organization (least access preferred). 7498 * 1. Google Cloud Functions service account 7499 * (service-{project_number}@gcf-admin-robot.iam.gserviceaccount.com) - 7500 * Required to protect the function's image. 7501 * 2. Google Storage service account 7502 * (service-{project_number}@gs-project-accounts.iam.gserviceaccount.com) - 7503 * Required to protect the function's source code. 7504 * If this service account does not exist, deploying a function without a 7505 * KMS key or retrieving the service agent name provisions it. For more 7506 * information, see 7507 * https://cloud.google.com/storage/docs/projects#service-agents and 7508 * https://cloud.google.com/storage/docs/getting-service-agent#gsutil. 7509 * Google Cloud Functions delegates access to service agents to protect 7510 * function resources in internal projects that are not accessible by the 7511 * end user. 7512 * </pre> 7513 * 7514 * <code>string kms_key_name = 25 [(.google.api.resource_reference) = { ... }</code> 7515 * 7516 * @return This builder for chaining. 7517 */ clearKmsKeyName()7518 public Builder clearKmsKeyName() { 7519 kmsKeyName_ = getDefaultInstance().getKmsKeyName(); 7520 bitField0_ = (bitField0_ & ~0x01000000); 7521 onChanged(); 7522 return this; 7523 } 7524 /** 7525 * 7526 * 7527 * <pre> 7528 * Resource name of a KMS crypto key (managed by the user) used to 7529 * encrypt/decrypt function resources. 7530 * It must match the pattern 7531 * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. 7532 * If specified, you must also provide an artifact registry repository using 7533 * the `docker_repository` field that was created with the same KMS crypto 7534 * key. 7535 * The following service accounts need to be granted the role 'Cloud KMS 7536 * CryptoKey Encrypter/Decrypter (roles/cloudkms.cryptoKeyEncrypterDecrypter)' 7537 * on the Key/KeyRing/Project/Organization (least access preferred). 7538 * 1. Google Cloud Functions service account 7539 * (service-{project_number}@gcf-admin-robot.iam.gserviceaccount.com) - 7540 * Required to protect the function's image. 7541 * 2. Google Storage service account 7542 * (service-{project_number}@gs-project-accounts.iam.gserviceaccount.com) - 7543 * Required to protect the function's source code. 7544 * If this service account does not exist, deploying a function without a 7545 * KMS key or retrieving the service agent name provisions it. For more 7546 * information, see 7547 * https://cloud.google.com/storage/docs/projects#service-agents and 7548 * https://cloud.google.com/storage/docs/getting-service-agent#gsutil. 7549 * Google Cloud Functions delegates access to service agents to protect 7550 * function resources in internal projects that are not accessible by the 7551 * end user. 7552 * </pre> 7553 * 7554 * <code>string kms_key_name = 25 [(.google.api.resource_reference) = { ... }</code> 7555 * 7556 * @param value The bytes for kmsKeyName to set. 7557 * @return This builder for chaining. 7558 */ setKmsKeyNameBytes(com.google.protobuf.ByteString value)7559 public Builder setKmsKeyNameBytes(com.google.protobuf.ByteString value) { 7560 if (value == null) { 7561 throw new NullPointerException(); 7562 } 7563 checkByteStringIsUtf8(value); 7564 kmsKeyName_ = value; 7565 bitField0_ |= 0x01000000; 7566 onChanged(); 7567 return this; 7568 } 7569 7570 private java.lang.Object buildWorkerPool_ = ""; 7571 /** 7572 * 7573 * 7574 * <pre> 7575 * Name of the Cloud Build Custom Worker Pool that should be used to build the 7576 * function. The format of this field is 7577 * `projects/{project}/locations/{region}/workerPools/{workerPool}` where 7578 * `{project}` and `{region}` are the project id and region respectively where 7579 * the worker pool is defined and `{workerPool}` is the short name of the 7580 * worker pool. 7581 * If the project id is not the same as the function, then the Cloud 7582 * Functions Service Agent 7583 * (`service-<project_number>@gcf-admin-robot.iam.gserviceaccount.com`) must 7584 * be granted the role Cloud Build Custom Workers Builder 7585 * (`roles/cloudbuild.customworkers.builder`) in the project. 7586 * </pre> 7587 * 7588 * <code>string build_worker_pool = 26;</code> 7589 * 7590 * @return The buildWorkerPool. 7591 */ getBuildWorkerPool()7592 public java.lang.String getBuildWorkerPool() { 7593 java.lang.Object ref = buildWorkerPool_; 7594 if (!(ref instanceof java.lang.String)) { 7595 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 7596 java.lang.String s = bs.toStringUtf8(); 7597 buildWorkerPool_ = s; 7598 return s; 7599 } else { 7600 return (java.lang.String) ref; 7601 } 7602 } 7603 /** 7604 * 7605 * 7606 * <pre> 7607 * Name of the Cloud Build Custom Worker Pool that should be used to build the 7608 * function. The format of this field is 7609 * `projects/{project}/locations/{region}/workerPools/{workerPool}` where 7610 * `{project}` and `{region}` are the project id and region respectively where 7611 * the worker pool is defined and `{workerPool}` is the short name of the 7612 * worker pool. 7613 * If the project id is not the same as the function, then the Cloud 7614 * Functions Service Agent 7615 * (`service-<project_number>@gcf-admin-robot.iam.gserviceaccount.com`) must 7616 * be granted the role Cloud Build Custom Workers Builder 7617 * (`roles/cloudbuild.customworkers.builder`) in the project. 7618 * </pre> 7619 * 7620 * <code>string build_worker_pool = 26;</code> 7621 * 7622 * @return The bytes for buildWorkerPool. 7623 */ getBuildWorkerPoolBytes()7624 public com.google.protobuf.ByteString getBuildWorkerPoolBytes() { 7625 java.lang.Object ref = buildWorkerPool_; 7626 if (ref instanceof String) { 7627 com.google.protobuf.ByteString b = 7628 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 7629 buildWorkerPool_ = b; 7630 return b; 7631 } else { 7632 return (com.google.protobuf.ByteString) ref; 7633 } 7634 } 7635 /** 7636 * 7637 * 7638 * <pre> 7639 * Name of the Cloud Build Custom Worker Pool that should be used to build the 7640 * function. The format of this field is 7641 * `projects/{project}/locations/{region}/workerPools/{workerPool}` where 7642 * `{project}` and `{region}` are the project id and region respectively where 7643 * the worker pool is defined and `{workerPool}` is the short name of the 7644 * worker pool. 7645 * If the project id is not the same as the function, then the Cloud 7646 * Functions Service Agent 7647 * (`service-<project_number>@gcf-admin-robot.iam.gserviceaccount.com`) must 7648 * be granted the role Cloud Build Custom Workers Builder 7649 * (`roles/cloudbuild.customworkers.builder`) in the project. 7650 * </pre> 7651 * 7652 * <code>string build_worker_pool = 26;</code> 7653 * 7654 * @param value The buildWorkerPool to set. 7655 * @return This builder for chaining. 7656 */ setBuildWorkerPool(java.lang.String value)7657 public Builder setBuildWorkerPool(java.lang.String value) { 7658 if (value == null) { 7659 throw new NullPointerException(); 7660 } 7661 buildWorkerPool_ = value; 7662 bitField0_ |= 0x02000000; 7663 onChanged(); 7664 return this; 7665 } 7666 /** 7667 * 7668 * 7669 * <pre> 7670 * Name of the Cloud Build Custom Worker Pool that should be used to build the 7671 * function. The format of this field is 7672 * `projects/{project}/locations/{region}/workerPools/{workerPool}` where 7673 * `{project}` and `{region}` are the project id and region respectively where 7674 * the worker pool is defined and `{workerPool}` is the short name of the 7675 * worker pool. 7676 * If the project id is not the same as the function, then the Cloud 7677 * Functions Service Agent 7678 * (`service-<project_number>@gcf-admin-robot.iam.gserviceaccount.com`) must 7679 * be granted the role Cloud Build Custom Workers Builder 7680 * (`roles/cloudbuild.customworkers.builder`) in the project. 7681 * </pre> 7682 * 7683 * <code>string build_worker_pool = 26;</code> 7684 * 7685 * @return This builder for chaining. 7686 */ clearBuildWorkerPool()7687 public Builder clearBuildWorkerPool() { 7688 buildWorkerPool_ = getDefaultInstance().getBuildWorkerPool(); 7689 bitField0_ = (bitField0_ & ~0x02000000); 7690 onChanged(); 7691 return this; 7692 } 7693 /** 7694 * 7695 * 7696 * <pre> 7697 * Name of the Cloud Build Custom Worker Pool that should be used to build the 7698 * function. The format of this field is 7699 * `projects/{project}/locations/{region}/workerPools/{workerPool}` where 7700 * `{project}` and `{region}` are the project id and region respectively where 7701 * the worker pool is defined and `{workerPool}` is the short name of the 7702 * worker pool. 7703 * If the project id is not the same as the function, then the Cloud 7704 * Functions Service Agent 7705 * (`service-<project_number>@gcf-admin-robot.iam.gserviceaccount.com`) must 7706 * be granted the role Cloud Build Custom Workers Builder 7707 * (`roles/cloudbuild.customworkers.builder`) in the project. 7708 * </pre> 7709 * 7710 * <code>string build_worker_pool = 26;</code> 7711 * 7712 * @param value The bytes for buildWorkerPool to set. 7713 * @return This builder for chaining. 7714 */ setBuildWorkerPoolBytes(com.google.protobuf.ByteString value)7715 public Builder setBuildWorkerPoolBytes(com.google.protobuf.ByteString value) { 7716 if (value == null) { 7717 throw new NullPointerException(); 7718 } 7719 checkByteStringIsUtf8(value); 7720 buildWorkerPool_ = value; 7721 bitField0_ |= 0x02000000; 7722 onChanged(); 7723 return this; 7724 } 7725 7726 private java.lang.Object buildId_ = ""; 7727 /** 7728 * 7729 * 7730 * <pre> 7731 * Output only. The Cloud Build ID of the latest successful deployment of the 7732 * function. 7733 * </pre> 7734 * 7735 * <code>string build_id = 27 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 7736 * 7737 * @return The buildId. 7738 */ getBuildId()7739 public java.lang.String getBuildId() { 7740 java.lang.Object ref = buildId_; 7741 if (!(ref instanceof java.lang.String)) { 7742 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 7743 java.lang.String s = bs.toStringUtf8(); 7744 buildId_ = s; 7745 return s; 7746 } else { 7747 return (java.lang.String) ref; 7748 } 7749 } 7750 /** 7751 * 7752 * 7753 * <pre> 7754 * Output only. The Cloud Build ID of the latest successful deployment of the 7755 * function. 7756 * </pre> 7757 * 7758 * <code>string build_id = 27 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 7759 * 7760 * @return The bytes for buildId. 7761 */ getBuildIdBytes()7762 public com.google.protobuf.ByteString getBuildIdBytes() { 7763 java.lang.Object ref = buildId_; 7764 if (ref instanceof String) { 7765 com.google.protobuf.ByteString b = 7766 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 7767 buildId_ = b; 7768 return b; 7769 } else { 7770 return (com.google.protobuf.ByteString) ref; 7771 } 7772 } 7773 /** 7774 * 7775 * 7776 * <pre> 7777 * Output only. The Cloud Build ID of the latest successful deployment of the 7778 * function. 7779 * </pre> 7780 * 7781 * <code>string build_id = 27 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 7782 * 7783 * @param value The buildId to set. 7784 * @return This builder for chaining. 7785 */ setBuildId(java.lang.String value)7786 public Builder setBuildId(java.lang.String value) { 7787 if (value == null) { 7788 throw new NullPointerException(); 7789 } 7790 buildId_ = value; 7791 bitField0_ |= 0x04000000; 7792 onChanged(); 7793 return this; 7794 } 7795 /** 7796 * 7797 * 7798 * <pre> 7799 * Output only. The Cloud Build ID of the latest successful deployment of the 7800 * function. 7801 * </pre> 7802 * 7803 * <code>string build_id = 27 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 7804 * 7805 * @return This builder for chaining. 7806 */ clearBuildId()7807 public Builder clearBuildId() { 7808 buildId_ = getDefaultInstance().getBuildId(); 7809 bitField0_ = (bitField0_ & ~0x04000000); 7810 onChanged(); 7811 return this; 7812 } 7813 /** 7814 * 7815 * 7816 * <pre> 7817 * Output only. The Cloud Build ID of the latest successful deployment of the 7818 * function. 7819 * </pre> 7820 * 7821 * <code>string build_id = 27 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 7822 * 7823 * @param value The bytes for buildId to set. 7824 * @return This builder for chaining. 7825 */ setBuildIdBytes(com.google.protobuf.ByteString value)7826 public Builder setBuildIdBytes(com.google.protobuf.ByteString value) { 7827 if (value == null) { 7828 throw new NullPointerException(); 7829 } 7830 checkByteStringIsUtf8(value); 7831 buildId_ = value; 7832 bitField0_ |= 0x04000000; 7833 onChanged(); 7834 return this; 7835 } 7836 7837 private java.lang.Object buildName_ = ""; 7838 /** 7839 * 7840 * 7841 * <pre> 7842 * Output only. The Cloud Build Name of the function deployment. 7843 * `projects/<project-number>/locations/<region>/builds/<build-id>`. 7844 * </pre> 7845 * 7846 * <code>string build_name = 33 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 7847 * 7848 * @return The buildName. 7849 */ getBuildName()7850 public java.lang.String getBuildName() { 7851 java.lang.Object ref = buildName_; 7852 if (!(ref instanceof java.lang.String)) { 7853 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 7854 java.lang.String s = bs.toStringUtf8(); 7855 buildName_ = s; 7856 return s; 7857 } else { 7858 return (java.lang.String) ref; 7859 } 7860 } 7861 /** 7862 * 7863 * 7864 * <pre> 7865 * Output only. The Cloud Build Name of the function deployment. 7866 * `projects/<project-number>/locations/<region>/builds/<build-id>`. 7867 * </pre> 7868 * 7869 * <code>string build_name = 33 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 7870 * 7871 * @return The bytes for buildName. 7872 */ getBuildNameBytes()7873 public com.google.protobuf.ByteString getBuildNameBytes() { 7874 java.lang.Object ref = buildName_; 7875 if (ref instanceof String) { 7876 com.google.protobuf.ByteString b = 7877 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 7878 buildName_ = b; 7879 return b; 7880 } else { 7881 return (com.google.protobuf.ByteString) ref; 7882 } 7883 } 7884 /** 7885 * 7886 * 7887 * <pre> 7888 * Output only. The Cloud Build Name of the function deployment. 7889 * `projects/<project-number>/locations/<region>/builds/<build-id>`. 7890 * </pre> 7891 * 7892 * <code>string build_name = 33 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 7893 * 7894 * @param value The buildName to set. 7895 * @return This builder for chaining. 7896 */ setBuildName(java.lang.String value)7897 public Builder setBuildName(java.lang.String value) { 7898 if (value == null) { 7899 throw new NullPointerException(); 7900 } 7901 buildName_ = value; 7902 bitField0_ |= 0x08000000; 7903 onChanged(); 7904 return this; 7905 } 7906 /** 7907 * 7908 * 7909 * <pre> 7910 * Output only. The Cloud Build Name of the function deployment. 7911 * `projects/<project-number>/locations/<region>/builds/<build-id>`. 7912 * </pre> 7913 * 7914 * <code>string build_name = 33 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 7915 * 7916 * @return This builder for chaining. 7917 */ clearBuildName()7918 public Builder clearBuildName() { 7919 buildName_ = getDefaultInstance().getBuildName(); 7920 bitField0_ = (bitField0_ & ~0x08000000); 7921 onChanged(); 7922 return this; 7923 } 7924 /** 7925 * 7926 * 7927 * <pre> 7928 * Output only. The Cloud Build Name of the function deployment. 7929 * `projects/<project-number>/locations/<region>/builds/<build-id>`. 7930 * </pre> 7931 * 7932 * <code>string build_name = 33 [(.google.api.field_behavior) = OUTPUT_ONLY];</code> 7933 * 7934 * @param value The bytes for buildName to set. 7935 * @return This builder for chaining. 7936 */ setBuildNameBytes(com.google.protobuf.ByteString value)7937 public Builder setBuildNameBytes(com.google.protobuf.ByteString value) { 7938 if (value == null) { 7939 throw new NullPointerException(); 7940 } 7941 checkByteStringIsUtf8(value); 7942 buildName_ = value; 7943 bitField0_ |= 0x08000000; 7944 onChanged(); 7945 return this; 7946 } 7947 7948 private java.util.List<com.google.cloud.functions.v1.SecretEnvVar> secretEnvironmentVariables_ = 7949 java.util.Collections.emptyList(); 7950 ensureSecretEnvironmentVariablesIsMutable()7951 private void ensureSecretEnvironmentVariablesIsMutable() { 7952 if (!((bitField0_ & 0x10000000) != 0)) { 7953 secretEnvironmentVariables_ = 7954 new java.util.ArrayList<com.google.cloud.functions.v1.SecretEnvVar>( 7955 secretEnvironmentVariables_); 7956 bitField0_ |= 0x10000000; 7957 } 7958 } 7959 7960 private com.google.protobuf.RepeatedFieldBuilderV3< 7961 com.google.cloud.functions.v1.SecretEnvVar, 7962 com.google.cloud.functions.v1.SecretEnvVar.Builder, 7963 com.google.cloud.functions.v1.SecretEnvVarOrBuilder> 7964 secretEnvironmentVariablesBuilder_; 7965 7966 /** 7967 * 7968 * 7969 * <pre> 7970 * Secret environment variables configuration. 7971 * </pre> 7972 * 7973 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 7974 * </code> 7975 */ 7976 public java.util.List<com.google.cloud.functions.v1.SecretEnvVar> getSecretEnvironmentVariablesList()7977 getSecretEnvironmentVariablesList() { 7978 if (secretEnvironmentVariablesBuilder_ == null) { 7979 return java.util.Collections.unmodifiableList(secretEnvironmentVariables_); 7980 } else { 7981 return secretEnvironmentVariablesBuilder_.getMessageList(); 7982 } 7983 } 7984 /** 7985 * 7986 * 7987 * <pre> 7988 * Secret environment variables configuration. 7989 * </pre> 7990 * 7991 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 7992 * </code> 7993 */ getSecretEnvironmentVariablesCount()7994 public int getSecretEnvironmentVariablesCount() { 7995 if (secretEnvironmentVariablesBuilder_ == null) { 7996 return secretEnvironmentVariables_.size(); 7997 } else { 7998 return secretEnvironmentVariablesBuilder_.getCount(); 7999 } 8000 } 8001 /** 8002 * 8003 * 8004 * <pre> 8005 * Secret environment variables configuration. 8006 * </pre> 8007 * 8008 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8009 * </code> 8010 */ getSecretEnvironmentVariables(int index)8011 public com.google.cloud.functions.v1.SecretEnvVar getSecretEnvironmentVariables(int index) { 8012 if (secretEnvironmentVariablesBuilder_ == null) { 8013 return secretEnvironmentVariables_.get(index); 8014 } else { 8015 return secretEnvironmentVariablesBuilder_.getMessage(index); 8016 } 8017 } 8018 /** 8019 * 8020 * 8021 * <pre> 8022 * Secret environment variables configuration. 8023 * </pre> 8024 * 8025 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8026 * </code> 8027 */ setSecretEnvironmentVariables( int index, com.google.cloud.functions.v1.SecretEnvVar value)8028 public Builder setSecretEnvironmentVariables( 8029 int index, com.google.cloud.functions.v1.SecretEnvVar value) { 8030 if (secretEnvironmentVariablesBuilder_ == null) { 8031 if (value == null) { 8032 throw new NullPointerException(); 8033 } 8034 ensureSecretEnvironmentVariablesIsMutable(); 8035 secretEnvironmentVariables_.set(index, value); 8036 onChanged(); 8037 } else { 8038 secretEnvironmentVariablesBuilder_.setMessage(index, value); 8039 } 8040 return this; 8041 } 8042 /** 8043 * 8044 * 8045 * <pre> 8046 * Secret environment variables configuration. 8047 * </pre> 8048 * 8049 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8050 * </code> 8051 */ setSecretEnvironmentVariables( int index, com.google.cloud.functions.v1.SecretEnvVar.Builder builderForValue)8052 public Builder setSecretEnvironmentVariables( 8053 int index, com.google.cloud.functions.v1.SecretEnvVar.Builder builderForValue) { 8054 if (secretEnvironmentVariablesBuilder_ == null) { 8055 ensureSecretEnvironmentVariablesIsMutable(); 8056 secretEnvironmentVariables_.set(index, builderForValue.build()); 8057 onChanged(); 8058 } else { 8059 secretEnvironmentVariablesBuilder_.setMessage(index, builderForValue.build()); 8060 } 8061 return this; 8062 } 8063 /** 8064 * 8065 * 8066 * <pre> 8067 * Secret environment variables configuration. 8068 * </pre> 8069 * 8070 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8071 * </code> 8072 */ addSecretEnvironmentVariables(com.google.cloud.functions.v1.SecretEnvVar value)8073 public Builder addSecretEnvironmentVariables(com.google.cloud.functions.v1.SecretEnvVar value) { 8074 if (secretEnvironmentVariablesBuilder_ == null) { 8075 if (value == null) { 8076 throw new NullPointerException(); 8077 } 8078 ensureSecretEnvironmentVariablesIsMutable(); 8079 secretEnvironmentVariables_.add(value); 8080 onChanged(); 8081 } else { 8082 secretEnvironmentVariablesBuilder_.addMessage(value); 8083 } 8084 return this; 8085 } 8086 /** 8087 * 8088 * 8089 * <pre> 8090 * Secret environment variables configuration. 8091 * </pre> 8092 * 8093 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8094 * </code> 8095 */ addSecretEnvironmentVariables( int index, com.google.cloud.functions.v1.SecretEnvVar value)8096 public Builder addSecretEnvironmentVariables( 8097 int index, com.google.cloud.functions.v1.SecretEnvVar value) { 8098 if (secretEnvironmentVariablesBuilder_ == null) { 8099 if (value == null) { 8100 throw new NullPointerException(); 8101 } 8102 ensureSecretEnvironmentVariablesIsMutable(); 8103 secretEnvironmentVariables_.add(index, value); 8104 onChanged(); 8105 } else { 8106 secretEnvironmentVariablesBuilder_.addMessage(index, value); 8107 } 8108 return this; 8109 } 8110 /** 8111 * 8112 * 8113 * <pre> 8114 * Secret environment variables configuration. 8115 * </pre> 8116 * 8117 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8118 * </code> 8119 */ addSecretEnvironmentVariables( com.google.cloud.functions.v1.SecretEnvVar.Builder builderForValue)8120 public Builder addSecretEnvironmentVariables( 8121 com.google.cloud.functions.v1.SecretEnvVar.Builder builderForValue) { 8122 if (secretEnvironmentVariablesBuilder_ == null) { 8123 ensureSecretEnvironmentVariablesIsMutable(); 8124 secretEnvironmentVariables_.add(builderForValue.build()); 8125 onChanged(); 8126 } else { 8127 secretEnvironmentVariablesBuilder_.addMessage(builderForValue.build()); 8128 } 8129 return this; 8130 } 8131 /** 8132 * 8133 * 8134 * <pre> 8135 * Secret environment variables configuration. 8136 * </pre> 8137 * 8138 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8139 * </code> 8140 */ addSecretEnvironmentVariables( int index, com.google.cloud.functions.v1.SecretEnvVar.Builder builderForValue)8141 public Builder addSecretEnvironmentVariables( 8142 int index, com.google.cloud.functions.v1.SecretEnvVar.Builder builderForValue) { 8143 if (secretEnvironmentVariablesBuilder_ == null) { 8144 ensureSecretEnvironmentVariablesIsMutable(); 8145 secretEnvironmentVariables_.add(index, builderForValue.build()); 8146 onChanged(); 8147 } else { 8148 secretEnvironmentVariablesBuilder_.addMessage(index, builderForValue.build()); 8149 } 8150 return this; 8151 } 8152 /** 8153 * 8154 * 8155 * <pre> 8156 * Secret environment variables configuration. 8157 * </pre> 8158 * 8159 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8160 * </code> 8161 */ addAllSecretEnvironmentVariables( java.lang.Iterable<? extends com.google.cloud.functions.v1.SecretEnvVar> values)8162 public Builder addAllSecretEnvironmentVariables( 8163 java.lang.Iterable<? extends com.google.cloud.functions.v1.SecretEnvVar> values) { 8164 if (secretEnvironmentVariablesBuilder_ == null) { 8165 ensureSecretEnvironmentVariablesIsMutable(); 8166 com.google.protobuf.AbstractMessageLite.Builder.addAll(values, secretEnvironmentVariables_); 8167 onChanged(); 8168 } else { 8169 secretEnvironmentVariablesBuilder_.addAllMessages(values); 8170 } 8171 return this; 8172 } 8173 /** 8174 * 8175 * 8176 * <pre> 8177 * Secret environment variables configuration. 8178 * </pre> 8179 * 8180 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8181 * </code> 8182 */ clearSecretEnvironmentVariables()8183 public Builder clearSecretEnvironmentVariables() { 8184 if (secretEnvironmentVariablesBuilder_ == null) { 8185 secretEnvironmentVariables_ = java.util.Collections.emptyList(); 8186 bitField0_ = (bitField0_ & ~0x10000000); 8187 onChanged(); 8188 } else { 8189 secretEnvironmentVariablesBuilder_.clear(); 8190 } 8191 return this; 8192 } 8193 /** 8194 * 8195 * 8196 * <pre> 8197 * Secret environment variables configuration. 8198 * </pre> 8199 * 8200 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8201 * </code> 8202 */ removeSecretEnvironmentVariables(int index)8203 public Builder removeSecretEnvironmentVariables(int index) { 8204 if (secretEnvironmentVariablesBuilder_ == null) { 8205 ensureSecretEnvironmentVariablesIsMutable(); 8206 secretEnvironmentVariables_.remove(index); 8207 onChanged(); 8208 } else { 8209 secretEnvironmentVariablesBuilder_.remove(index); 8210 } 8211 return this; 8212 } 8213 /** 8214 * 8215 * 8216 * <pre> 8217 * Secret environment variables configuration. 8218 * </pre> 8219 * 8220 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8221 * </code> 8222 */ getSecretEnvironmentVariablesBuilder( int index)8223 public com.google.cloud.functions.v1.SecretEnvVar.Builder getSecretEnvironmentVariablesBuilder( 8224 int index) { 8225 return getSecretEnvironmentVariablesFieldBuilder().getBuilder(index); 8226 } 8227 /** 8228 * 8229 * 8230 * <pre> 8231 * Secret environment variables configuration. 8232 * </pre> 8233 * 8234 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8235 * </code> 8236 */ 8237 public com.google.cloud.functions.v1.SecretEnvVarOrBuilder getSecretEnvironmentVariablesOrBuilder(int index)8238 getSecretEnvironmentVariablesOrBuilder(int index) { 8239 if (secretEnvironmentVariablesBuilder_ == null) { 8240 return secretEnvironmentVariables_.get(index); 8241 } else { 8242 return secretEnvironmentVariablesBuilder_.getMessageOrBuilder(index); 8243 } 8244 } 8245 /** 8246 * 8247 * 8248 * <pre> 8249 * Secret environment variables configuration. 8250 * </pre> 8251 * 8252 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8253 * </code> 8254 */ 8255 public java.util.List<? extends com.google.cloud.functions.v1.SecretEnvVarOrBuilder> getSecretEnvironmentVariablesOrBuilderList()8256 getSecretEnvironmentVariablesOrBuilderList() { 8257 if (secretEnvironmentVariablesBuilder_ != null) { 8258 return secretEnvironmentVariablesBuilder_.getMessageOrBuilderList(); 8259 } else { 8260 return java.util.Collections.unmodifiableList(secretEnvironmentVariables_); 8261 } 8262 } 8263 /** 8264 * 8265 * 8266 * <pre> 8267 * Secret environment variables configuration. 8268 * </pre> 8269 * 8270 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8271 * </code> 8272 */ 8273 public com.google.cloud.functions.v1.SecretEnvVar.Builder addSecretEnvironmentVariablesBuilder()8274 addSecretEnvironmentVariablesBuilder() { 8275 return getSecretEnvironmentVariablesFieldBuilder() 8276 .addBuilder(com.google.cloud.functions.v1.SecretEnvVar.getDefaultInstance()); 8277 } 8278 /** 8279 * 8280 * 8281 * <pre> 8282 * Secret environment variables configuration. 8283 * </pre> 8284 * 8285 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8286 * </code> 8287 */ addSecretEnvironmentVariablesBuilder( int index)8288 public com.google.cloud.functions.v1.SecretEnvVar.Builder addSecretEnvironmentVariablesBuilder( 8289 int index) { 8290 return getSecretEnvironmentVariablesFieldBuilder() 8291 .addBuilder(index, com.google.cloud.functions.v1.SecretEnvVar.getDefaultInstance()); 8292 } 8293 /** 8294 * 8295 * 8296 * <pre> 8297 * Secret environment variables configuration. 8298 * </pre> 8299 * 8300 * <code>repeated .google.cloud.functions.v1.SecretEnvVar secret_environment_variables = 29; 8301 * </code> 8302 */ 8303 public java.util.List<com.google.cloud.functions.v1.SecretEnvVar.Builder> getSecretEnvironmentVariablesBuilderList()8304 getSecretEnvironmentVariablesBuilderList() { 8305 return getSecretEnvironmentVariablesFieldBuilder().getBuilderList(); 8306 } 8307 8308 private com.google.protobuf.RepeatedFieldBuilderV3< 8309 com.google.cloud.functions.v1.SecretEnvVar, 8310 com.google.cloud.functions.v1.SecretEnvVar.Builder, 8311 com.google.cloud.functions.v1.SecretEnvVarOrBuilder> getSecretEnvironmentVariablesFieldBuilder()8312 getSecretEnvironmentVariablesFieldBuilder() { 8313 if (secretEnvironmentVariablesBuilder_ == null) { 8314 secretEnvironmentVariablesBuilder_ = 8315 new com.google.protobuf.RepeatedFieldBuilderV3< 8316 com.google.cloud.functions.v1.SecretEnvVar, 8317 com.google.cloud.functions.v1.SecretEnvVar.Builder, 8318 com.google.cloud.functions.v1.SecretEnvVarOrBuilder>( 8319 secretEnvironmentVariables_, 8320 ((bitField0_ & 0x10000000) != 0), 8321 getParentForChildren(), 8322 isClean()); 8323 secretEnvironmentVariables_ = null; 8324 } 8325 return secretEnvironmentVariablesBuilder_; 8326 } 8327 8328 private java.util.List<com.google.cloud.functions.v1.SecretVolume> secretVolumes_ = 8329 java.util.Collections.emptyList(); 8330 ensureSecretVolumesIsMutable()8331 private void ensureSecretVolumesIsMutable() { 8332 if (!((bitField0_ & 0x20000000) != 0)) { 8333 secretVolumes_ = 8334 new java.util.ArrayList<com.google.cloud.functions.v1.SecretVolume>(secretVolumes_); 8335 bitField0_ |= 0x20000000; 8336 } 8337 } 8338 8339 private com.google.protobuf.RepeatedFieldBuilderV3< 8340 com.google.cloud.functions.v1.SecretVolume, 8341 com.google.cloud.functions.v1.SecretVolume.Builder, 8342 com.google.cloud.functions.v1.SecretVolumeOrBuilder> 8343 secretVolumesBuilder_; 8344 8345 /** 8346 * 8347 * 8348 * <pre> 8349 * Secret volumes configuration. 8350 * </pre> 8351 * 8352 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8353 */ getSecretVolumesList()8354 public java.util.List<com.google.cloud.functions.v1.SecretVolume> getSecretVolumesList() { 8355 if (secretVolumesBuilder_ == null) { 8356 return java.util.Collections.unmodifiableList(secretVolumes_); 8357 } else { 8358 return secretVolumesBuilder_.getMessageList(); 8359 } 8360 } 8361 /** 8362 * 8363 * 8364 * <pre> 8365 * Secret volumes configuration. 8366 * </pre> 8367 * 8368 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8369 */ getSecretVolumesCount()8370 public int getSecretVolumesCount() { 8371 if (secretVolumesBuilder_ == null) { 8372 return secretVolumes_.size(); 8373 } else { 8374 return secretVolumesBuilder_.getCount(); 8375 } 8376 } 8377 /** 8378 * 8379 * 8380 * <pre> 8381 * Secret volumes configuration. 8382 * </pre> 8383 * 8384 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8385 */ getSecretVolumes(int index)8386 public com.google.cloud.functions.v1.SecretVolume getSecretVolumes(int index) { 8387 if (secretVolumesBuilder_ == null) { 8388 return secretVolumes_.get(index); 8389 } else { 8390 return secretVolumesBuilder_.getMessage(index); 8391 } 8392 } 8393 /** 8394 * 8395 * 8396 * <pre> 8397 * Secret volumes configuration. 8398 * </pre> 8399 * 8400 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8401 */ setSecretVolumes(int index, com.google.cloud.functions.v1.SecretVolume value)8402 public Builder setSecretVolumes(int index, com.google.cloud.functions.v1.SecretVolume value) { 8403 if (secretVolumesBuilder_ == null) { 8404 if (value == null) { 8405 throw new NullPointerException(); 8406 } 8407 ensureSecretVolumesIsMutable(); 8408 secretVolumes_.set(index, value); 8409 onChanged(); 8410 } else { 8411 secretVolumesBuilder_.setMessage(index, value); 8412 } 8413 return this; 8414 } 8415 /** 8416 * 8417 * 8418 * <pre> 8419 * Secret volumes configuration. 8420 * </pre> 8421 * 8422 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8423 */ setSecretVolumes( int index, com.google.cloud.functions.v1.SecretVolume.Builder builderForValue)8424 public Builder setSecretVolumes( 8425 int index, com.google.cloud.functions.v1.SecretVolume.Builder builderForValue) { 8426 if (secretVolumesBuilder_ == null) { 8427 ensureSecretVolumesIsMutable(); 8428 secretVolumes_.set(index, builderForValue.build()); 8429 onChanged(); 8430 } else { 8431 secretVolumesBuilder_.setMessage(index, builderForValue.build()); 8432 } 8433 return this; 8434 } 8435 /** 8436 * 8437 * 8438 * <pre> 8439 * Secret volumes configuration. 8440 * </pre> 8441 * 8442 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8443 */ addSecretVolumes(com.google.cloud.functions.v1.SecretVolume value)8444 public Builder addSecretVolumes(com.google.cloud.functions.v1.SecretVolume value) { 8445 if (secretVolumesBuilder_ == null) { 8446 if (value == null) { 8447 throw new NullPointerException(); 8448 } 8449 ensureSecretVolumesIsMutable(); 8450 secretVolumes_.add(value); 8451 onChanged(); 8452 } else { 8453 secretVolumesBuilder_.addMessage(value); 8454 } 8455 return this; 8456 } 8457 /** 8458 * 8459 * 8460 * <pre> 8461 * Secret volumes configuration. 8462 * </pre> 8463 * 8464 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8465 */ addSecretVolumes(int index, com.google.cloud.functions.v1.SecretVolume value)8466 public Builder addSecretVolumes(int index, com.google.cloud.functions.v1.SecretVolume value) { 8467 if (secretVolumesBuilder_ == null) { 8468 if (value == null) { 8469 throw new NullPointerException(); 8470 } 8471 ensureSecretVolumesIsMutable(); 8472 secretVolumes_.add(index, value); 8473 onChanged(); 8474 } else { 8475 secretVolumesBuilder_.addMessage(index, value); 8476 } 8477 return this; 8478 } 8479 /** 8480 * 8481 * 8482 * <pre> 8483 * Secret volumes configuration. 8484 * </pre> 8485 * 8486 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8487 */ addSecretVolumes( com.google.cloud.functions.v1.SecretVolume.Builder builderForValue)8488 public Builder addSecretVolumes( 8489 com.google.cloud.functions.v1.SecretVolume.Builder builderForValue) { 8490 if (secretVolumesBuilder_ == null) { 8491 ensureSecretVolumesIsMutable(); 8492 secretVolumes_.add(builderForValue.build()); 8493 onChanged(); 8494 } else { 8495 secretVolumesBuilder_.addMessage(builderForValue.build()); 8496 } 8497 return this; 8498 } 8499 /** 8500 * 8501 * 8502 * <pre> 8503 * Secret volumes configuration. 8504 * </pre> 8505 * 8506 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8507 */ addSecretVolumes( int index, com.google.cloud.functions.v1.SecretVolume.Builder builderForValue)8508 public Builder addSecretVolumes( 8509 int index, com.google.cloud.functions.v1.SecretVolume.Builder builderForValue) { 8510 if (secretVolumesBuilder_ == null) { 8511 ensureSecretVolumesIsMutable(); 8512 secretVolumes_.add(index, builderForValue.build()); 8513 onChanged(); 8514 } else { 8515 secretVolumesBuilder_.addMessage(index, builderForValue.build()); 8516 } 8517 return this; 8518 } 8519 /** 8520 * 8521 * 8522 * <pre> 8523 * Secret volumes configuration. 8524 * </pre> 8525 * 8526 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8527 */ addAllSecretVolumes( java.lang.Iterable<? extends com.google.cloud.functions.v1.SecretVolume> values)8528 public Builder addAllSecretVolumes( 8529 java.lang.Iterable<? extends com.google.cloud.functions.v1.SecretVolume> values) { 8530 if (secretVolumesBuilder_ == null) { 8531 ensureSecretVolumesIsMutable(); 8532 com.google.protobuf.AbstractMessageLite.Builder.addAll(values, secretVolumes_); 8533 onChanged(); 8534 } else { 8535 secretVolumesBuilder_.addAllMessages(values); 8536 } 8537 return this; 8538 } 8539 /** 8540 * 8541 * 8542 * <pre> 8543 * Secret volumes configuration. 8544 * </pre> 8545 * 8546 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8547 */ clearSecretVolumes()8548 public Builder clearSecretVolumes() { 8549 if (secretVolumesBuilder_ == null) { 8550 secretVolumes_ = java.util.Collections.emptyList(); 8551 bitField0_ = (bitField0_ & ~0x20000000); 8552 onChanged(); 8553 } else { 8554 secretVolumesBuilder_.clear(); 8555 } 8556 return this; 8557 } 8558 /** 8559 * 8560 * 8561 * <pre> 8562 * Secret volumes configuration. 8563 * </pre> 8564 * 8565 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8566 */ removeSecretVolumes(int index)8567 public Builder removeSecretVolumes(int index) { 8568 if (secretVolumesBuilder_ == null) { 8569 ensureSecretVolumesIsMutable(); 8570 secretVolumes_.remove(index); 8571 onChanged(); 8572 } else { 8573 secretVolumesBuilder_.remove(index); 8574 } 8575 return this; 8576 } 8577 /** 8578 * 8579 * 8580 * <pre> 8581 * Secret volumes configuration. 8582 * </pre> 8583 * 8584 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8585 */ getSecretVolumesBuilder(int index)8586 public com.google.cloud.functions.v1.SecretVolume.Builder getSecretVolumesBuilder(int index) { 8587 return getSecretVolumesFieldBuilder().getBuilder(index); 8588 } 8589 /** 8590 * 8591 * 8592 * <pre> 8593 * Secret volumes configuration. 8594 * </pre> 8595 * 8596 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8597 */ getSecretVolumesOrBuilder( int index)8598 public com.google.cloud.functions.v1.SecretVolumeOrBuilder getSecretVolumesOrBuilder( 8599 int index) { 8600 if (secretVolumesBuilder_ == null) { 8601 return secretVolumes_.get(index); 8602 } else { 8603 return secretVolumesBuilder_.getMessageOrBuilder(index); 8604 } 8605 } 8606 /** 8607 * 8608 * 8609 * <pre> 8610 * Secret volumes configuration. 8611 * </pre> 8612 * 8613 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8614 */ 8615 public java.util.List<? extends com.google.cloud.functions.v1.SecretVolumeOrBuilder> getSecretVolumesOrBuilderList()8616 getSecretVolumesOrBuilderList() { 8617 if (secretVolumesBuilder_ != null) { 8618 return secretVolumesBuilder_.getMessageOrBuilderList(); 8619 } else { 8620 return java.util.Collections.unmodifiableList(secretVolumes_); 8621 } 8622 } 8623 /** 8624 * 8625 * 8626 * <pre> 8627 * Secret volumes configuration. 8628 * </pre> 8629 * 8630 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8631 */ addSecretVolumesBuilder()8632 public com.google.cloud.functions.v1.SecretVolume.Builder addSecretVolumesBuilder() { 8633 return getSecretVolumesFieldBuilder() 8634 .addBuilder(com.google.cloud.functions.v1.SecretVolume.getDefaultInstance()); 8635 } 8636 /** 8637 * 8638 * 8639 * <pre> 8640 * Secret volumes configuration. 8641 * </pre> 8642 * 8643 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8644 */ addSecretVolumesBuilder(int index)8645 public com.google.cloud.functions.v1.SecretVolume.Builder addSecretVolumesBuilder(int index) { 8646 return getSecretVolumesFieldBuilder() 8647 .addBuilder(index, com.google.cloud.functions.v1.SecretVolume.getDefaultInstance()); 8648 } 8649 /** 8650 * 8651 * 8652 * <pre> 8653 * Secret volumes configuration. 8654 * </pre> 8655 * 8656 * <code>repeated .google.cloud.functions.v1.SecretVolume secret_volumes = 30;</code> 8657 */ 8658 public java.util.List<com.google.cloud.functions.v1.SecretVolume.Builder> getSecretVolumesBuilderList()8659 getSecretVolumesBuilderList() { 8660 return getSecretVolumesFieldBuilder().getBuilderList(); 8661 } 8662 8663 private com.google.protobuf.RepeatedFieldBuilderV3< 8664 com.google.cloud.functions.v1.SecretVolume, 8665 com.google.cloud.functions.v1.SecretVolume.Builder, 8666 com.google.cloud.functions.v1.SecretVolumeOrBuilder> getSecretVolumesFieldBuilder()8667 getSecretVolumesFieldBuilder() { 8668 if (secretVolumesBuilder_ == null) { 8669 secretVolumesBuilder_ = 8670 new com.google.protobuf.RepeatedFieldBuilderV3< 8671 com.google.cloud.functions.v1.SecretVolume, 8672 com.google.cloud.functions.v1.SecretVolume.Builder, 8673 com.google.cloud.functions.v1.SecretVolumeOrBuilder>( 8674 secretVolumes_, 8675 ((bitField0_ & 0x20000000) != 0), 8676 getParentForChildren(), 8677 isClean()); 8678 secretVolumes_ = null; 8679 } 8680 return secretVolumesBuilder_; 8681 } 8682 8683 private java.lang.Object sourceToken_ = ""; 8684 /** 8685 * 8686 * 8687 * <pre> 8688 * Input only. An identifier for Firebase function sources. Disclaimer: This 8689 * field is only supported for Firebase function deployments. 8690 * </pre> 8691 * 8692 * <code>string source_token = 31 [(.google.api.field_behavior) = INPUT_ONLY];</code> 8693 * 8694 * @return The sourceToken. 8695 */ getSourceToken()8696 public java.lang.String getSourceToken() { 8697 java.lang.Object ref = sourceToken_; 8698 if (!(ref instanceof java.lang.String)) { 8699 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 8700 java.lang.String s = bs.toStringUtf8(); 8701 sourceToken_ = s; 8702 return s; 8703 } else { 8704 return (java.lang.String) ref; 8705 } 8706 } 8707 /** 8708 * 8709 * 8710 * <pre> 8711 * Input only. An identifier for Firebase function sources. Disclaimer: This 8712 * field is only supported for Firebase function deployments. 8713 * </pre> 8714 * 8715 * <code>string source_token = 31 [(.google.api.field_behavior) = INPUT_ONLY];</code> 8716 * 8717 * @return The bytes for sourceToken. 8718 */ getSourceTokenBytes()8719 public com.google.protobuf.ByteString getSourceTokenBytes() { 8720 java.lang.Object ref = sourceToken_; 8721 if (ref instanceof String) { 8722 com.google.protobuf.ByteString b = 8723 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 8724 sourceToken_ = b; 8725 return b; 8726 } else { 8727 return (com.google.protobuf.ByteString) ref; 8728 } 8729 } 8730 /** 8731 * 8732 * 8733 * <pre> 8734 * Input only. An identifier for Firebase function sources. Disclaimer: This 8735 * field is only supported for Firebase function deployments. 8736 * </pre> 8737 * 8738 * <code>string source_token = 31 [(.google.api.field_behavior) = INPUT_ONLY];</code> 8739 * 8740 * @param value The sourceToken to set. 8741 * @return This builder for chaining. 8742 */ setSourceToken(java.lang.String value)8743 public Builder setSourceToken(java.lang.String value) { 8744 if (value == null) { 8745 throw new NullPointerException(); 8746 } 8747 sourceToken_ = value; 8748 bitField0_ |= 0x40000000; 8749 onChanged(); 8750 return this; 8751 } 8752 /** 8753 * 8754 * 8755 * <pre> 8756 * Input only. An identifier for Firebase function sources. Disclaimer: This 8757 * field is only supported for Firebase function deployments. 8758 * </pre> 8759 * 8760 * <code>string source_token = 31 [(.google.api.field_behavior) = INPUT_ONLY];</code> 8761 * 8762 * @return This builder for chaining. 8763 */ clearSourceToken()8764 public Builder clearSourceToken() { 8765 sourceToken_ = getDefaultInstance().getSourceToken(); 8766 bitField0_ = (bitField0_ & ~0x40000000); 8767 onChanged(); 8768 return this; 8769 } 8770 /** 8771 * 8772 * 8773 * <pre> 8774 * Input only. An identifier for Firebase function sources. Disclaimer: This 8775 * field is only supported for Firebase function deployments. 8776 * </pre> 8777 * 8778 * <code>string source_token = 31 [(.google.api.field_behavior) = INPUT_ONLY];</code> 8779 * 8780 * @param value The bytes for sourceToken to set. 8781 * @return This builder for chaining. 8782 */ setSourceTokenBytes(com.google.protobuf.ByteString value)8783 public Builder setSourceTokenBytes(com.google.protobuf.ByteString value) { 8784 if (value == null) { 8785 throw new NullPointerException(); 8786 } 8787 checkByteStringIsUtf8(value); 8788 sourceToken_ = value; 8789 bitField0_ |= 0x40000000; 8790 onChanged(); 8791 return this; 8792 } 8793 8794 private java.lang.Object dockerRepository_ = ""; 8795 /** 8796 * 8797 * 8798 * <pre> 8799 * User managed repository created in Artifact Registry optionally with a 8800 * customer managed encryption key. If specified, deployments will use 8801 * Artifact Registry. If unspecified and the deployment is eligible to use 8802 * Artifact Registry, GCF will create and use a repository named 8803 * 'gcf-artifacts' for every deployed region. This is the repository to which 8804 * the function docker image is pushed after it is built by Cloud Build. 8805 * It must match the pattern 8806 * `projects/{project}/locations/{location}/repositories/{repository}`. 8807 * Cross-project repositories are not supported. 8808 * Cross-location repositories are not supported. 8809 * Repository format must be 'DOCKER'. 8810 * </pre> 8811 * 8812 * <code>string docker_repository = 34 [(.google.api.resource_reference) = { ... }</code> 8813 * 8814 * @return The dockerRepository. 8815 */ getDockerRepository()8816 public java.lang.String getDockerRepository() { 8817 java.lang.Object ref = dockerRepository_; 8818 if (!(ref instanceof java.lang.String)) { 8819 com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; 8820 java.lang.String s = bs.toStringUtf8(); 8821 dockerRepository_ = s; 8822 return s; 8823 } else { 8824 return (java.lang.String) ref; 8825 } 8826 } 8827 /** 8828 * 8829 * 8830 * <pre> 8831 * User managed repository created in Artifact Registry optionally with a 8832 * customer managed encryption key. If specified, deployments will use 8833 * Artifact Registry. If unspecified and the deployment is eligible to use 8834 * Artifact Registry, GCF will create and use a repository named 8835 * 'gcf-artifacts' for every deployed region. This is the repository to which 8836 * the function docker image is pushed after it is built by Cloud Build. 8837 * It must match the pattern 8838 * `projects/{project}/locations/{location}/repositories/{repository}`. 8839 * Cross-project repositories are not supported. 8840 * Cross-location repositories are not supported. 8841 * Repository format must be 'DOCKER'. 8842 * </pre> 8843 * 8844 * <code>string docker_repository = 34 [(.google.api.resource_reference) = { ... }</code> 8845 * 8846 * @return The bytes for dockerRepository. 8847 */ getDockerRepositoryBytes()8848 public com.google.protobuf.ByteString getDockerRepositoryBytes() { 8849 java.lang.Object ref = dockerRepository_; 8850 if (ref instanceof String) { 8851 com.google.protobuf.ByteString b = 8852 com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); 8853 dockerRepository_ = b; 8854 return b; 8855 } else { 8856 return (com.google.protobuf.ByteString) ref; 8857 } 8858 } 8859 /** 8860 * 8861 * 8862 * <pre> 8863 * User managed repository created in Artifact Registry optionally with a 8864 * customer managed encryption key. If specified, deployments will use 8865 * Artifact Registry. If unspecified and the deployment is eligible to use 8866 * Artifact Registry, GCF will create and use a repository named 8867 * 'gcf-artifacts' for every deployed region. This is the repository to which 8868 * the function docker image is pushed after it is built by Cloud Build. 8869 * It must match the pattern 8870 * `projects/{project}/locations/{location}/repositories/{repository}`. 8871 * Cross-project repositories are not supported. 8872 * Cross-location repositories are not supported. 8873 * Repository format must be 'DOCKER'. 8874 * </pre> 8875 * 8876 * <code>string docker_repository = 34 [(.google.api.resource_reference) = { ... }</code> 8877 * 8878 * @param value The dockerRepository to set. 8879 * @return This builder for chaining. 8880 */ setDockerRepository(java.lang.String value)8881 public Builder setDockerRepository(java.lang.String value) { 8882 if (value == null) { 8883 throw new NullPointerException(); 8884 } 8885 dockerRepository_ = value; 8886 bitField0_ |= 0x80000000; 8887 onChanged(); 8888 return this; 8889 } 8890 /** 8891 * 8892 * 8893 * <pre> 8894 * User managed repository created in Artifact Registry optionally with a 8895 * customer managed encryption key. If specified, deployments will use 8896 * Artifact Registry. If unspecified and the deployment is eligible to use 8897 * Artifact Registry, GCF will create and use a repository named 8898 * 'gcf-artifacts' for every deployed region. This is the repository to which 8899 * the function docker image is pushed after it is built by Cloud Build. 8900 * It must match the pattern 8901 * `projects/{project}/locations/{location}/repositories/{repository}`. 8902 * Cross-project repositories are not supported. 8903 * Cross-location repositories are not supported. 8904 * Repository format must be 'DOCKER'. 8905 * </pre> 8906 * 8907 * <code>string docker_repository = 34 [(.google.api.resource_reference) = { ... }</code> 8908 * 8909 * @return This builder for chaining. 8910 */ clearDockerRepository()8911 public Builder clearDockerRepository() { 8912 dockerRepository_ = getDefaultInstance().getDockerRepository(); 8913 bitField0_ = (bitField0_ & ~0x80000000); 8914 onChanged(); 8915 return this; 8916 } 8917 /** 8918 * 8919 * 8920 * <pre> 8921 * User managed repository created in Artifact Registry optionally with a 8922 * customer managed encryption key. If specified, deployments will use 8923 * Artifact Registry. If unspecified and the deployment is eligible to use 8924 * Artifact Registry, GCF will create and use a repository named 8925 * 'gcf-artifacts' for every deployed region. This is the repository to which 8926 * the function docker image is pushed after it is built by Cloud Build. 8927 * It must match the pattern 8928 * `projects/{project}/locations/{location}/repositories/{repository}`. 8929 * Cross-project repositories are not supported. 8930 * Cross-location repositories are not supported. 8931 * Repository format must be 'DOCKER'. 8932 * </pre> 8933 * 8934 * <code>string docker_repository = 34 [(.google.api.resource_reference) = { ... }</code> 8935 * 8936 * @param value The bytes for dockerRepository to set. 8937 * @return This builder for chaining. 8938 */ setDockerRepositoryBytes(com.google.protobuf.ByteString value)8939 public Builder setDockerRepositoryBytes(com.google.protobuf.ByteString value) { 8940 if (value == null) { 8941 throw new NullPointerException(); 8942 } 8943 checkByteStringIsUtf8(value); 8944 dockerRepository_ = value; 8945 bitField0_ |= 0x80000000; 8946 onChanged(); 8947 return this; 8948 } 8949 8950 private int dockerRegistry_ = 0; 8951 /** 8952 * 8953 * 8954 * <pre> 8955 * Docker Registry to use for this deployment. 8956 * If `docker_repository` field is specified, this field is automatically 8957 * set as `ARTIFACT_REGISTRY`. 8958 * If unspecified, it currently defaults to `CONTAINER_REGISTRY`. 8959 * This field may be overridden by the backend for eligible deployments. 8960 * </pre> 8961 * 8962 * <code>.google.cloud.functions.v1.CloudFunction.DockerRegistry docker_registry = 35;</code> 8963 * 8964 * @return The enum numeric value on the wire for dockerRegistry. 8965 */ 8966 @java.lang.Override getDockerRegistryValue()8967 public int getDockerRegistryValue() { 8968 return dockerRegistry_; 8969 } 8970 /** 8971 * 8972 * 8973 * <pre> 8974 * Docker Registry to use for this deployment. 8975 * If `docker_repository` field is specified, this field is automatically 8976 * set as `ARTIFACT_REGISTRY`. 8977 * If unspecified, it currently defaults to `CONTAINER_REGISTRY`. 8978 * This field may be overridden by the backend for eligible deployments. 8979 * </pre> 8980 * 8981 * <code>.google.cloud.functions.v1.CloudFunction.DockerRegistry docker_registry = 35;</code> 8982 * 8983 * @param value The enum numeric value on the wire for dockerRegistry to set. 8984 * @return This builder for chaining. 8985 */ setDockerRegistryValue(int value)8986 public Builder setDockerRegistryValue(int value) { 8987 dockerRegistry_ = value; 8988 bitField1_ |= 0x00000001; 8989 onChanged(); 8990 return this; 8991 } 8992 /** 8993 * 8994 * 8995 * <pre> 8996 * Docker Registry to use for this deployment. 8997 * If `docker_repository` field is specified, this field is automatically 8998 * set as `ARTIFACT_REGISTRY`. 8999 * If unspecified, it currently defaults to `CONTAINER_REGISTRY`. 9000 * This field may be overridden by the backend for eligible deployments. 9001 * </pre> 9002 * 9003 * <code>.google.cloud.functions.v1.CloudFunction.DockerRegistry docker_registry = 35;</code> 9004 * 9005 * @return The dockerRegistry. 9006 */ 9007 @java.lang.Override getDockerRegistry()9008 public com.google.cloud.functions.v1.CloudFunction.DockerRegistry getDockerRegistry() { 9009 com.google.cloud.functions.v1.CloudFunction.DockerRegistry result = 9010 com.google.cloud.functions.v1.CloudFunction.DockerRegistry.forNumber(dockerRegistry_); 9011 return result == null 9012 ? com.google.cloud.functions.v1.CloudFunction.DockerRegistry.UNRECOGNIZED 9013 : result; 9014 } 9015 /** 9016 * 9017 * 9018 * <pre> 9019 * Docker Registry to use for this deployment. 9020 * If `docker_repository` field is specified, this field is automatically 9021 * set as `ARTIFACT_REGISTRY`. 9022 * If unspecified, it currently defaults to `CONTAINER_REGISTRY`. 9023 * This field may be overridden by the backend for eligible deployments. 9024 * </pre> 9025 * 9026 * <code>.google.cloud.functions.v1.CloudFunction.DockerRegistry docker_registry = 35;</code> 9027 * 9028 * @param value The dockerRegistry to set. 9029 * @return This builder for chaining. 9030 */ setDockerRegistry( com.google.cloud.functions.v1.CloudFunction.DockerRegistry value)9031 public Builder setDockerRegistry( 9032 com.google.cloud.functions.v1.CloudFunction.DockerRegistry value) { 9033 if (value == null) { 9034 throw new NullPointerException(); 9035 } 9036 bitField1_ |= 0x00000001; 9037 dockerRegistry_ = value.getNumber(); 9038 onChanged(); 9039 return this; 9040 } 9041 /** 9042 * 9043 * 9044 * <pre> 9045 * Docker Registry to use for this deployment. 9046 * If `docker_repository` field is specified, this field is automatically 9047 * set as `ARTIFACT_REGISTRY`. 9048 * If unspecified, it currently defaults to `CONTAINER_REGISTRY`. 9049 * This field may be overridden by the backend for eligible deployments. 9050 * </pre> 9051 * 9052 * <code>.google.cloud.functions.v1.CloudFunction.DockerRegistry docker_registry = 35;</code> 9053 * 9054 * @return This builder for chaining. 9055 */ clearDockerRegistry()9056 public Builder clearDockerRegistry() { 9057 bitField1_ = (bitField1_ & ~0x00000001); 9058 dockerRegistry_ = 0; 9059 onChanged(); 9060 return this; 9061 } 9062 9063 @java.lang.Override setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields)9064 public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { 9065 return super.setUnknownFields(unknownFields); 9066 } 9067 9068 @java.lang.Override mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)9069 public final Builder mergeUnknownFields( 9070 final com.google.protobuf.UnknownFieldSet unknownFields) { 9071 return super.mergeUnknownFields(unknownFields); 9072 } 9073 9074 // @@protoc_insertion_point(builder_scope:google.cloud.functions.v1.CloudFunction) 9075 } 9076 9077 // @@protoc_insertion_point(class_scope:google.cloud.functions.v1.CloudFunction) 9078 private static final com.google.cloud.functions.v1.CloudFunction DEFAULT_INSTANCE; 9079 9080 static { 9081 DEFAULT_INSTANCE = new com.google.cloud.functions.v1.CloudFunction(); 9082 } 9083 getDefaultInstance()9084 public static com.google.cloud.functions.v1.CloudFunction getDefaultInstance() { 9085 return DEFAULT_INSTANCE; 9086 } 9087 9088 private static final com.google.protobuf.Parser<CloudFunction> PARSER = 9089 new com.google.protobuf.AbstractParser<CloudFunction>() { 9090 @java.lang.Override 9091 public CloudFunction parsePartialFrom( 9092 com.google.protobuf.CodedInputStream input, 9093 com.google.protobuf.ExtensionRegistryLite extensionRegistry) 9094 throws com.google.protobuf.InvalidProtocolBufferException { 9095 Builder builder = newBuilder(); 9096 try { 9097 builder.mergeFrom(input, extensionRegistry); 9098 } catch (com.google.protobuf.InvalidProtocolBufferException e) { 9099 throw e.setUnfinishedMessage(builder.buildPartial()); 9100 } catch (com.google.protobuf.UninitializedMessageException e) { 9101 throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); 9102 } catch (java.io.IOException e) { 9103 throw new com.google.protobuf.InvalidProtocolBufferException(e) 9104 .setUnfinishedMessage(builder.buildPartial()); 9105 } 9106 return builder.buildPartial(); 9107 } 9108 }; 9109 parser()9110 public static com.google.protobuf.Parser<CloudFunction> parser() { 9111 return PARSER; 9112 } 9113 9114 @java.lang.Override getParserForType()9115 public com.google.protobuf.Parser<CloudFunction> getParserForType() { 9116 return PARSER; 9117 } 9118 9119 @java.lang.Override getDefaultInstanceForType()9120 public com.google.cloud.functions.v1.CloudFunction getDefaultInstanceForType() { 9121 return DEFAULT_INSTANCE; 9122 } 9123 } 9124